Better Auth Has Insecure Cryptographic Defaults
Affects better-authSource GCVE Database
CVSS 8.7 High : upgrade to 1.6.11 soon.
Data as of 8 Jul 2026, 13:44 UTC
- Patch
- Available – fixed in 1.6.11
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:NWhat to do
Upgrade better-auth to 1.6.11.
Affected software
| Product | Affected | Fixed in |
|---|---|---|
| npmbetter-auth | Affected
| Fixed in
|
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
AI-suggested
Upgrade to better-auth version 1.6.11 or later, which removes the insecure 'none' algorithm from discovery metadata and disables acceptance of plain PKCE by default. Migrate from the deprecated oidcProvider and mcp plugins to the @better-auth/oauth-provider package, which is not affected by these issues. If immediate upgrade is not possible, explicitly disable plain PKCE by setting allowPlainCodeChallengeMethod to false in oidcProvider or mcp configurations, and override the discovery metadata to exclude 'none' from id_token_signing_alg_values_supported. Verify changes by inspecting the .well-known endpoint. These mitigations align runtime and discovery behavior to secure defaults.
Description
The better-auth library versions prior to 1.6.11, when using the legacy oidcProvider or mcp plugins, have insecure cryptographic defaults. These include advertising the 'none' algorithm for ID token signing in the discovery document, which can lead to acceptance of unsigned tokens by relying parties that do not pin algorithms. Additionally, the default acceptance of the PKCE 'plain' code challenge method violates OAuth 2.1 standards and weakens authorization code protection if the authorization URL is exposed. The newer @better-auth/oauth-provider package is not affected. A fix is available in better-auth version 1.6.11 and later.