1
0
mirror of https://github.com/danog/tgseclib.git synced 2024-11-26 20:24:39 +01:00

SSH2: update private key auth example

This commit is contained in:
terrafrost 2019-09-07 17:06:51 -05:00
parent eddbdcc66c
commit 8a03e90d95

View File

@ -24,9 +24,7 @@
* <?php
* include 'vendor/autoload.php';
*
* \phpseclib\Crypt\PublicKeyLoader::load('...');
* //$key->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)) {