Q2 2026 Security & Compliance Report67 incidents, $764M in losses, 88% from operational failures.
Get the report →

Audit name:

[SCA] GiveUs | Voting + DAO | May2023

Date:

Jul 5, 2023

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 GiveUs team for the collaborative engagement that enabled the execution of this Smart Contract Security Assessment.

GiveUs is crypto donation made easy and secure. The first crowdfunding platform for humanitarian projects, built on the Blockchain. GiveUs is a gathering of individuals who believe in the power of collective action to make a meaningful difference in the world.

titlecontent
PlatformEVM
LanguageSolidity
TagsDAO; Voting
Timeline05/05/2023 - 07/07/2023
Methodologyhttps://hackenio.cc/sc_methodology→

    Review Scope

    Repositoryhttps://github.com/Krayt78/GiveUsContracts/tree/Audit-Changes→
    Commit74e5746634be8f74042b38b7a0c982a2b82f2a36

    Audit Summary

    Total10/10
    Security Score

    10/10

    Test Coverage

    100%

    Code Quality Score

    10/10

    Documentation Quality Score

    10/10

    17Total Findings
    15Resolved
    0Accepted
    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 GiveUs
    Audited ByHacken
    Websitehttps://giveus.io/→
    Changelog12/07/2023 - Initial Review
    13/06/2023 - Second Review
    07/07/2023 - Third Review
    • Document

      Name
      Smart Contract Code Review and Security Analysis Report for GiveUs
      Audited By
      Hacken
      Changelog
      12/07/2023 - Initial Review
      13/06/2023 - Second Review
      07/07/2023 - Third Review

    System Overview

    The scope of this audit consists of a crowdfunding contract that aims to collect donations for project owners in the form of ERC20 tokens. The projects’ specifications are determined by an admin role called UPDATER_ROLE, which acts as the coordinator of each project funding in the system.

    Every project has several threshold donation values. When the donations reach thresholds, the sessions are voted by the donors for passage to the next session. If the votes are successful, project owners can withdraw the donations. If not, the session is reset and gets into a cooldown period.

    The files in the scope:

    • Crowdfunding.sol - The main contract of the system that is responsible for storing project specifications, the collection of funds, and withdrawal of funds.

    • ICrowdfunding.sol - Interface for Crowdfunding.sol.

    Privileged roles

    • Crowdfunding contract use Access Control to restrict access to important functions. In the contract, there are 3 key privileged roles:

    • PAUSER_ROLE - address with this privilege is permitted to pause and unpause contract in case of emergency.

    • UPDATER_ROLE - address with this privilege has access to most functions. This role can create new crowdfunding projects, start a vote session for a threshold for a given project, add new supported token, update donation fee for given project, update project status (set if project is active or not), update project vote cooldown and withdraw funds to other projects.

    • WITHDRAWER_ROLE - this role is defined in the system but never used. Address with this role does not have more privileges than other addresses. This role should be deleted.

    Executive Summary

    Documentation quality

    The total Documentation quality score is 10 out of 10.

    • Technical description is provided.

    • Description of the development environment is provided.

    • NatSpec is sufficient.

    Code quality

    The total Code quality score is 10 out of 10.

    • Best practices are followed.

    • Development environment is configured.

    Test coverage

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

    • Deployment and basic user interactions are covered with tests.

    • Negative cases coverage is present.

    • Interactions by several users are not tested thoroughly.

    Security score

    Upon auditing, the code was found to contain 2 critical, 3 high, 4 medium, and 4 low severity issues. Out of these, 13 issues have been addressed and resolved, leading to a Security 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

    No risks have been identified for this project.

    Findings

    F-2023-0666 Funds Lock
    Status
    fixed
    Severity

    Critical
    F-2023-0665Funds Lock / Undocumented Behavior
    Status
    fixed
    Severity

    Critical
    F-2023-0669 Highly Permissive Role Access / Token Balance Manipulation
    Status
    fixed
    Severity

    High
    F-2023-0668Undocumented Mathematical Operation
    Status
    fixed
    Severity

    High
    F-2023-0667Unchecked Transfer
    Status
    fixed
    Severity

    High
    F-2023-0673Contradiction
    Status
    fixed
    Severity

    Medium
    F-2023-0672Uninitialized Inheritance
    Status
    fixed
    Severity

    Medium
    F-2023-0671Contradiction - Missing Validation
    Status
    fixed
    Severity

    Medium
    F-2023-0670Non-Finalized Code
    Status
    fixed
    Severity

    Medium
    F-2023-0677 Redundant Modifier Usage
    Status
    fixed
    Severity

    Low
    Code
    ―
    Title
    Status
    Severity
    F-2023-0666 Funds Lock
    fixed

    Critical
    F-2023-0665Funds Lock / Undocumented Behavior
    fixed

    Critical
    F-2023-0669 Highly Permissive Role Access / Token Balance Manipulation
    fixed

    High
    F-2023-0668Undocumented Mathematical Operation
    fixed

    High
    F-2023-0667Unchecked Transfer
    fixed

    High
    F-2023-0673Contradiction
    fixed

    Medium
    F-2023-0672Uninitialized Inheritance
    fixed

    Medium
    F-2023-0671Contradiction - Missing Validation
    fixed

    Medium
    F-2023-0670Non-Finalized Code
    fixed

    Medium
    F-2023-0677 Redundant Modifier Usage
    fixed

    Low
    1-10 of 17 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:

    Scope Details

    Repositoryhttps://github.com/Krayt78/GiveUsContracts/tree/Audit-Changes→
    Commit74e5746634be8f74042b38b7a0c982a2b82f2a36
    WhitepaperProvided→
    RequirementsProvided→
    Technical RequirementsProvided→

    Contracts in Scope

    contracts
    Crowdfunding.sol - contracts › Crowdfunding.sol
    ICrowdfunding.sol - contracts › ICrowdfunding.sol

    Disclaimer