Files
node/test/committee/short.txt
zeekayandHanzo Dev b98e8d9d61 The name is the node; the chain is in the proof
LP-10603 said the chain was in the NAME and I implemented that. The document
now says otherwise, and it is right: Go derives a node's own identity with
ids.Empty (node.go's MyNodeID = DeriveNodeID(ids.Empty)) and re-derives with
ids.Empty to check a peer, so a node answers to one name on every chain it
serves. Putting the chain in the name gave it as many names as it had chains,
and it broke agreement with Rust, which was right all along.

What the chain scopes is the ENTITLEMENT, and that belongs one layer down. The
possession proof is now signed and checked over chain | node | key rather than
node | key alone, so a line published for one network authorises nothing on
another while the name stays the same everywhere. Committee::claim is the one
statement of those 100 bytes; Signer::publish signs them and the door checks
them. The link goes back to binding a peer at chain zero, which is what Go
does and what a name is.

The door is this file's own now, and that is a consequence worth naming.
consensus::admit holds the REGISTRATION proof, whose message is fixed at
node | key and pinned across three languages by a frozen corpus; a committee
proof is a different message, so it cannot go through that door. The clauses
are the same clauses in the same order — encoding, possession, one key per
node — and the pairing is under the tag lux::consensus::bls publishes. That
surface exposes a general pop_sign and only a node-bound pop_verify; the
general verify would belong there.

Measured, three ways, on test/committee/four.txt:

  C++  Committee::read(...).root()   de34e8d1948f90d09610c8737c6487d494e093ba01680f1a54095a1cdfa696e7
  Rust lux_node::engine::Committee   de34e8d1948f90d09610c8737c6487d494e093ba01680f1a54095a1cdfa696e7
  Go   luxfi/validators SetRoot      de34e8d1948f90d09610c8737c6487d494e093ba01680f1a54095a1cdfa696e7

with the four names agreeing one for one in all three — the divergence from
Rust is gone. Go checks every proof over chain | node | key with its own
bls.VerifyProofOfPossession and answers for all four; read as a committee of
another network the same file names the same validators and admits none of
them. test/committee/elsewhere.txt is the mirror: the same four publishing
somewhere else, refused here. Rust computes the same root and then says
PopInvalid, because it still checks the node-bound proof — the remaining half
of the port, not a disagreement.

TWO THINGS CARRIED, both in this commit because they are what the link needed.

Signing is deterministic now. LP-10602 mandates it and Go signs that way, but
the C ABI offered only SignCtx(rand.Reader, ...), so a published handshake
could be checked and never reproduced. mldsa65_sign_ctx_det now exists in
luxfi/crypto's cabi — SignCtxDeterministic was already there, it was simply
not exported — and the link signs through it. The vector carries both secrets,
and pq_vector_test re-makes both signatures and compares them byte for byte:
signing prefix_resp here gives back the bytes GO put on the wire, which says
the two implementations agree on the signature rather than merely accepting
each other's.

And the nine-line ZAP pairing is gone from plugin.cpp. zap-cpp-core wrote and
read an error response's body length-prefixed where Go writes it raw, so every
error from a Go plugin arrived as "truncated error response" — fixed in both
halves on lux-cpp/zap-cpp-core branch net/error-body-is-raw, with a
conformance case that pins the bytes rather than a round trip. Verified live:
the plugin's real complaint now reaches the caller through ZapClient.

Co-authored-by: Hanzo Dev <[email protected]>
2026-09-08 01:15:09 -07:00

4 lines
8.0 KiB
Plaintext

# SPDX-License-Identifier: BSD-3-Clause-Eco
03841301a387b95aa112348f7820e71b527f72e47a99aa89b8d54bcafd108058e43fa8ec40884ad4ab5f73ee0b3d922fbaf47a27b95e3a90b4ce015c5ec02353e63b918f74bd61a3ae59223307ae22e55c88d6fbe38a24c1c792d830e00f985f06a06e0768a509087deecc6cc19d67fc7fb9e386532e20d4fc10a3c98e7beb39136a5178cea3a12321963297cd55262455e28692fb6c2dbe372204390a30a52b3ff2655a9bd611ab08362a9fba11c6b305b41ed69221e289e33b962cdeffaef3f10d4eb981a561a83220c09021ec45e4cde654618133d183f83fda6240396aea6017ab20778f2eb0861fad1f32b1980e97b5e9a70e94afe0f5add967268d8cc4c8fcac0412214f6cf9bd88e5d9d6864701cf5f36be75d7b67b6fc06373de68e16c4ce4a6abebefbfde5766a174846de569ea048959dc26d5788495cef9b99b5810711e4e720fa3f964f50ac9f4cbee2541c8054ba9a5ca41fce94ff329866676ee117e8265f44fe84b68090df7bbc934809d3709e9777db50f15366c2060c52aff8c4e9c8557b0124ba9f5f5fac521cb8840f9ab1d8bc4fd3cbf87efe8b96ed9e453852aa6c3033b956f229586bfb908d5cab5932ce1dfb7a177b731af0ea4c86a6bd7e4fee5e44a4e8d6a32fea7e562c02f5eef58ab5eac33f537dd8f7f09bd810b7a89a224c8912456c9e748664de7657f2d61d11df9bf5dcb12484ccdac7718aca6a480ffa5f4b58db0743a6d2c7f34eef23e81cfac351315efffe7acd3bc04c3366b68fb208aa167d1234bf080fd8d371b73ccf3e978001645bb074928a352317572b5a00ca8d4c96c356392835794a8887cacca3646098cc89a763c1bda2e73c923936f0dc0eaeabbf2a03e91a2dce99be46290dd80b25c1ab64cd1bbfe76fc3f02440e90fa8a059898963088f0fdb204931fdd1ebd73f433f7a50e69bc4c0ad3c79e93c96bcb7ee9a2267018d8da8bbe70011c8acb14c793faa2c9ce28b1a0e2ace21148729e18638d6a495eff92bb0aa07a156f0ff558d7d7473a4845b3762cb26e2d6482e6613490262672422166ac48547c0f99d5b55f41659c5ac590fdbac3e3b257b10c5f70dfa61b96c7dacb1c3d82f73528a351872a9069de6cd708a8d4f9ae7669b1cc62c22234f4171afb6fc736344db1facf5b787fa704f6847db68b1a71ccf1f8ea4f410784178142c580107de11beb564256f987b39d8750391e4621698870b0b00dbb66c97fecac9abfb11fe20874fcc50a473114db60bbf12d9c2d754b0b9b3b96fab7da8cc92d94cd7c23809f86c96ddb019ac9825a636dce6cabb40a3239ad273736c9d6d49106457b13a0ba591694df87a18f8869af7cf40f1aaac36c9534625e676b9970021ffe035885c36868f3bc1978e9626b147ca042a81b00f4b3ad2ebbc2ed16a53b7e5668e60b936d4821353fe9385d8a90d362144a0a148cd2d5a2b345cb67c041818701b47b637b4775c50762f73d289db4b41de9d669d004e1062994531be56700e9e3a74c18725cd3cc335d8e5b7fe122a1c7f9b51b6c88d341caf940f4e9649f4bc1bf071d37de2c3bb2712ded21dfdb777f72f2f993275343305c1a1fe49f730ea05d74cfb84c64469bd288bcaf594cc49aa09afa8e3b5d19b6fdce8975b64350475e8e2ab36077abe461df6375860e5df21964e01d4d193b4711154458a0aedda5ffe26d99a052e92ff9b11e27a1eeba4517152038390653090736207f0c68774ecd562d1f944699f3f8e112c70a4b5ef44ac25bc1107d349f5659ab24d85e93429278444151eb5424031c6c44018c2422091b859f209b96b41d94ebfcf7b968ed9613350c333f7ec338842bf52e6f5375b60af7f6103fab60bbe53fd5f18bc67cd12979406558223ba4aae86ab353caa268f671d7aa8b6b7faf9aec3e2703cd474005a61e1ba4b9a61c3986948ab73bbf486f8cada5634f93f06848191d03651a19b28a2cce0c4bd0f0f5d0370f900ccc34832339c706f9a59665075284ef74aaa15a1f561543e36448551ec44fe79b2cce785cfea61227466c1eb84d097616b080c0828f272aee41e535440376cb0a2c985a831da7970de93872aabb15806adfc9c69f61af6336fdf28e0813a20a2b16e8dd0f9dc7acc44fcac68f62dbd96587b28a1a52f4c95eb260d97eb2b40938108098280f2d0626fae48efd804ecc679179013679f6bb1d80648987e20db275cbf4f7c01dfc7a9f3d799c01217cd18712b33d0cea3d8548b52864d406891695957635c98ed918ca5a476c0a63d9d8bdced483d9d725a40ac75032a90423a4930cffa63b7ac74d4eff4b2233952d8ff483153a54e586bb501e205ab60205b0bc514a8aaf4e059961e6e5d86c72d1ac2b8b61b99a98bad7046200bd1bd9d70ad3284f2bf266dc180e7bee323950302190a4295b6e400a861637318094d59fb7d0dc0e5440912da474d4562970d5d510be9c5419cfabc86a1524ee381b7787729f3a2dbff776f3df10a7c3dd86d9d1cd11cc03978ff575716896a2eb584f32ae6ee76a19a53de675874f69f810625f03ff93cef0d48c27601696bd2874f179c053e94c8455553f0e6eed8fea4c0fe9f8e1b6ed7132a7383b114985816f70f665a7e427fe68e7e4811a074f32cf6062731b3c28ba51edad6b3c47c6f4d5011585d018bf6343f714b4cacc9e1cbc3f1617c4875141125ac59e22f9b44e46ea407beec1c32428ab100966baf7a3e0ec948e10b410d6297ff5e93a9730bbfadf b37afa0bf15dd8095ef4d560785c1bec0699e9ee003a5d2981e1827423402de00f26deb79a37b008197b52d1a011357b 970e292ef18d9ad2148c6ae063320bf871caf79b74d903787f30bfb73caeb43525bc50e503315f44a0931e7db1756c100ab9357cfa6408d48b172bf38d92a901b048fa516aca6126e5da7372509f0d947794b3a539288744174e43be010ba51f
fc00695525bfe7685a3e3b8a6a96b7d6d6cbce4855dba8bd56ef3cce6b615b33ae1be3bee41dd225ed19998386c14bbd0274767602120d93730a29a942d475bb588d99e214dc40893870dc32dc1d831b3a63db27f7684eb9c68f42ee3fc4cc749a1b124d7a3685d77db42995f39094c17317b8b1af5f053f7272331a6947fc246cab0820c36ba62024ef470a416e5ade69607957812c30322399250782f832a422c58cd1b2f23112fa5dddcd6035a71c9c361f741ea155a5c3dbb3280c53d149a50bb91fbf9bc68a1e766d3f50002f0c391705ffbf0bde8fea91aa2502127efaaa087039cd2dad18654002e7c016b307476474695ce586a876f0f2ce3bc92f7bc19da8716d5e1692c5f39d49c1b24fcbf7446fbe2b8da0b5fd9d82e2bf3b64bd710cb6338ae2b83d0a6037a9dafa269b464b0b39de2ed777452a1bf929573a1f0681a4bc313ea5b3dd4a504c8cf4c9668e0e0e5de6aa62176bbe54f4d5ea74baa1427c784341b25090ab827e5cdfadfd53d506026dc74f0cd8c7fd2b17e2a0f74ea556273b552f031b36770e9f3ea33b6b58a1250932d7bc0199fbd04e9e9134b322cd75af25a6354bf186ec8c0ee2db7cebb90aee6bae82939267661de060f7be432fcf32363ea06343ed2bc02910539a0548cd248c51872b912e0cd7b62295e5a268531b3a32dff460525f2a30873d8d4cad791dd186ebd0490bfbbcf0e9b8eae8c210c665d4bfd45bdb78a1629109f446046158b7a6c89cf2587509e3a4994ce1fabc4e96a82b973306f92e5d84de3cff540fa7aec1d4b8ebf5547ce29c41b67e1fea31008a237a604d279d5efd0ba912bf1586b2ae871f17c54f80f95c935096529b5e81f77592c76f2deb6d80098c42f672cb09d47ffe64c5fed73126cca63cbbdde1b39be92576c2806547943ef31ee2b9467ce8063a5798e4460ea55361486c5ade8c4105ae3f40a8f6e13496a00b59046df56b2163aa72bdd0c0937f0827d397f7da5aa6aa264f9bd125999bf2d3ef1930a35bdca9efba3eaf3c22641a361c842d1a9df979f1c079e11cecf6d210f7dc0a8043f02c87775cd19d18bd9019ea0ca190626e2b680ef9907063b09bdded123c8329f571307d680ed92743dd03c0bba30757a121178baed8c05aec09b93641e190c8524e377f2f755cc48db26180fc108cd3ab139de5344aa49df18621d404c5a526147a4490c9b815ee059161c9fa845c4db5aff31b0c36b5ed23b5f0741188d5f09a64a86ed13fcdca23675e30dab4cafc7ddb7ab0fb819b74483c3e96e0ead72c6a9e756520427edcea0e9d3e03151322049da2d382a4abd147aa802174dc540b0d964d42e673de61f18d4cdb610aa8e187b09fe7ac0d5eeb881e6cbe9d15b1ef742a0c2f1cedbc1b696ec8f212e37acbe144cb4bbc0ece44ef2dc6d47b19bdd1a14d7a646f4ae954c51c80e8c6b874f29b8dc8a35475087c39828cf4fbf6d3f149cb18696306cc27187eb68badea8311a9e258e2985bfb7490cc3bd72b1e7b9eb67e5af120327f892b482c37b1dffcc31c0765eff0d88c61af6255f4c6f1bf56711f151460b8a233257ec680e2d7e47845c5f34a18ae71be61d78c5fd52716e956d0747351ecee78a216380adab4bd101f15de114620f61fd3c385bd979d568b3adce7ad487f125e5fbc9664c93766b15a878eb18ca3ff2b27340689b9832068044ebc85b0bf7522b111308f9efbf774cc6c1df1b615d0e397e3aa8d5d8e08a43d1d2e461a5ec49b5a1f33eb5cb1742d7caa159339b7d5825b4b1645ca39d9e163f21a01ab31ec952596c645a513716c89aea19a2208056ccf1f59925b6c8b683826c48a167a677f7d533fd39f06a9435c1d0a0092e1c684b0deaf122603d7084750c4c53030771912fd4772007a924de469a1c24c928c7860f5c7752cedb2061d4237e8b3545103dfe60e33666144437918ab2e7e53f0f8029ebc304127d729ae5ccd6afc0317691bc11e0d94968b703d1bd2d87f5bc502d79172dbe60cd989ec2618c96f6ebbd514163cfa03ec80fa0a6dbea993400b5d96570b3b6ecd2b5909f4afac12b8ff98c52f254fad37349d1758ee00194bb597880d9c1241f6dd1fc0689262876b4620abbdeb00b2c8d12598c64baa50e8cd814533f5061e8fe2ef6c1a754dd8e3404fd1717e7012666d341353f9b246158fab7b729104ac7314ec3208b5b92054a58b7523175cacbb6f4b2a9b0650d640521c6a936894961329b939a742084c5722af0bd1438ae68bd1d2b9dbecb0081c77c079b281aecc8672a1852bbec32bab71d125268a486619c20c9a6caf16ad393b164c3937530993ddc85d2e4f2a4bd5ca8bd2bda41a39ce47fe2024a7015a95f69f4b4dc68d775f47d41c430e160521ce814de58c97875fcac964853861f21a6ad9cb45ee211450fc71cbbff50a8f0cbadcef00ed4e76fae6946e3979c793b2f4aade076d8925331608a23f22460749716e948bfd59cc14bde830234fad883e33f1b714336888d2df38ca9a55f0f4682f10c26d0710e4287328b475d9674c558ce88d3f5d1d4ad0e2291e16ee4aa8d1768a2c1858c96501a633e338905aa714cae9fd1c8234854489d79be5922dac8dc04f7f1dfaad50743c9045624245d1285e6f16ae0d70f8098e96061a675ca3f03b191afdb35ae46d605e88a74918835ada056bf6c6855d0c00cedbdd9f70a4b85fd6759902dfb369a960e4b78dd89d94f7f70168d9b860a912530969603e58d22b1e7b b9445f4601a08d207c50dc194e73efc49a73ebed4734a7abbfb2217e231bb5f8591b4095bc90d1025aaa875add716ba9