Skip to content

error:06000066:public key routines:OPENSSL_internal:DECODE_ERROR #183

@akabisdev

Description

@akabisdev

Hello,

I am trying to use the following code snippet, i am trying to use this for mobile device

var publicKey = """
-----BEGIN PUBLIC KEY-----
MMKCASI......xxxxxxxx
-----END PUBLIC KEY-----
""";
var keyData = PemCodec(PemLabel.publicKey).decode(publicKey);

 var key = await RsaOaepPublicKey.importSpkiKey(
        keyData,
        Hash.sha256,
      );


I am getting the following exception :
FormatException: error:06000066:public key routines:OPENSSL_internal:DECODE_ERROR

Any suggestion if i missed anything or anything wrong in the approach?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions