1
0
mirror of https://github.com/danog/phpseclib.git synced 2024-12-04 18:48:24 +01:00

Merge branch '1.0' into 3.0

This commit is contained in:
terrafrost 2021-09-28 09:00:00 -05:00
commit 13b5ad9593

View File

@ -227,8 +227,8 @@ abstract class OpenSSH
$key = Strings::packSSH2('sssNss', 'none', 'none', '', 1, $publicKey, $paddedKey);
$key = "openssh-key-v1\0$key";
return "-----BEGIN OPENSSH PRIVATE KEY-----\r\n" .
chunk_split(Base64::encode($key), 70) .
"-----END OPENSSH PRIVATE KEY-----";
return "-----BEGIN OPENSSH PRIVATE KEY-----\n" .
chunk_split(Base64::encode($key), 70, "\n") .
"-----END OPENSSH PRIVATE KEY-----\n";
}
}