mirror of
https://github.com/danog/phpseclib.git
synced 2024-12-04 10:38:12 +01:00
Merge branch '2.0' into 3.0
This commit is contained in:
commit
b1a1fb5a08
@ -2046,6 +2046,15 @@ class SSH2
|
||||
public function login($username, ...$args)
|
||||
{
|
||||
$this->auth[] = array_merge([$username], $args);
|
||||
|
||||
// try logging with 'none' as an authentication method first since that's what
|
||||
// PuTTY does
|
||||
if ($this->sublogin($username)) {
|
||||
return true;
|
||||
}
|
||||
if (!count($args)) {
|
||||
return false;
|
||||
}
|
||||
return $this->sublogin($username, ...$args);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user