This page is included in the guided lesson.Open this part in context →
Safety: account-recovery practice
- Use only this supplied app on 127.0.0.1 and the fictional
campus.exampleaccounts. Do not test real recovery pages or enter university credentials. - Keep the server local. Do not change the binding, deploy it publicly, use a tunnel or connect it to real email. The starter intentionally permits unauthorized password changes.
- The teaching mailbox is deliberately visible to the learner playing the owner. It is not an access-controlled mailbox or a production design. A real recovery channel must remain private to its owner.
- Use the given fictional passwords. Account state and tokens are temporary and reset when the server restarts or the lab is reset.
- Do not publish real passwords or tokens. Lab screenshots may show only the disposable fictional values generated here.
- The worked repair demonstrates proof-of-control checks, not complete protection of a production identity system. Real systems also need protected delivery, abuse controls, session handling and recovery notifications.
- Edit only
recovery-policy.mjsduring the student task. Leave token generation, password hashing and checks unchanged. - When finished, stop the server with Ctrl+C. No external scanning or network service is needed.