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

execute in VoteProxy should be payable #17

Open
code423n4 opened this issue Feb 3, 2022 · 2 comments
Open

execute in VoteProxy should be payable #17

code423n4 opened this issue Feb 3, 2022 · 2 comments
Labels
2 (Med Risk) Assets not at direct risk, but function/availability of the protocol could be impacted or leak value bug Something isn't working sponsor confirmed Sponsor agrees this is a problem and intends to fix it (OK to use w/ "disagree with severity")

Comments

@code423n4
Copy link
Contributor

Handle

wuwe1

Vulnerability details

Impact

execute will revert when msg.value > 0

Proof of Concept

Lacking payable mutability specifier.

https://github.com/code-423n4/2022-02-concur/blob/main/contracts/VoteProxy.sol#L28-L35

    function execute(
        address _to,
        uint256 _value,
        bytes calldata _data
    ) external onlyOwner returns (bool, bytes memory) {
        (bool success, bytes memory result) = _to.call{value: _value}(_data);
        return (success, result);
    }

Recommended Mitigation Steps

Add payable mutability specifier.

@code423n4 code423n4 added 2 (Med Risk) Assets not at direct risk, but function/availability of the protocol could be impacted or leak value bug Something isn't working labels Feb 3, 2022
code423n4 added a commit that referenced this issue Feb 3, 2022
@leekt leekt added the sponsor confirmed Sponsor agrees this is a problem and intends to fix it (OK to use w/ "disagree with severity") label Feb 18, 2022
@GalloDaSballo
Copy link
Collaborator

@leekt Can you tell me what you'd need execute to be used for?

Do you really need it to be payable?

@GalloDaSballo
Copy link
Collaborator

After some thinking I do believe that it would be wise to allow for payable calls

Will mark as valid and because this is contingent on a specific usage, I think Medium Severity to be appropriate

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2 (Med Risk) Assets not at direct risk, but function/availability of the protocol could be impacted or leak value bug Something isn't working sponsor confirmed Sponsor agrees this is a problem and intends to fix it (OK to use w/ "disagree with severity")
Projects
None yet
Development

No branches or pull requests

3 participants