PhoenixKit 2.22.8: Honest confirmation resend and no alert on sign-up
PhoenixKit 2.22.8 fixes three things on the email confirmation page and in login alerts.
Asking for a new confirmation link always said “We’ve sent a new confirmation link”, even when the 3-in-5-minutes limit had been reached or the email failed to send. A signed-in user waiting for confirmation now sees what really happened: that the link was sent, that the limit was reached, or a request to try again in a moment. A signed-out visitor still sees the same message whatever the outcome, so the form cannot be used to find out which accounts exist.
With new login alerts on, every new account got a “new login” email about the sign-in that ends its own registration. The first device of an account no longer triggers an alert; it is still recorded and logged.
The form for correcting the email address of an unconfirmed account no longer asks for the current password.
Full release notes: PhoenixKit 2.22.8
2.22.8 · 9 September 2026
Changed
- The parked “wrong email?” fix-up form no longer asks for the current
password. It reused the same
apply_user_email/3path Profile Settings uses for a confirmed user’s email change, but there is no live/confirmed account yet for a hijacked session to protect at that point — just a pending signup fixing a typo before its first confirmation. NewAuth.apply_unconfirmed_user_email/2is pattern-matched onconfirmed_at: nilso it structurally cannot be reused once an account is confirmed. - A confirmation resend now says what actually happened. The handler
ran the rate-limit check, the account lookup, and the send inside a
withwhose result was never inspected, so hitting the 3-per-5-minutes resend limit (or a genuine mailer failure) still flashed “we’ve sent a new confirmation link” with nothing to explain why no mail showed up. The parked (authenticated) branch now flashes the real outcome — success, a clear rate-limit notice, or a retry message with the actual reason logged server-side. The anonymous branch is unchanged: it always shows the same vague message regardless of outcome, which is what avoids turning the endpoint into an account-enumeration oracle for a signed-out visitor. - The “new login” security alert no longer fires on an account’s own
signup. Registration ends by logging the new user in through the same
path every other login uses, and a brand-new account has no device
history yet — so with
new_login_alert_enabledon, every signup immediately triggered a “we noticed a new login to your account” email about the login it had just performed to finish registering.LoginAlertsnow checks whether the account has any known device on record before alerting; a true first device is still recorded (so an actual second device correctly reads as new) and still logged to the activity feed, but skips the email and in-app notification.
PhoenixKit 2.22.8. Install or update: {:phoenix_kit, "~> 2.22"}, then mix deps.get && mix phoenix_kit.update. Full history: CHANGELOG.