zoomyboy/php-ssh

There is no license information available for the latest version (1.0.18) of this package.

Ssh WWrapper around PhpSecLib

1.0.18 2020-07-16 14:56 UTC

This package is auto-updated.

Last update: 2024-12-17 01:37:45 UTC


README

Check login

You can check if ssh credentials are valid - either with Password authentication or with PubKe authentication

use Zoomyboy\PhpSsh\Client;

$sshValid = Client::auth($host, $user) ->withPassword($password) ->check(); $sshValid = Client::auth($host, $user) ->withKeyFile($keyFile) ->check();

The Key file has to be an absolute path to your private key filelogin.

If you really want to connect, you can use the connect method: $sshValid = Client::auth($host, $user) ->withKeyFile($keyFile) ->connect();