.NET Based OPC UA Client/Server SDK  2.6.1.422
UnifiedAutomation.UaBase.RsaUtils Class Reference

Defines functions to implement RSA cryptography. More...

Static Public Member Functions

static int GetPlainTextBlockSize (X509Certificate2 encryptingCertificate, bool useOaep)
 Return the plaintext block size for RSA OAEP encryption. More...
 
static int GetCipherTextBlockSize (X509Certificate2 encryptingCertificate, bool useOaep)
 Return the ciphertext block size for RSA OAEP encryption. More...
 
static int Pkcs15Sha1_GetSignatureLength (X509Certificate2 signingCertificate)
 Returns the length of a RSA PKCS#1 v1.5 signature of a SHA1 digest. More...
 
static byte[] Pkcs15Sha1_Sign (ArraySegment< byte > dataToSign, X509Certificate2 signingCertificate)
 Computes an RSA/SHA1 PKCS#1 v1.5 signature. More...
 
static bool Pkcs15Sha1_Verify (ArraySegment< byte > dataToVerify, byte[] signature, X509Certificate2 signingCertificate)
 Verifies an RSA/SHA1 PKCS#1 v1.5 signature. More...
 
static int Pkcs15Sha256_GetSignatureLength (X509Certificate2 signingCertificate)
 Returns the length of a RSA PKCS#1 v1.5 signature of a SHA256 digest. More...
 
static byte[] Pkcs15Sha256_Sign (ArraySegment< byte > dataToSign, X509Certificate2 signingCertificate)
 Creates an RSA PKCS#1 v1.5 signature of a SHA256 for the stream. More...
 
static bool Pkcs15Sha256_Verify (ArraySegment< byte > dataToVerify, byte[] signature, X509Certificate2 signingCertificate)
 Verifies an RSA PKCS#1 v1.5 signature of a SHA256 for the stream. More...
 
static byte[] Encrypt (byte[] dataToEncrypt, X509Certificate2 encryptingCertificate, bool useOaep)
 Encrypts the data using RSA PKCS#1 v1.5 encryption. More...
 
static ArraySegment< byte > Encrypt (ArraySegment< byte > dataToEncrypt, X509Certificate2 encryptingCertificate, bool useOaep, ArraySegment< byte > outputBuffer)
 Encrypts the data using RSA PKCS#1 v1.5 or OAEP encryption. More...
 
static byte[] Decrypt (ArraySegment< byte > dataToDecrypt, X509Certificate2 encryptingCertificate, bool useOaep)
 Decrypts the data using RSA PKCS#1 v1.5 encryption. More...
 
static ArraySegment< byte > Decrypt (ArraySegment< byte > dataToDecrypt, X509Certificate2 encryptingCertificate, bool useOaep, ArraySegment< byte > outputBuffer)
 Decrypts the message using RSA OAEP encryption. More...
 

Detailed Description

Defines functions to implement RSA cryptography.

Member Function Documentation

static byte [] UnifiedAutomation.UaBase.RsaUtils.Decrypt ( ArraySegment< byte >  dataToDecrypt,
X509Certificate2  encryptingCertificate,
bool  useOaep 
)
inlinestatic

Decrypts the data using RSA PKCS#1 v1.5 encryption.

static ArraySegment<byte> UnifiedAutomation.UaBase.RsaUtils.Decrypt ( ArraySegment< byte >  dataToDecrypt,
X509Certificate2  encryptingCertificate,
bool  useOaep,
ArraySegment< byte >  outputBuffer 
)
inlinestatic

Decrypts the message using RSA OAEP encryption.

static byte [] UnifiedAutomation.UaBase.RsaUtils.Encrypt ( byte[]  dataToEncrypt,
X509Certificate2  encryptingCertificate,
bool  useOaep 
)
inlinestatic

Encrypts the data using RSA PKCS#1 v1.5 encryption.

static ArraySegment<byte> UnifiedAutomation.UaBase.RsaUtils.Encrypt ( ArraySegment< byte >  dataToEncrypt,
X509Certificate2  encryptingCertificate,
bool  useOaep,
ArraySegment< byte >  outputBuffer 
)
inlinestatic

Encrypts the data using RSA PKCS#1 v1.5 or OAEP encryption.

static int UnifiedAutomation.UaBase.RsaUtils.GetCipherTextBlockSize ( X509Certificate2  encryptingCertificate,
bool  useOaep 
)
inlinestatic

Return the ciphertext block size for RSA OAEP encryption.

static int UnifiedAutomation.UaBase.RsaUtils.GetPlainTextBlockSize ( X509Certificate2  encryptingCertificate,
bool  useOaep 
)
inlinestatic

Return the plaintext block size for RSA OAEP encryption.

static int UnifiedAutomation.UaBase.RsaUtils.Pkcs15Sha1_GetSignatureLength ( X509Certificate2  signingCertificate)
inlinestatic

Returns the length of a RSA PKCS#1 v1.5 signature of a SHA1 digest.

static byte [] UnifiedAutomation.UaBase.RsaUtils.Pkcs15Sha1_Sign ( ArraySegment< byte >  dataToSign,
X509Certificate2  signingCertificate 
)
inlinestatic

Computes an RSA/SHA1 PKCS#1 v1.5 signature.

static bool UnifiedAutomation.UaBase.RsaUtils.Pkcs15Sha1_Verify ( ArraySegment< byte >  dataToVerify,
byte[]  signature,
X509Certificate2  signingCertificate 
)
inlinestatic

Verifies an RSA/SHA1 PKCS#1 v1.5 signature.

static int UnifiedAutomation.UaBase.RsaUtils.Pkcs15Sha256_GetSignatureLength ( X509Certificate2  signingCertificate)
inlinestatic

Returns the length of a RSA PKCS#1 v1.5 signature of a SHA256 digest.

static byte [] UnifiedAutomation.UaBase.RsaUtils.Pkcs15Sha256_Sign ( ArraySegment< byte >  dataToSign,
X509Certificate2  signingCertificate 
)
inlinestatic

Creates an RSA PKCS#1 v1.5 signature of a SHA256 for the stream.

static bool UnifiedAutomation.UaBase.RsaUtils.Pkcs15Sha256_Verify ( ArraySegment< byte >  dataToVerify,
byte[]  signature,
X509Certificate2  signingCertificate 
)
inlinestatic

Verifies an RSA PKCS#1 v1.5 signature of a SHA256 for the stream.


The documentation for this class was generated from the following file: