The contract sets a cutOffScore
during session initialization but fails to enforce this threshold during graduation, violating a key system invariant. Despite the requirement that "Only students who meet the cutoff score can graduate to the next level," all students are processed identically during graduation regardless of their academic performance.
The graduateAndUpgrade
function violates a critical system invariant by:
Never checking student scores against the cutOffScore
Failing to filter which students should graduate to the next level
Allowing all students to progress regardless of academic performance
Additionally, the contract doesn't verify that each student has received exactly 4 reviews before graduation, as specified in the student invariants.
This vulnerability breaks multiple core educational principles of the system:
The invariant "Only students who meet the cutoff score can graduate to the next level" is completely violated
Students with failing grades can progress to more advanced levels
The review system becomes meaningless since scores have no impact on graduation
Teachers' evaluation work is rendered pointless
The principal's authority to set academic standards is undermined
Modify the graduateAndUpgrade
function to enforce the student invariants:
This implementation ensures that:
Only students who meet the cutoff score graduate
Each student has received the required 4 reviews
The session has properly ended before graduation
All students are graduated when the graduation function is called as the cut-off criteria is not applied.
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.