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

Missing zero address check which will put forfeited rewards at risk(ForefeitHandler.sol) #216

Open
code423n4 opened this issue Nov 30, 2021 · 1 comment
Labels
1 (Low Risk) Assets are not at risk. State handling, function incorrect as to spec, issues with comments 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

0xwags

Vulnerability details

Impact

Since users forfeited awards will be shared between either the treasury and the swing trader, there should be a zero address in the initialize() function to ensure rewards are not lost and thereby affecting Malt's collateralisation and other such funding mechanism.

This will have implications for safetransfer() functions in lines 50 & 54 in handleForfeit().

Tools Used

Manual Analysis.

Recommended Mitigation Steps

require(treasuryMultisig&& swingTrader ! =address(0), "0x0");

@code423n4 code423n4 added 3 (High Risk) Assets can be stolen/lost/compromised directly bug Something isn't working labels Nov 30, 2021
code423n4 added a commit that referenced this issue Nov 30, 2021
@0xScotch 0xScotch added disagree with severity Sponsor confirms validity, but disagrees with warden’s risk assessment (sponsor explain in comments) sponsor confirmed Sponsor agrees this is a problem and intends to fix it (OK to use w/ "disagree with severity") and removed disagree with severity Sponsor confirms validity, but disagrees with warden’s risk assessment (sponsor explain in comments) labels Dec 3, 2021
@GalloDaSballo
Copy link
Collaborator

Heavily disagree with severity on this finding

The finding is valid, but as per most auditing firms, lack of input validation is a low severity finding.

The consequences showed by the warden are not as dire as they sound as calling as doing a CALL on the address 0 will revert

Will mark this as Low Seveirty

@GalloDaSballo GalloDaSballo added 1 (Low Risk) Assets are not at risk. State handling, function incorrect as to spec, issues with comments and removed 3 (High Risk) Assets can be stolen/lost/compromised directly labels Jan 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1 (Low Risk) Assets are not at risk. State handling, function incorrect as to spec, issues with comments 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