Jump to content

Tvheadend work from VLC but not from Emby: HttpException: Unauthorized


Recommended Posts

Posted

Hi there all, 

I have set the TVheadend into a Qnap docker (I'll put on a NUC when will arrive) 

and all the think is work nice via VLC on my PC. 

 

I don't use the TVheadend plugin because I want my personal m3u file with all the order that I use for all programs. 

The problem is that same m3u file it's work on the PC VLC but this is not work in the Emby TV (via TV Source Setup > m3u) 

I put here the piece of the log that cause the problem: 

2023-02-06 12:15:14.149 Error MediaSourceManager: Error opening live stream
*** Error Report ***
Version: 4.7.11.0
Command line: /share/CACHEDEV1_DATA/.qpkg/EmbyServer/system/EmbyServer.dll -programdata /share/CACHEDEV1_DATA/.qpkg/EmbyServer/programdata -ffdetect /share/CACHEDEV1_DATA/.qpkg/EmbyServer/bin/ffdetect -ffmpeg /share/CACHEDEV1_DATA/.qpkg/EmbyServer/bin/ffmpeg -ffprobe /share/CACHEDEV1_DATA/.qpkg/EmbyServer/bin/ffprobe -defaultdirectory /share/CACHEDEV1_DATA/Public -updatepackage emby-server-qnap_{version}_x86_64.qpkg -noautorunwebapp
Operating system: Linux version 5.10.60-qnap (root@U16BuildServer117) (x86_64-QNAP-linux-gnu-gcc (toolchain config: [gcc-4.9.2 binutils-2.25 glibc-2.21]) 4.9.2, GNU ld
Framework: .NET 6.0.8
OS/Process: x64/x64
Runtime: share/CACHEDEV1_DATA/.qpkg/EmbyServer/system/System.Private.CoreLib.dll
Processor count: 4
Data path: /share/CACHEDEV1_DATA/.qpkg/EmbyServer/programdata
Application path: /share/CACHEDEV1_DATA/.qpkg/EmbyServer/system
MediaBrowser.Model.Net.HttpException: MediaBrowser.Model.Net.HttpException: Unauthorized
at Emby.LiveTV.EmbyTV.GetChannelStreamWithDirectStreamProvider(BaseItem dbChannel, String providerChannelId, String streamId, List`1 currentLiveStreams, CancellationToken cancellationToken)
at Emby.LiveTV.LiveTvManager.GetChannelStream(String id, String mediaSourceId, List`1 currentLiveStreams, CancellationToken cancellationToken)
at Emby.Server.Implementations.Library.MediaSourceManager.OpenLiveStreamInternal2(LiveStreamRequest request, CancellationToken cancellationToken)
Source: Emby.Server.Implementations
TargetSite: Void MoveNext()
2023-02-06 12:15:14.150 Error Server: Error processing request
*** Error Report ***
Version: 4.7.11.0
Command line: /share/CACHEDEV1_DATA/.qpkg/EmbyServer/system/EmbyServer.dll -programdata /share/CACHEDEV1_DATA/.qpkg/EmbyServer/programdata -ffdetect /share/CACHEDEV1_DATA/.qpkg/EmbyServer/bin/ffdetect -ffmpeg /share/CACHEDEV1_DATA/.qpkg/EmbyServer/bin/ffmpeg -ffprobe /share/CACHEDEV1_DATA/.qpkg/EmbyServer/bin/ffprobe -defaultdirectory /share/CACHEDEV1_DATA/Public -updatepackage emby-server-qnap_{version}_x86_64.qpkg -noautorunwebapp
Operating system: Linux version 5.10.60-qnap (root@U16BuildServer117) (x86_64-QNAP-linux-gnu-gcc (toolchain config: [gcc-4.9.2 binutils-2.25 glibc-2.21]) 4.9.2, GNU ld
Framework: .NET 6.0.8
OS/Process: x64/x64
Runtime: share/CACHEDEV1_DATA/.qpkg/EmbyServer/system/System.Private.CoreLib.dll
Processor count: 4
Data path: /share/CACHEDEV1_DATA/.qpkg/EmbyServer/programdata
Application path: /share/CACHEDEV1_DATA/.qpkg/EmbyServer/system
MediaBrowser.Model.Net.HttpException: MediaBrowser.Model.Net.HttpException: Unauthorized
at Emby.LiveTV.EmbyTV.GetChannelStreamWithDirectStreamProvider(BaseItem dbChannel, String providerChannelId, String streamId, List`1 currentLiveStreams, CancellationToken cancellationToken)
at Emby.LiveTV.LiveTvManager.GetChannelStream(String id, String mediaSourceId, List`1 currentLiveStreams, CancellationToken cancellationToken)
at Emby.Server.Implementations.Library.MediaSourceManager.OpenLiveStreamInternal2(LiveStreamRequest request, CancellationToken cancellationToken)
at Emby.Server.Implementations.Library.MediaSourceManager.OpenLiveStreamInternal2(LiveStreamRequest request, CancellationToken cancellationToken)
at Emby.Server.Implementations.Library.MediaSourceManager.OpenLiveStreamInternal(LiveStreamRequest request, CancellationToken cancellationToken)
at Emby.Server.Implementations.Library.MediaSourceManager.OpenLiveStream(LiveStreamRequest request, CancellationToken cancellationToken)
at Emby.Server.MediaEncoding.Api.MediaInfoService.OpenMediaSource(OpenMediaSource request, CancellationToken cancellationToken)
at Emby.Server.MediaEncoding.Api.MediaInfoService.GetPlaybackInfo(GetPostedPlaybackInfo request, CancellationToken cancellationToken)
at Emby.Server.MediaEncoding.Api.MediaInfoService.Post(GetPostedPlaybackInfo request)
at Emby.Server.Implementations.Services.ServiceController.GetTaskResult(Task task)
at Emby.Server.Implementations.Services.ServiceHandler.ProcessRequestAsync(HttpListenerHost appHost, IRequest httpReq, IResponse httpRes, RestPath restPath, String responseContentType, CancellationToken cancellationToken)
at Emby.Server.Implementations.HttpServer.HttpListenerHost.RequestHandler(IRequest httpReq, ReadOnlyMemory`1 urlString, ReadOnlyMemory`1 localPath, CancellationToken cancellationToken)
Source: Emby.Server.Implementations
TargetSite: Void MoveNext()
2023-02-06 12:15:14.150 Info Server: http/1.1 Response 500 to host2. Time: 4ms. http://emby_remote_ip/emby/Items/178098/PlaybackInfo?UserId=ae98c12de99d4cc4a95d5107d7451b28&StartTimeTicks=0&IsPlayback=true&AutoOpenLiveStream=true&MaxStreamingBitrate=3465000&X-Emby-Client=Emby Web&X-Emby-Device-Name=Google Chrome Windows&X-Emby-Device-Id=ed79bbb8-21b0-4f34-9c07-1925b497433d&X-Emby-Client-Version=4.7.11.0&X-Emby-Language=en-us&reqformat=json
2023-02-06 12:15:19.230 Info Server: http/1.1 POST http://emby_remote_ip/emby/Sessions/Capabilities/Full?X-Emby-Client=Emby Web&X-Emby-Device-Name=Google Chrome Windows&X-Emby-Device-Id=ed79bbb8-21b0-4f34-9c07-1925b497433d&X-Emby-Client-Version=4.7.11.0&X-Emby-Language=en-us&reqformat=json. UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/109.0.0.0 Safari/537.36
2023-02-06 12:15:19.231 Info Server: http/1.1 Response 204 to host2. Time: 1ms. http://emby_remote_ip/emby/Sessions/Capabilities/Full?X-Emby-Client=Emby Web&X-Emby-Device-Name=Google Chrome Windows&X-Emby-Device-Id=ed79bbb8-21b0-4f34-9c07-1925b497433d&X-Emby-Client-Version=4.7.11.0&X-Emby-Language=en-us&reqformat=json

 

I'm not so linux guru but I think that this is the cause: 

MediaBrowser.Model.Net.HttpException: MediaBrowser.Model.Net.HttpException: Unauthorized

The file m3u have this type of records inside: 

#EXTINF:-1 tvg-logo="http://odmsto.com/uploads/tv_image/sm/canale-5-3lle0v8ngp9r.png" group-title="ITA PROVE" tvg-chno="5",Canale5 HD TEST
http://myuser:mypass@192.168.1.168:9981/stream/channelid/447723412?profile=pass

 

And in the TVheadset I have the settings > Authentication type: Both plain and digest

The Qnap and my PC is on the same LAN (1gb). 

 

Can anyone please help me with some ideea please ? 

Thanks in advance 

Denis

 

 

 

  • 2 weeks later...
Posted

No one can help me with this issue please ? 

Thanks again 

Denis

Posted

The forum search feature is quite good.  This can get you started on the right track.

 

Posted

Before to post my issue I have read all thread of TVH...

So in your sample I didn't find the resolution to my problem. 

Also I didn't want to use TVH with out authorization, this because my THV will be open outside of my LAN. 

So I must use Emby with a link m3u using the user:pass method. 

 

Thanks for the help 

Denis

 

Posted
2 hours ago, denisj said:

 

So I must use Emby with a link m3u using the user:pass method. 

 

Thanks for the help 

Denis

 

Thanks for following up with the solution.

Posted
2 hours ago, denisj said:

Before to post my issue I have read all thread of TVH...

So in your sample I didn't find the resolution to my problem. 

Also I didn't want to use TVH with out authorization, this because my THV will be open outside of my LAN. 

So I must use Emby with a link m3u using the user:pass method. 

 

Thanks for the help 

Denis

 

Unless something changed recently Emby does not reauthenticate the session with TVH when using m3u tuner. I don't know if it even authenticated the initial connection when using credentials, I can't remember. If you must have authentication then you use the plug-in.

OR

Create the no-auth account in TVH for the m3u tuner AND restrict access to that account by allowing only the Emby server IP address to connect without credentials. This is built-in to TVH.

Posted
1 hour ago, Q-Droid said:

Create the no-auth account in TVH for the m3u tuner AND restrict access to that account by allowing only the Emby server IP address to connect without credentials. This is built-in to TVH.

This can be a greate idea 🙂 

I just need to understand how to do it... 

Thanks a lot for the help 

Denis

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...