FAQ  •  Register  •  Login

Login to Media Browser fails with rewrite to https

<<

i-matrixx

Serviio newbie

Posts: 3

Joined: Fri Jan 11, 2013 8:04 am

Post Fri Jan 11, 2013 8:57 am

Login to Media Browser fails with rewrite to https

Hi all,

I´ve successfully installed serviio and in the next step I wanted to give the MediaBrowser a try.
My users must access the MediaBrowser through apache mod_proxy which I have configured according to viewtopic.php?f=5&t=6852&p=49666#p49850. In addition I have configured apache to rewrite every http request to https.
This seems to be a problem as no one is able to sign in to the MediaBrowser.

As I can see in chrome developer tools the URL http://www.example.net/cds/login is requested when the button 'Sign in' is pressed and the Status is (canceled).
The rewrite seems to break to communication. To prove my assumption I configured apache NOT to rewrite every http request to https and everything works fine.

I wondered why only the request to /cds/login was http and found out the 'http://' used for the request is hard coded in media-browser.js.

  Code:
var folderListUrl = "http://"
      + host
      + "/cds/browse/flv_player/{folderId}/BrowseDirectChildren/containers/0/0?authToken={token}";
var folderItemsUrl = "http://"
      + host
      + "/cds/browse/flv_player/{folderId}/BrowseDirectChildren/items/{offset}/{limit}?authToken={token}";
var itemMetadataUrl = "http://"
      + host
      + "/cds/browse/flv_player/{objectId}/BrowseMetadata/all/0/1?authToken={token}";

var loginUrl = "http://" + host + "/cds/login";
var logoutUrl = "http://" + host + "/cds/logout";


Why is the http:// hard coded inside the media-browser.js? Isn´t it better and even correct to use location.protocol?

I was wondering nobody else had this issue before, but I couldn´t find any post. Hope this can be solved, as I am not willing to sacrifice https communication.

Thanks for any help!

Regards

Ingo
Last edited by i-matrixx on Thu Jan 17, 2013 6:50 am, edited 1 time in total.
<<

zip

User avatar

Serviio developer / Site Admin

Posts: 17212

Joined: Sat Oct 24, 2009 12:24 pm

Location: London, UK

Post Sat Jan 12, 2013 3:45 pm

Re: Login to Media Browser fails with rewrite to https

Looks a reasonable request. please file a bitbucket ticket.
<<

r-win

User avatar

DLNA master

Posts: 100

Joined: Sun May 22, 2011 6:16 am

Location: Lelystad, Netherlands

Post Sat Jan 12, 2013 6:33 pm

Login to Media Browser fails with rewrite to https

i-matrixx wrote:I was wondering nobody else had this issue before, but I couldn´t find any post. Hope this can be solved, as I am not willing to sacrifice https communication.

Actually, I had the same issue before, but I had it fixed in my local copy of the mediabrowser jar, but then I forgot to file a report. Sorry about that!
Linksys WRT320N | Samsung PS-50C7700 | Microsoft XBOX 360 | Windows 8.1 | Linux Ubuntu 13.04
<<

jeffshead

Serviio newbie

Posts: 15

Joined: Sun Sep 30, 2012 9:49 pm

Post Wed Jan 16, 2013 4:32 pm

Re: Login to Media Browser fails with rewrite to https

r-win wrote:Actually, I had the same issue before, but I had it fixed in my local copy of the mediabrowser jar, but then I forgot to file a report. Sorry about that!


How did you fix this? Can I use something like ClikView to edit the file? What are the code edits?

Also, if this change is made, is only the login done via https or does the stream also use https?

Actually, how can this work with SSL (port 443) when the port for MediaBrowser is 23424?
<<

i-matrixx

Serviio newbie

Posts: 3

Joined: Fri Jan 11, 2013 8:04 am

Post Thu Jan 17, 2013 7:01 am

Re: Login to Media Browser fails with rewrite to https

Actually, how can this work with SSL (port 443) when the port for MediaBrowser is 23424?


Seems you have skiped a important passage in my post .
My users must access the MediaBrowser through apache mod_proxy which I have configured according to viewtopic.php?f=5&t=6852&p=49666#p49850. In addition I have configured apache to rewrite every http request to https.


This only applys if you access the MediaBrowser through apache with mod_proxy and rewrite to https.
The file to edit is located in the serviio-media-browser.jar. I think it´s best to keep your hands off this if your are not knowing how to do.
I´ve opend a ticket issue/624 and I am sure this will get fixed in the next version.

Return to Serviio Support & Help

Who is online

Users browsing this forum: No registered users and 34 guests

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software for PTF.