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

Lack of zero address validation #56

Open
code423n4 opened this issue Jun 15, 2021 · 3 comments
Open

Lack of zero address validation #56

code423n4 opened this issue Jun 15, 2021 · 3 comments

Comments

@code423n4
Copy link
Contributor

Handle

JMukesh

Vulnerability details

Impact

constructor of RCorderbook.sol lacks zero address validation , since parameter of costructor are used initialize state variable which are used in other function of the contract , error in these state variable can lead to redeployment of contract

Proof of Concept

https://github.com/code-423n4/2021-06-realitycards/blob/main/contracts/RCOrderbook.sol#L106

Tools Used

manual review

Recommended Mitigation Steps

add require condition to check for zero address

@code423n4 code423n4 added 1 (Low Risk) bug Something isn't working labels Jun 15, 2021
code423n4 added a commit that referenced this issue Jun 15, 2021
@Splidge
Copy link
Collaborator

Splidge commented Jun 16, 2021

I think the zero address validation isn't a problem for factoryAddress as this can be set later in the function setFactoryAddress
However yes Treasury is missing a possible setTreasuryAddress

@Splidge
Copy link
Collaborator

Splidge commented Jun 21, 2021

implemented here

@Splidge
Copy link
Collaborator

Splidge commented Jun 21, 2021

Additional changes for #142 and #115 are here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants