Closed
Bug 2005669
Opened 11 months ago
Closed 9 months ago
ML-KEM PCT does not error properly
Categories
(NSS :: Libraries, defect, P3)
NSS
Libraries
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: joachim.vandersmissen, Unassigned)
References
(Depends on 1 open bug)
Details
Attachments
(1 external file)
Steps to reproduce:
The ML-KEM PCT currently has two issues:
isKEM = sftk_isTrue(privateKey, CKA_ENCAPSULATE);is incorrect, as the private key in ML-KEM is used for decapsulation not encapsulation. Ref. FIPS 203 Section 2.1: "decapsulation key A cryptographic key produced by a KEM during key generation and used during the decapsulation process. The decapsulation key must be kept private and must be destroyed after it is no longer needed. (See Section 3.3.)"- The function must return
CKR_GENERAL_ERRORif the PCT fails, however this is never done for the KEM PCT.
Actual results:
A PCT failure will never move the module to the error state.
Expected results:
A PCT failure must move the module to the error state.
| Reporter | ||
Comment 1•11 months ago
|
||
There is a third issue: when creating the template for the shared secret, the template omits the required CKA_CLASS attribute and instead erroneously sets CKO_SECRET_KEY to be the CKA_KEY_TYPE. Both have to be present.
| Reporter | ||
Comment 2•11 months ago
|
||
Updated•11 months ago
|
Severity: -- → S3
Priority: -- → P3
Comment 3•11 months ago
|
||
Adding a depends on an UAF fix patch that is only not a issue because of this bug.
Pushed by rrelyea@redhat.com:
https://hg.mozilla.org/projects/nss/rev/a447f109f456
fix ML-KEM PCT. r=#nss-reviewers,rrelyea
Status: UNCONFIRMED → RESOLVED
Closed: 9 months ago
Resolution: --- → FIXED
Pushed by nkulatova@mozilla.com:
https://hg.mozilla.org/projects/nss/rev/2182cee4bd7e
fix ML-KEM PCT. r=#nss-reviewers,rrelyea
You need to log in
before you can comment on or make changes to this bug.
Description
•