Intel

AIKIDO-2026-10482

better-auth is vulnerable to Incorrect Authorization

Incorrect Authorization Pre-CVE
Found by Aikido Intel before public disclosure or CVE publication.
Published Apr 15, 2026

24

Low Risk

This Affects:

JSbetter-auth
1.4.0 - 1.6.2
Fixed in 1.6.3
Are you affected? Scan for Free

TL;DR

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.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range.

Background info

better-auth is vulnerable to Incorrect Authorization in versions 1.4.0 - 1.6.2.

How to fix this

Upgrade the better-auth library to the patch version.

Are You Affected?

Connect your repositories to instantly see whether vulnerable or malicious packages exist in your codebase.

Free. No credit card required.

Aikido Platform