Depends on the C exports and the Python bindings landing first.
Cross-implementation test vectors, following the layout already used by BLS and KZG: generators under bindings/python/tests/xmss/ that call the spec through the Python bindings and write tests/xmss/<handler>/<case>/data.yaml through dumper.write_case, with one format.md per handler describing the fields.
Handlers worth covering, and the cases that earn their place:
- the raw hash: the RFC 7693 test vectors, the empty input, and 63, 64 and 65 bytes;
- the tweaked hash: one case per tweak type, plus cases showing that changing the type, the position, the index or the public parameter changes the output;
- the message encoding: one admissible encoding, one rejected because a spare bit is set, one rejected because the digits miss 195;
- key generation: epoch 0, a middle epoch, epoch
2^32 - 1; the same seed twice giving the same key; and two different epoch ranges giving different roots;
- signing: valid at the start, middle and end of a range; the same inputs twice giving the same signature; an epoch outside the range;
- verification: a valid signature, then one tampered chain value, one tampered sibling, one tampered randomizer, a wrong epoch, a wrong message, and public keys and signatures of the wrong length.
The negative cases are the point. A test suite that only contains valid signatures passes against an implementation that accepts everything.
One more step that is easy to skip and shouldn't be: run the same inputs through leanEthereum/leanVM once, diff the outputs, and record in format.md which commit of that repository was used. Without it the vectors prove only that this specification agrees with itself.
Depends on the C exports and the Python bindings landing first.
Cross-implementation test vectors, following the layout already used by BLS and KZG: generators under
bindings/python/tests/xmss/that call the spec through the Python bindings and writetests/xmss/<handler>/<case>/data.yamlthroughdumper.write_case, with oneformat.mdper handler describing the fields.Handlers worth covering, and the cases that earn their place:
2^32 - 1; the same seed twice giving the same key; and two different epoch ranges giving different roots;The negative cases are the point. A test suite that only contains valid signatures passes against an implementation that accepts everything.
One more step that is easy to skip and shouldn't be: run the same inputs through
leanEthereum/leanVMonce, diff the outputs, and record informat.mdwhich commit of that repository was used. Without it the vectors prove only that this specification agrees with itself.