From 8a03e90d953ecce2009db4ed3cbd6db6f6b529c4 Mon Sep 17 00:00:00 2001 From: terrafrost Date: Sat, 7 Sep 2019 17:06:51 -0500 Subject: [PATCH] SSH2: update private key auth example --- phpseclib/Net/SSH2.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/phpseclib/Net/SSH2.php b/phpseclib/Net/SSH2.php index f323ef00..c045db25 100644 --- a/phpseclib/Net/SSH2.php +++ b/phpseclib/Net/SSH2.php @@ -24,9 +24,7 @@ * setPassword('whatever'); - * $key->load(file_get_contents('privatekey')); + * $key = \phpseclib\Crypt\PublicKeyLoader::load('...', '(optional) password'); * * $ssh = new \phpseclib\Net\SSH2('www.domain.tld'); * if (!$ssh->login('username', $key)) {