Two-factor not working #139

Closed
nevins-b opened this Issue Feb 25, 2013 · 6 comments

Projects

None yet

3 participants

@nevins-b

Hi there,
It appears that Paramiko does not work with "RequiredAuthentications2 publickey,password" option in OpenSSH_5.3p1 on Centos 6.3.

Looking at the logs it appears that it sends on authentication type but never sends the other:

sshd[16481]: Accepted password for test from 1.1.1.1 port 57946 ssh2
sshd[16482]: dispatch_protocol_error: type 90 seq 5

@nevins-b

some more information:

DEB [20130225-09:38:58.599] thr=1 paramiko.transport: userauth is OK
INF [20130225-09:39:04.189] thr=1 paramiko.transport: Authentication continues...
DEB [20130225-09:39:04.189] thr=1 paramiko.transport: Methods: ['password']
DEB [20130225-09:39:04.290] thr=1 paramiko.transport: EOF in transport thread

@nevins-b

my mistake, I was initializing the private key incorrectly.

@nevins-b nevins-b closed this Feb 25, 2013
@nevins-b

I'm going to reopen this:

On like 454 of clients.py
it should be: allowed_types = self._transport.auth_publickey(username, key)

https://github.com/paramiko/paramiko/blob/master/paramiko/client.py#L454

@nevins-b nevins-b reopened this Feb 25, 2013
@perryjrandall
Contributor

In addition to that line... The lines having (allowed_types == ['password']) should be rewritten ('password' in allowed_types) which I have addressed in my fork. Please let me know if this is useful to you

Fork:
https://github.com/perryjrandall/paramiko
Pull Req:
#467

@bitprophet
Member

Linking this to #412 in case they're the same issue (sounds like probably)

@bitprophet
Member

Rolling this into #467

@bitprophet bitprophet closed this Nov 4, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment