{"id":"CVE-2026-121971","kind":"vulnerability","aliases":["CVE-2026-121971"],"related":[],"title":"Symfony HttpClient: relative URLs can leak bearer and basic credentials to other hosts","description":"The component ScopingHttpClient in Symfony HttpClient merges the options of its default scope (such as auth_bearer or auth_basic) into a request before resolving a relative URL against the base_uri, allowing a network-path reference such as \"//evil.example/steal\" to be sent to another origin together with the default scope’s credentials, and resulting in potential disclosure of those credentials to an attacker-controlled server. This affects Symfony in versions 5.x prior to 5.4.56, 6.x prior to 6.4.50, 7.x prior to 7.4.23, and 8.x prior to 8.1.11.\n\n\n\nThe resolved URL falls outside the origin of the base URI, yet it keeps the merged options, whereas the absolute spelling \"https://evil.example/steal\" receives none. The same happens with a different port or user-info part on the same host.\n\n\n\n\n\n\n\n\n\nThis is reachable whenever an attacker controls the beginning of a URL passed to a client built with a base_uri and credentials, including those created with HttpClient::createForBaseUri() or configured under framework.http_client.scoped_clients.\n\nTo solve the issue, after resolving a relative URL against the base URI of the default scope, ScopingHttpClient now compares the scheme and authority of the result with those of the base URI, parsed the way the request is sent.","summary":"Symfony HttpClient's ScopingHttpClient merges a default scope's auth options into a request before resolving a relative URL against base_uri, so a network-path reference such as \"//evil.example/steal\" is sent to another origin with the credentials attached. An attacker who controls the start of a URL passed to such a client can capture the auth_bearer or auth_basic credentials.","severity":"high","cvss":8.2,"epss":null,"exploited":false,"exploited_at":null,"products":[],"ecosystems":[],"tags":["http-client","package","php","scoped-clients","symfony"],"not_affected_if":["fixed-urls-only","no-scoped-credentials","patched-version"],"how_to_check":"- Check the Symfony version in `composer.lock` or with `composer show symfony/http-client`.\n- Search the code for `HttpClient::createForBaseUri(` and for `scoped_clients` under `framework.http_client` in config.\n- Look for places where a URL that comes from user input or external data is passed to a scoped client that has `auth_bearer` or `auth_basic` set.","fix":"- Symfony 5.x: `5.4.56` or later\n- Symfony 6.x: `6.4.50` or later\n- Symfony 7.x: `7.4.23` or later\n- Symfony 8.x: `8.1.11` or later","status":"open","published_at":"2026-11-04T18:17:43+00:00","first_seen_at":"2026-11-04T18:28:34+00:00","triaged_at":"2026-11-04T18:29:37+00:00","updated_at":"2026-11-04T18:29:37+00:00","category":"package","confidence":0.85,"triage":{"at":"2026-11-04T18:29:37Z","model":"claude-haiku-5-5","output":{"fix":"- Symfony 5.x: `5.4.56` or later\n- Symfony 6.x: `6.4.50` or later\n- Symfony 7.x: `7.4.23` or later\n- Symfony 8.x: `8.1.11` or later","reach":"internet","title":"Symfony HttpClient: relative URLs can leak bearer and basic credentials to other hosts","impact":"high","summary":"Symfony HttpClient's ScopingHttpClient merges a default scope's auth options into a request before resolving a relative URL against base_uri, so a network-path reference such as \"//evil.example/steal\" is sent to another origin with the credentials attached. An attacker who controls the start of a URL passed to such a client can capture the auth_bearer or auth_basic credentials.","audience":"developers","category":"package","nicknames":[],"who_cares":["symfony","php","http-client","scoped-clients"],"confidence":0.85,"fix_status":"available","needs_auth":"no","worst_case":"credentials sent to attacker-controlled server","analyst_note":"","how_to_check":"- Check the Symfony version in `composer.lock` or with `composer show symfony/http-client`.\n- Search the code for `HttpClient::createForBaseUri(` and for `scoped_clients` under `framework.http_client` in config.\n- Look for places where a URL that comes from user input or external data is passed to a scoped client that has `auth_bearer` or `auth_basic` set.","plain_action":"","needs_analyst":false,"not_affected_if":["no-scoped-credentials","fixed-urls-only","patched-version"],"who_is_affected":"Applications that use Symfony HttpClient with a base_uri and credentials (auth_bearer or auth_basic), created through HttpClient::createForBaseUri() or configured under framework.http_client.scoped_clients. Exposure requires that an attacker can influence the start of a URL passed to that client, for example through a protocol-relative path. Applications that do not use scoped clients with credentials, or that only send fixed URLs, are not exposed.","user_interaction":"no","needs_special_setup":"yes","severity_if_unknown":"high"},"cost_usd":0.000817,"input_tokens":4474,"output_tokens":739,"severity_before":"high"},"analyst_status":null,"analyst_note":null,"search":"'-121971':16A,19A '-2026':15A,18A '/evil.example/steal':59B,132C '/steal':209C '5':165C '5.4.56':169C '6':170C '6.4.50':174C '7':175C '7.4.23':179C '8':181C '8.1.11':185C 'absolut':205C 'affect':161C 'allow':124C 'anoth':63B,137C 'attach':68B 'attack':70B,157C,233C 'attacker-control':156C 'auth':38B,86B,89B,107C,110C 'author':285C 'base':49B,122C,195C,247C,273C,293C 'basic':9A,90B,111C 'bearer':7A,87B,108C 'begin':236C 'built':244C 'captur':84B 'client':22B,27B,82B,243C,261C 'compar':281C 'compon':93C 'configur':258C 'control':72B,158C,234C 'creat':253C 'createforbaseuri':256C 'credenti':10A,67B,91B,145C,153C,250C 'cve':14A,17A 'default':35B,103C,142C,277C 'differ':217C 'disclosur':150C 'evil.example':208C 'evil.example/steal':207C 'fall':189C 'framework.http_client.scoped':260C 'happen':214C 'host':13A,227C 'http':21B 'http-client':20B 'httpclient':2A,30B,97C,255C 'includ':251C 'info':222C 'issu':265C 'keep':199C 'leak':6A 'merg':33B,98C,201C 'network':54B,127C 'network-path':53B,126C 'none':211C 'option':39B,100C,202C 'origin':64B,138C,192C 'outsid':190C 'packag':23B 'pars':295C 'part':223C 'pass':78B,240C 'path':55B,128C 'php':24B 'port':218C 'potenti':149C 'prior':167C,172C,177C,183C 'reachabl':230C 'receiv':210C 'refer':56B,129C 'relat':3A,46B,118C,269C 'request':42B,114C,299C 'resolv':44B,116C,187C,267C 'result':147C,288C 'scheme':283C 'scope':26B,36B,104C,143C,278C 'scoped-cli':25B 'scopinghttpcli':32B,94C,279C 'sent':61B,135C,301C 'server':159C 'solv':263C 'spell':206C 'start':74B 'symfoni':1A,28B,29B,96C,162C 'togeth':139C 'uri':50B,123C,196C,248C,274C,294C 'url':4A,47B,77B,119C,188C,239C,270C 'user':221C 'user-info':220C 'version':164C 'way':297C 'whenev':231C 'wherea':203C 'x':166C,171C,176C,182C 'yet':197C","nicknames":[],"mitigations":[],"who_affected":"Applications that use Symfony HttpClient with a base_uri and credentials (auth_bearer or auth_basic), created through HttpClient::createForBaseUri() or configured under framework.http_client.scoped_clients. Exposure requires that an attacker can influence the start of a URL passed to that client, for example through a protocol-relative path. Applications that do not use scoped clients with credentials, or that only send fixed URLs, are not exposed.","tier":"B","verified":{},"analyst_revisit_at":null,"fix_status":"available","audience":"developers","plain_action":null,"pkeys":[],"ptokens":[],"labels":["high","httpclient","package","php","scopedclients","symfony"],"campaign_type":null,"first_public_at":"2026-11-04T11:43:45+00:00","kev":null,"cvss_vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","cvss_by":"596c5446-0ce5-4ba2-aa66-48b3b757a647","poc_count":0,"sources":[{"source":"nvd","external_id":"CVE-2026-121971","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-121971","severity":null,"published_at":"2026-11-04T18:17:43+00:00","modified_at":"2026-11-04T18:17:43+00:00","first_seen_at":"2026-11-04T18:28:34+00:00","fetched_at":"2026-11-04T18:28:34+00:00","note":null}],"documents":[{"id":69369,"url":"https://github.com/symfony/symfony/commit/64c34e85bd03b3f8a735d8e1af393659dda91d7c","title":"Patch: github.com","kind":"other","source":"nvd","publisher":"vendor","text":null,"published_at":null,"relation":"fix","confidence":null,"note":"Patch: github.com"},{"id":69370,"url":"https://github.com/symfony/symfony/security/advisories/GHSA-gq53-v8w2-gjhj","title":"Vendor advisory: github.com","kind":"vendor","source":"nvd","publisher":"vendor","text":null,"published_at":"2026-11-04T11:43:45+00:00","relation":"advisory","confidence":null,"note":"Vendor advisory: github.com"}],"notice":"Free to read at a human pace. An API with keys and an MCP server are in preparation; early access: hello@infrastack.ai"}