Commit 6696135
authored
Cherry-picks #22854 (`feat(aztec-nr): Initial handshake registry
contract with non interactive handshake function`) to
`backport-to-v4-next-staging`.
## Conflict resolution
The only conflict was in
`noir-projects/noir-protocol-circuits/crates/types/src/constants_tests.nr`.
`next` has accumulated a number of new merkle/partial-note dom seps
(`DOM_SEP__MERKLE_HASH`, `DOM_SEP__NULLIFIER_MERKLE`,
`DOM_SEP__PARTIAL_NOTE_COMMITMENT`, `DOM_SEP__PUBLIC_DATA_MERKLE`) that
don't exist on `v4-next`, so the upstream version of this file imports
symbols that aren't defined here.
Resolution: drop the imports/assertions for those non-existent
constants, but keep the two new ones added by this PR
(`DOM_SEP__HANDSHAKE_SECRET_HASH`,
`DOM_SEP__NON_INTERACTIVE_HANDSHAKE_LOG_TAG`). `HashedValueTester` sized
`<58, 51>` = v4-next baseline `<56, 49>` plus the two new dom seps.
Validated:
- Imports list matches the symbols actually referenced inside
`hashed_values_match_derived` (no orphan imports / no missing imports).
- Assertion counts inside the test match the tester generics: `48`
`assert_dom_sep_matches_derived` + `3`
`assert_blob_prefixes_match_derived` = 51 u32 values; plus `1`
protocol-circuit value + `6` aztec-nr values = 58 total field values.
- All aztec-nr APIs the new contract uses (`derive_ecdh_shared_secret`,
`generate_positive_ephemeral_key_pair`, `set_sender_for_tags`,
`compute_log_tag`, `MessageDelivery.ONCHAIN_UNCONSTRAINED`, `Owned`,
`emit_private_log_vec_unsafe`, `to_address_point`,
`compute_siloed_private_log_first_field`,
`poseidon2_hash_with_separator`) exist on `v4-next` — the contract uses
the `aztec::protocol` re-export of `protocol_types`.
## Commit structure
Per the backport convention, history is preserved as:
1. Cherry-pick with conflicts (markers in tree, recorded in history).
2. Conflict resolution commit (this PR's tip).
No separate build-fixes commit was needed — the conflict was
metadata-only.
## Build verification
The container does not ship a prebuilt `nargo`, and Docker is
unavailable, so `noir-contracts/bootstrap.sh` cannot run locally.
Relying on CI for end-to-end build validation.
Original PR: #22854
ClaudeBox log: https://claudebox.work/s/096af9ddd4f770c8?run=4
8 files changed
Lines changed: 428 additions & 3 deletions
File tree
- noir-projects
- noir-contracts
- contracts/message_discovery/handshake_registry_contract
- src
- noir-protocol-circuits/crates/types/src
- yarn-project/constants/src
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
| 29 | + | |
29 | 30 | | |
30 | 31 | | |
31 | 32 | | |
| |||
Lines changed: 8 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
Lines changed: 43 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
Lines changed: 111 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
0 commit comments