Skip to content

Commit 8a9169d

Browse files
committed
Refresh wasm admission release evidence
1 parent 63eef52 commit 8a9169d

7 files changed

Lines changed: 34 additions & 18 deletions

File tree

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,13 @@
1919
- Added a fail-closed wasm encode scalar-verification step: fixed-block wasm
2020
encode output is staged, compared against scalar output, wiped, and only then
2121
copied to caller output.
22+
- Hardened the wasm scalar-verification error path so staged stack buffers are
23+
wiped before any verification error returns, and narrowed the unsafe block to
24+
only the fixed-size wasm SIMD view/call.
25+
- Added Standard and URL-safe strict decode error-surface evidence proving
26+
`decode_slice`, `decode_slice_clear_tail`, stack-buffer, vec, and secret
27+
helpers match scalar error shapes and that clear-tail buffers are wiped on
28+
rejected input.
2229
- Added `scripts/generate_wasm_simd_evidence.sh` and wired it into the local
2330
release checks so installed wasm targets emit release test-harness LLVM IR
2431
with `target-feature=+simd128` and checked vector-codegen markers.

docs/SIMD_ACTIVATION_CHECKLIST.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
# SIMD Activation Checklist
22

33
This checklist is mandatory before any additional SIMD code becomes
4-
dispatchable. AVX-512 VBMI, AVX2, SSSE3/SSE4.1, and NEON encode are admitted
5-
only for std x86/x86_64 or little-endian std aarch64 Standard and URL-safe
6-
alphabet families.
7-
wasm, custom-alphabet, in-place, and decode SIMD paths remain prototype-only or
8-
scalar until their own checklist evidence is complete.
4+
dispatchable. AVX-512 VBMI, AVX2, SSSE3/SSE4.1, NEON, and the narrow wasm
5+
`simd128` runtime profile are admitted only for their documented Standard and
6+
URL-safe alphabet-family scopes. Custom-alphabet, in-place, wrapped, legacy,
7+
CT-secret, broader wasm/browser, and future decode surfaces remain
8+
prototype-only or scalar until their own checklist evidence is complete.
99

1010
## Non-Negotiable Rule
1111

@@ -64,10 +64,10 @@ and deployment profile have generated-code/JIT evidence, or the release notes
6464
scope wasm SIMD out of any register-retention claim.
6565

6666
Current non-dispatchable prototypes are exempt from admission only because they
67-
are test-only and non-dispatchable. The wasm prototype already loads caller
68-
bytes into vector registers and therefore carries generated-code notes plus
69-
unsafe-inventory documentation as evidence. That evidence is not enough for
70-
active dispatch until the full admission package is complete.
67+
are test-only and non-dispatchable. The narrow wasm `simd128` profile is no
68+
longer prototype-only: it is admitted only for the documented runtime smoke
69+
profile and remains scoped out of hardware-like register-retention and
70+
runtime/JIT timing claims.
7171

7272
## Source Changes
7373

docs/TRUST.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ stable release.
1212
| Default dev dependencies | Zero external crates | `Cargo.toml` |
1313
| Optional runtime features | `alloc`, `std`, `stream`; `allow-wasm32-best-effort-wipe` explicit wasm cleanup-limit acceptance; `allow-compiler-fence-only-wipe` explicit unsupported-native cleanup-limit acceptance; reserved `simd`, `tokio`, `kani`, `fuzzing`. AArch64 CSDB attestation uses custom cfg `base64_ng_aarch64_csdb_attested`, not a feature. | `Cargo.toml`, `scripts/check_reserved_features.sh`, `scripts/check_wasm_wipe_policy.sh` |
1414
| Unsafe policy | Scalar encode/decode remains safe Rust; audited unsafe is limited to volatile wiping, constant-time comparison, CT alphabet scan and result-gate barriers, and the reviewed SIMD boundary; runtime unsafe-boundary reports are conservative and mark SIMD-enabled builds as not high-assurance-boundary-enforced | `src/cleanup.rs`, `src/ct/`, `src/simd/`, `docs/UNSAFE.md` |
15-
| Active backend | Scalar by default; std x86/x86_64 AVX-512 VBMI encode preferred, then AVX2, then SSSE3/SSE4.1 encode, plus little-endian std aarch64 NEON encode, when `simd` is enabled and platform checks pass. Strict decode has a separate runtime report method and may use std x86/x86_64 AVX-512 VBMI, AVX2, SSSE3/SSE4.1, or little-endian std aarch64 NEON only. | `runtime::backend_report()` tests |
16-
| SIMD status | AVX-512 VBMI, AVX2, SSSE3/SSE4.1, and NEON encode admitted for Standard and URL-safe alphabet families; AVX-512 VBMI, AVX2, SSSE3/SSE4.1, and NEON strict decode admitted for std x86/x86_64 or little-endian std aarch64 Standard and URL-safe alphabet families. wasm, custom-alphabet, in-place, wrapped, legacy, CT secret, big-endian AArch64, and `no_std` acceleration remain prototype-only or scalar. | `docs/SIMD.md` |
15+
| Active backend | Scalar by default; std x86/x86_64 AVX-512 VBMI encode preferred, then AVX2, then SSSE3/SSE4.1 encode, plus little-endian std aarch64 NEON encode, when `simd` is enabled and platform checks pass. Strict decode has a separate runtime report method and may use std x86/x86_64 AVX-512 VBMI, AVX2, SSSE3/SSE4.1, or little-endian std aarch64 NEON. wasm32 binaries compiled with `target-feature=+simd128`, `simd`, and `allow-wasm32-best-effort-wipe` may use the admitted narrow wasm `simd128` encode and strict-decode backend. | `runtime::backend_report()` tests |
16+
| SIMD status | AVX-512 VBMI, AVX2, SSSE3/SSE4.1, NEON, and narrow wasm `simd128` encode admitted for Standard and URL-safe alphabet families; AVX-512 VBMI, AVX2, SSSE3/SSE4.1, NEON, and narrow wasm `simd128` strict decode admitted for the documented runtime profiles. Custom-alphabet, in-place, wrapped, legacy, CT secret, big-endian AArch64, broader wasm/browser, and `no_std` acceleration remain prototype-only or scalar. | `docs/SIMD.md` |
1717
| Strict decoding | Default behavior rejects whitespace, mixed alphabets, malformed padding, and non-canonical trailing bits | integration tests |
1818
| Legacy compatibility | Explicit opt-in APIs only | `decode_slice_legacy`, `validate_legacy` |
1919
| Constant-time API | Constant-time-oriented scalar validation/decode and equal-length redacted-buffer comparison helpers exist with isolated dudect-style timing evidence; no formal cryptographic constant-time guarantee | `docs/CONSTANT_TIME.md`, `docs/DUDECT.md` |
@@ -65,8 +65,8 @@ without `std`-equivalent runtime probing.
6565

6666
- formally verified cryptographic constant-time behavior
6767
- formal zeroization of all historical memory copies
68-
- wasm, custom-alphabet, in-place, wrapped, legacy, CT secret, or `no_std`
69-
acceleration
68+
- custom-alphabet, in-place, wrapped, legacy, CT secret, broader wasm/browser,
69+
or `no_std` acceleration
7070
- async/Tokio support in the core crate's inert `tokio` feature
7171
- serde or bytes integration in the core crate
7272
- Kani-complete whole-crate formal verification

docs/WASM_SIMD128_RUNTIME_REVIEW.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -88,9 +88,11 @@ provide:
8888

8989
- `src/simd/mod.rs` includes `WasmSimd128` in `ActiveBackend` only behind
9090
`cfg(all(feature = "simd", target_arch = "wasm32"))`.
91-
- `src/simd/wasm.rs` stages wasm encode output and compares it against scalar
92-
output before copying bytes to the caller's output buffer; specifically, it
93-
compares it against scalar output before copying bytes to caller output.
91+
- `src/simd/wasm.rs` stages wasm encode output, compares it against scalar
92+
output before copying bytes to the caller's output buffer, and wipes staged
93+
stack buffers on every verification failure path before returning.
94+
Evidence phrase: compares it against scalar output before copying bytes to the caller's output buffer.
95+
Evidence phrase: wipes staged stack buffers on every verification failure path before returning.
9496
- `scripts/validate-wasm-posture.sh` checks this review document, the SIMD
9597
documentation, the admission manifest, and the runtime boundary.
9698
- `scripts/check_wasm_runtime_dispatch.sh` executes the runtime smoke under

release-notes/RELEASE_NOTES_1.3.3.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,12 @@ wasm `simd128` runtime-dispatch profile with explicit runtime smoke evidence.
2121
for the same admitted wasm `simd128` profile.
2222
- Added fail-closed scalar verification for wasm fixed-block encode before
2323
copying staged SIMD output to caller output.
24+
- Hardened wasm scalar-verification cleanup so staged stack buffers are wiped
25+
before any verification error returns, and kept the unsafe block scoped to
26+
the fixed-size wasm SIMD view/call.
27+
- Added strict decode error-surface evidence for Standard and URL-safe
28+
padded/unpadded public helpers, including clear-tail wiping on rejected
29+
input.
2430
- Added release-gated wasm SIMD codegen evidence through
2531
`scripts/generate_wasm_simd_evidence.sh`, which emits test-harness LLVM IR
2632
with `target-feature=+simd128` when the wasm target is installed.

scripts/validate-release-metadata.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ for required_trust_text in \
213213
"Active backend | Scalar by default; std x86/x86_64 AVX-512 VBMI encode preferred, then AVX2, then SSSE3/SSE4.1 encode, plus little-endian std aarch64 NEON encode" \
214214
"no formal cryptographic constant-time guarantee" \
215215
"formally verified cryptographic constant-time behavior" \
216-
"wasm, custom-alphabet, in-place, wrapped, legacy, CT secret" \
216+
"custom-alphabet, in-place, wrapped, legacy, CT secret, broader wasm/browser" \
217217
"async/Tokio support" \
218218
"serde or bytes integration"
219219
do

scripts/validate-wasm-posture.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,8 @@ require_text "$review_doc" "active encode and decode backends are \`wasm-simd128
4949
require_text "$review_doc" "deterministic length sweep from 0 through 200 bytes"
5050
require_text "$review_doc" "independent scalar reference encoder"
5151
require_text "$review_doc" "malformed block-boundary inputs"
52-
require_text "$review_doc" "compares it against scalar output before copying bytes"
52+
require_text "$review_doc" "compares it against scalar output before copying bytes to the caller's output buffer"
53+
require_text "$review_doc" "wipes staged stack buffers on every verification failure path before returning"
5354
require_text "$review_doc" "scripts/generate_wasm_simd_evidence.sh"
5455
require_text "$review_doc" "scripts/check_wasm_runtime_dispatch.sh"
5556
require_text "$review_doc" "scripts/check_wasm_browser_dispatch.sh"

0 commit comments

Comments
 (0)