This audit report identifies a critical issue in the ThePredicter
smart contract regarding the basis of points allocation and the distribution of fees. The current implementation allocates points and distributes rewards based on prediction fees, while the entrance fee is used to cover miscellaneous expenses. This system is not encouraging as it does not reflect a fair contribution by all players. Instead, the entrance fee should be used to cover hall rent and other expenses, while the prediction fee, which is paid by all players, should be shared among the players.
Current Implementation:
Entrance Fee: Used to cover hall rent and miscellaneous expenses.
Prediction Fee: Allocated to the prize pool and distributed among players based on their points.
Documentation Claim: The documentation specifies that the entrance fees paid at the beginning form the prize fund, which after the end of the tournament is distributed among all Players who paid at least one prediction fee and depending on their collected number of points.
The current system is not encouraging and fair for the following reasons:
Untrusted Users: Only untrusted users pay the entrance fee, which means the prize fund is not equally contributed by all players.
Fair Contribution: The prediction fee, which all players must pay to make predictions, represents a fairer contribution to the prize pool. Sharing this fee among players ensures that all participants have an equal stake in the rewards.
Inconsistent Basis: Using the entrance fee for hall rent and other expenses while allocating points and rewards based on prediction fees creates inconsistency and potential dissatisfaction among players.
manual review
To ensure a fair and encouraging system, the following changes are recommended:
Use Entrance Fee for Expenses: The entrance fee should be used exclusively for covering hall rent and other miscellaneous expenses.
Use Prediction Fee for Prize Pool: The prediction fee, which is paid by all players, should form the prize pool. This ensures that the rewards are fairly distributed among all participants who have contributed to the pool.
Proposed Changes:
Allocate Entrance Fees:
Use the entrance fee to cover hall rent and miscellaneous expenses.
Allocate Prediction Fees:
Use the prediction fee to form the prize pool.
Distribute the prize pool among players based on their points.
Update Withdraw Function:
Ensure the prize pool is distributed among players based on their points.
To encourage fair participation and reward distribution, it is crucial to reallocate the usage of entrance and prediction fees. By using the entrance fee for expenses and the prediction fee for the prize pool, the system will ensure that all players contribute fairly and receive rewards based on their participation. Implementing these changes will align the contract with the principles of fairness and transparency, fostering a more positive and encouraging environment for all participants.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.