Core Contracts

Regnum Aurum Acquisition Corp
HardhatReal World AssetsNFT
77,280 USDC
View results
Submission Details
Severity: low
Invalid

Missing Event Emission for Emission Rate Updates: Critical State Change Without Notification

Summary

A Low severity vulnerability has been identified in the RAACMinter contract where the updateEmissionRate() function modifies the emission rate without emitting an event. This omission prevents external systems from tracking critical state changes, compromising system transparency and monitoring capabilities.

Vulnerability Details

Issue: No Event for updateEmissionRate()

Location: updateEmissionRate() function

Description:

function updateEmissionRate() public whenNotPaused {
if (emissionUpdateInterval > 0 && block.timestamp < lastEmissionUpdateTimestamp + emissionUpdateInterval) {
revert EmissionUpdateTooFrequent();
}
uint256 newRate = calculateNewEmissionRate();
emissionRate = newRate;
lastEmissionUpdateTimestamp = block.timestamp;
// Missing event emission here
}

Root Cause

The vulnerability stems from a missing event emission in the updateEmissionRate() function. While the function correctly updates the emission rate, it fails to notify external systems of this critical state change.

Impact

The missing event emission has several significant consequences:

  • External systems cannot track emission rate changes in real-time

  • Frontend applications cannot update their displays automatically

  • Auditing becomes more complex and error-prone

Tools Used

  • Manual code review

  • Static analysis

  • Smart contract security best practices analysis

Proof of Concept

Mitigation

To fix this vulnerability, add an event emission to the updateEmissionRate() function:

event EmissionRateUpdated(uint256 oldRate, uint256 newRate);
function updateEmissionRate() public whenNotPaused {
if (emissionUpdateInterval > 0 && block.timestamp < lastEmissionUpdateTimestamp + emissionUpdateInterval) {
revert EmissionUpdateTooFrequent();
}
uint256 newRate = calculateNewEmissionRate();
uint256 oldRate = emissionRate;
emissionRate = newRate;
lastEmissionUpdateTimestamp = block.timestamp;
emit EmissionRateUpdated(oldRate, newRate); // Add this line
}

Recommendations

  1. Implement the proposed event emission fix immediately

  2. Review all state-changing functions for similar missing events

  3. Update monitoring systems to track the new event

  4. Document the event in the contract's documentation

Updates

Lead Judging Commences

inallhonesty Lead Judge 4 months ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.