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

[ETHEREUM-CONRACTS] fix simple forwarder #2044

Closed
wants to merge 8 commits into from
Closed

Conversation

d10r
Copy link
Collaborator

@d10r d10r commented Dec 17, 2024

Problem: SimpleForwarder is deployed by the constructor of Superfluid.
SimpleForwarder.forwardCall was made onlyOwner for no good reason, other than mitigating potential unspecified phishing type abuse. However this causes it not to work in deployments where Superfluid (host) is upgradable, which is all prod deployments.
The tests didn't "see" this issue because the foundry deployer doesn't use an upgradable host instance.

Solution: remove the onlyOwner clause.
Also withdrawLostNativeTokens was replaced by logic which makes it impossible for any native tokens to remain in SimpleForwarder. They either are taken by the target, or taken back by the sender, or the tx fails. TODO: add test coverage verifying this.

Copy link

Changelog Reminder

Reminder to update the CHANGELOG.md for any of the modified packages in this PR.

  • CHANGELOG.md modified
  • Double check before merge

@d10r d10r changed the base branch from dev-next to cfa_hook_no_footgun December 17, 2024 14:00
@hellwolf hellwolf changed the base branch from cfa_hook_no_footgun to dev December 23, 2024 18:46
Copy link
Contributor

@hellwolf hellwolf left a comment

Choose a reason for hiding this comment

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

to be replaced by fix-simple-forwarder-2

@d10r d10r closed this Dec 23, 2024
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.

3 participants