Discuss this help topic in SecureBlackbox Forum


TElCertificateRequest     See also     

Filter: C#  VB.NET  Pascal  C++  PHP  Java  

Generates new Certificate Request using previously set subject information


    Sub Generate(ByVal PublicKeyAlgorithm As Integer, ByVal Bits As Integer, ByVal SignatureAlgorithm As Integer)
    Sub Generate(ByVal PublicKeyAlgorithm As TElAlgorithmIdentifier, ByVal Bits As Integer, ByVal SignatureAlgorithm As TElAlgorithmIdentifier)

    procedure Generate(PublicKeyAlgorithm : integer; Bits : integer; SignatureAlgorithm : integer);

    void Generate(int32_t PublicKeyAlgorithm, int32_t Bits, int32_t SignatureAlgorithm);
    void Generate(TElAlgorithmIdentifier &PublicKeyAlgorithm, int32_t Bits, TElAlgorithmIdentifier &SignatureAlgorithm);
    void Generate(TElAlgorithmIdentifier *PublicKeyAlgorithm, int32_t Bits, TElAlgorithmIdentifier *SignatureAlgorithm);

    void Generate(integer $PublicKeyAlgorithm, integer $Bits, integer $SignatureAlgorithm)
    void Generate(TElAlgorithmIdentifier $PublicKeyAlgorithm, integer $Bits, TElAlgorithmIdentifier $SignatureAlgorithm)

    void generate(int PublicKeyAlgorithm, int Bits, int SignatureAlgorithm);
    void generate(TElAlgorithmIdentifier PublicKeyAlgorithm, int Bits, TElAlgorithmIdentifier SignatureAlgorithm);


  • 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.


The following algorithms may be used as public key algorithms:

The following algorithms may be used as signature algorithms:


    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.

    You can use exising key material (eg. the one from the PKCS#11 device) by setting KeyMaterial and PreserveKeyMaterial properties. If you don't set them, new key material is generated.

See also:     KeyMaterial property     PreserveKeyMaterial property     SaveToBuffer method    

Discuss this help topic in SecureBlackbox Forum