Średnia

Webauthn Framework: allowed_origins collapses URL-like origins to host-only values, bypassing exact origin validation

  • Ujawniono: 10.03.2026
  • Aktualizacja: 11.10.2026 10:22

Summary

When allowed_origins is configured, CheckAllowedOrigins reduces URL-like values to their host component and accepts on host match alone. This makes exact origin policies impossible to express: scheme and port differences are silently ignored.

Details

CheckAllowedOrigins stores each configured allowed origin as:

php
parse_url($allowedOrigin)['host'] ?? $allowedOrigin

and later reduces the received clientDataJSON.origin the same way:

php
parse_url($C->origin)['host'] ?? $C->origin

If the reduced value matches, the method returns early. As a result, for the normal allowed_origins path, the later HTTPS check is not reached.

This differs from WebAuthn Level 2, which requires verifying that C.origin matches the RP's origin (scheme + host + port), separately from verifying that authData.rpIdHash matches the expected RP ID.

Affected code:

Spec references:

PoC

Configuration:

yaml
webauthn:
  allowed_origins:
    - https://login.example.com:8443
  allow_subdomains: false

Send a registration or authentication response whose clientDataJSON.origin is:

https://login.example.com:9443

Observed: the response is accepted, because both values are reduced to login.example.com.

Expected: the response should be rejected, because https://login.example.com:8443 and https://login.example.com:9443 are different origins.

Impact

This is an origin validation error (CWE-346) affecting deployments that use allowed_origins. The most practical browser-facing scenario is same-host / different-port origin confusion. In non-browser or custom clients, scheme confusion may also be relevant.

Fix

Fixed in version 5.2.4 by rewriting CheckAllowedOrigins to perform full origin comparison (scheme + host + port) as required by the WebAuthn spec:

  • Origins configured with a scheme (e.g. https://example.com:8443) are now stored and compared as full scheme://host[:port] values, with default port normalization (443 for HTTPS, 80 for HTTP).
  • Origins configured without a scheme are still matched by host only, for backward compatibility.
  • Subdomain matching now also verifies scheme and port consistency.

See commit b4cd9a43.

Mitigation

Upgrade to web-auth/webauthn-framework (or web-auth/webauthn-lib / web-auth/webauthn-symfony-bundle) >= 5.2.4.

Czego dotyczy

Kliknij technologię, aby zobaczyć wszystkie dotyczące jej podatności.

PlatformaPaczkaPodatne wersjePoprawka w wersji
Paczka Composer web-auth/webauthn-framework >= 5.2.0, < 5.2.4 5.2.4
Paczka Composer web-auth/webauthn-lib >= 5.2.0, < 5.2.4 5.2.4
Paczka Composer web-auth/webauthn-symfony-bundle >= 5.2.0, < 5.2.4 5.2.4

Odnośniki

Ocena CVSS 5.4/10
Wektor CVSS
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N
Słabość (CWE)
CWE-346
Platforma
Composer
Paczka
web-auth/webauthn-framework, web-auth/webauthn-lib, web-auth/webauthn-symfony-bundle
Ujawniono
10.03.2026
Aktualizacja
11.10.2026 10:22

Źródła i licencje

OSV / GitHub Advisory Database - GHSA-f7pm-6hr8-7ggm - CC BY 4.0

Historia podatności: web-auth/webauthn-lib

Wszystkie opisane podatności tej paczki (Paczka Composer), od najnowszej. Widać, czy to jednorazowa wpadka, czy paczka, której trzeba pilnować.

Wszystkich wpisów
3
Pierwsza → ostatnia
07.2024 07.2026
Bez poprawki
0
Wykorzystywana w atakach
0

Rozkład istotności

  • Średnia 2
  • Niska 1

Ujawnienia w latach

  1. 2024: 1
  2. 2025: 0
  3. 2026: 2
  1. Webauthn Framework: allowed_origins collapses URL-like origins to host-only values, bypassing exact origin validation ten wpis
    Średnia · 5.4 CVE-2026-30964 >= 5.2.0, < 5.2.4 5.2.4
  2. Średnia · 5.3 CVE-2024-39912 >= 4.5.0, < 4.9.0 4.9.0

Dowiedz się, które podatności dotyczą Twojej aplikacji

Po podłączeniu integracji DockRay i włączeniu raportowania oprogramowania DockRay porównuje zgłoszone wersje komponentów ze znanymi podatnościami i powiadamia o potwierdzonych dopasowaniach. Zakres zależy od obsługiwanej technologii i dostępnych biuletynów.

Podłącz swoją aplikację
Newsletter DockRay

Bezpieczeństwo aplikacji w Twojej skrzynce

Najważniejsze podatności, konkretne zalecenia i praktyczne wskazówki dla Twoich aplikacji. Wybierz technologie i śledź to, co ma znaczenie dla Twojego projektu.

  • Codzienne zestawienie nowych podatności, także krytycznych.
  • Powiadomienia o ważnych aktualizacjach.
  • Praktyczne porady o bezpieczeństwie i monitoringu aplikacji.

Pozostaw puste, aby otrzymywać informacje o wszystkich technologiach.

Zapis jest bezpłatny. Wypiszesz się jednym kliknięciem w wiadomości.