diff --git a/phpseclib/Crypt/EC/Formats/Keys/PKCS8.php b/phpseclib/Crypt/EC/Formats/Keys/PKCS8.php index b678545e..fa7ed457 100644 --- a/phpseclib/Crypt/EC/Formats/Keys/PKCS8.php +++ b/phpseclib/Crypt/EC/Formats/Keys/PKCS8.php @@ -223,7 +223,7 @@ abstract class PKCS8 extends Progenitor null, $password, $curve instanceof Ed25519 ? 'id-Ed25519' : 'id-Ed448', - $curve->encodePoint($publicKey) + "\0" . $curve->encodePoint($publicKey) ); }