Reading .pem files for secured

Dukc ajieskola at gmail.com
Thu Jun 6 11:08:18 UTC 2019


On Friday, 31 May 2019 at 12:17:14 UTC, Sebastiaan Koppe wrote:
> On Friday, 31 May 2019 at 10:35:46 UTC, Dukc wrote:
>> But then came a problem that I need to feed the key from .pem 
>> to initialize RSA class.
>
> Just base64 decode the PEM data (without the ====) and feed it 
> to RSA.this(ubyte[] publicKey). Ought to be that simple.

We were both wrong :-). It turned out that the correct way to 
initialize a SecureD RSA private key is to feed contents of .pem 
in without ANY processing.




More information about the Digitalmars-d-learn mailing list