Connection lost, but only a couple of channels

I'm out of ideas unless you have an ad blocker or it's your AV software.
When I try Three I get redirected to fullscreen.nz and cloudfront gives me a 403 error (geo-blocked, I'm sure). But trying One and Two both redirect me directly to cloudfront.net

May be worth trying a different DNS provider to test, like one of the QUAD DNS servers.

Thanks. I did try Google's DNS servers and still the same outcome. Tried again with Jellyfin and works fine.

Got to be something that Channels is doing differently to all the others - I just don't know what :weary:

Are you using Matt's Raw m3u8?
I can view some of the channels (which I guess aren't geo-blocked) from that one.

Yes raw is what I'm using. Since I'm from NZ so nothing should be geo blocked.

I also tried Matt's Kodi links and had the same issue, all work except TVNZ channels.

looks like there was same issue here some time ago:

I wonder if Channels adds a referrer header when following the redirect and cloudfront is blocking that?

@Brad1
You could try adding the final url directly
https://dz1g25geip0uq.cloudfront.net/master.m3u8
See if that plays in Channels

UPDATE:
Did a little experiment

If i added a referrer header, i get the same 403 error.
Without, i get the playlist fine

@tmm1
Do you know if any referrer header is added on redirects in Channels?
Will a "Referrer-Policy: no-referrer" help on my side when returning redirects?

I recall Kodi had the same issue at some stage so I started adding "referrer:" to the piped kodi headers to force it to not send it.

Actually, I PRd to remove that here:

Turn off CURLOPT_AUTOREFERER

I don't believe this would work for Channels though?

1 Like

Matt, thanks for jumping in and helping.

That's VERY interesting. Firstly, I couldn't import the cloudfront m3u8 directly into Channels Sources, got an error. Imported the raw IPTV link into iptveditor, manually changed the source for TV1 from mjh.nz to cloudfront:

I imported the playlist into Channels using iptveditor link. TV3 worked as per above, TV2 failed as per above
BUT.... this time TV1 worked!
So the direct cloudfront link (via iptveditor) worked great!

2025/06/09 21:25:48.795339 [TNR] Opened connection to M3U-CloudfrontTestviaIPTVEditor for ch3 Three
2025/06/09 21:25:48.795339 [HLS] Starting live stream for channel 3 from 192.168.88.9 (bitrate=8461kbps)
2025/06/09 21:25:49.559468 [HLS] Session ch3-dANY-ip192.168.88.9 started in 764.1285ms
2025/06/09 21:25:49.657149 [HLS] Probed live stream in 861.1466ms: h264 1920x1080 progressive 3809753bps
2025/06/09 21:25:56.698708 [HLS] Stopping transcoder session ch3-dANY-ip192.168.88.9 (out=14.388s finished=false first_seq=1 last_seq=7)
2025/06/09 21:25:56.699212 [TNR] Closed connection to M3U-CloudfrontTestviaIPTVEditor for ch3 Three
2025/06/09 21:25:56.703167 [SNR] Buffer statistics for ch3 Three: buf=0% drop=0%
2025/06/09 21:25:56.703167 [SNR] Streaming statistics for ch3 Three: timeouts=0 segment_timeouts=0 playlist_timeouts=0
2025/06/09 21:26:00.671630 [ERR] Failed to start stream for ch2: M3U: Could not fetch playlist from i.mjh.nz: GET: https://i.mjh.nz/.r/tvnz-2.m3u8: 403 Forbidden
2025/06/09 21:26:00.680505 [HLS] Couldn't generate master playlist for ch2-dANY-ip192.168.88.9: M3U: Could not fetch playlist from i.mjh.nz: GET: https://i.mjh.nz/.r/tvnz-2.m3u8: 403 Forbidden
2025/06/09 21:26:00.680505 [HLS] Stopping transcoder session ch2-dANY-ip192.168.88.9 (out=0s finished=false first_seq=0 last_seq=-1)
2025/06/09 21:26:12.121904 [TNR] Opened connection to M3U-CloudfrontTestviaIPTVEditor for ch1 TVNZ 1
2025/06/09 21:26:12.121904 [HLS] Starting live stream for channel 1 from 192.168.88.9 (bitrate=3281kbps)
2025/06/09 21:26:12.882905 [HLS] Session ch1-dANY-ip192.168.88.9 started in 761.0014ms
2025/06/09 21:26:12.972889 [HLS] Probed live stream in 850.4772ms: h264 1280x720 progressive 1771303bps
2025/06/09 21:26:21.981711 [HLS] Stopping transcoder session ch1-dANY-ip192.168.88.9 (out=13.418667s finished=false first_seq=1 last_seq=7)
2025/06/09 21:26:21.982249 [TNR] Closed connection to M3U-CloudfrontTestviaIPTVEditor for ch1 TVNZ 1
2025/06/09 21:26:21.986322 [SNR] Buffer statistics for ch1 TVNZ 1: buf=0% drop=0%
2025/06/09 21:26:21.986322 [SNR] Streaming statistics for ch1 TVNZ 1: timeouts=0 segment_timeouts=0 playlist_timeouts=0

@matthuisman here is the crazy thing. I have zero issues getting tvnz1 and tvnz2 using the raw m3u. However I have never been able to get Three, Duke, or Eden to work. Do you have those direct urls so I could test this theory on those channels?

you can get the direct urls by just loading the i.mjh.nz url

You must virtually be in NZ :laughing:

Sorry to be a pain but how you get the direct link by "loading" the mjh.nz url?

If I can get direct TVNZ1, TVNZ2 and Duke I think all my problems are solved haha

put it in a web browser and see what url it redirects you to.

Just prompts to download a file

Ohh I figured out a way to find the cloudfront links. I used VideoDownloadHelper in FF to find the details.

TVNZ1:
https://dz1g25geip0uq
TVNZ2:
https://d5qh9kd2mz71z
Duke:
https://d32ubfwfcm754e

@matthuisman do these cloudfront links update often? If load them into Channels will I have to constantly update them?

Ahh, yes. Unless you use a browser (like Brave) that tells you where the file is being downloaded from,
Capture
you would have to use your browser network inspector to see the location in the response header of the 302 redirect from mjh.nz
Capture2
or look at the redirected get
Capture3
FF will let you copy the Download url for saved downloads
Capture4

Bing - thats why i use redirects so your links dont get outdated.
I think nz urls dont change that often so might be safe,
But i dont want to be constantly asked when they change.

id rather we work with @tmm1 to figure out why the redirects are not working.
I still suspect referer header is being added?

1 Like

Next time just use https://inspectstream.theoplayer.com

Somebody should make a docker out of it.

Have you tried the latest dvr pre-release?

Sounds like it might be related to your issue, just saying

No I hadn't but I just installed the latest pre-release 2025.06.10.1557, re-started, held my breath and.... sadly let it out again. Still the same error :frowning:

2025/06/11 11:06:40.153543 [ERR] Failed to start stream for ch2: M3U: Could not fetch playlist from i.mjh.nz: GET: https://i.mjh.nz/.r/tvnz-2.m3u8: 403 Forbidden
2025/06/11 11:06:40.153543 [HLS] Couldn't generate stream playlist for ch2-dANY-ip127.0.0.1: M3U: Could not fetch playlist from i.mjh.nz: GET: https://i.mjh.nz/.r/tvnz-2.m3u8: 403 Forbidden
2025/06/11 11:06:40.153543 [HLS] Stopping transcoder session ch2-dANY-ip127.0.0.1 (out=0s finished=false first_seq=0 last_seq=-1)
1 Like

:man_shrugging: well, it sounded good