better-auth is vulnerable to Incorrect Authorization
24
Low Risk
After a backup code was consumed, the plugin rewrote the remaining codes using the built-in encryption path even when the deployment configured plain text or a custom storeBackupCodes strategy. Subsequent verification could then fail for legitimate users, effectively breaking second-factor recovery. The fix re-saves remaining codes with the same strategy the application configured.
You are affected if you are using a version that falls within the vulnerable range.
better-auth is vulnerable to Incorrect Authorization in versions 1.4.0 - 1.6.2.
Upgrade the better-auth library to the patch version.
Connect your repositories to instantly see whether vulnerable or malicious packages exist in your codebase.
Free. No credit card required.

SOC 2Compliant
ISO 27001Compliant