Q1 2026 Security & Compliance Report44 incidents, $482M in losses, insights from 11 industry leaders.
Read the report

Audit name:

[SCA] DERA | ERC20 | Apr2024

Date:

Apr 29, 2024

Table of Content

Introduction
Audit Summary
Document Information
System Overview
Executive Summary
Risks
Findings
Appendix 1. Severity Definitions
Appendix 2. Scope
Disclaimer

Want a comprehensive audit report like this?

Introduction

We express our gratitude to the Digital Era team for the collaborative engagement that enabled the execution of this Smart Contract Security Assessment.

DERA is a protocol which allows to interact with the different farming pools.

titlecontent
PlatformEVM
LanguageSolidity
TagsDEX
Timeline05/04/2024 - 06/05/2024
Methodologyhttps://hackenio.cc/sc_methodology

    Review Scope

    Repositoryhttps://github.com/Digital-Era-Foundation/smart-contracts
    Commit4b04fec66620b39bcb67ca0686af0a8a3ef60821

    Audit Summary

    Total10/10
    Security Score

    10/10

    Test Coverage

    100%

    Code Quality Score

    10/10

    Documentation Quality Score

    10/10

    5Total Findings
    4Resolved
    1Accepted
    0Mitigated

    The system users should acknowledge all the risks summed up in the risks section of the report

    Document Information

    This report may contain confidential information about IT systems and the intellectual property of the Customer, as well as information about potential vulnerabilities and methods of their exploitation.

    The report can be disclosed publicly after prior consent by another Party. Any subsequent publication of this report shall be without mandatory consent.

    Document

    NameSmart Contract Code Review and Security Analysis Report for Digital Era
    Audited ByMax Fedorenko, Roman Tiutiun
    Approved ByGrzegorz Trawinski
    Websitehttps://hacken.io
    Changelog10/04/2024 - Preliminary Report; 06/05/2024 - Final Report
    • Document

      Name
      Smart Contract Code Review and Security Analysis Report for Digital Era
      Audited By
      Max Fedorenko, Roman Tiutiun
      Approved By
      Grzegorz Trawinski
      Changelog
      10/04/2024 - Preliminary Report; 06/05/2024 - Final Report

    System Overview

    DERA is a protocol that allows to interaction with different farming pools and includes the following contracts:

    • DERA1  — simple ERC-20 token that mints all initial supply to a deployer.

    • DeraAdmin — a contract which allows to manage whitelisted tokens, protocol pools, and allocation percentages, among other functionalities, while ensuring only the owner can execute administrative tasks.

    • DeraEngine — a contract serves as the operational engine for the DERA protocol, facilitating the deposit funds to the third party protocols, minting and burning of DERA tokens based on USDT values.

    • BeefyProtocolConnector — a connector facilitating the deposit and withdrawal of funds from the protocol, performing necessary token swaps and liquidity operations, and ensuring seamless integration with the DERA protocol's operations.

    Privileged roles

    • The owner of the DERA1 contract can mint, and burn tokens.

    • The owner of the DeraAdmin contract can add a protocol pool, set protocol allocation, update the protocol pool, remove protocol, add whitelisted tokens, remove whitelisted tokens, and set spread.

    Executive Summary

    Documentation quality

    The total Documentation Quality score is 10 out of 10.

    Code quality

    The total Code Quality score is 10 out of 10.

    Test coverage

    Code coverage of the project is 100% (branch coverage).

    Security score

    Upon auditing, the code was found to contain 0 critical, 0 high, 1 medium, and 1 low severity issues, leading to a security score of 9 out of 10. Upon the retest, all issues were fixed resulting in the final score of 10 out of 10.

    All identified issues are detailed in the “Findings” section of this report.

    Summary

    The comprehensive audit of the customer's smart contract yields an overall score of 10. This score reflects the combined evaluation of documentation, code quality, test coverage, and security aspects of the project.

    Risks

    Dependency on External Logic for Implemented Logic: The implemented DeraEngine and BeefyProtocolConnector logic highly depends on external contracts not covered by the audit. This reliance introduces risks if these external contracts are compromised or contain vulnerabilities, affecting the audited project's integrity.

    System Reliance on External Contracts: The functioning of the system significantly relies on specific external contracts. Any flaws or vulnerabilities in these contracts adversely affect the audited project, potentially leading to security breaches or loss of funds.

    Interactions with External DeFi Protocols: Dependence on external DeFi protocols inherits their risks and vulnerabilities. This might lead to direct financial losses if these protocols are exploited, indirectly affecting the audited project.

    Centralized Control of Minting and Burning Process: The token contract’s design allows for centralized control over the minting and burning process, posing a risk of unauthorized token issuance, potentially diluting the token value and undermining trust in the project's economic governance.

    Administrative Key Control Risks: The digital contract architecture relies on administrative keys for critical operations. Centralized control over these keys presents a significant security risk, as compromise or misuse can lead to unauthorized actions or loss of funds.

    Absence of Time-lock Mechanisms for Critical Operations: Without time-locks on critical operations, there is no buffer to review or revert potentially harmful actions, increasing the risk of rapid exploitation and irreversible changes.

    Findings

    Code
    Title
    Status
    Severity
    F-2024-2066Unlimited Allowance
    fixed

    Medium
    F-2024-2059Unrestricted System Spread
    fixed

    Low
    F-2024-2069Floating Pragma
    accepted

    Observation
    F-2024-2065Commented Code Parts TODO And NOTE Comments
    fixed

    Observation
    F-2024-2063Redundant Import Statement
    fixed

    Observation
    1-5 of 5 findings

    Identify vulnerabilities in your smart contracts.

    Appendix 1. Severity Definitions

    When auditing smart contracts, Hacken is using a risk-based approach that considers Likelihood, Impact, Exploitability and Complexity metrics to evaluate findings and score severities.

    Reference on how risk scoring is done is available through the repository in our Github organization:

    Severity

    Description

    Critical
    Critical vulnerabilities are usually straightforward to exploit and can lead to the loss of user funds or contract state manipulation.

    High
    High vulnerabilities are usually harder to exploit, requiring specific conditions, or have a more limited scope, but can still lead to the loss of user funds or contract state manipulation.

    Medium
    Medium vulnerabilities are usually limited to state manipulations and, in most cases, cannot lead to asset loss. Contradictions and requirements violations. Major deviations from best practices are also in this category.

    Low
    Major deviations from best practices or major Gas inefficiency. These issues will not have a significant impact on code execution, do not affect security score but can affect code quality score.
    • Severity

      Critical

      Description

      Critical vulnerabilities are usually straightforward to exploit and can lead to the loss of user funds or contract state manipulation.

      Severity

      High

      Description

      High vulnerabilities are usually harder to exploit, requiring specific conditions, or have a more limited scope, but can still lead to the loss of user funds or contract state manipulation.

      Severity

      Medium

      Description

      Medium vulnerabilities are usually limited to state manipulations and, in most cases, cannot lead to asset loss. Contradictions and requirements violations. Major deviations from best practices are also in this category.

      Severity

      Low

      Description

      Major deviations from best practices or major Gas inefficiency. These issues will not have a significant impact on code execution, do not affect security score but can affect code quality score.

    Appendix 2. Scope

    The scope of the project includes the following smart contracts from the provided repository:

    Contracts in Scope

    src
    core
    DERA1.sol - src › core › DERA1.sol
    DeraAdmin.sol - src › core › DeraAdmin.sol
    DeraEngine.sol - src › core › DeraEngine.sol
    interfaces
    IDefiProtocolConnector.sol - src › interfaces › IDefiProtocolConnector.sol
    IDERA1.sol - src › interfaces › IDERA1.sol
    IDeraAdmin.sol - src › interfaces › IDeraAdmin.sol
    IDeraEngine.sol - src › interfaces › IDeraEngine.sol
    IStorage.sol - src › interfaces › IStorage.sol
    IUSDT.sol - src › interfaces › IUSDT.sol
    protocols
    beefy
    BeefyProtocolConnector.sol - src › protocols › beefy › BeefyProtocolConnector.sol
    interfaces
    IStargateRouter.sol - src › protocols › beefy › interfaces › IStargateRouter.sol
    IStrategy.sol - src › protocols › beefy › interfaces › IStrategy.sol
    IUniswapV3Router.sol - src › protocols › beefy › interfaces › IUniswapV3Router.sol
    IVault.sol - src › protocols › beefy › interfaces › IVault.sol

    Disclaimer