Repository navigation
Never show the signed-in user's e-mail address in full - #161
Merged
Merged
Conversation
A content creator filming the site leaked their address: the homepage newsletter field was filled with the account's e-mail. - Newsletter: the field is always empty; signed-in users get « Use my account address », which takes the address from the session. - Design system: ac-tooltip and ac-masked (tooltip.css), dsMaskEmail() and ac_masked_email(): c•••@gmail.com, the full address in a tooltip on hover or focus. - Account menu, account page and the hello-world demo page show the address masked. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
julesduroux
approved these changes
Oct 22, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Why
A content creator browsing the site while filming leaked their e-mail address: for a signed-in user, the homepage newsletter field was filled with the account's address (
value="<?= h($email) ?>"), visible as soon as the page loaded. The address was also shown in full in the account menu and on the account page, with the same risk on a stream or a video.How
includes/newsletter_sub.php): the field is never filled (and hasautocomplete="off"). Signed-in users get a « Utiliser l'adresse de mon compte » button: it submitsnl_use_accountand the server takes the address from the session, so the page never contains it.tooltip.css(ac-tooltip,--start,--below,ac-tooltip-host,ac-masked), docdocs/components/tooltip.md, section on/pages/design-system. Helpers inphp/ui.php:dsMaskEmail()(c•••@gmail.com) andac_masked_email()(masked address, full one in a tooltip shown on hover, keyboard focus, or a tap on touch screens)..az-am-subno longer clips), account page (profile header and newsletter sentence), hello-world demo page.includes/newsletter_sub.php,design-system/css/components/tooltip.css,design-system/php/ui.php.Outcomes
Homepage newsletter, signed in: empty field, « Utiliser l'adresse de mon compte » under it.
Account page: address masked, in full in the tooltip on focus or hover.
Account menu: same, tooltip under the address.
php tests/run.php: 125 passed (masking, escaping, novalueon the newsletter field)tests/e2e/newsletter-email.spec.ts, desktop and mobile: the page text never contains the full address, tooltip shows on focus/hover, the account button subscribes🤖 Generated with Claude Code