PHP  
downloads | documentation | faq | getting help | mailing lists | reporting bugs | php.net sites | links | my php.net 
search for in the  
<ssh2_auth_nonessh2_auth_pubkey_file>
Last updated: Mon, 16 Jul 2012

ssh2_auth_password

(PECL)

ssh2_auth_password --  Authenticate over SSH using a plain password

Description

bool ssh2_auth_password ( resource session, string username, string password )

Authenticate over SSH using a plain password

例子 1. Authenticating with a password

<?php
$connection
= ssh2_connect('shell.example.com', 22);

if (
ssh2_auth_password($connection, 'username', 'secret')) {
  echo
"Authentication Successful!\n";
} else {
  die(
'Authentication Failed...');
}
?>



<ssh2_auth_nonessh2_auth_pubkey_file>
 Last updated: Mon, 16 Jul 2012
 
Copyright © 2001-2005 The PHP Group
All rights reserved.
This unofficial mirror is operated at: http://manual.phpv.net/
Last updated: Thu Jul 7 19:13:47 2005 CST