---
id: CVE-2025-71401
title: >-
  better-auth (npm) before 1.4.2 allows an external request to configure baseURL
  when it is not otherwise defined (e.g., BETTER_AUTH_URL is unset)
summary: >-
  better-auth (npm) before 1.4.2 allows an external request to configure baseURL
  when it is not otherwise defined (e.g., BETTER_AUTH_URL is unset). An attacker
  able to make the very first request to the server after startup can poison the
  …
severity: medium
cvss: 5.9
cvssVector: 'CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H'
cwe:
  - CWE-770
published: '2026-08-02'
updated: '2026-09-08'
sourceUpdated: '2026-09-08T20:34:34.997'
source: NVD
sourceUrl: 'https://nvd.nist.gov/vuln/detail/CVE-2025-71401'
references:
  - url: >-
      https://github.com/better-auth/better-auth/security/advisories/GHSA-569q-mpph-wgww
    label: disclosure@vulncheck.com
  - url: >-
      https://www.vulncheck.com/advisories/better-auth-before-basepath-modification-dos
    label: disclosure@vulncheck.com
tags:
  - nvd
epss: 0.0026
epssPercentile: 0.1803
ingestedAt: '2026-08-02T13:18:29.919Z'
---

## Overview

better-auth (npm) before 1.4.2 allows an external request to configure baseURL when it is not otherwise defined (e.g., BETTER_AUTH_URL is unset). An attacker able to make the very first request to the server after startup can poison the router's base path, causing all routes to return 404 for all users (denial of service). The issue is not reachable when baseURL is explicitly configured or on typical managed hosting platforms.

## Remediation

Refer to the linked advisories for vendor-supplied fixes and affected version ranges.
