snobu / destreamer

Save Microsoft Stream videos for offline enjoyment.
MIT License
2.36k stars 441 forks source link

chromium login error message #326

Closed emmecirm closed 3 years ago

emmecirm commented 3 years ago

Hello! When I digit the command ./destreamer.sh -I "URL" I always got a login error page on chromium about my account. It seems that my microsoft account is not valid for login and I should use an organization one. How could I resolve it? Thanks in advance!

snobu commented 3 years ago

You may need to login at a different URL. How do you login usually to MS Stream? When the browser window pops up navigate to that page and once signed in destreamer will try to capture the session cookie.

emmecirm commented 3 years ago

You may need to login at a different URL. How do you login usually to MS Stream? When the browser window pops up navigate to that page and once signed in destreamer will try to capture the session cookie.

I was able to login with my email but it didn't work, both with teams login (http://teams.microsoft.com) and "login.microsoftonline.com". With the last url I'm into my office account and in both cases destreamer give me this error: TimeoutError: waiting for target failed: timeout 150000ms exceeded     at Object.waitWithTimeout (/Users/myname/destreamer/node_modules/puppeteer/lib/cjs/puppeteer/common/helper.js:224:26)     at Browser.waitForTarget (/Users/myname/destreamer/node_modules/puppeteer/lib/cjs/puppeteer/common/Browser.js:269:45)     at DoInteractiveLogin (/Users/myname/destreamer/build/src/destreamer.js:71:19)     at processTicksAndRejections (internal/process/task_queues.js:93:5)     at async main (/Users/myname/destreamer/build/src/destreamer.js:216:73)

snobu commented 3 years ago

After you login, can you navigate to the video page quickly see if that helps? If you video page URL is not web.microsoftstream.com/somethingwe may have a very different problem here, meaning your tenant has cloaked the URL destreamer expects to find.

See this - https://github.com/snobu/destreamer/blob/master/src/destreamer.ts#L84

After login, the video URL you end up with MUST end in microsoftstream.com. If it uses its own domain, just edit that line in destreamer.ts to reflect the domain your tenant uses and run npm run build again. You can also increase the timeout to give you a bit more breathing room, right now it's 150 seconds, hardcoded on the same line.

emmecirm commented 3 years ago

It hosted on sharepoint, it’s possible to download it?

snobu commented 3 years ago

So just SharePoint or is MSStream redirecting you to SharePoint?

Can you post the video URL here? Redact it however you see fit so this doesn't become a privacy concern.

emmecirm commented 3 years ago

https://uniroma2.sharepoint.com/:v:/r/sites/........./2009.02.2021.mp4?csf=1&web=1&e=Ad1kep

snobu commented 3 years ago

Sorry, no, we are unable to download from SharePoint.

emmecirm commented 3 years ago

Sorry, no, we are unable to download from SharePoint.

No chance in the future?

snobu commented 3 years ago

Maybe. No promises though.