Table of Contents

Class PEMCrypto

Namespace
SecureExchangesSDK.Helpers
Assembly
SecureExchangesSDK.NetCore.dll
public class PEMCrypto
Inheritance
PEMCrypto
Inherited Members
Extension Methods

Methods

ExportPrivateKey(RSA)

Export private (including public) key from RSA into OpenSSH PEM string slightly modified from https://stackoverflow.com/a/23739932/2860309

public static string ExportPrivateKey(RSA rsa)

Parameters

rsa RSA

Returns

string

ExportPublicKey(RSA)

Export public key from RSA into OpenSSH PEM string slightly modified from https://stackoverflow.com/a/28407693

public static string ExportPublicKey(RSA rsa)

Parameters

rsa RSA

Returns

string

ImportPrivateKey(string)

Import OpenSSH PEM private key string into RSA

public static RSA ImportPrivateKey(string pem)

Parameters

pem string

Returns

RSA

ImportPublicKey(string, RSA)

Import OpenSSH PEM public key string into RSA

public static RSA ImportPublicKey(string pem, RSA rsa)

Parameters

pem string
rsa RSA

Returns

RSA