SSH2: make it so you can verify server public host key without logging on

This commit is contained in:
terrafrost 2014-06-16 10:19:34 -05:00
parent c05cfe4c10
commit 5f56781261
1 changed files with 7 additions and 0 deletions

View File

@ -3625,6 +3625,13 @@ class Net_SSH2
*/
function getServerPublicHostKey()
{
if (!($this->bitmap & NET_SSH2_MASK_CONSTRUCTOR)) {
$this->bitmap |= NET_SSH2_MASK_CONSTRUCTOR;
if (!$this->_connect()) {
return false;
}
}
$signature = $this->signature;
$server_public_host_key = $this->server_public_host_key;