remixz / umi

📺 Watch Crunchyroll together, and more
https://umi.party
127 stars 24 forks source link

Episodes not playing #18

Closed piapple1 closed 6 years ago

piapple1 commented 6 years ago

Recently some episodes will not play on Umi. It seems I have better luck getting it to work when I watch an episode I have watched before but that is not always the case.

MiraWaNeko commented 6 years ago

Seems like newer episodes are stored on vrv CDN servers which have more strict HTTP headers.

piapple1 commented 6 years ago

Hopefully it can be worked around. I just thought I should let the dev know because umi has been super great.

oozyluce commented 6 years ago

As of march 16th, me and my anime buddy have been having some similar issues, where either one of us gets stuck in an eternal "buffering" state. It's weird because sometimes i get stuck in that state, and sometimes its my friend that gets stuck. However in all cases at least one of us was able to stream episodes normally. We haven't been able to determine what seems to be causing it. DISCLAIMER This might be completely unrelated, but the animes that have been causing us trouble so far are Jormungand Season 1 Episode 2 and 3, as well as Terraformers Season 1 episode 1

remixz commented 6 years ago

Hey folks, @Chikachi is unfortunately correct that Crunchyroll/Ellation is (finally!) starting to actually secure their videos. I'm going to be looking for a workaround, as there's another site (a pirate site, but I digress) that's using a very similar method to Umi where it's using the video directly from Crunchyroll's servers, but it's still working for new content. However, they're doing some parsing on the server, so it's possible that it might not work for Umi.

I'm hesitant to collect any Crunchyroll credentials on the Umi servers, as I don't want there to be any possibility that they get leaked somehow. I believe I can make it as secure as I have with the MyAnimeList integration, but the difference there is that MAL accounts have much less sensitive info that could be leaked, and they officially support an API. My belief is that the system I've designed is secure, as it's pretty much how most secure cookie-based sessions work, but since I'm a 3rd party using a system that wasn't designed for external use, I don't want to accidentally leak anyone's credentials.

If I can't find a workaround that lets me keep everything on the client, then unfortunately Umi will slowly stop working as more content to moved to Crunchyroll's newer systems. I'll be completely honest and say I'm surprised it worked for this long. 😅 I'm guessing that it's the aforementioned pirate site that finally got Crunchyroll to start implementing changes, as it's pretty bad that a site could literally just steal content from Crunchyroll's server (i.e. the pirates don't have to pay anything for hosting the videos), and then also have their own ads on the page.

One possibility if Crunchyroll does break Umi in the browser is that I can make it a desktop app with Electron, as with that I can have it ignore any CORS errors. I may do that for myself, as I just prefer using Umi player over Crunchyroll's site. 😂 If I do, I'll release it and make it open source for anyone who really wants to use Umi player. There's also a possibility I could make a Chrome extension that would be a "helper extension", where basically all the network requests for Umi would go through the extension, as extensions can also ignore CORS errors. Both would definitely cut down on people using it though, since downloading stuff is a hassle, plus feels pretty fishy for something that takes in Crunchyroll credentials.

MiraWaNeko commented 6 years ago

If you decide to make a desktop app I'd definitely use it ^w^

remixz commented 6 years ago

Hey folks, I have a happy update: I've found a way to get Umi working again! 🎉 The catch is that it does require an extension, which you can download for Chrome https://chrome.google.com/webstore/detail/umi-enabler/ebpgknlgpomojokdkpgphjigniicjcgc or Firefox https://addons.mozilla.org/en-US/firefox/addon/umi-enabler/

I managed to figure out a way that I felt was safe enough to publish. Essentially, this extension is just modifying the response headers as they come in, so that it ignores the CORS errors. Extremely simple... yet effective! You can see the source here: https://github.com/remixz/umi/blob/master/extension/background.js

I'm going to leave this issue open for a bit longer, just in case people are still searching for a solution. Happy watching!

oozyluce commented 6 years ago

You're the man!!

piapple1 commented 6 years ago

Thank you!!