decaf448
Compute in the decaf448 prime-order group from RFC 9496.
Warning
Hazmat and experimental: these are raw group operations on the pre-release
ed448-goldilocks 0.14.0-pre.15, pinned to an exact version. They provide
no signature, key-exchange or encryption guarantees on their own, the
crate's API and behavior can change between pre-releases, and its README
states that the code has not been audited or reviewed.
from oxcrypto.hazmat.group.decaf448 import DECAF448
group = DECAF448.DECAF448
scalar = group.reduce_scalar(bytes(range(112)))
point = group.multiply_base(scalar)
assert group.add(point, group.negate(point)) == bytes(56)Elements are 56-byte RFC 9496 encodings and scalars are 56-byte little-endian
integers below the group order. The methods match
ristretto255; from_uniform_bytes takes 112 bytes
(section 5.3.4) and reduce_scalar reduces a 112-byte integer.
Upstream
| Crate | Standard | Audit |
|---|---|---|
ed448-goldilocks 0.14.0-pre.15 (pre-release) | RFC 9496 | No published audit |
The crate builds with Rust 1.88, the oxcrypto MSRV. Tests use RFC 9496 appendices B.1 to B.3.
Zeroization
Note
The decoded scalar is wiped after each call. Not covered: scalars passed in
or returned as Python bytes, and the copies ed448-goldilocks makes on the
stack or in registers during scalar multiplication.