Title: fix(auth): gate email-otp auto-signup behind DISABLE_EMAIL_SIGNUP by waleedlatif1 · Pull Request #5840 · simstudioai/sim · GitHub
Open Graph Title: fix(auth): gate email-otp auto-signup behind DISABLE_EMAIL_SIGNUP by waleedlatif1 · Pull Request #5840 · simstudioai/sim
X Title: fix(auth): gate email-otp auto-signup behind DISABLE_EMAIL_SIGNUP by waleedlatif1 · Pull Request #5840 · simstudioai/sim
Description: Summary `DISABLE_EMAIL_SIGNUP` only blocked the `/sign-up/email` path, but better-auth's email-otp plugin auto-registers any unknown email on `/sign-in/email-otp` — so new accounts could still be created with the flag set Wire the same flag into better-auth's native `disableSignUp` option on both `emailAndPassword` and the `emailOTP` plugin, and drop the now-redundant path-string check in the before-hook With `disableSignUp` set, the OTP plugin also skips sending sign-in codes to unknown emails (enumeration-safe) while existing users keep OTP sign-in, email/password sign-in, and the verify-email flow unchanged; social/SSO signup is unaffected Type of Change Bug fix Testing Verified against better-auth 1.6.13 source: unknown-email OTP sign-in rejects instead of creating a user; existing-user OTP sign-in, email/password sign-in, and email verification paths unchanged. Typecheck and lint pass. Checklist Code follows project style guidelines Self-reviewed my changes Tests added/updated and passing No new warnings introduced I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)
Open Graph Description: Summary `DISABLE_EMAIL_SIGNUP` only blocked the `/sign-up/email` path, but better-auth's email-otp plugin auto-registers any unknown email on `/sign-in/email-otp` — so new accounts could still...
X Description: Summary `DISABLE_EMAIL_SIGNUP` only blocked the `/sign-up/email` path, but better-auth's email-otp plugin auto-registers any unknown email on `/sign-in/email-otp` — so new accounts could s...
Opengraph URL: https://github.com/simstudioai/sim/pull/5840
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:fed33257-baaf-49b1-7378-a09438222462 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | AD5C:197722:B5CAAB:1044A65:6A631ADB |
| html-safe-nonce | 72783cdeff23fb52a3b98689a2b2c77b9ad25f826622f9cc82fcefd1fad4f166 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBRDVDOjE5NzcyMjpCNUNBQUI6MTA0NEE2NTo2QTYzMUFEQiIsInZpc2l0b3JfaWQiOiI3NDkyNTg4NDkyODE0NDkwMzMxIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 8e778f0d17a72c2d750ece30eb415041b1dd6f671eff871931292f79c169ec39 |
| hovercard-subject-tag | pull_request:4105669252 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/simstudioai/sim/pull/5840/files |
| twitter:image | https://avatars.githubusercontent.com/u/40672544?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/40672544?s=400&v=4 |
| og:image:alt | Summary `DISABLE_EMAIL_SIGNUP` only blocked the `/sign-up/email` path, but better-auth's email-otp plugin auto-registers any unknown email on `/sign-in/email-otp` — so new accounts could still... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 1a6c056e02f174fffc096c521ec0ff6fb83e40a2ec8cb8875466ec1524872dd6 |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/simstudioai/sim git https://github.com/simstudioai/sim.git |
| octolytics-dimension-user_id | 199344406 |
| octolytics-dimension-user_login | simstudioai |
| octolytics-dimension-repository_id | 912559512 |
| octolytics-dimension-repository_nwo | simstudioai/sim |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 912559512 |
| octolytics-dimension-repository_network_root_nwo | simstudioai/sim |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 6a93e25585f487ddff9e3996c06d5b869d6e1828 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width