|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2009-02-08 12:15 UTC] mikesul@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Oct 27 17:00:01 2025 UTC |
Description: ------------ The bundled libssh2 in CVS fails to work under Windows. You can connect, but the function "ssh2_auth_pubkey_file" fails always. If you use the latest libssh2, you can use this function without a problem. BTW: your PHP versions are out of date (I'm using 5.2.8). Reproduce code: --------------- <?php $connection = ssh2_connect('shell.example.com', 22, array('hostkey'=>'ssh-rsa')); if (ssh2_auth_pubkey_file($connection, 'username', '/home/username/.ssh/id_rsa.pub', '/home/username/.ssh/id_rsa', 'secret')) { echo "Public Key Authentication Successful\n"; } else { die('Public Key Authentication Failed'); } ?> Expected result: ---------------- on my server: I expect "Public Key Authentication Successful" Actual result: -------------- A warning that the authentication failed and "Public Key Authentication Failed"