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

Audit name:

[SCA] Authic Labs | NFT Marketplace | Jun2023

Date:

Jul 26, 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 Authic Labs team for the collaborative engagement that enabled the execution of this Smart Contract Security Assessment.

Authic Labs is a B2B SaaS loyalty platform, leveraging blockchain technology to create unique brand experiences.

titlecontent
PlatformEVM
LanguageSolidity
TagsERC1155; NFT Marketplace
Timeline10/06/2023 - 02/08/2023
Methodologyhttps://hackenio.cc/sc_methodology→

    Review Scope

    Repositoryhttps://gitlab.com/a7717/authic-smart-contracts→
    Commite67250b

    Audit Summary

    Total8.9/10
    Security Score

    10/10

    Test Coverage

    83.71%

    Code Quality Score

    9/10

    Documentation Quality Score

    7/10

    20Total Findings
    17Resolved
    0Accepted
    1Mitigated

    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 Authic Labs
    Audited ByHacken
    Websitehttps://authic.io→
    Changelog15/06/2023 - Initial Review
    02/08/2023 - Second Review
    • Document

      Name
      Smart Contract Code Review and Security Analysis Report for Authic Labs
      Audited By
      Hacken
      Changelog
      15/06/2023 - Initial Review
      02/08/2023 - Second Review

    System Overview

    AuticLabs - is an NFT market place with following smart contracts:

    • FactoryV2 - is a factory smart contract for creating and managing ERC-1155 token collections. It is implemented with several features to enhance its security and functionality. The factory contract allows the creation of new token collections, each assigned a minter role to a designated marketplace.

    • PrimaryMarketPlaceV2 - is a marketplace smart contract that allows the purchase of ERC-1155 tokens at a fixed price. It includes the functionality to withdraw commission and pause, unpause the contract.

    • AuthicERC1155 - an implementation of a smart contract for ERC1155, which is a token standard on the Ethereum blockchain. The contract allows for the minting, transfer, and burning of tokens. It also includes royalty functionality, meaning that certain addresses can receive a defined percentage of transactions involving specific tokens. Additionally, it includes a mechanism to check if an address is permitted to mint tokens using a Merkle proof.

    • IERC1155 - an interface for ERC1155 smart contract.

    • IERC1155Receiver - an interface of ERC1155 token receiver.

    • IFactory - an interface for FactroryV2 smart contract.

    • IPrimaryMarketplace - an interface for PrimaryMarketPlaceV2 smart contract.

    Privileged roles

    FactoryV2:

    • Admin Role: granted to the contract deployer initially and can perform critical operations such as:

      • Pausing and unpausing the contract.

      • Modifying the marketplace and validator addresses.

    PrimaryMarketPlaceV2:

    • Admin Role: granted to the contract deployer initially and can perform critical operations such as:

      • Withdraw fees, set validator pause and unpause smart contract.

    AuthicERC1155:

    • Admin Role: granted to the contract creator during the contract deployment. It allows the holder to perform administrative functions such as:

      • Updating the Merkle root for whitelisting and setting the maximum supply for a token. It can add new token types to the contract.

      • The role is granted to the marketplace address during the contract deployment. This allows the holder to mint new tokens to a specified address.

    Executive Summary

    Documentation quality

    The total Documentation quality score is 7 out of 10.

    • Technical description is inadequate:

      • Run instructions are provided.

      • Technical specification is provided.

      • NatSpec is sufficient.

    • Functional requirements are present, but only in a limited capacity:

      • Overall system requirements are provided.

      • No roles description.

      • Use cases are not fully described.

    Code quality

    The total Code quality score is 10 out of 10.

    • Best practice violation.

    Test coverage

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

    • Deployment and basic user interactions are covered with tests.

    • Interactions by several users are tested thoroughly.

    Security score

    Upon auditing, the code was found to contain 2 critical, 2 high, 5 medium, and 2 low severity issues. Out of these, 11 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 8.9. This score reflects the combined evaluation of documentation, code quality, test coverage, and security aspects of the project.

    Risks

    Iterating over a dynamic array populated with custom tokenId can lead to Gas limit denial of service if the number of tokenIds gets too big.

    Payment Splitter.sol is deprecated by OpenZeppelin, this can cause problems in the later stages of the project's lifecycle.

    Findings

    F-2023-0077Requirements Violation
    Status
    fixed
    Severity

    Critical
    F-2023-0076Compilation Error
    Status
    fixed
    Severity

    Critical
    F-2023-0079Requirements Violation
    Status
    fixed
    Severity

    High
    F-2023-0078Funds Lock - Leftover Funds
    Status
    fixed
    Severity

    High
    F-2023-0084Highly Permissive Role Access
    Status
    mitigated
    Severity

    Medium
    F-2023-0083Inefficient Gas Modeling
    Status
    fixed
    Severity

    Medium
    F-2023-0082Best Practice Violation: Usage of built-in Transfer
    Status
    fixed
    Severity

    Medium
    F-2023-0081Unchecked Return Value
    Status
    fixed
    Severity

    Medium
    F-2023-0080Missing Events
    Status
    fixed
    Severity

    Medium
    F-2023-0086Function Naming Mismatch
    Status
    fixed
    Severity

    Low
    Code
    ―
    Title
    Status
    Severity
    F-2023-0077Requirements Violation
    fixed

    Critical
    F-2023-0076Compilation Error
    fixed

    Critical
    F-2023-0079Requirements Violation
    fixed

    High
    F-2023-0078Funds Lock - Leftover Funds
    fixed

    High
    F-2023-0084Highly Permissive Role Access
    mitigated

    Medium
    F-2023-0083Inefficient Gas Modeling
    fixed

    Medium
    F-2023-0082Best Practice Violation: Usage of built-in Transfer
    fixed

    Medium
    F-2023-0081Unchecked Return Value
    fixed

    Medium
    F-2023-0080Missing Events
    fixed

    Medium
    F-2023-0086Function Naming Mismatch
    fixed

    Low
    1-10 of 20 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://gitlab.com/a7717/authic-smart-contracts→
    Commite67250b
    WhitepaperNot provided
    RequirementsProvided→
    Technical RequirementsProvided→

    Contracts in Scope

    contracts
    ERC1155
    Factory.sol - contracts › ERC1155 › Factory.sol
    PrimaryMarketplace.sol - contracts › ERC1155 › PrimaryMarketplace.sol
    CustomERC1155.sol - contracts › ERC1155 › CustomERC1155.sol
    interface
    IERC1155.sol - contracts › ERC1155 › interface › IERC1155.sol
    IERC1155Receiver.sol - contracts › ERC1155 › interface › IERC1155Receiver.sol
    IFactory.sol - contracts › ERC1155 › interface › IFactory.sol
    IPrimaryMarketplace.sol - contracts › ERC1155 › interface › IPrimaryMarketplace.sol

    Disclaimer