PLValidateMLDSAIdentity
Cryptography, digital signatures
Description
Checks that an ML-DSA private key belongs to a certificate and expands it into the FIPS 204 secret key used by the pure-Pascal signing path
PrivateKeyDER is a raw 32-byte seed or an unencrypted PKCS #8 v2 value wrapping one; the certificate must carry the matching ML-DSA public key (ISO/TS 32005)
Syntax
Delphi
Function PLValidateMLDSAIdentity(Const CertificateDER, PrivateKeyDER: AnsiString;
Out Kind: Integer; Out SecretKey: AnsiString): Boolean;Parameters
| CertificateDER | DER-encoded certificate holding the ML-DSA public key |
|---|---|
| PrivateKeyDER | Raw 32-byte seed or DER-encoded unencrypted PKCS #8 v2 private key |
| Kind | Receives 1, 2 or 3 for ML-DSA-44, ML-DSA-65 or ML-DSA-87; 0 on failure |
| SecretKey | Receives the expanded FIPS 204 secret key; empty on failure |
Return values
| False | The pair does not match, is not ML-DSA, or the encodings are malformed |
|---|---|
| True | Kind and SecretKey identify the parameter set and the key usable with the ML-DSA sign helpers |
Remarks
This is the identity gate behind SetSignProcessMLDSAIdentity
See also
SetSignProcessMLDSAIdentity, MLDSA44Sign, MLDSA65Sign, MLDSA87Sign, PLValidateEd25519Identity