Datasheet

Table Of Contents
43.3.7.3.5 Code Example
PUKCL_PARAM PUKCLParam;
PPUKCL_PARAM pvPUKCLParam = &PUKCLParam;
PUKCL (u2Option) = 0;
PUKCL _GF2NEccDbl(nu1ModBase) = <Base of the ram location of P>;
PUKCL _GF2NEccDbl(u2ModLength) = <Byte length of P>;
PUKCL _GF2NEccDbl(nu1CnsBase) = <Base of the ram location of Cns>;
PUKCL _GF2NEccDbl(nu1PointABase) = <Base of the ram location of the A point>;
PUKCL _GF2NEccDbl(nu1ABBase) = <Base of the a and b parameters of the elliptic curve>;
PUKCL _GF2NEccDbl(nu1Workspace) = <Base of the ram location of the workspace>;
...
// vPUKCL_Process() is a macro command, which populates the service name
// and then calls the library...
vPUKCL_Process(GF2NEccDblFast,&PUKCLParam);
if (PUKCL (u2Status) == PUKCL_OK)
{
...
}
else // Manage the error
43.3.7.3.6 Constraints
No overlapping between either input and output are allowed. The following conditions must be avoided to
ensure the service works correctly:
nu1ModBase, nu1CnsBase, nu1PointABase, nu1ABBase, nu1Workspace are not aligned on 32-bit
boundaries
{nu1ModBase, u2ModLength + 4}, {nu1CnsBase, u2ModLength + 8}, {nu1PointABase,
3*u2ModLength+ 12}, {nu1ABBase, 2*u2ModLength + 8}, {nu1Workspace, <WorkspaceLength>} are
not in Crypto RAM
u2ModLength is either: < 12, > 0xffc or not a 32-bit length
All overlapping between {nu1ModBase, u2ModLength + 4}, {nu1CnsBase, u2ModLength + 8},
{nu1PointABase, 3*u2ModLength + 12}, {nu1ABase, u2ModLength + 4} and {nu1Workspace,
4*u2ModLength + 28}
43.3.7.3.7 Status Returned Values
Table 43-97. GF2NEccDblFast Service Return Codes
Returned Status Importance Meaning
PUKCL_OK The computation passed without problem.
43.3.7.4 Scalar Point Multiply
43.3.7.4.1 Purpose
This service is used to multiply a point by an integral constant K on a given elliptic curve over GF(2
n
).
43.3.7.4.2 How to Use the Service
43.3.7.4.3 Description
The operation performed is:
Pt
C
= K × Pt
A
In this computation, the following parameters need to be provided:
A the input point is filled in projective coordinates (X,Y,Z) (pointed by {nu1PointABase,
3*u2ModLength + 12}). This point can be the Infinite Point.
Cns the Fast Modular Constant filled (pointed by {nu1CnsBase,u2ModLength + 8})
SAM D5x/E5x Family Data Sheet
Public Key Cryptography Controller (PUKCC)
© 2019 Microchip Technology Inc.
Datasheet
DS60001507E-page 1550