summaryrefslogtreecommitdiff
path: root/src/libstrongswan/plugins/pkcs1/pkcs1_builder.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstrongswan/plugins/pkcs1/pkcs1_builder.c')
-rw-r--r--src/libstrongswan/plugins/pkcs1/pkcs1_builder.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/libstrongswan/plugins/pkcs1/pkcs1_builder.c b/src/libstrongswan/plugins/pkcs1/pkcs1_builder.c
index 766832d39..f64294783 100644
--- a/src/libstrongswan/plugins/pkcs1/pkcs1_builder.c
+++ b/src/libstrongswan/plugins/pkcs1/pkcs1_builder.c
@@ -75,6 +75,13 @@ static public_key_t *parse_public_key(chunk_t blob)
KEY_BLISS, BUILD_BLOB_ASN1_DER, blob, BUILD_END);
goto end;
}
+ else if (oid == OID_ED25519)
+ {
+ /* Need the whole subjectPublicKeyInfo for Ed25519 public keys */
+ key = lib->creds->create(lib->creds, CRED_PUBLIC_KEY,
+ KEY_ED25519, BUILD_BLOB_ASN1_DER, blob, BUILD_END);
+ goto end;
+ }
else
{
/* key type not supported */
@@ -259,7 +266,7 @@ end:
* }
*
* While the parameters and publicKey fields are OPTIONAL, RFC 5915 says that
- * paramaters MUST be included and publicKey SHOULD be.
+ * parameters MUST be included and publicKey SHOULD be.
*/
static bool is_ec_private_key(chunk_t blob)
{