Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Third-party m3u8 and mpd files are being redirected #13

Open
verone0001 opened this issue Apr 11, 2024 · 3 comments
Open

Third-party m3u8 and mpd files are being redirected #13

verone0001 opened this issue Apr 11, 2024 · 3 comments

Comments

@verone0001
Copy link

verone0001 commented Apr 11, 2024

Hello!

Since the update, I found that every m3u8 link embedded into a player in a website, let's say jwplayer, is being redirected to the extension, so instead of having an iframe displaying such player to play the file, the iframe loads it directly with the extension. This would normally work for a common m3u8 link, but no when the given link needs widevine keys to play.

Before, I just used to delete to content of DNR rules, keeping it blank but enabled. This allowed me to redirect the m3u8's only when entered into the address bar, and for any other website there was no redirection (expected behavior). Thing is that after a recent update (the one coming with the new GUI), this is not possible anymore.

I've tried to change these options making use of excludedDomains and this worked, but since it was not only needed for a single website, it was not quite the solution. Then I tried with an empty array of domains, as well as making use of domainType, but the expected was still not achievable. I have gone through the declarativeNetRequest docs but could not solve this.

What I would want to happen is to be able to only redirect those links when they are directly entered manually into the address bar. There must be no redirection when the link is embedded into an external player in a website (iframe). Is there any solution for this?

Edit: Expected behavior is found for example in version 4.0.1.

Edit 2: After trial and error, it seems that I managed to have the expected working by adding another condition like following:

"initiatorDomains": ["localhost"]

 
Thanks in advance.

@Palethorn
Copy link
Owner

Hello @verone0001, the use case is hard for me to imagine and replicate. Do you have an example of such site or at least a code snippet of the embedded streaming URL so that I can try to reproduce this?

The struggle with the new manifest and DNR rules gave me headaches for months until I got it in some kind of working order, and the extension is still acting unpredictable. Regex support differs from browser to browser, and it's quite excruciating to keep the behaviour consistent. Manifest permissions are still a mistery to me.

@verone0001
Copy link
Author

Hello @Palethorn,

Sure, here is an example. The m3u8 should play with JWPlayer, but when the extension is enabled, the url is redirected to be opened with chrome-extension, which will cause loading fail as there is no direct m3u8 file to read. The same happens with mpd files.

Example of the extension behavior once enabled and after performing the steps mentioned at the beginning:
chrome-extension://cjfbmleiaobegagekpmlhmaadepdeedn/index.html#https://conywhan.bar/star.html?get=https://live-ftc-na-south-2.media.starott.com/clt2/va01/starplus/event/2024/05/07/Miami_Marlins_vs_Los_Ange_20240507_1715041815091/ctr-all-complete.m3u8&img=https://prod-ripcut-delivery.disney-plus.net/v1/variant/star/F8E5529DA1DD358E289067BF94D2F31FA779C77494C09F75B8CB4C809E4AD311/scale?width=1920&aspectRatio=1.78&format=jpeg&key=26861671be3c4242878379a06afcedc0&key2=b2ec7929500b251127d190c8692f0ce8

The only workaround I found in the meantime was to download and uncompress an old version of the working extension in this use case (v.4.0.1), and load it unpacked. Note I'm using Chrome.

@Palethorn
Copy link
Owner

OK, I see the problem, I'll try to fix it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants