It is hidden in the SubjectPublicKeyInfo
, there should be a subjectPublicKey in there somewhere
{:SubjectPublicKeyInfo,
{:AlgorithmIdentifier, {1, 2, 840, 113549, 1, 1, 1}, <<5, 0>>},
<<48, 130, 1, 10, 2, 130, 1, 1, 0, 168, 183, 5, 117, 87, 21, 236, 119, 68,
58, 139, 108, 52, 186, 12, 62, 16, 251, 224, 37, 245, 122, 60, 220, 129,
243, 110, 136, ...>>}, :asn1_NOVALUE, :asn1_NOVALUE,
The <<48, 130, 1, 10 ...>>
is the DER encoded public key I think. So then public_key:der_decode(:"RSAPublicKey", DerValue)