Skip to content

Send password reset SMS only to the account's stored phone number - #7408

Open
compwron wants to merge 1 commit into
mainfrom
fix/password-reset-sms-stored-number
Open

compwron wants to merge 1 commit into
mainfrom
fix/password-reset-sms-stored-number

Conversation

@compwron

Copy link
Copy Markdown
Collaborator

What

The reset SMS now goes to the account's stored phone number, and only when the number typed into the form matches it (digits compared, so formatting does not matter). Previously the SMS To: was the submitted string. The email path is unchanged.

Tests

Added specs for a mismatched number (email still sent, no SMS) and a differently formatted matching number (SMS goes to the stored number). spec/requests/users/passwords_spec.rb: 14 examples, 0 failures.

🤖 Generated with Claude Code

The reset SMS was sent to the phone number typed into the form, so an email
plus the requester's own number delivered a working reset link for someone
else's account. Text only the stored number, and only when the submitted
number matches it; the email is unaffected.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@github-actions github-actions Bot added 🧪 Tests Tests ruby Touches Ruby code labels Nov 16, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ruby Touches Ruby code 🧪 Tests Tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant