The principal can add himself as a teacher by calling 'addTeacher`
Contrary to `enroll`, the function does not revert if the argument _teacher
is the principal address.
The princiapl will receive a part of the fees distributed to teacher in graduateAndUpgrade
The impact is low because even if the function revert, the principal can still bypass the check by providing another address managed by him.
Manual analysis
Add the same check as for enroll
if (msg.sender == principal) {
revert HH__NotAllowed();
}
Principal can add themselves as teacher and share in teacher pay upon graduation
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.