Datasheet

Table Of Contents
{nu1PrecompBase,<PrecompLength>} overlaps with either: {nu1NBase, u2NLength + 4},
{nu1CnsBase, u2NLength + 12} {nu1RndBase, u2NLength + 12} or {nu1ExpBase, u2ExpLength + 4}
{nu1RndBase,3*u2NLength + 24} overlaps with either: {nu1NBase, u2NLength + 4},{nu1CnsBase,
u2NLength + 12} {nu1XBase, u2NLength + 12} or {nu1ExpBase, u2ExpLength + 4}
{nu1NBase, u2NLength + 4} overlaps {nu1CnsBase, u2NLength +12}
43.3.5.3.9 Status Returned Values
Table 43-61. PrimeGen Service Return Codes
Returned Status Importance Meaning
PUKCL_NUMBER_IS_PRIME Information The generated or tested number has been detected
as probably prime.
PUKCL_NUMBER_IS_NOT_PRIME Information The generated or tested number has been detected
as composite.
43.3.5.4 Modular Exponentiation (With CRT)
43.3.5.4.1 Purpose
The purpose of this service is to perform the Modular Exponentiation with the Chinese Remainders
Theorem (CRT). This service processes integers in GF(p) only.
The options available for this service are:
Fast implementation
Regular implementation
Exponent is located in Crypto RAM or not
Exponent window size
43.3.5.4.2 How to Use the Service
43.3.5.4.3 Description
This service processes a Modular Exponentiation with the Chinese Remainder Theorem:
R = X
D
mod(N) with N = P *Q
Important:  For this service, be sure to follow the directives given for the RSA implementation
on the chip you use.
This service requires that the modulus N is the product of two co-primes P and Q and that the decryption
exponents D is co-prime with the product ((P-1)*(Q-1)).
The Input data are P, Q, EP, EQ, Rvalue, and X. P and Q are the co-primes so that N = P*Q.
X is the number to exponentiate.
EP, EQ and Rval are calculated as follows:
EP = Dmod(P – 1) EQ = Dmod(Q – 1) Rval = P
–1
mod(Q)
In some cases, the decryption exponent D may not be available and the encryption exponent E may be
available instead. The possibilities to calculate the parameters are:
Calculate D from E with the formula:
D = E
–1
mod((P – 1) × (Q – 1))
SAM D5x/E5x Family Data Sheet
Public Key Cryptography Controller (PUKCC)
© 2019 Microchip Technology Inc.
Datasheet
DS60001507E-page 1501