Mātou email verification: an address is only 'verified' once its owner clicked a link — the gateway mints the proof, Mātou mail only carries it #1744

Open
opened 2026-09-22 18:23:00 +00:00 by ben · 2 comments
Owner

Commissioned by Ben, 2026-09-22, out of the #1707 / DDR 0266 email-correction design.

The hole

Nothing in IDSS has ever verified that an email address belongs to the person it is typed onto, yet the stack tells services it did:

  • the IDIP bridge stamps email_verified: true on any roster address (internal/idp/storage.go:582);
  • ADR 0255 has Paperless sign a person in to the account holding the verified email the IdP asserts, re-matched at every sign-in;
  • founding accepted ben@matou,nz (#1703) and passed it on as a verified address of the Whakatōhea Demo operator.

DDR 0266 holds the takeover door shut from the inside — an address is unique across members (refused inline), and an existing service account never moves on an email change — so this is not a live breach. But the word "verified" is unearned, and every email-matching co-host is trusting it.

A community cannot verify addresses by itself: sending mail needs a mail service, and at founding it has none (ADR 0115/0116 grow mail later, most communities never install it). Mātou already operates mail for exactly this reason — the Notifier submits alerts as notify@mail.matou.nz over per-community SMTP credentials held as clan vars (ADR 0106, Ben's #85 ruling). Verification rides the same standing dependency.

What to build

A verification ceremony owned by the gateway, with Mātou mail as the carrier — not a Mātou-side verification service that holds anyone's address.

  1. The gateway mints the proof. A single-use, short-expiry token signed by the gateway, bound to (member, address, purpose). It is stored on the gateway. Confirmation lands back on the gateway (https://<apex>/verify/<token>), which flips the address to verified. Mātou mail is the carrier: it accepts an SMTP submission and delivers it, exactly as it does for alerts today, and it decides nothing about who is verified. The community's member list stays on the community's own box, and the eject route stays real: a community with its own mail submits through that instead, with no other change, and a community that leaves Mātou loses a convenience, never its identities. (What Mātou does keep is the founding operator's address — see 2.)

  2. No third-party verification vendor, ever. An outside deliverability service would mean sending members' addresses to a company outside the community's control. Rejected on sovereignty grounds, not cost.

    Mātou does keep the FOUNDING operator's address (Ben, 2026-09-22): the founding operator email is recorded and held by Mātou to build the relationship with that operator community. This is a stated fact of founding, not a side effect — founding must SAY so on the screen that asks for it (P1-S2 copy), and nothing in the product may claim otherwise. Members' addresses are a different matter: they stay on the community's own gateway, and Mātou mail only carries a message to them.

  3. Where it fires: the founding operator email (P1-S2), a member added with a real address (ADR 0251), an address corrected on their row (DDR 0266, P6-S10/S10i), and an invite acceptance that collects one.

  4. What verified means, who is blocked on it, and who may turn it off (Ben's rulings, 2026-09-22):

    • Founding is BLOCKED on a verified operator address. Founding does not complete until the operator has clicked the link sent to the address they typed on P1-S2. This is the one hard gate: it is the address Mātou keeps, the address alerts go to, and the address that named the Whakatōhea Demo defect. The stand-up may run while the operator verifies, but the hand-off does not hand over until it is verified. Design owes the waiting state, the resend, the change-the-address path from that screen, and an honest wall for a founding that genuinely cannot reach mail — name it, do not silently pass.
    • Members and services are governed by an operator TOGGLE — Require a verified email address — in Settings. Proposed default ON, since the ceremony exists and it is what makes the email_verified claim honest. While ON, an unverified member is added and can sign in to the community, but a co-host that MATCHES A PERSON by email (Paperless, ADR 0255) does not pre-match them until they verify. While OFF, the bridge asserts the address without a confirmation and email-matching co-hosts accept it, which is exactly today's behaviour — the toggle's help text says so plainly, in the operator's words, as a trust choice they are making.
    • The email_verified claim always tells the truth about the address: true only with a stored confirmation. The toggle governs what SERVICES are allowed to do with an unverified address; it never makes the claim lie.
  5. A community with no route to mail is not broken. When neither Mātou mail nor a community mail service can be reached, the address stays unverified, and that state is honest on screen and in the claim. Nothing queues forever and no delivery failure is silent (ADR 0106's rule).

  6. Bounces are facts. A hard bounce or an SMTP refusal shows on the member's row as address didn't accept mail, with resend — the same shape as DDR 0266's "not yet applied" row. An expired or re-used token lands on a plain re-request screen, never a raw error.

  7. Rate-limited and audited: a bounded number of sends per address per hour, every send and confirmation in the audit log (old/new address on a correction).

Founding verification runs on MĀTOU's side, and the founder only needs a mailbox (Ben, 2026-09-22)

At founding there is no community yet: no apex, no gateway, often no DNS — so a gateway-minted link has nowhere to land, and the operator is looking at the app on their own machine, not a browser on their community. Founding verification therefore runs through Mātou (the same standing path the rental broker already uses, ADR 0047/0135 — the operator app talks to Mātou, not the other way round):

  1. The app asks Mātou to verify the address the operator typed on P1-S2. Mātou sends the message from a Mātou address, and keeps the address — this is the founding record Mātou holds by ruling.
  2. The founder does the simplest possible thing: receive an email and either click the link in it or type the short code into the app. Preferred: a 6-digit code typed into the app, because the app is the surface in front of them and the code works with no community domain, no inbound port and no browser hand-back. The link is the same proof by another route, and lands on a Mātou page that says "you can go back to the app now".
  3. The app polls Mātou for the verified fact (or accepts the typed code), and founding carries the verified address into the gateway's first render, so the gateway is born knowing the operator's address is proven. No verification ceremony ever blocks on the community's own mail, which does not exist at that moment.
  4. Requirements on the operator: a mailbox they can read. Nothing else — no DNS, no mail service, no inbound anything.

After founding, a member's address is verified by the gateway that holds it (the token design below), with Mātou mail as the carrier and a Mātou From: — the link lands on the community's own apex, which exists by then.

Screens needed (hence needs-design)

  • Check your email states on founding S2, on member-add, and on P6-S10c after an email change (the change applies to display everywhere, but the verified flag waits for the click);
  • the member row's unverified chip with resend and its didn't accept mail variant;
  • the confirmation landing page on the community's own apex (verified / expired / already used), wearing the brand kit;
  • the operator's view of an unverified operator address at hand-off (this is the one that bit us: the demo's typo'd address was invisible after founding).

Acceptance

  • Founding cannot complete without a proven address (clicked link OR typed code): a founding whose operator address is never verified never reaches hand-off, and says why, with resend and change-address; the verified founding does reach it. A drive leg proves both.
  • The toggle ON refuses an email-match pre-provision for an unverified member and allows it once verified; the toggle OFF reproduces today's behaviour. Seam tests on both.
  • An address corrected on P6-S10 is displayed everywhere immediately and asserted verified only after the new address is clicked; the email-matching co-host is updated on that event (DDR 0266 rule 5 sequencing).
  • A seam test proves the bridge never stamps email_verified: true for an address with no stored confirmation.
  • A drive leg proves the whole ceremony on a live rented community, and a second leg proves the no-mail community still founds, signs in and runs with an unverified address.

#1707 / DDR 0266 (email correction — this is its named open question), ADR 0255 (Paperless email match), ADR 0251 (members carry a real address), ADR 0106 (Notifier over Mātou mail — the carrier precedent), ADR 0115/0116 (community mail, when it exists), #1703 (founding-time validation).

**Commissioned by Ben, 2026-09-22**, out of the #1707 / DDR 0266 email-correction design. ## The hole Nothing in IDSS has ever verified that an email address belongs to the person it is typed onto, yet the stack tells services it did: - the IDIP bridge stamps `email_verified: true` on **any** roster address (`internal/idp/storage.go:582`); - **ADR 0255** has Paperless sign a person in to the account holding the verified email the IdP asserts, re-matched at **every** sign-in; - founding accepted `ben@matou,nz` (#1703) and passed it on as a verified address of the Whakatōhea Demo operator. DDR 0266 holds the takeover door shut from the inside — an address is unique across members (refused inline), and an existing service account never moves on an email change — so this is **not a live breach**. But the word "verified" is unearned, and every email-matching co-host is trusting it. A community cannot verify addresses by itself: sending mail needs a mail service, and at founding it has none (ADR 0115/0116 grow mail later, most communities never install it). Mātou already operates mail for exactly this reason — the Notifier submits alerts as `notify@mail.matou.nz` over per-community SMTP credentials held as clan vars (**ADR 0106**, Ben's #85 ruling). Verification rides the same standing dependency. ## What to build **A verification ceremony owned by the gateway, with Mātou mail as the carrier — not a Mātou-side verification service that holds anyone's address.** 1. **The gateway mints the proof.** A single-use, short-expiry token signed by the gateway, bound to (member, address, purpose). It is stored on the gateway. Confirmation lands back on the gateway (`https://<apex>/verify/<token>`), which flips the address to verified. Mātou mail is the **carrier**: it accepts an SMTP submission and delivers it, exactly as it does for alerts today, and it decides nothing about who is verified. The community's member list stays on the community's own box, and the eject route stays real: a community with its own mail submits through that instead, with no other change, and a community that leaves Mātou loses a convenience, never its identities. (What Mātou does keep is the founding operator's address — see 2.) 2. **No third-party verification vendor, ever.** An outside deliverability service would mean sending members' addresses to a company outside the community's control. Rejected on sovereignty grounds, not cost. **Mātou does keep the FOUNDING operator's address** (Ben, 2026-09-22): the founding operator email is recorded and held by Mātou to build the relationship with that operator community. This is a stated fact of founding, not a side effect — founding must SAY so on the screen that asks for it (P1-S2 copy), and nothing in the product may claim otherwise. Members' addresses are a different matter: they stay on the community's own gateway, and Mātou mail only carries a message to them. 3. **Where it fires:** the founding operator email (P1-S2), a member added with a real address (ADR 0251), an address corrected on their row (DDR 0266, P6-S10/S10i), and an invite acceptance that collects one. 4. **What `verified` means, who is blocked on it, and who may turn it off (Ben's rulings, 2026-09-22):** - **Founding is BLOCKED on a verified operator address.** Founding does not complete until the operator has clicked the link sent to the address they typed on P1-S2. This is the one hard gate: it is the address Mātou keeps, the address alerts go to, and the address that named the Whakatōhea Demo defect. The stand-up may run while the operator verifies, but the hand-off does not hand over until it is verified. Design owes the waiting state, the resend, the change-the-address path from that screen, and an honest wall for a founding that genuinely cannot reach mail — name it, do not silently pass. - **Members and services are governed by an operator TOGGLE** — *Require a verified email address* — in Settings. Proposed default **ON**, since the ceremony exists and it is what makes the `email_verified` claim honest. While ON, an unverified member is added and can sign in to the community, but a co-host that MATCHES A PERSON by email (Paperless, ADR 0255) does not pre-match them until they verify. While OFF, the bridge asserts the address without a confirmation and email-matching co-hosts accept it, which is exactly today's behaviour — the toggle's help text says so plainly, in the operator's words, as a trust choice they are making. - The `email_verified` claim always tells the truth about the address: `true` only with a stored confirmation. The toggle governs what SERVICES are allowed to do with an unverified address; it never makes the claim lie. 5. **A community with no route to mail is not broken.** When neither Mātou mail nor a community mail service can be reached, the address stays unverified, and that state is honest on screen and in the claim. Nothing queues forever and no delivery failure is silent (ADR 0106's rule). 6. **Bounces are facts.** A hard bounce or an SMTP refusal shows on the member's row as *address didn't accept mail*, with resend — the same shape as DDR 0266's "not yet applied" row. An expired or re-used token lands on a plain re-request screen, never a raw error. 7. **Rate-limited and audited:** a bounded number of sends per address per hour, every send and confirmation in the audit log (old/new address on a correction). ## Founding verification runs on MĀTOU's side, and the founder only needs a mailbox (Ben, 2026-09-22) At founding there is no community yet: no apex, no gateway, often no DNS — so a gateway-minted link has nowhere to land, and the operator is looking at the **app on their own machine**, not a browser on their community. Founding verification therefore runs through **Mātou** (the same standing path the rental broker already uses, ADR 0047/0135 — the operator app talks to Mātou, not the other way round): 1. The app asks Mātou to verify the address the operator typed on P1-S2. Mātou sends the message **from a Mātou address**, and keeps the address — this is the founding record Mātou holds by ruling. 2. The founder does the simplest possible thing: **receive an email and either click the link in it or type the short code into the app.** Preferred: **a 6-digit code typed into the app**, because the app is the surface in front of them and the code works with no community domain, no inbound port and no browser hand-back. The link is the same proof by another route, and lands on a Mātou page that says "you can go back to the app now". 3. The app polls Mātou for the verified fact (or accepts the typed code), and founding carries the verified address into the gateway's first render, so the gateway is born knowing the operator's address is proven. No verification ceremony ever blocks on the community's own mail, which does not exist at that moment. 4. Requirements on the operator: **a mailbox they can read**. Nothing else — no DNS, no mail service, no inbound anything. **After founding**, a member's address is verified by the gateway that holds it (the token design below), with Mātou mail as the carrier and a Mātou `From:` — the link lands on the community's own apex, which exists by then. ## Screens needed (hence `needs-design`) - *Check your email* states on founding S2, on member-add, and on P6-S10c after an email change (the change applies to display everywhere, but the verified flag waits for the click); - the member row's **unverified** chip with *resend* and its *didn't accept mail* variant; - the confirmation landing page on the community's own apex (verified / expired / already used), wearing the brand kit; - the operator's view of an unverified operator address at hand-off (this is the one that bit us: the demo's typo'd address was invisible after founding). ## Acceptance - **Founding cannot complete without a proven address (clicked link OR typed code):** a founding whose operator address is never verified never reaches hand-off, and says why, with resend and change-address; the verified founding does reach it. A drive leg proves both. - The toggle ON refuses an email-match pre-provision for an unverified member and allows it once verified; the toggle OFF reproduces today's behaviour. Seam tests on both. - An address corrected on P6-S10 is displayed everywhere immediately and asserted verified only after the new address is clicked; the email-matching co-host is updated on that event (DDR 0266 rule 5 sequencing). - A seam test proves the bridge never stamps `email_verified: true` for an address with no stored confirmation. - A drive leg proves the whole ceremony on a live rented community, and a second leg proves the no-mail community still founds, signs in and runs with an unverified address. ## Related #1707 / DDR 0266 (email correction — this is its named open question), ADR 0255 (Paperless email match), ADR 0251 (members carry a real address), ADR 0106 (Notifier over Mātou mail — the carrier precedent), ADR 0115/0116 (community mail, when it exists), #1703 (founding-time validation).
Author
Owner

Ben's rulings, 2026-09-22 (folded into the body above):

  1. Founding is blocked on a verified operator email address. No hand-off until the link is clicked.
  2. Members and services are governed by an operator toggle — Require a verified email address (Settings). Default proposed ON; OFF reproduces today's behaviour and says so honestly in its help text.
  3. Mātou records and keeps the FOUNDING operator's email address to build the relationship with that operator community. Founding must say so on P1-S2, and no screen, ADR or help text may claim Mātou keeps nothing. Members' addresses stay on the community's own gateway; Mātou mail only carries messages to them.

Design owes, on top of the screens already listed: the founding wait-for-verification state (resend / change the address), the honest wall for a founding that cannot reach mail at all, the Settings toggle with its help text, and the P1-S2 disclosure line.

**Ben's rulings, 2026-09-22 (folded into the body above):** 1. **Founding is blocked on a verified operator email address.** No hand-off until the link is clicked. 2. **Members and services are governed by an operator toggle** — *Require a verified email address* (Settings). Default proposed ON; OFF reproduces today's behaviour and says so honestly in its help text. 3. **Mātou records and keeps the FOUNDING operator's email address** to build the relationship with that operator community. Founding must say so on P1-S2, and no screen, ADR or help text may claim Mātou keeps nothing. Members' addresses stay on the community's own gateway; Mātou mail only carries messages to them. Design owes, on top of the screens already listed: the founding wait-for-verification state (resend / change the address), the honest wall for a founding that cannot reach mail at all, the Settings toggle with its help text, and the P1-S2 disclosure line.
Author
Owner

Refinement (Ben, 2026-09-22): the founding verification email comes from MĀTOU, and the founder needs nothing but a mailbox.

At founding there is no apex, no gateway and often no DNS, so a gateway-minted link has nowhere to land and the operator is looking at the app on their own machine. So founding verification runs Mātou-side, over the path the rental broker already uses: the app asks Mātou to verify the typed address, Mātou sends the message from a Mātou address (and keeps the address — the founding record it holds by ruling), and the operator either types a 6-digit code into the app (preferred — no domain, no inbound port, no browser hand-back) or clicks the link, which lands on a Mātou page telling them to return to the app. Founding then carries the proven address into the gateway's first render.

Post-founding member verification stays gateway-minted with a Mātou From: and a link onto the community's own apex, which exists by then.

This also dissolves the open question from my last note: a founding never needs the community to be able to send or receive mail, so there is no air-gapped founding wall to design. The only requirement on the founder is a mailbox they can read.

**Refinement (Ben, 2026-09-22): the founding verification email comes from MĀTOU, and the founder needs nothing but a mailbox.** At founding there is no apex, no gateway and often no DNS, so a gateway-minted link has nowhere to land and the operator is looking at the app on their own machine. So founding verification runs Mātou-side, over the path the rental broker already uses: the app asks Mātou to verify the typed address, Mātou sends the message from a Mātou address (and keeps the address — the founding record it holds by ruling), and the operator either **types a 6-digit code into the app** (preferred — no domain, no inbound port, no browser hand-back) or clicks the link, which lands on a Mātou page telling them to return to the app. Founding then carries the proven address into the gateway's first render. Post-founding member verification stays gateway-minted with a Mātou `From:` and a link onto the community's own apex, which exists by then. This also dissolves the open question from my last note: a founding never needs the community to be able to send or receive mail, so there is no air-gapped founding wall to design. The only requirement on the founder is a mailbox they can read.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Matou/idss#1744
No description provided.