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

Petite Pewter Orangutan - No access control on setCollateralEscrowBeacon #55

Open
sherlock-admin2 opened this issue Dec 10, 2024 · 0 comments

Comments

@sherlock-admin2
Copy link

Petite Pewter Orangutan

High

No access control on setCollateralEscrowBeacon

Summary

CollateralManager::setCollateralEscrowBeacon can be called by anyone.

Root Cause

No response

Internal pre-conditions

No response

External pre-conditions

No response

Attack Path

No response

Impact

An attacker can set the escrow beacon and drain funds.
As we can see it has reinitializer, which means it can be changed.

PoC

CollateralManager::setCollateralEscrowBeacon

    /**
     * @notice Sets the address of the Beacon contract used for the collateral escrow contracts.
     * @param _collateralEscrowBeacon The address of the Beacon contract.
     */
    function setCollateralEscrowBeacon(address _collateralEscrowBeacon)
        external
        reinitializer(2)
    {
        collateralEscrowBeacon = _collateralEscrowBeacon;
    }

Mitigation

for setCollateralEscrowBeacon() set onlyTellerV2 modifier.

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

No branches or pull requests

1 participant