inherits from TInterfacedObject
implements iIFKey
destructor Destroy; override;
property Scheme: tIFScheme read GetScheme write SetScheme;
property N: iDSInteger read GetN write SetN;
property E: iDSInteger read GetE write SetE;
iSignKey is listed beside iSignKeyIF (here and in tIFPrivateKey) because Supports and as find only the interfaces a class lists, never their ancestors: a key listing iSignKeyIF alone does not answer iSignKey.
constructor CreateFromKey(aSource: iIFPublicKey);
destructor Destroy; override;
function Validate(const aPriv: iIFPrivateKey): Boolean;
inherits from Exception
(no public members)
inherits from Exception
(no public members)
inherits from eDSIException
Integer-factorisation (RSA) branch of the DSI exception hierarchy - see eDSIError in StreamSec.DSI.ArithTypes.
(no public members)
inherits from eDSIIFC
The requested tHashAlgorithm has no implementation linked into the application (FindHashClass returned nil), or is too weak / not permitted for the encoding method that asked for it.
(no public members)
inherits from eDSIIFC
An external (HSM / PKCS#11 / CryptoAPI) key failed the private-key operation. There is no software fallback: the private exponent is not in this process.
(no public members)
inherits from eDSIIFC
An IEEE P1363 / PKCS#1 encoding or decoding method failed a size or consistency check.
(no public members)
constructor CreateFromKey(aSource: iIFPrivateKey);
procedure Clear;
procedure IFRSAKeys(aBitSize : UInt32; aReprType : Byte; aKind : tIFKeyGenerationKind; var aPubl : iIFPublicKey; aTerminate : tGetTerminate = nil);
procedure IFRSAPublicKey(var aPubl : iIFPublicKey; aCompatibility: Boolean);
procedure IFRWKeys(aBitSize : Cardinal; aReprType : Byte; aStrongPrimes: Boolean; var aPubl : iIFPublicKey);
function Validate(const aPubl: iIFPublicKey): Boolean; overload;
function Validate(const aPublicKey: iUnknown): Boolean; overload;
property ReprType: Byte read GetReprType write SetReprType;
property D: iDSInteger read GetD write SetD;
property P: iDSInteger read GetP write SetP;
property Q: iDSInteger read GetQ write SetQ;
property D1: iDSInteger read GetD1 write SetD1;
property D2: iDSInteger read GetD2 write SetD2;
property C: iDSInteger read GetC write SetC;
property ExternalKey: tExternalIFPrivateKey read GetExtKey write SetExtKey;
inherits from TInterfacedObject
implements iDSIIF, iTrailerField, iIFDecryptionRFC8017
constructor Create;
function NewPrivateKey: iIFPrivateKey;
function NewPrivateKeyFrom(const aSource: iIFPrivateKey): iIFPrivateKey;
function NewPublicKey: iIFPublicKey;
function NewPublicKeyFrom(const aSource: iIFPublicKey): iIFPublicKey;
function GetEncodingRangeEME1(aKeyBits : Cardinal; aHashAlgorithm: tHashAlgorithm; var aMaxBytes : Integer) : Boolean;
function GetEncodingRangeEME_PKCS1_v1_5(aKeyBits : Cardinal; var aMaxBytes: Integer) : Boolean;
procedure RSAKeys(aBitSize : UInt32; aReprType : Byte; aKind : tIFKeyGenerationKind; var aPriv : iIFPrivateKey; var aPubl : iIFPublicKey; aTerminate: tGetTerminate = nil);
procedure RSAPublicKey(const aPriv : iIFPrivateKey; var aPubl : iIFPublicKey; aCompatibility: Boolean = False);
procedure RWKeys(aBitSize : UInt32; aReprType : Byte; aStrongPrimes: Boolean; var aPriv : iIFPrivateKey; var aPubl : iIFPublicKey);
function ValidatePrivateKey(const aPriv: iIFPrivateKey; const aPubl: iIFPublicKey) : Boolean;
function SSASignatureGeneration(const aKey : iIFPrivateKey; const aDigest : tBytes; aOffset, aCount : Integer; aHashAlgorithm : tHashAlgorithm; aMGFHashAlgorithm: tHashAlgorithm; aSaltLen : Cardinal; aEncoding : tSignEncoding; aNullMsg : Boolean; var aSign : tBytes) : Integer; overload;
function SSASignatureGeneration(const aKey : iIFPrivateKey; aDigest : pByteArray; aCount : Integer; aHashAlgorithm : tHashAlgorithm; aMGFHashAlgorithm: tHashAlgorithm; aSaltLen : Cardinal; aEncoding : tSignEncoding; aNullMsg : Boolean; var aSign : tBytes) : Integer; overload;
function SSASignatureGeneration(const aKey : iIFPrivateKey; const aDigest : tBytes; aHashAlgorithm : tHashAlgorithm; aMGFHashAlgorithm: tHashAlgorithm; aSaltLen : Cardinal; aEncoding : tSignEncoding; aNullMsg : Boolean; var aSign : tBytes) : Integer; overload;
function SSASignatureGeneration(const aKey : iIFPrivateKey; const aMsg : tBytes; aOffset, aCount : Integer; aHashAlgorithm : tHashAlgorithm; aMGFHashAlgorithm: tHashAlgorithm; aSaltLen : Cardinal; aEncoding : tSignEncoding; var aSign : tBytes) : Integer; overload;
function SSASignatureGeneration(const aKey : iIFPrivateKey; const aMsg : tBytes; aHashAlgorithm : tHashAlgorithm; aMGFHashAlgorithm: tHashAlgorithm; aSaltLen : Cardinal; aEncoding : tSignEncoding; var aSign : tBytes) : Integer; overload;
function SSASignatureVerification(const aKey : iIFPublicKey; const aDigest : tBytes; aDOffset, aDCount : Integer; const aSign : tBytes; aSOffset, aSCount : Integer; aHashAlgorithm : tHashAlgorithm; aMGFHashAlgorithm: tHashAlgorithm; aSaltLen : Cardinal; aEncoding : tSignEncoding;
function SSASignatureVerification(const aKey : iIFPublicKey; const aDigest : tBytes; const aSign : tBytes; aHashAlgorithm : tHashAlgorithm; aMGFHashAlgorithm: tHashAlgorithm; aSaltLen : Cardinal; aEncoding : tSignEncoding; aNullMsg : Boolean) : Boolean; overload;
function SSASignatureVerification(const aKey : iIFPublicKey; const aMsg : tBytes; aMOffset, aMCount : Integer; const aSign : tBytes; aSOffset, aSCount : Integer; aHashAlgorithm : tHashAlgorithm; aMGFHashAlgorithm: tHashAlgorithm; aSaltLen : Cardinal; aEncoding : tSignEncoding)
function SSASignatureVerification(const aKey : iIFPublicKey; const aMsg : tBytes; const aSign : tBytes; aHashAlgorithm : tHashAlgorithm; aMGFHashAlgorithm: tHashAlgorithm; aSaltLen : Cardinal; aEncoding : tSignEncoding) : Boolean; overload;
procedure Encryption(const aKey : iIFPublicKey; const aMsg : tBytes; aMOffset, aMCount : Integer; const aP : tBytes; aPOffset, aPCount : Integer; aHashAlgorithm : tHashAlgorithm; aMGFHashAlgorithm: tHashAlgorithm; aEncryptEncoding : tEncryptEncoding; var aEMsg : tBytes); overload;
procedure Encryption(const aKey : iIFPublicKey; const aMsg : tBytes; aOffset, aCount : Integer; aHashAlgorithm : tHashAlgorithm; aEncryptEncoding: tEncryptEncoding; var aEMsg : tBytes); overload;
function Decryption(const aKey : iIFPrivateKey; const aEMsg : tBytes; aEOffset, aECount : Integer; const aP : tBytes; aPOffset, aPCount : Integer; aHashAlgorithm : tHashAlgorithm; aMGFHashAlgorithm: tHashAlgorithm; aEncryptEncoding : tEncryptEncoding; var aMsg : tBytes)
function Decryption(const aKey : iIFPrivateKey; const aEMsg : tBytes; aOffset, aCount : Integer; aHashAlgorithm : tHashAlgorithm; aEncryptEncoding: tEncryptEncoding; var aMsg : tBytes) : Boolean; overload;
function Decryption(const aKey : iIFPrivateKey; const aEMsg : tBytes; aOffset, aCount : Integer; aHashAlgorithm : tHashAlgorithm; aEncryptEncoding: tEncryptEncoding; var aMsg : iSecretKey) : Boolean; overload;
function DecryptionRFC8017(const aKey : iIFPrivateKey; const aEMsg : tBytes; aEOffset, aECount : Integer; const aP : tBytes; aPOffset, aPCount : Integer; aHashAlgorithm : tHashAlgorithm; aMGFHashAlgorithm: tHashAlgorithm; aEncryptEncoding : tEncryptEncoding; var aMsg : tBytes)
function SignatureAlgEMSA3(aHA: tHashAlgorithm): ObjectIdentifier;
function ExtractHashAlgEMSA3(const aOID: ObjectIdentifier; var aHA : tHashAlgorithm) : Boolean;