Vulnerabilities in pkg:npm/@better-auth/passkey

PACKAGE
Advisory Summary

GHSA-4vcf-q4xf-f48m is a HIGH (CVSS 7.1) better auth passkey plugin allows vulnerability (CWE-284: Improper Access Control) affecting @better auth/passkey libraries in the npm ecosystem. The issue involves better auth passkey plugin allows passkey deletion through idor. Remediation is available by upgrading affected packages to version 1.4.0.

1 Known Advisory Record(s)
Package Vulnerability Intelligence

pkg:npm/@better-auth/passkey

1 Known Advisory Record(s)

Vulnerability advisories affecting package pkg:npm/@better-auth/passkey. Select an advisory below to view technical details or fixes.

Advisory ID CVE / NVD Severity Summary
GHSA-4vcf-q4xf-f48m - HIGH Better Auth Passkey Plugin allows passkey deletion through IDOR

GHSA-4vcf-q4xf-f48m at a Glance

CVE Identifier N/A
GHSA Identifier GHSA-4vcf-q4xf-f48m
Severity HIGH
CVSS v3.1 Base Score 7.1
CWE Classification CWE-284: Improper Access Control
Affected Product @better auth/passkey
Package Ecosystem npm
Published Date
Last Updated

Security Impact

CVSS: 7.1

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:L).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required Low (PR:L)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality None (C:N)
Integrity High (I:H)
Availability Low (A:L)

How to Fix GHSA-4vcf-q4xf-f48m

To remediate this vulnerability, upgrade all affected @better auth/passkey dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

@better-auth/passkey fixed: 1.4.0
npm install @better-auth/passkey@1.4.0
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

npm ls @better-auth/passkey

How to Check if You Are Affected

To determine whether your Node.js application is affected by GHSA-4vcf-q4xf-f48m, inspect your project dependencies using npm:

npm ls @better-auth/passkey

Analyze the terminal output to locate any version of @better auth/passkey in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.4.0), your application is affected.

Note: The npm ls @better-auth/passkey command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-284: Improper Access Control, where the product does not restrict or incorrectly restricts access to a resource from an unauthorized actor. In @better auth/passkey, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

# Summary Affected versions of the better-auth passkey plugin allow users with any valid session to delete arbitrary passkeys via their ID using `POST /passkey/delete-passkey`. # Details `ctx.body.id` is implicitly trusted and used in passkey deletion queries. better-auth applications configured with `useNumberId` may use auto incrementing IDs which makes it trivial to delete all passkeys via enumeration.

GHSA-4vcf-q4xf-f48m Affected @better auth/passkey Versions

1 component(s)
Fixed Versions:
1.4.0
Product / Package Ecosystem Affected Versions Fixed Version
@better-auth/passkey
npm
< 1.4.0
1.4.0

References

Frequently Asked Questions

What is GHSA-4vcf-q4xf-f48m?
GHSA-4vcf-q4xf-f48m is a security vulnerability in @better auth/passkey involving Better Auth Passkey Plugin allows passkey deletion through IDOR under CWE-284: Improper Access Control.
Which @better auth/passkey versions are affected?
Affected versions include releases prior to 1.4.0 across affected packages: @better-auth/passkey.
What version fixes GHSA-4vcf-q4xf-f48m?
Upgrading to 1.4.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is @better-auth/passkey affected?
Yes, @better-auth/passkey is affected in releases prior to 1.4.0. Upgrade your dependency to 1.4.0 or later.
What is the CVSS score of GHSA-4vcf-q4xf-f48m?
GHSA-4vcf-q4xf-f48m has a CVSS v3.1 base score of 7.1 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:L.
What CWE is associated with GHSA-4vcf-q4xf-f48m?
GHSA-4vcf-q4xf-f48m is classified under CWE-284: Improper Access Control (The product does not restrict or incorrectly restricts access to a resource from an unauthorized actor.).
How can I check npm dependencies for GHSA-4vcf-q4xf-f48m?
Run the dependency tree command: 'npm ls @better-auth/passkey'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-4vcf-q4xf-f48m",
  "modified" : "2025-11-25T21:42:53Z",
  "published" : "2025-11-25T21:42:53Z",
  "aliases" : [ ],
  "summary" : "Better Auth Passkey Plugin allows passkey deletion through IDOR",
  "details" : "# Summary\n\nAffected versions of the better-auth passkey plugin allow users with any valid session to delete arbitrary passkeys via their ID using `POST /passkey/delete-passkey`.\n\n# Details\n\n`ctx.body.id` is implicitly trusted and used in passkey deletion queries.\n\nbetter-auth applications configured with `useNumberId` may use auto incrementing IDs which makes it trivial to delete all passkeys via enumeration.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:L"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "@better-auth/passkey"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "1.4.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/better-auth/better-auth/security/advisories/GHSA-4vcf-q4xf-f48m"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/better-auth/better-auth/commit/06d68239e"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/better-auth/better-auth"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-284", "CWE-639" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2025-11-25T21:42:53Z",
    "nvd_published_at" : null
  }
}