Hawk High

First Flight #39
Beginner FriendlySolidity
100 EXP
View results
Submission Details
Impact: high
Likelihood: high
Invalid

A blacklisted teacher address in the USDC token contract can permanently block the graduation process

Summary

A blacklisted teacher address in the USDC token contract can permanently block the graduation process and prevent the school from upgrading to LevelTwo, effectively creating a denial of service condition.

Vulnerability Details

In the graduateAndUpgrade function, teacher payments are processed in a loop using safeTransfer:

function graduateAndUpgrade(address _levelTwo, bytes memory) public onlyPrincipal {
// ... other code ...
for (uint256 n = 0; n < totalTeachers; n++) {
usdc.safeTransfer(listOfTeachers[n], payPerTeacher);
}
// ... principal payment ...
}

If any teacher's address is blacklisted in the USDC contract:

  • The safeTransfer to that address will revert

  • Due to the loop structure, this revert causes the entire transaction to fail

  • No subsequent teachers can receive their payments

  • The upgrade to LevelTwo cannot proceed

USDC has an active blacklist feature that can block addresses at any time

Teachers can use contract addresses which might get blacklisted

There's no way to skip or remove a problematic teacher during the graduation process

The principal cannot graduate the school without successfully paying all teachers

Impact

A single blacklisted teacher address can:

  • Permanently prevent the school from graduating

  • Block all teacher payments

  • Prevent the upgrade to LevelTwo

  • Lock the remaining funds in the contract

  • Force the school to remain in LevelOne indefinitely

Tools Used

manual review

Recommendations

Implement a pull payment pattern instead of push payments where every teacher calls a function.

Updates

Lead Judging Commences

yeahchibyke Lead Judge 6 months ago
Submission Judgement Published
Invalidated
Reason: Design choice
yeahchibyke Lead Judge 6 months ago
Submission Judgement Published
Invalidated
Reason: Design choice

Appeal created

mishoko Submitter
6 months ago
yeahchibyke Lead Judge
6 months ago
yeahchibyke Lead Judge 6 months ago
Submission Judgement Published
Invalidated
Reason: Design choice

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.