Skip to content

feat!: make get_shared_secrets batched oracle call#23352

Merged
nchamo merged 4 commits into
merge-train/fairiesfrom
nchamo/f-656-replace-get_shared_secret-with-batched-version
May 18, 2026
Merged

feat!: make get_shared_secrets batched oracle call#23352
nchamo merged 4 commits into
merge-train/fairiesfrom
nchamo/f-656-replace-get_shared_secret-with-batched-version

Conversation

@nchamo

@nchamo nchamo commented May 17, 2026

Copy link
Copy Markdown
Contributor

Why we are doing this

As part of constrained delivery, computing multiple shared secrets for multiple ephemeral public keys is needed. The existing oracle only supported a single eph key per call, requiring repeated round-trips for multi-key scenarios.

Our fix

aztec_utl_getSharedSecret has been replaced by aztec_utl_getSharedSecrets, which accepts a batch of ephemeral public keys via an EphemeralArray slot and returns the corresponding secrets. The oracle major version has been bumped to 23.

The existing get_shared_secret Noir function is preserved as a thin wrapper around get_shared_secrets, so single-key callers are unaffected. The new get_shared_secrets function accepts a BoundedVec<Point, N> and returns a BoundedVec<Field, N>.

Fixes F-656

@nchamo nchamo requested a review from nventuro as a code owner May 17, 2026 15:38
@nchamo nchamo self-assigned this May 17, 2026
nchamo added 3 commits May 17, 2026 16:44
…ared_secret

- Consolidate imports using grouped `use` statements
- Add explicit type annotations on BoundedVec bindings for type inference
- Add turbofish ::<1> on singular get_shared_secrets call
- Make mock_get_shared_secrets unconstrained (calls unconstrained FFI)
- Fix AztecAddress import path to use re-export pattern
- Add missing FromField import in test module
…rdering test

x=3 has no valid point on Grumpkin (y^2 = x^3 - 17); x=8 is a known valid x coordinate.
@nchamo nchamo requested review from mverzilli and vezenovm May 17, 2026 17:02
@mverzilli mverzilli added ci-compat-e2e Checks that contracts compiled in older stable versions still work on current stack. and removed ci-compat-e2e Checks that contracts compiled in older stable versions still work on current stack. labels May 18, 2026

@mverzilli mverzilli left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

@nchamo nchamo merged commit 941cb6b into merge-train/fairies May 18, 2026
31 checks passed
@nchamo nchamo deleted the nchamo/f-656-replace-get_shared_secret-with-batched-version branch May 18, 2026 17:17
danielntmd pushed a commit to danielntmd/aztec-packages that referenced this pull request Jun 4, 2026
BEGIN_COMMIT_OVERRIDE
feat!: make get_shared_secrets batched oracle call (AztecProtocol#23352)
feat(ci): run aztec-cli acceptance test on macOS (AztecProtocol#23309)
END_COMMIT_OVERRIDE
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants