2016-11-14, 23:57
(2016-11-14, 22:04)Aristogiton Wrote: There is no simple way to change kodi user-agent. But it's unnecessary. You should try instead to recompile the filmon.pvr with this simple fix.
https://github.com/kodi-pvr/pvr.filmon/b...monAPI.cpp - line 217:
bool res = filmonRequest("tv/api/init?channelProvider=ipad&app_id=IGlsbSBuVCJ7UDwZBl0eBR4JGgEBERhRXlBcWl0CEw==");
should be
bool res = filmonRequest("tv/api/init?channelProvider=ipad&app_id=IGlsbSBuVCJ7UDwZBl0eBR4JGgEBERhRXlBcWl0CEw==|User-Agent=Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.9.0.3) Gecko/2008092417 Firefox/3.0.3");
or maybe better
bool res = filmonRequest("tv/api/init?channelProvider=ipad&app_id=IGlsbSBuVCJ7UDwZBl0eBR4JGgEBERhRXlBcWl0CEw==|User-Agent=Mozilla%2F5.0%20(Windows%3B%20U%3B%20Windows%20NT%205.1%3B%20en-GB%3B%20rv%3A1.9.0.3)%20Gecko%2F2008092417%20Firefox%2F3.0.3");
Hope this helps.
NOTE: en-GB is not the real trouble. User-agent has to be EXACTLY what I wrote. I really don't know why.
Hi new forum member here, I'm very interested in getting this resolved also.
Are you sure this is correct Aristogiton? Does the "|" symbol set the user_agent in kodi, as if you just add the user_agent switch when calling the filmon api you still get a 403 return (I can only get the json to return correctly if I manually in chrome change my user agent to be the one you first mentioned).
Drt1989, I can compile the code, but I'm not sure how to distribute it if we resolve this as I need to make it work for android and I'm not sure if it's the same code path for android/windows/ios etc.