z/OS Cryptographic Services System SSL Programming
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


gsk_factor_private_key_rsa()

z/OS Cryptographic Services System SSL Programming
SC14-7495-00

Factorizes an RSA private key into its component values.
Note: This function is deprecated. Use gsk_factor_private_key() instead.

Format

   #include <gskcms.h>

   gsk_status gsk_factor_private_key_rsa (
                                          pkcs_private_key_info * private_key,
                                          gsk_buffer *            modulus,
                                          gsk_buffer *            public_exponent,
                                          gsk_buffer *            private_exponent,
                                          gsk_buffer *            prime1,
                                          gsk_buffer *            prime2,
                                          gsk_buffer *            prime_exponent1,
                                          gsk_buffer *            prime_exponent2,
                                          gsk_buffer *            coefficient)                                                      

Parameters

private_key
Specifies the private key.
modulus
Returns the modulus (n).
public_exponent
Returns the public exponent (e).
private_exponent
Returns the private exponent (d).
prime1
Returns the 1st prime (p).
prime2
Returns the 2nd prime (q).
prime_exponent1
Returns the private exponent d modulo p-1.
prime_exponent2
Returns the private exponent d modulo q-1.
coefficient
Returns the CRT coefficient q-1 mod p.

Results

The function return value will be 0 if no error is detected. Otherwise, it will be one of the return codes listed in the gskcms.h include file. These are some possible errors:
[ASN_ELEMENTS_MISSING]
Required data element is missing.

Usage

The gsk_factor_private_key_rsa() function deconstructs the pkcs_private_key_info into its RSA private key components.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014