7 min read

Auth Library Security Advisories, Counted: Better Auth 42 in a Year, Auth.js 4

We counted every published GitHub security advisory for six auth projects. Better Auth had 42 in 12 months. Here is what the number means for your app.

Auth Library Security Advisories, Counted: Better Auth 42 in a Year, Auth.js 4

A team posted on X on November 21 that attackers had run up at least $15,000 in FAL credits through their app in 24 hours, and the fix they named was upgrading Better Auth. That's one report, and we haven't verified it. But it raised a fair question: is Better Auth less safe than the alternatives?

So we counted. Better Auth published 42 security advisories in the last 12 months. Auth.js published 4.

How many advisories did each auth library publish?

Twelve months here means advisories published from November 26, 2025 to November 26, 2026. Severity is the rating on each advisory. The last column is the median gap between the first npm release that fixed the issue and the advisory going public. We counted repository advisories only, not CVEs filed elsewhere, and we didn't install or attack any library.

Project Last 12 months Critical High Medium Low All time Median gap, fix to advisory
Better Auth 42 4 20 14 4 49 0.7 days
SuperTokens (core and Node SDK) 34 1 20 10 3 34 0.8 days (Node SDK only)
Clerk (JavaScript SDKs) 5 1 3 1 0 7 0.1 days
Auth.js 4 0 2 1 1 15 0.1 days
Supabase Auth (server and auth-js) 1 0 0 1 0 5 no npm release to match
WorkOS AuthKit (Next.js SDK) 1 0 0 1 0 4 4.8 days

Lucia and Stack Auth have none published.

Clerk, Supabase and WorkOS run hosted services. A bug on their servers gets fixed there, with no GitHub advisory, so their rows count only the open-source code you install. Better Auth and Auth.js run inside your own app, and SuperTokens core runs on a server you host unless you use its managed service, so every fix is one you have to install.

Why does Better Auth have so many?

Better Auth's GitHub security advisories page, 49 published

Three things push the number up, and only one of them is bad news.

The first is surface. Better Auth ships its plugins from the same repository: SSO, SCIM, passkeys, Expo, Electron, Stripe billing, an OAuth provider and database adapters. 35 of its 49 advisories name the core better-auth package, and the rest land in plugins, 5 of them in @better-auth/sso. Every plugin you add is more code that can be wrong.

The second is disclosure. Better Auth's security policy promises a reply within 72 hours, disclosure once a patch ships, and disclosure after 90 days even without a fix. The project publishes in batches. 13 advisories went out on May 31, 2026 and 12 on November 3. A project that writes up every bug looks worse in a count than one that patches quietly.

The third is the bad news. Four of the 42 were critical, rated 9.1 to 9.9:

  • May 31: in @better-auth/sso, any signed-in user could make the server fetch and read internal URLs (CVSS 9.6).
  • June 26: in @better-auth/scim, SCIM tokens could take over users they didn't own (9.9).
  • September 30: an OAuth state value could be used as a magic link to sign in as another user (9.1). Version 1.7.7, the one the FAL post told people to install, fixed this and a related high-severity OAuth proxy flaw.
  • November 3: in @better-auth/expo, the authorization proxy could sign values it didn't issue (9.1).

Better Auth isn't a niche library anymore, either. npm counted 84 million downloads of better-auth between October 26 and November 24, against 40 million for next-auth (npm downloads API, checked November 26, 2026). A lot of apps carry those bugs until their owners upgrade.

Is SuperTokens just as bad?

SuperTokens' 34 all arrived in a burst. Every one of them was published between October 16 and November 9, 2026, in three batches of 8, 7 and 19. It had published none before that. That looks like an audit landing, not a steady rate, and one burst isn't a trend. One was critical (CVSS 9.9): an app-scoped API key could overwrite another app's credentials.

If you self-host SuperTokens core, all 34 apply to a server you run. Patch it like you'd patch Postgres.

What does the fix-to-advisory gap tell you?

Mostly good news. For four of the five libraries we could time, the median advisory went public within a day of the fixed npm release. WorkOS's one advisory took 4.8 days. Auth.js published all four of its 2026 advisories on one day, July 20, within hours of the fix.

The outliers matter more than the median. 8 of Better Auth's 42 advisories went public more than 30 days after the release that fixed them, and the longest gaps were 232 and 347 days. If you upgraded within a month of each release, you were covered before anyone knew. If you pinned a version and waited for advisories, you were exposed for that whole stretch without a warning.

Better Auth's policy also says it supports only the latest version. There are no backported fixes for an old minor line, so "stay on 1.5 until we have time" doesn't work here.

What should you do if you use Better Auth?

Upgrade on a schedule, not on news. A monthly bump of better-auth and every @better-auth/* package together covers the gap above. The November release notes say the plugins ship with the same versions and should be updated as one.

After that:

  • Read the advisory for each plugin you use. Some fixes need a step after the upgrade. The November Expo fix needs the application secret rotated, and the phone-number fix needs unverified numbers cleaned out (Vercel's bulletin lists them).
  • Turn on Dependabot security alerts or run npm audit in CI, so a new advisory reaches you the day it's published.
  • Install only the plugins you use. The SSO, SCIM and Expo plugins account for three of the four criticals.
  • Put a spend cap on every paid API key your app holds (AI image models, email, SMS). The FAL case was costly because an auth bypass reached a key with no limit. @illyism's list of guardrails is a good start: daily caps, one key per app, dependency sweeps.

So which one should you pick?

Don't pick on the count alone. Pick on who patches.

If you want to own your auth code and you'll upgrade monthly, Better Auth is still a reasonable choice. Its bugs get found and published fast. Auth.js has a far quieter record this year, with 4 advisories and none critical, and it fits a Next.js app that needs OAuth and sessions without the extra plugins. If you'd rather the vendor fix server-side bugs without you doing anything, a hosted service like Clerk or Supabase Auth moves most of that work off your plate. You still have to update their SDKs, and Clerk had a critical middleware bypass in April.

We compared the features and prices of three of these in Better Auth vs Clerk vs Auth.js. For the hosted side, see Clerk vs Auth0 vs Supabase Auth and the Auth0 alternatives we priced.

Spotted an advisory we missed? Tell us on X at @devtoolpicks.

Frequently Asked Questions

Does Vercel's firewall protect a Better Auth app from these vulnerabilities?

Partly, and only for the November 3, 2026 release. Vercel says it deployed WAF rules for those 12 advisories to every project it hosts, at no cost and with no redeploy. Its own bulletin then says not to rely on the WAF for full protection, because some fixes also need a secret rotation or a data cleanup that no firewall can do. Upgrade to 1.7.16 or later either way, and treat the WAF as a stopgap while you test the upgrade.

Found this useful? Follow @devtoolpicks on X for more honest tool comparisons.
Share: X/Twitter | LinkedIn |

Get honest tool comparisons in your inbox

Join 50+ indie hackers and solo developers who get new comparisons, pricing changes, and tool picks. No spam. Unsubscribe anytime.