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

Unable to log in via username+password #209

Closed
wasrek404 opened this issue Feb 3, 2016 · 14 comments
Closed

Unable to log in via username+password #209

wasrek404 opened this issue Feb 3, 2016 · 14 comments

Comments

@wasrek404
Copy link

I tried to use livestreamer-twitch-gui version 0.11.2 application on a host running Arch linux. Installed it trough yaourt. The login dialogue appears and I can enter password and username but after Clicking the login button it changes to "Logging in..." Thats were it just sits. I can stop the logging process but I cant view any data linked to my account. Am I doing something wrong or is something else happening here (or not). Feel free to ask for any info! Oh and btw the login on the website works!

Are you able to help me with that?

Kind regards,

wasrek

@bastimeyer
Copy link
Member

I can't re-login either, my used OAuth token is still valid, though...

There seems to be something wrong on Twitch's end, I think. The GUI's auth system has not been changed in one of the last releases. The application's client-id is also still valid (it is still listed in my account's connections).

But when I try to login, it says

Oops! We encountered an unexpected error logging you in. Please try again.

without redirecting me after my successful login attempt.

I really hope they didn't change anything and this is just temporary. They could have either disabled my client-id or have changed anything in their auth system, I'm not sure.
The GUI for instance doesn't use a HTTP redirect url for the OAuth flow, but a NW.js specific protocol instead, so maybe something broke here. This would be catastrophic though and I would need to quickly rewrite the auth system and release a new version.

You're still able to log in by directly using an oauth token.
Advanced settings need to be enabled for this first (top of the settings menu). Then go to the user menu and click the Use access token button. OAuth tokens are application independent, which means you can use one that's been generated by another app. Just make sure, that these oauth-scopes are being requested by the app's client-id which is generating the token.

@bastimeyer bastimeyer changed the title unable to log in using Arch Unable to log in via username+password Feb 3, 2016
@bastimeyer
Copy link
Member

Now I also get the error message

Please complete the CAPTCHA correctly.

And there is no captcha in the login form...

@wasrek404
Copy link
Author

Sometimes I do get the captcha but I can assure you, filling it in correctly does not slove this :)

@undu
Copy link

undu commented Feb 3, 2016

I'm having the same problem.

When I de-authorize the app, instead of hanging when trying to log in, it goes correctly to the authorize page and it hangs when I click on "Authorize".
Afterwards Twitch connection's page shows the app is connected.

Maybe the response from the server is not parsed correctly?

BTW, how can I generate such OAuth token?

@Hayatory
Copy link

Hayatory commented Feb 3, 2016

Whenever I try to Log in, I can sometimes get to the 'Authorize' button but clicking it, Authorizes it through the Twitch website, yet does nothing in the client and the login page times out, Other times i try and login and it eventually times out and or the captcha expires.

@bastimeyer
Copy link
Member

Maybe the response from the server is not parsed correctly?

There is no server response at all... What you are seeing in the auth window is the default Twitch application login form on their website. When you enter your username and password, it should redirect your browser to the specified return-URL (see here) with the token and scopes as parameters. But as you can see, it does not redirect and instead shows an error message. Why it is doing this, I can't tell.

BTW, how can I generate such OAuth token?

You can use a token generated by any registered app. These are the required scopes...

There are a few services out there which let you login via their client-id so you can get an oauth token. But these services only set the chat_login scope, so you're not able to use the token in the GUI.
I haven't found another service yet which sets all the required scopes...

If you want to register your own app with your own client-id, you also need your own return-url and set up a webserver as well.

@bastimeyer
Copy link
Member

I have created a thread on the twitch dev forums, since I haven't seen any auth related issues today.
Let's hope this will get fixed soon...

@kussii
Copy link

kussii commented Feb 4, 2016

Error
There was an error while trying to display this page.

Name
HTTP Error
Message
Service Unavailable
Detail
Unable to retrieve stream summary
Status
503
Host
api.twitch.tv
Path
kraken/streams/summary

cant login, how can i get a OAuth token from another app?

@bastimeyer
Copy link
Member

Detail
Unable to retrieve stream summary
Status
503

This is completely unrelated to this issue... It is just a boringly normal API request fail.
Please don't bloat this thread with this kind of stuff. Thanks.

how can i get a OAuth token from another app?

This depends on the app/service you are using. I made the token accessible, because people requested it, so they could use the same login on multiple devices. Other developers may not see the need in that, simply don't care or see it as a security risk, whatever.
Just use Google (twitch access token, etc.). I can't help you with that, I don't know any other apps/services with this kind of feature and the same required OAuth scopes.

I'm going to reimplement the AuthService if this issue is still not fixed after the weekend. I don't know if I'm able to do this in time though, since I'm a little bit busy right now...

@Gaaamin
Copy link

Gaaamin commented Feb 4, 2016

Hello!
First, i would say your app is very good, keep-up the good work Bastimeyer!

I have the same problem as everyone here for a few days now, i tried to log in with the 2 possible ways, but it failed. I hope it will be fixed easy and fast.

@krivchnik
Copy link

Hey, I'm usuing your API too (and, btw, it's awesome, ty for that). But I also have this issue. I installed new version yesterday and up to this moment thought it was my fault that I could'n login) Anyway, I have had this message popped once: "Oops! We encountered an unexpected error logging you in. Please try again.". I guess it might be helpful (or not). Good luck with your other projects and fixing this issue)

@bastimeyer
Copy link
Member

I have just reimplemented the authentication system. The work has not been merged into the master branch yet, as I want to verify that everything is working correctly on all systems first.

So far, it's running fine on all my systems, but I'd like to know if there are any potential issues with the local webserver that's being started, like issues with the Windows firewall for instance.

The changes are on the auth-reimplementation branch and these are the commands for cloning the repo and running the application:

git clone -b auth-reimplementation https://github.com/bastimeyer/livestreamer-twitch-gui.git
cd livestreamer-twitch-gui
npm install -g grunt-cli bower
npm install
grunt metadata less:source run:src

More infos about building the app can be found here.

Now, before you're able to run this, you first need to change the app's client-id. The current client-id still has the old redirect-url set, so Twitch will reject the configuration that's being used. This will be changed once I know that everything is working.

Until then, please apply this patch first client-id.patch.zip (deleted). Unpack the file and run git apply client-id.patch before running the grunt command. This will replace the client-id with a temporarily registered one that has the proper redirect-url set, so the auth system is able to work.

Thank you very much for helping!

@mikeparadinas
Copy link

So how can a find my acces token,
any easy methods?

@bastimeyer
Copy link
Member

Ok, I decided to merge this. I don't see anything odd, even on Windows. This should be good to go...

A new release containing these changes will be uploaded soon.
Reopening the thread for visibility...

@bastimeyer bastimeyer reopened this Feb 6, 2016
@bastimeyer
Copy link
Member

https://github.com/bastimeyer/livestreamer-twitch-gui/releases/tag/v0.12.0

If there are any new issues related to the authentication, please open another thread. Thanks.

@streamlink streamlink locked and limited conversation to collaborators Feb 6, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

8 participants