I'm trying to parse public key with sshpk.parseKey(publicKeyString, 'pem') which has been created with algorithm: "ECDSA" and ecdsaCurve: "P256".
Key is of type:
-----BEGIN PUBLIC KEY-----
Blah-blah-blah
-----END PUBLIC KEY-----
When I'm trying to call sshpk.parseKey(publicKeyString, 'pem') and pass public key in publicKeyString it's working without error. But above code returns:
Type = ecdsa
Alg = undefined
Kty = undefined
Kid = undefined
Crv = undefined
Use = undefined
X = undefined
Y = undefined
So values X, Y and others are not initialized. Why all parameters are not initialized?
I'm trying to parse public key with
sshpk.parseKey(publicKeyString, 'pem')
which has been created with algorithm: "ECDSA" and ecdsaCurve: "P256". Key is of type: -----BEGIN PUBLIC KEY----- Blah-blah-blah -----END PUBLIC KEY-----When I'm trying to call sshpk.parseKey(publicKeyString, 'pem') and pass public key in publicKeyString it's working without error. But above code returns:
So values X, Y and others are not initialized. Why all parameters are not initialized?