Set LMS Private Key State#
Syntax#
IppStatus ippsLMSSetPrivateKeyState (const IppsLMSAlgoType OIDAlgo,
const Ipp32u q,
const Ipp8u* pSecretSeed,
const Ipp8u* pI,
const Ipp8u* pExtraBuf,
const Ipp32s extraBufSize,
IppsLMSPrivateKeyState* pState);
Include Files#
ippcp.h
Parameters#
OIDAlgo |
LMS Algorithm ID. It defines a set of LMS parameters. See Supported LMS Algorithms for more information. |
q |
Leaf number (signature counter). Must be less than |
pSecretSeed |
Pointer to the LMS private key secret seed ( |
pI |
Pointer to the LMS 16-byte private key identifier |
pExtraBuf |
Pointer to the extra buffer data. Can be |
extraBufSize |
Size of the extra buffer data, in bytes. |
pState |
Pointer to the LMS private key state. |
Description#
This function sets the LMS private key state.
It writes the algorithm types, the signature counter q, the secret seed,
the identifier I and the optional extra buffer content into the provided
private key state.
The scheme of the private key is shown below:
+---------------------------------+
| IppsLMSAlgo | 4 bytes
+---------------------------------+
| IppsLMOTSAlgo | 4 bytes
+---------------------------------+
| q | 4 bytes
+---------------------------------+
| secret seed | m bytes
+---------------------------------+
| I | 16 bytes
+---------------------------------+
| extra buffer | extraBufSize bytes
+---------------------------------+
m is an LMS parameter.
Note
extraBufSize must be a multiple of the LMS parameter m.
If it is not, the value will be reduced to the nearest lower multiple of m
inside the implementation.
Note
Important
This is a Preview Feature.
You need to enable the IPPCP_PREVIEW_LMS macro to use the feature.
Return Values#
ippStsNoErr |
Indicates no error. All single operations executed without errors. Any other value indicates an error or warning. |
ippStsNullPtrErr |
|
ippStsLengthErr |
|
ippStsBadArgErr |
|