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 Login #375

Open
def-mycroft opened this issue Dec 21, 2016 · 14 comments
Open

Unable to Login #375

def-mycroft opened this issue Dec 21, 2016 · 14 comments

Comments

@def-mycroft
Copy link

def-mycroft commented Dec 21, 2016

Hello,

I'm just installed this on Ubuntu 16.04. Can't login.

I'm able to input my username / password and skip the two-factor authentication, and get no message after logging in. Using "geeknote logout" after login attempt returns "you are already logged out."

Thanks!!

Edit: One thing I should note is that I recently reinstalled my Ubuntu installation, clearing all old files. I wonder if there is an issue there with the geeknote/evernote connection because it previously had a connection? It has been a few months since I've used geeknote.

@shaunpatel
Copy link

Also had the same issue. I use geek note regularly and normally do not have to enter username/password information. However, I was prompted to do so today and was unable to login successfully, even after setting up two-factor auth. Did something change with Evernote?

@def-mycroft
Copy link
Author

One thing I should note is that I recently reinstalled my Ubuntu installation, clearing all old files. I wonder if there is an issue there with the geeknote/evernote connection because it previously had a connection? It has been a few months since I've used geeknote.

@jeffkowalski
Copy link

Likely duplicate of #372

@def-mycroft
Copy link
Author

def-mycroft commented Dec 22, 2016 via email

@DataThinkMonkey
Copy link

I have the same issue on Fedora 25 and Ubuntu 16.10 both new installs. 2 Factor is disable, however I am prompted. I press enter at 2nd auth request, script ends with no error and I am not logged in.

@karimone
Copy link

karimone commented Jan 2, 2017

The error seems the handling of the response. Something is changed on evernote oauth.

Here the code that trigger the two factor authentication https://github.com/VitaliyRodnenko/geeknote/blob/master/geeknote/oauth.py#L232

We should check the oauth process if still working as expected (here to test https://dev.evernote.com/doc/articles/authentication.php)

@aprouzeau
Copy link

I have the same issue on Mac OS Sierra. I activate 2 factor auth, and it doesn't display any errors, but I am not logged in.

@pipakin
Copy link

pipakin commented Jan 10, 2017

(Copied from #372)

#374

This should fix it. It was a csrf token failure. Evernote was outputting two csrf token hidden fields that needed to be sent along with the request.

Or alternatively feel free to just use my branch. It doesn't look like pull requests have been accepted here for some time.

@pipakin
Copy link

pipakin commented Jan 10, 2017

My fix should also work for tfa, though I don't have it enabled, so I can't prove that.

@rgutzen
Copy link

rgutzen commented Jan 17, 2017

@pipakin: Had the same problem (as first time user), no tfa, and with your fix it works fine. Thanks!

@adrcad
Copy link

adrcad commented Apr 10, 2017

@pipakin : Same problem (login), cherry-picked your fix and worked fine ! Thanks a lot !

@NGenetzky
Copy link

Does not work with 2FA. @pipakin

Login:       
Password: 
Two-Factor Authentication Code: 566771  
    : Allow Access...Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/geeknote-0.2a-py2.7.egg/geeknote/geeknote.py", line 883, in main
    User().login(**ARGS)
  File "/usr/local/lib/python2.7/dist-packages/geeknote-0.2a-py2.7.egg/geeknote/geeknote.py", line 35, in wrappe
r
    return func(*args, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/geeknote-0.2a-py2.7.egg/geeknote/geeknote.py", line 397, in login
    if self.getEvernote().auth():
  File "/usr/local/lib/python2.7/dist-packages/geeknote-0.2a-py2.7.egg/geeknote/geeknote.py", line 151, in auth
    self.authToken = GNA.getToken()
  File "/usr/local/lib/python2.7/dist-packages/geeknote-0.2a-py2.7.egg/geeknote/oauth.py", line 140, in getToken
    self.allowAccess()
  File "/usr/local/lib/python2.7/dist-packages/geeknote-0.2a-py2.7.egg/geeknote/oauth.py", line 251, in allowAccess
    token = "&" + urlencode({ 'csrfBusterToken': tree.xpath("//input[@name='csrfBusterToken']/@value")[0]}) + "&" + urlencode({ 'csrfBusterToken': tree.xpath("//input[@name='csrfBusterToken']/@value")[1]})
IndexError: list index out of range

@ticklemynausea
Copy link

Hi. I could enter my user and password, but it kept asking me my mfa codes (which I didn't even had enabled). I enabled mfa in evernote, and still it doesn't work. Username and password is correctly validated, though. If I don't enter the correct details, I don't get the mfa prompt.

@ejsexton82
Copy link

Lines 232 - 234 are wrong. Logging in successfully always seems to result in a 302 redirect now, so that can no longer be used as an indicator of whether Two-Factor Authentication is required or not. I commented out those lines for now, and was able to login successfully:

 # if response.status == 302:
     # the user has enabled two factor auth
     # return self.handleTwoFactor()

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