Example of using function mcuxClRsa_sign to perform the RSA signature generation with EMSA-PSS-SIGN padding scheme according to PKCS #1 v2.2. More...
#include <mcuxClSession.h>
#include <mcuxClExample_Session_Helper.h>
#include <mcuxCsslFlowProtection.h>
#include <mcuxClCore_FunctionIdentifiers.h>
#include <mcuxClRandom.h>
#include <mcuxClRsa.h>
#include <mcuxClCore_Examples.h>
#include <mcuxClEls.h>
#include <mcuxClExample_ELS_Helper.h>
Macros | |
#define | RSA_KEY_BIT_LENGTH |
The example uses a 2048-bit key. More... | |
#define | RSA_KEY_BYTE_LENGTH |
Converting the key-bitlength to bytelength. More... | |
#define | RSA_MESSAGE_DIGEST_LENGTH |
The example uses a Sha2-256 digest, which is 32 bytes long. More... | |
#define | RSA_PSS_SALT_LENGTH |
The salt length is set to 0 in this example. More... | |
Functions | |
static const uint8_t modulus [RSA_KEY_BYTE_LENGTH] | __attribute__ ((aligned(4))) |
Example value for public RSA modulus N. More... | |
MCUXCLEXAMPLE_FUNCTION (mcuxClRsa_sign_pss_sha2_256_example) | |
Performs a session set-up; a call to function mcuxClRsa_sign using mode mcuxClRsa_Mode_Sign_Pss_Sha2_256; a session clean-up. More... | |
Example of using function mcuxClRsa_sign to perform the RSA signature generation with EMSA-PSS-SIGN padding scheme according to PKCS #1 v2.2.
#define RSA_KEY_BIT_LENGTH |
The example uses a 2048-bit key.
#define RSA_KEY_BYTE_LENGTH |
Converting the key-bitlength to bytelength.
#define RSA_MESSAGE_DIGEST_LENGTH |
The example uses a Sha2-256 digest, which is 32 bytes long.
#define RSA_PSS_SALT_LENGTH |
The salt length is set to 0 in this example.
|
static |
Example value for public RSA modulus N.
Expected signature.
Example value for Sha2-256 message digest.
Example value for private RSA exponent d.
MCUXCLEXAMPLE_FUNCTION | ( | mcuxClRsa_sign_pss_sha2_256_example | ) |
Performs a session set-up; a call to function mcuxClRsa_sign using mode mcuxClRsa_Mode_Sign_Pss_Sha2_256; a session clean-up.
MCUXCLEXAMPLE_STATUS_OK | The example code completed successfully |
MCUXCLEXAMPLE_STATUS_ERROR | The example code failed |
Initialize ELS, Enable the ELS
Destroy Session and cleanup Session
Disable the ELS