note 117816 deleted from function.ssh2-connect by googleguy

From: Date: Thu, 13 Aug 2015 18:09:22 +0000
Subject: note 117816 deleted from function.ssh2-connect by googleguy
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-203338@lists.php.net to get a copy of this message
Note Submitter: whirlwind110 at 163 dot com ---- 打开一次连接后,只能密码错误三次,第四次将出现奇特的异常。 <?php $username="root"; $pwdarr = array('ad','adadsa','sdf575','xsdddr','fdgt56'); $target="xxx.xxx.xxx.xxx"; $connection=ssh2_connect($target,22); print("strating...\n"); foreach ($pwdarr as $password) { $stime=microtime(true); @ssh2_auth_password($connection,$username,$password); $etime=microtime(true); $time=$etime-$stime; print("$password\n共用时".$time."\n"); } ?> // Ubuntu 下 $ php ssh.php strating... ad 共用时1.6269960403442 adadsa 共用时2.2547791004181 sdf575 共用时2.1681230068207 段错误 (核心已转储)

« previous php.notes (#203338) next »