logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

kcapi_kpp_dh_setparam_pkcs3 - set the PG parameters using PKCS3 format

Arguments

handle
           [in] cipher handle

       pkcs3
           [in] parameter buffer in DER format

       pkcs3len
           [in] length of key buffer

Author

StephanMueller <smueller@chronox.de>
           Author.

Description

       With this function, the caller sets the PG parameters for subsequent cipher operations.

       The parameter set must be in DER format as follows

       SEQUENCE { prime INTEGER ({ dh_get_p }), base INTEGER ({ dh_get_g }) }

       The following command generates such parameter set where the output

File Content Is Has The Correct Der Structure

       openssl dhparam -outform DER -out dhparam.der 2048

       Note, this function defines that the subsequent key generation and shared secret operation performs an
       FFC Diffie-Hellman operation.

       After the caller provided the key, the caller may destroy the parameter as it is now maintained by the
       kernel.

       return upon success the value of the maximum size for the KPP operation is returned (e.g. the prime
       size); a negative errno-style error code if an error occurred

Name

       kcapi_kpp_dh_setparam_pkcs3 - set the PG parameters using PKCS3 format

Synopsis

intkcapi_kpp_dh_setparam_pkcs3(structkcapi_handle*handle,constuint8_t*pkcs3,uint32_tpkcs3len);

See Also