TokenAI Info
TokenAi, Nasdaq YYAI's ecosystem engine, offers 6% daily returns. Hong Kong launch summit on May 15.
TrustNet Score
The TrustNet Score evaluates crypto projects based on audit results, security, KYC verification, and social media presence. This score offers a quick, transparent view of a project's credibility, helping users make informed decisions in the Web3 space.
Real-Time Threat Detection
Real-time threat detection, powered by Cyvers.io,
is currently not
activated
for this project.
This advanced feature provides continuous monitoring and instant alerts to safeguard your assets from potential security threats. Real-time detection enhances your project's security by proactively identifying and mitigating risks.
For more information, click here.
Summary and Final Words
No crucial issues found
The contract does not contain issues of high or medium criticality. This means that no known vulnerabilities were found in the source code.
Contract owner cannot mint
It is not possible to mint new tokens.
Contract owner cannot blacklist addresses.
It is not possible to lock user funds by blacklisting addresses.
Contract owner cannot set high fees
The fees, if applicable, can be a maximum of 25% or lower. The contract can therefore not be locked. Please take a look in the comment section for more details.
Contract cannot be locked
Owner cannot lock any user funds.
Token cannot be burned
There is no burning within the contract without any allowances
Ownership is renounced
The contract does not include owner functions that allow post-deployment modifications.
Contract is not upgradeable
The contract does not use proxy patterns or other mechanisms to allow future upgrades. Its behavior is locked in its current state.
Scope of Work
This audit encompasses the evaluation of the files listed below, each verified with a SHA-1 Hash. The team referenced above has provided the necessary files for assessment.
The auditing process consists of the following systematic steps:
- Specification Review: Analyze the provided specifications, source code, and instructions to fully understand the smart contract's size, scope, and functionality.
- Manual Code Examination: Conduct a thorough line-by-line review of the source code to identify potential vulnerabilities and areas for improvement.
- Specification Alignment: Ensure that the code accurately implements the provided specifications and intended functionalities.
- Test Coverage Assessment: Evaluate the extent and effectiveness of test cases in covering the codebase, identifying any gaps in testing.
- Symbolic Execution: Analyze the smart contract to determine how various inputs affect execution paths, identifying potential edge cases and vulnerabilities.
- Best Practices Evaluation: Assess the smart contracts against established industry and academic best practices to enhance efficiency, maintainability, and security.
- Actionable Recommendations: Provide detailed, specific, and actionable steps to secure and optimize the smart contracts.
A file with a different Hash has been intentionally or otherwise modified after the security review. A different Hash may indicate a changed condition or potential vulnerability that was not within the scope of this review.
Final Words
The following provides a concise summary of the audit report, accompanied by insightful comments from the auditor. This overview captures the key findings and observations, offering valuable context and clarity.
Smart Contract Analysis Statement
Contract Analysis
The YYAI contract implements a standard ERC20 token built on the OpenZeppelin v5 base contracts with three project-specific additions: an owner-gated mint function, the burn extension, and a convenience batchTransfer that forwards multiple transfers in a single call. The overall design follows common patterns on BNB Smart Chain, and the on-chain runtime bytecode is verified as an exact match of the published source. A few areas need attention:
- The mint function was protected only by a single-step Ownable model, with no supply cap in code. Although the deployer renounced ownership shortly after launch and the function is now permanently unreachable, the design itself permitted unbounded inflation during the early window.
- The batchTransfer function iterates over a user-supplied recipient array without any upper bound. A caller passing a very large array runs into the block gas limit. This is mostly self-inflicted, but any contract wrapping this function and accepting untrusted inputs could be denied service by an oversized list.
- Pre-renounce, the contract owner was a plain externally owned wallet, funded directly from a centralized exchange hot wallet, rather than a multisig or a timelocked governance address.
Ownership Privileges
The ownership of the contract has been renounced on-chain. The current owner is the zero address, which means every onlyOwner function reverts for every caller and the privileges below cannot be exercised again. During the brief pre-renounce window the owner held the following abilities:
- Mint an arbitrary amount of YYAI to any address by calling mint(to, amount), with no supply cap and no rate limit.
- Transfer ownership to another address in a single transaction, without a confirmation step from the receiving party.
- Renounce ownership entirely, which is what was eventually done.
- Read the current owner address through the standard owner() view.
- The contract was not upgradeable, so the owner could not change the contract's logic.
- The contract had no pause, blacklist, or fee toggle, so the owner could not freeze transfers, target individual holders, or change the cost of moving tokens.
- There is no oracle, AMM hook, or bridge integration, so the owner could not influence on-chain pricing or cross-chain supply.
- Since ownership is renounced, none of the above privileges remain accessible to anyone going forward.
Security Features
The contract implements several positive security features:
- The OpenZeppelin v5 ERC20 implementation rejects transfers to and from the zero address, prevents accidental allowance underflows, and uses typed custom errors throughout. These guarantees apply automatically to YYAI.
- Solidity 0.8.20 default arithmetic checks prevent integer overflow and underflow in every value-moving path, and there are no unchecked blocks in the project code.
- There are no external calls during state-changing flows and no transfer hooks, which removes both classic and read-only reentrancy as concerns.
- The deployer has renounced ownership, permanently disabling mint, transferOwnership, and the ability to re-renounce. The contract has therefore transitioned from a single-EOA-controlled token to an effectively immutable, holder-only ERC20.
Note - This Audit report consists of a security analysis of the YYAI smart contract deployed at 0x552F92E545354644eF69F65830FB1Dc7aC5b588E on BNB Smart Chain. This analysis did not include economic analysis of the contract's tokenomics. Moreover, we only audited the main contract for the YYAI team. Other contracts associated with the project were not audited by our team. We recommend investors do their own research before investing.
Files and details
Functions
public
/
State variables
public
/
Total lines
of code
/
Capabilities
Hover on items
/
Findings and Audit result
low Issues | 4 findings
Pending
#1 low Issue
Unbounded loop in batchTransfer allows caller-induced DoS
batchTransfer iterates over the recipients array and forwards each entry to transfer, with no upper bound on the array length. A caller passing a very large array will hit the block gas limit and the entire transaction will revert. There is no partial-success path either, so a single failing transfer (zero-address recipient, insufficient balance, etc.) reverts the full batch. The impact is mainly self-inflicted, but any contract that wraps this function and accepts user-supplied recipient lists could be DoSed by a deliberately oversized input.
Pending
#2 low Issue
Single-step ownership transfer (no Ownable2Step)
The contract inherits the classic OpenZeppelin Ownable, which performs ownership transfer in a single step. A typo in the new-owner argument would have immediately and permanently transferred control. This was a real risk during the pre-renounce window. It is no longer applicable now that owner() is the zero address, but it is recorded here because it would otherwise resurface in any future redeployment that reuses the same template.
Pending
#3 low Issue
Tokens accidentally sent to the contract address are permanently locked
The contract has no rescue function for tokens sent to its own address by mistake. A user who accidentally transfers YYAI (or any other BEP-20) to the contract's address loses access to those tokens because no path can move them out. Because ownership has been renounced, no upgrade or admin call can recover these stuck tokens. This is a common user-error footgun rather than an exploitable bug, but it is permanent once it happens.
Pending
#4 low Issue
Pre-renounce centralization - unbounded mint by a single EOA
The mint function is gated only by onlyOwner and has no supply cap. During the window between deployment and renounceOwnership (around five hours), a single externally owned account, funded directly from a centralized-exchange hot wallet, held the ability to inflate supply arbitrarily. There was no multisig, no timelock, and no enforced cap. The current state mitigates this fully because owner() is the zero address and mint reverts for every caller, but holders who were active in the early window were exposed to this risk and the design itself permitted it.
optimization Issues | 5 findings
Pending
#1 optimization Issue
Use calldata instead of memory for batchTransfer parameters
batchTransfer declares its array parameters as memory while never mutating them. Using calldata avoids the cost of copying both arrays into memory on every invocation, which scales linearly with the number of recipients.
Pending
#2 optimization Issue
Unchecked loop counter increment
The loop counter increment in batchTransfer runs under Solidity's default checked arithmetic. Because the loop terminates well below 2^256, the overflow check is unnecessary on every iteration. Moving the increment into an unchecked block trims roughly fifty gas per recipient.
Pending
#3 optimization Issue
Cache recipients.length outside the loop header
The loop header re-reads recipients.length on every iteration. Caching this value into a local saves one MLOAD per iteration with no behavior change.
Pending
#4 optimization Issue
Replace require strings with custom errors
The two require statements in batchTransfer carry inline string messages, while the inherited base contracts already use custom errors throughout. Aligning batchTransfer to the same custom-error pattern saves deployment bytecode, reduces gas on the revert path, and gives integrators typed errors to handle off-chain.
Pending
#5 optimization Issue
Mark batchTransfer external rather than public
batchTransfer is declared public but has no internal call sites. Demoting it to external avoids the implicit memory copy that public functions perform on reference-type arguments, which is significant for the two arrays this function receives.
informational Issues | 7 findings
Pending
#1 informational Issue
Floating compiler pragma
The source uses a caret pragma, which allows the contract to compile with any 0.8.x release at or above 0.8.20. The deployed bytecode was produced by exactly 0.8.20, so pinning the version in source removes ambiguity for anyone rebuilding or verifying the contract later.
Pending
#2 informational Issue
Contract is named MyToken rather than YYAI
The contract is declared as MyToken, which is the OpenZeppelin Wizard default name. Investors and integrators looking at the verified source see this generic name rather than the symbol they expect, which makes the deployment look less polished and harder to identify at a glance on the explorer.
Pending
#3 informational Issue
No NatSpec on public or external functions
None of the project-specific functions or the contract itself carry NatSpec. The inherited surface is documented in OpenZeppelin, but the bespoke parts (mint, batchTransfer, and the constructor's supply-scaling behavior) are not. This affects readability and tooling that surfaces NatSpec to integrators and explorer users.
Pending
#4 informational Issue
Initial-supply scaling is footgun-prone
The constructor multiplies the user-supplied initialSupply by 10**decimals(). Because decimals defaults to 18, a deployer reading the constructor literally and passing what they think is 42 million base units actually mints 42 million whole tokens, which is 18 decimal places larger than they might intend. A deployer who is unaware of the implicit scaling has no way to catch the mistake before broadcast.
Pending
#5 informational Issue
ERC20 approve race condition (SWC-114) not addressed
The contract exposes the standard approve function with no protection against the well-known front-run race when a non-zero allowance is replaced by another non-zero allowance. OpenZeppelin v5 deliberately removed the helper methods that previously mitigated this, leaving the application or the user to follow the zero-then-set pattern.
Pending
#6 informational Issue
No EIP-2612 permit support
The contract does not implement permit, so users cannot grant approvals via signed off-chain messages. Every transferFrom flow requires a separate on-chain approve transaction. This is a UX consideration, not a security defect.
Pending
#7 informational Issue
burnFrom(self) requires an allowance on self in OZ v5
OpenZeppelin v5's _spendAllowance is enforced unconditionally inside burnFrom, even when the spender equals the account. A user who tries to burn their own tokens through burnFrom must first approve themselves, which is counterintuitive. The correct path for self-burn is the burn(value) function.