XDoor Info
The blockchain world is a vast universe of infinite possibilities — behind every door lies an unknown realm of opportunity and risk. You never know what awaits when you open the next door — it could be fortune and growth, or it could be danger and loss. Every door is a choice, and every push forward marks a turning point. XDOOR stands as the gateway to the unknown, a mysterious entrance at the edge of the X-Layer world. Each XDOOR represents a new beginning. Some hesitate before it. Others push forward with courage. Every brave decision can change your destiny. A choice is not merely an action — it is the key to meeting your fate.
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.
Security Assessments
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 not renounced
The owner retains significant control, which could potentially be used to modify key contract parameters.
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.
Ownership Privileges
- The airdrop contract can add a reward.
Note - This Audit report consists of a security analysis of the XDoorLP smart contract. This analysis did not include functional testing (or unit testing) of the contract’s logic. Moreover, we only audited the mentioned contract for the XDoor 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
medium Issues | 1 findings
Acknowledged
#1 medium Issue
Reward Rate Dilution Unfairly Punishes Stakers
The reward calculation logic in the addReward function contains a severe flaw that allows for the dilution of promised rewards, unfairly penalizing long-term stakers. Each time addReward is called, it recalculates the rewardPerBlock by dividing the entire remaining pool of rewards over a full, new reward distribution period (releaseBlockNumber). This means that any subsequent deposit of rewards, no matter how small, will take the rewards that were already being distributed and spread them out over a new, longer time frame, effectively reducing the rewardPerBlock rate. This breaks the implicit promise of a consistent reward rate over a defined period and allows the administrator to arbitrarily decrease the yield for existing stakers, thus cheating them out of their expected future earnings.
optimization Issues | 1 findings
Resolved
#1 optimization Issue
Public updatePool Function Allows for Unnecessary Gas Expenditure
The updatePool function, which is responsible for updating the pool's reward accounting, is declared as public. This means that anyone can call it at any time, even if there are no pending rewards to update. While the function has checks to exit early if conditions aren't met, each call still consumes a base amount of gas for the external call and the initial sload operations. A malicious or misinformed actor could repeatedly call this function in a tight loop, causing a minor but unnecessary gas expenditure on the network and potentially cluttering the contract's transaction history.
informational Issues | 1 findings
Resolved
#1 informational Issue
Inconsistent Application of Reentrancy Guard
The contract imports and utilizes OpenZeppelin's ReentrancyGuard, correctly applying the nonReentrant modifier to functions that perform direct external calls involving ETH transfers or interactions with the main token contract, such as withdraw, claim, and addLiquidity. However, the modifier is notably absent from the deposit and addReward functions. While these two functions do not contain a classic reentrancy vector in their current implementation with standard ERC20 tokens, the inconsistent application of the guard is a deviation from security best practices. This creates a latent risk, as any future modification to these functions that introduces an external call could inadvertently create a reentrancy vulnerability. Adhering to a consistent security posture by applying the modifier to all state-changing external and public functions provides a robust defense-in-depth against both current and future potential exploits.