kxco-post-quantum 1.5.0 → 1.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/BENCHMARKS.md CHANGED
@@ -15,7 +15,51 @@ node --expose-gc bench/primitives.mjs --iterations 100 --json bench/results/prim
15
15
  ```
16
16
 
17
17
  Every parameter set the package can reach is measured, not only the five it wraps
18
- in its own helpers.
18
+ in its own helpers. The OpenSSL rows appear only on a runtime that provides those
19
+ primitives, so run it on Node 24 or later to reproduce the comparison below and
20
+ on Node 22 for the JavaScript figures alone.
21
+
22
+ ## Two backends
23
+
24
+ Since 1.5.0 this package runs the FIPS primitives in OpenSSL 3.5 where the
25
+ runtime provides them (Node 24 and later) and in JavaScript everywhere else.
26
+ Those are different implementations, so one set of numbers cannot describe both.
27
+ The harness measures whichever are available and labels every row, and the
28
+ tables below the comparison are the JavaScript figures.
29
+
30
+ | Algorithm | Operation | OpenSSL p50 | JavaScript p50 | OpenSSL p99 | JavaScript p99 | faster by |
31
+ |---|---|---:|---:|---:|---:|---:|
32
+ | ML-DSA-44 | sign | 1.125 | 5.116 | 4.619 | 21.325 | 4.5x |
33
+ | ML-DSA-44 | verify | 0.241 | 1.373 | 0.725 | 2.451 | 5.7x |
34
+ | ML-DSA-65 | sign | 1.293 | 8.074 | 4.562 | 40.840 | 6.2x |
35
+ | ML-DSA-65 | verify | 0.288 | 2.249 | 0.652 | 3.803 | 7.8x |
36
+ | ML-DSA-87 | sign | 1.879 | 11.031 | 7.128 | 39.404 | 5.9x |
37
+ | ML-DSA-87 | verify | 0.613 | 3.363 | 1.831 | 5.843 | 5.5x |
38
+ | ML-KEM-1024 | encapsulate | 0.126 | 0.708 | 0.278 | 1.986 | 5.6x |
39
+ | ML-KEM-1024 | decapsulate | 0.230 | 0.919 | 0.339 | 1.630 | 4.0x |
40
+ | ML-KEM-512 | encapsulate | 0.079 | 0.378 | 0.212 | 1.008 | 4.8x |
41
+ | ML-KEM-512 | decapsulate | 0.236 | 0.461 | 0.380 | 1.498 | 2.0x |
42
+ | ML-KEM-768 | encapsulate | 0.148 | 0.558 | 0.256 | 1.288 | 3.8x |
43
+ | ML-KEM-768 | decapsulate | 0.183 | 0.874 | 0.523 | 5.378 | 4.8x |
44
+ | SLH-DSA-SHA2-128f | sign | 68.639 | 97.791 | 165.092 | 173.466 | 1.4x |
45
+ | SLH-DSA-SHA2-128f | verify | 3.459 | 6.082 | 4.303 | 27.278 | 1.8x |
46
+ | SLH-DSA-SHA2-192s | sign | 1710.954 | 4342.105 | 1938.773 | 4628.987 | 2.5x |
47
+ | SLH-DSA-SHA2-192s | verify | 1.263 | 7.457 | 2.405 | 40.920 | 5.9x |
48
+ | SLH-DSA-SHAKE-256f | sign | 161.358 | 2158.272 | 179.655 | 3510.503 | 13.4x |
49
+ | SLH-DSA-SHAKE-256f | verify | 5.599 | 66.177 | 6.774 | 98.654 | 11.8x |
50
+
51
+ The speedup column is the headline, but for a document about tail latency the
52
+ p99 columns matter more. ML-DSA-65 signing goes from a 40.8 ms p99 to 4.6 ms:
53
+ the rejection-sampling tail that the opening of this document warns about is
54
+ still there in the OpenSSL path, but it is roughly nine times tighter, so a
55
+ timeout sized off it can be far smaller.
56
+
57
+ SLH-DSA-SHAKE-256f is the largest single change, 2158 ms down to 161 ms for a
58
+ signature. SLH-DSA-SHA2-192s remains slow in absolute terms at 1.7 seconds and
59
+ no backend makes a hash-based signature cheap; it is 2.5x rather than fast.
60
+
61
+ Neither column is a side-channel claim. See
62
+ [THREAT-MODEL.md](THREAT-MODEL.md).
19
63
 
20
64
  ## Signatures
21
65
 
package/CHANGELOG.md CHANGED
@@ -1,5 +1,29 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.5.1
4
+
5
+ Dependency bump: `@noble/post-quantum` 0.7.0 to **0.7.1**, published 2026-08-27.
6
+ Exact pin as always, never a range.
7
+
8
+ Worth taking rather than waiting for the scheduled Dependabot run, because one of
9
+ its changes touches how this package calls it: 0.7.1 snapshots options on entry
10
+ so a caller's object cannot be mutated afterwards. Every FIPS 204 context string
11
+ this package passes goes in as an options object, so that hardening is directly
12
+ on our path.
13
+
14
+ It also adds a WebCrypto wrapper for ML-KEM upstream. Nothing here uses it yet,
15
+ but it is worth knowing that the backend is converging on the same thing this
16
+ package did in 1.5.0: use the platform's implementation where the platform has
17
+ one.
18
+
19
+ Verified before merging, on all three runtimes: 39 pinned vectors bit-for-bit and
20
+ 53 tests on Node 20 and 22 (the JavaScript path, where this bump actually
21
+ applies) and on Node 24+ (the OpenSSL path).
22
+
23
+ AUDIT.md carries the new pin and its integrity hash. The conservative bound is
24
+ unchanged and restated: the maintainer's self-audit covers 0.6.1, we ship 0.7.1,
25
+ so **the version we ship is covered by no audit at all**.
26
+
3
27
  ## 1.5.0
4
28
 
5
29
  **The FIPS primitives now run in OpenSSL where the runtime has them.** On Node 24
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "kxco-post-quantum",
3
- "version": "1.5.0",
3
+ "version": "1.5.1",
4
4
  "description": "ML-DSA-65, ML-KEM-768 and SLH-DSA-SHA2-192s primitives with key fingerprinting. The base layer for all kxco-pq-* packages.",
5
5
  "keywords": [
6
6
  "post-quantum",
@@ -112,7 +112,7 @@
112
112
  },
113
113
  "dependencies": {
114
114
  "@noble/hashes": "2.3.0",
115
- "@noble/post-quantum": "0.7.0"
115
+ "@noble/post-quantum": "0.7.1"
116
116
  },
117
117
  "scripts": {
118
118
  "test": "node --test test/basic.test.js && node --test test/context.test.js && node --test test/category5.test.js && node --test test/browser-smoke.test.js && node test/run-vectors.js",