Sign in by e-mail code

Signing in without a password: the person types their address, receives a six-digit code, types it back, and the session opens.

It ships off. To turn it on:

  1. Configure a mail relay in Infra > Mail relay, and send its test mail.
  2. In Application > Security, card Sign in by e-mail, turn on Allow signing in with an e-mailed code.
  3. Open https://<data-plane>/login in a private window: Sign in with a code by e-mail is now under the form.

Off, the link is not on the sign-in page and its addresses answer 404.

It is for local accounts only: the code stands in for the local password. It closes with them - with the Local accounts authority disabled in Infra > Authentication, the link is gone and the addresses answer 404 - and an account that exists only through an external authority (an identity provider, a directory, GitHub) is never mailed a code. The page it sees is the same as for an unknown address.

What it moves

This door makes the mailbox the credential. The account is then worth what the mailbox is worth, no more. The argument is less clear-cut than it looks: if "forgot password" is open, the mailbox is already a way in, and the code only makes explicit what the reset flow implies in silence. But it is a decision, not a setting, which is why the switch arrives off.

The frame

Rule What it prevents
Data plane only The console is never openable by a mailbox: the pages are not mounted on the admin port, whoever the account belongs to
Bound to the browser The code is sealed with a random request id, held in a cookie. A code read out over the telephone opens nothing on the caller's machine
First factor only The second factor runs behind it, as it does behind a password. The code and a reset link travel the same channel: skipping the factor would hand both halves to whoever holds the mailbox
Ten minutes, single use A code left in an inbox cannot be replayed, and an inbox opened next week opens nothing
One live code Asking for a new code kills the previous one
No enumeration The same page, status and cookie whether the address exists or not
Throttled twice Sending is limited per address, guessing per browser
An authority cannot use the identifier code.

What the person sees

  1. On the sign-in page, Sign in with a code by e-mail.
  2. They type their address. The next page says a code is on its way, without saying whether an account is behind it.
  3. They type the code back. If their account owes a second factor, it is asked for next, exactly as after a password.

The sign-in history names the door: e-mailed code, or e-mailed code + code when a second factor followed.

What is not there

The magic link - one click in the mail instead of a code - is not written. That is a choice: a link is clickable by anything that scans mail, and it forwards in one gesture.

Forbidding this door per account or per role is not written either: the switch is global. For an administration account, today's protection is structural - the console never opens this way.