[gst-devel] Playbin unable to play http stream
Ron McOuat
rmcouat at smartt.com
Wed Feb 24 07:05:05 CET 2010
I added user authentication to souphttpsrc around Nov 2008 when there
was no means to provide basic or digest authentication on direct access
to a URL and souphttpsrc did not accept the http://user@password
embedded format either and still does not. I had a strong need for this
capability in my own work. Looking at the libsoup documentation it
looked like it was possible to service error code
SOUP_STATUS_PROXY_AUTHENTICATION_REQUIRED in the same callback routine
as regular authentication SOUP_STATUS_UNAUTHORIZED both of which are in
function gst_soup_http_src_authenticate_cb() so I added properties
proxy_id and proxy_pw to the souphttpsrc element properties to source
the values for proxy authentication. Unless libsoup reads the
environment for these values and could do proxy authentication
automatically I know I didn't put the code in to read the environment to
pick up the properties from there instead of from the added element
properties. In retrospect using the environment is likely a better
approach because proxy settings are often a system setting. I also have
limited ability to test this since proxy is not part of my environment.
I suppose setting up squid is all that is really needed and force a test
environment to use the squid setup. My workload has prevented me from
testing this further. Maybe the best approach is to file a bug report
and if there is someone better skilled at using a proxy environment to
find what is wrong with this? I believe libsoup has had a number of
issues with proxy over time but think that is not an issue now but don't
take my word for it, I was getting this from reading the libsoup
discussion area and not actual testing.
Going back to the URL in the original request I tried the gst-launch
command on a stock Ubuntu 9.10 Karmic system without a need for proxy
and the pipeline says it got EOS during preroll and did not display the
picture in a video sink which is not surprising since the URL content is
only a single JPG image. I would normally associate using gstreamer with
processing a sequence of video frames instead of just one image. Not to
discourage you from gstreamer but grabbing a single image frame looks
more like a file transfer job which libCurl you mention does quite well.
I probably just don't know what you want to do with the image content
after it is acquired so my comment is probably not valid.
Ron
On 10-02-23 8:52 PM, Debsu wrote:
> Hi Tim,
>
> You are right, that using souphttpsrc element is the better way of doing
> this. But in souphttpsrc element I am facing a strange problem.
> I am using playbin for display image which is nothing but a http source. But
> souphttpsrc gives me the error of "proxy-authentication failure" message,
> but http_proxy is already set in the environment variable. and also from
> commandline I can easily fetch that jpg file using libCurl.
>
> Regards,
> Deb
>
More information about the gstreamer-devel
mailing list