Susmit Sarkar created SSHD-1120:
-----------------------------------
Summary: Taking considerable time before PublickeyAuthenticator
being invoked
Key: SSHD-1120
URL: https://issues.apache.org/jira/browse/SSHD-1120
Project: MINA SSHD
Issue Type: Bug
Reporter: Susmit Sarkar
{code:java}
// code placeholder
// Login via winscp
final SSHDPasswordAuthenticator passwordAuthenticator = new
SSHDPasswordAuthenticator(config,final SSHDPasswordAuthenticator
passwordAuthenticator = new SSHDPasswordAuthenticator(config, policyInterface);
// Login via ssh terminal like PUTTY
SSHDPublicKeyAuthenticator publicKeyAuthenticator = new
SSHDPublicKeyAuthenticator(config, policyInterface);
sshdServer.setPublickeyAuthenticator(publicKeyAuthenticator);
sshdServer.setPasswordAuthenticator(passwordAuthenticator);
-------------------------------------------------------
Case 1 // During winscp and filezilla
public class SSHDPasswordAuthenticator extends UserAuthPassword implements
PasswordAuthenticator {
public boolean authenticate(String username, String password, ServerSession
session)public boolean authenticate(String username, String password,
ServerSession session) throws AsyncAuthException,
PasswordChangeRequiredException {
}
}
-------------------------------------------------------
Case 2 // During SSH TERMINAL like PUTTY
public class SSHDPublicKeyAuthenticator implements PublickeyAuthenticator {
public boolean authenticate(String username, PublicKey key, ServerSession
session) throws AsyncAuthException {public boolean authenticate(String
username, PublicKey key, ServerSession session) throws AsyncAuthException {
-------------------------------------------------------------------
Case 2 is quite slow it gets stuck before the authenticate is being called.
On debugging found that:
@Override
public void messageReceived(IoSession ioSession, Object message) throws
Exception{
org.apache.sshd.common.io.IoSession session = getSession(ioSession);
Readable ioBuffer = MinaSupport.asReadable((IoBuffer) message);
handler.messageReceived(session, ioBuffer);
}
is causing to delay/stuck state. Am i doing anything wrong ?{code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]