---
id: "CVE-2026-119285"
kind: "vulnerability"
aliases: ["CVE-2026-119285"]
title: "Fiber: CORS wildcard origin matching lets unrelated sites read authenticated responses"
severity: "medium"
cvss: 5.9
epss: null
exploited: false
status: "open"
category: "runtime"
products: []
ecosystems: []
tags: ["cors", "fiber", "go", "runtime", "self-hosted"]
not_affected_if: ["credentials-disabled", "no-wildcard-origins", "version-outside-2.52.1-2.52.2"]
published_at: "2026-10-29T22:17:01+00:00"
first_seen_at: "2026-10-29T22:27:06+00:00"
updated_at: "2026-10-29T22:28:57+00:00"
sources: [{"source": "nvd", "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-119285", "first_seen_at": "2026-10-29T22:27:06+00:00"}]
---

# Fiber: CORS wildcard origin matching lets unrelated sites read authenticated responses

Fiber's CORS middleware matches wildcard subdomain origins by host suffix without requiring a dot boundary, so an attacker-controlled domain ending in the configured base domain is reflected as allowed. When credentials are enabled, a logged-in user visiting that domain lets the attacker's page read authenticated cross-origin responses.

_Summary, check and fix written by a model from the sources; labelled as such._

## How to check

- Check the Fiber module version in `go.mod`; affected versions are from `2.52.1` up to but not including `2.52.3`.
- Search the Go code for `cors.New` and `AllowOrigins` using a wildcard subdomain value such as `https://*.example.com`.
- Check whether `AllowCredentials` is set to `true` in the same CORS configuration.

## Fix

- Fiber: upgrade to `2.52.3`.

## Timeline

- 2026-10-29T22:27:06+00:00 nvd https://nvd.nist.gov/vuln/detail/CVE-2026-119285

## From the sources

Fiber is an Express inspired web framework written in Go. From 2.52.1 until 2.52.3, the CORS middleware's validateDomain wildcard matcher in middleware/cors/utils.go strips the scheme and checks only a host suffix without requiring a dot boundary. An application configured with a wildcard-subdomain AllowOrigins value and AllowCredentials enabled can reflect an unrelated attacker-controlled origin whose host merely ends with the configured base domain. A user who visits that origin can expose authenticated cross-origin responses to the attacker's page; empty-label origins and later comma-space parsing hardening are outside this advisory. This issue is fixed in version 2.52.3.

---

_Free to read at a human pace. An API with keys and an MCP server are in preparation; early access: hello@infrastack.ai_
