The NexusFactory.sol contract allows users to create smart accounts, but it only emits the AccountCreated event when the account is not already deployed. This results in a lack of transparency and traceability when accounts are deployed deterministically and already exist.
The createAccount function in the NexusFactory.sol contract is responsible for creating smart accounts. It computes a deterministic address and checks if the account is already deployed. If the account is not already deployed, it initializes the account and emits the AccountCreated event. However, if the account is already deployed, no event is emitted.
The absence of the AccountCreated event emission for already deployed accounts can lead to:
Potential Inconsistencies: Event-based off-chain systems relying on these events might miss critical information.
Emit the AccountCreated event regardless of whether the account was already deployed or not. This ensures transparency and traceability of all account creations.
This modification ensures that the AccountCreated event is emitted for every account creation.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.