From 8ec220f3ed7e6c3f8c00671fea3cafff486b42ab Mon Sep 17 00:00:00 2001 From: goncalo-frade-iohk Date: Sat, 16 Dec 2023 15:02:07 +0000 Subject: [PATCH] fix: bug with header and footer of ed25519 and x25519 pem keys --- .../Apollo/Sources/Model/Ed25519Key+Exportable.swift | 4 ++-- AtalaPrismSDK/Apollo/Sources/Model/X25519Key+Exportable.swift | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/AtalaPrismSDK/Apollo/Sources/Model/Ed25519Key+Exportable.swift b/AtalaPrismSDK/Apollo/Sources/Model/Ed25519Key+Exportable.swift index 2327e3cf..7ee55129 100644 --- a/AtalaPrismSDK/Apollo/Sources/Model/Ed25519Key+Exportable.swift +++ b/AtalaPrismSDK/Apollo/Sources/Model/Ed25519Key+Exportable.swift @@ -4,7 +4,7 @@ import Foundation extension Ed25519PrivateKey: ExportableKey { var pem: String { PEMKey( - keyType: "EC PRIVATE KEY", + keyType: "PRIVATE KEY", keyData: raw ).pemEncoded() } @@ -32,7 +32,7 @@ extension Ed25519PrivateKey: ExportableKey { extension Ed25519PublicKey: ExportableKey { var pem: String { PEMKey( - keyType: "EC PRIVATE KEY", + keyType: "PRIVATE KEY", keyData: raw ).pemEncoded() } diff --git a/AtalaPrismSDK/Apollo/Sources/Model/X25519Key+Exportable.swift b/AtalaPrismSDK/Apollo/Sources/Model/X25519Key+Exportable.swift index b95759a1..4fc73cfc 100644 --- a/AtalaPrismSDK/Apollo/Sources/Model/X25519Key+Exportable.swift +++ b/AtalaPrismSDK/Apollo/Sources/Model/X25519Key+Exportable.swift @@ -4,7 +4,7 @@ import Foundation extension X25519PrivateKey: ExportableKey { var pem: String { PEMKey( - keyType: "EC PRIVATE KEY", + keyType: "PRIVATE KEY", keyData: raw ).pemEncoded() } @@ -32,7 +32,7 @@ extension X25519PrivateKey: ExportableKey { extension X25519PublicKey: ExportableKey { var pem: String { PEMKey( - keyType: "EC PRIVATE KEY", + keyType: "PRIVATE KEY", keyData: raw ).pemEncoded() }