EldoS
Navigation
Web site
Support
Table Of Contents

Filter: C#  VB.NET  Pascal  ActiveX  DLL 


TElCertificateRequest.Generate

TElCertificateRequest     See also    


 

Generates new Certificate Request using previously set subject information

 
 

Declaration

[C#]
    void Generate(int PublicKeyAlgorithm, int Bits, int SignatureAlgorithm);

[VB.NET]
    Sub Generate(ByVal PublicKeyAlgorithm As Integer, ByVal Bits As Integer, ByVal SignatureAlgorithm As Integer)

[Pascal]
    procedure Generate(PublicKeyAlgorithm : integer; Bits : integer; SignatureAlgorithm : integer);

[VB6]
    Sub IElCertificateRequestX.Generate(PublicKeyAlgorithm As TxSBSignatureAlgorithm, Bits As Long, SignatureAlgorithm As TxSBSignatureAlgorithm)

[ActiveX]
    HRESULT _stdcall IElCertificateRequestX.Generate([in] TxSBSignatureAlgorithm PublicKeyAlgorithm, [in] long Bits, [in] TxSBSignatureAlgorithm SignatureAlgorithm );

[DLL]
    __stdcall BOOL SBCertificateRequestGenerate(HANDLE hRequest, int PublicKeyAlgorithm, int Bits, int SignatureAlgorithm);
 
 

Parameters

  • [DLL]hRequest - handle to the TElCertificateRequest object that was returned by Constructor
  • PublicKeyAlgorithm - specifies the type of the key to be generated. Possible values are listed below.
  • Bits - The number of bits in resulting public key.
  • SignatureAlgorithm - specifies the algorithm which is used to sign the content of Certificate Request
 
 

Values:

The following algorithms may be used as public key algorithms:
[.NET] [Pascal] [ActiveX] [DLL] Value Description
SB_CERT_ALGORITHM_ID_RSA_ENCRYPTION 0 (0x00) RSA
SB_CERT_ALGORITHM_ID_DSA 4 (0x04) DSA
SB_CERT_ALGORITHM_DH_PUBLIC 6 (0x06) Diffie-Hellman
SB_CERT_ALGORITHM_ID_RSAPSS 11 (0x0B) RSA key, which can be used only in RSA-PSS signature scheme
SB_CERT_ALGORITHM_ID_RSAOAEP 12 (0x0C) RSA key, which can be used only for RSA-OAEP encryption
SB_CERT_ALGORITHM_UNKNOWN 65535 (0xFFFF) the algorithm is unknown
Declared in
[.NET] [Pascal]
Namespace: SBUtils
Assembly: SecureBlackbox
Unit: SBUtils

The following algorithms may be used as signature algorithms:
[.NET] [Pascal] [ActiveX] [DLL] Value Description
SB_CERT_ALGORITHM_MD2_RSA_ENCRYPTION 1 (0x01) RSA digital signature with MD2 digest
SB_CERT_ALGORITHM_MD5_RSA_ENCRYPTION 2 (0x02) RSA digital signature with MD5 digest
SB_CERT_ALGORITHM_SHA1_RSA_ENCRYPTION 3 (0x03) RSA digital signature with SHA1 digest
SB_CERT_ALGORITHM_ID_DSA_SHA1 5 (0x05) DSA digital signature with SHA1 digest
SB_CERT_ALGORITHM_SHA224_RSA_ENCRYPTION 7 (0x07) RSA digital signature with SHA-224 digest
SB_CERT_ALGORITHM_SHA256_RSA_ENCRYPTION 8 (0x08) RSA digital signature with SHA-256 digest
SB_CERT_ALGORITHM_SHA384_RSA_ENCRYPTION 9 (0x09) RSA digital signature with SHA-384 digest
SB_CERT_ALGORITHM_SHA512_RSA_ENCRYPTION 10 (0x0A) RSA digital signature with SHA-256 digest
SB_CERT_ALGORITHM_ID_RSAPSS 11 (0x0B) DSA digital signature with SHA1 digest
SB_CERT_ALGORITHM_RSASIGNATURE_RIPEMD160 13 (0x0D) RSA digital signature with RIPEMD-160 digest
SB_CERT_ALGORITHM_UNKNOWN 65535 (0xFFFF) the algorithm is unknown
Declared in
[.NET] [Pascal]
Namespace: SBUtils
Assembly: SecureBlackbox
Unit: SBUtils

 
 

Description

    Use this method to generate new certificate request. New public and private key are also generated.

    Note, that the signature algorithm should correspond with public key algorithm. I.e. if the public key algorithm is set to SB_CERT_ALGORITHM_ID_RSA_ENCRYPTION, the signature algorithm should be set to one of SB_CERT_ALGORITHM_MD2_RSA_ENCRYPTION, SB_CERT_ALGORITHM_MD5_RSA_ENCRYPTION or SB_CERT_ALGORITHM_SHA1_RSA_ENCRYPTION.

 
 

See also:     KeyMaterial     SaveToBuffer    

 
Contact Us | Terms of Use | Trademarks | Privacy Statement
Copyright (c) 1998-2012, EldoS Corporation