Boost _ Folks Finance 34025 - [Smart Contract - Medium] Malicious user can DoS the creation of every
Description
Brief/Intro
Vulnerability Details
function createAccount(
bytes32 accountId,
uint16 chainId,
bytes32 addr,
bytes32 refAccountId
) external override onlyRole(HUB_ROLE) {
// check account is not already created (empty is reserved for admin)
@> if (isAccountCreated(accountId) || accountId == bytes32(0)) revert AccountAlreadyCreated(accountId);
// check address is not already registered
if (isAddressRegistered(chainId, addr)) revert AddressPreviouslyRegistered(chainId, addr);
// check referrer is well defined
if (!(isAccountCreated(refAccountId) || refAccountId == bytes32(0)))
revert InvalidReferrerAccount(refAccountId);
// create account
accounts[accountId] = true;
accountAddresses[accountId][chainId] = AccountAddress({ addr: addr, invited: false, registered: true });
registeredAddresses[addr][chainId] = accountId;
emit CreateAccount(accountId, chainId, addr, refAccountId);
}Impact Details
References
Proof of concept
Proof of Concept
PreviousBoost _ Folks Finance 33987 - [Smart Contract - Medium] Incorrect access control in receiveMessage lNextBoost _ Folks Finance 34028 - [Smart Contract - Medium] Denial of Service DoS vulnerability in UserL
Last updated
Was this helpful?