Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat:! Allow outgoing messages to any address #4488

Closed
4 of 5 tasks
LHerskind opened this issue Feb 7, 2024 · 0 comments · Fixed by #4512
Closed
4 of 5 tasks

feat:! Allow outgoing messages to any address #4488

LHerskind opened this issue Feb 7, 2024 · 0 comments · Fixed by #4512
Assignees

Comments

@LHerskind
Copy link
Contributor

LHerskind commented Feb 7, 2024

Problem

We want to support sending messages to any address from an aztec contract.

Background

Currently, an aztec contract specify a portal_address at time of deployment.

The use of this address is rather simple:

  • for incoming messages it can be used to constrain L1 sender (app-circuit can chose to do this)
  • for outgoing messages it must be used as the recipient (kernel always enforces this)

The reasoning behind this is the same issue as discussed in #4130 - having a value that anyone can use to constrain against (without having race-conditions) is quite painful in the private domain.

By having the immutable value portal_address we have an easily accessible value in private that you can still constraint against.

However, hence we are currently forcing it in the kernel, we have this issue where applications that would want to send messages to different address, in private or public, simple cannot do that currently.

This means that applications such as upgradable bridges need to have a somewhat awkward design since it might be desirable to change the portal address sending messages to.

Solution

Since we have alternatives (even if not perfect) to stable values in private and public could always just used shared storage, we can allow sending messages to any address intended by adding another argument to the message_portal() function while still keeping the portal_address immutable.

By keeping the portal_address we can always use the "easy" solution for the communication, but allow more flexibility to developers that need it.

Tasks

Preview Give feedback
@LHerskind LHerskind added this to A3 Feb 7, 2024
@github-project-automation github-project-automation bot moved this to Todo in A3 Feb 7, 2024
github-merge-queue bot pushed a commit that referenced this issue Feb 15, 2024
Fixes #4488

Also fixed there 2 commands broken on master.
@github-project-automation github-project-automation bot moved this from Todo to Done in A3 Feb 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants