User records can now note when an account's email address was confirmed by link, and when and by whom the account was approved. A new table holds the single-use confirmation links sent by email, storing only a fingerprint of each link, never the link itself.
Whether someone may sign in is still decided only by the account's status; confirmation and approval are recorded as events, never filled in after the fact, so existing accounts show them as not yet happened. Email addresses must now be stored in one consistent form (trimmed, lowercase, plain letters), which keeps two different addresses from being treated as the same one. A confirmation link only proves the address it was sent to.