code wiki / (root) / nx_ed25519_signature_test.nx

nx_ed25519_signature_test.nx

buildroot/runtime/nx_ed25519_signature_test.nx

5057 B112 linesdepth 9pulls 12 transitivereach 0 importersview sourcekind gate/prooftopic ed25519
docsdependenciesstructsconstsfunctions

about

nx_ed25519_signature_test.nx -- RFC 8032 ยง7.1 TEST 1 KAT. Vector: priv: 9d61b19deffd5a60ba844af492ec2cc44449c5697b326919703bac031cae7f60 pub : d75a980182b10ab7d54bfed3c964073a0ee172f3daa62325af021a68f707511a msg : (empty) sig : e5564300c360ac729086e2cc806e828a84877f1eb8e5d974d873e065224901555f b8821590a33bacc61e39701cf9b46bd25bf5f0595bbe24655141438e7a100b Tests: A. ed25519_sign(priv, empty) produces sig byte-exact B. ed25519_verify_full(pub, empty, sig) == OK C. ed25519_verify_full(pub, empty, sig_with_tampered_byte) == BAD D. ed25519_verify_full(pub, 1-byte msg, sig) == BAD (wrong message) E. ed25519_verify_full(other_pub, empty, sig) == BAD (wrong pubkey) expect_exit: 0 license_tier: ORIGINAL

dependencies 7 imports · 0 importers

nx_syscalls.nx nx_x25519.nx nx_ed25519_field.nx nx_ed25519_point.nx nx_ed25519_arith.nx nx_ed25519_scalar.nx nx_ed25519_signature.nx nx_ed25519_signature_test.nx

imports: nx_syscalls.nxnx_x25519.nxnx_ed25519_field.nxnx_ed25519_point.nxnx_ed25519_arith.nxnx_ed25519_scalar.nxnx_ed25519_signature.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main sys_mmap ed25519_sign_full sys_mmap ↻ ed25519_sha512 sys_mmap ↻ sha512_init sha512_update sha512_blk_set_byte blk_get_i64 blk_set_i64 sha512_compress sys_mmap ↻ blk_get_i64 ↻ sha512_gamma0 rotr64_v shr64_v sha512_gamma1 rotr64_v ↻ shr64_v ↻ sha512_sigma1 rotr64_v ↻ sha512_ch sha512_k sha512_sigma0 rotr64_v ↻ sha512_maj sha512_final sha512_blk_set_byte ↻ sha512_compress ↻ ge_p3_alloc sys_mmap ↻ fe_alloc nx_scratch nx_scratch_init sys_mmap ↻ nx_scratch_oom sys_write sys_exit sys_mmap ↻

structs

none

consts

none

functions

28func main() -> i64