{"id":"CVE-2024-38475","kind":"vulnerability","aliases":["CVE-2024-38475"],"related":[],"title":"Improper escaping of output in mod_rewrite in Apache HTTP Server 2.4.59 and earlier allows an attacker to map URLs…","description":"Improper escaping of output in mod_rewrite in Apache HTTP Server 2.4.59 and earlier allows an attacker to map URLs to filesystem locations that are permitted to be served by the server but are not intentionally/directly reachable by any URL, resulting in code execution or source code disclosure. \n\nSubstitutions in server context that use a backreferences or variables as the first segment of the substitution are affected.  Some unsafe RewiteRules will be broken by this change and the rewrite flag \"UnsafePrefixStat\" can be used to opt back in once ensuring the substitution is appropriately constrained.","summary":"Apache HTTP Server's mod_rewrite can be tricked into mapping URLs to filesystem locations that are served but not meant to be reached directly. An attacker can use this to get source code disclosed or run code on the server.","severity":"critical","cvss":9.1,"epss":null,"exploited":true,"exploited_at":"2025-05-01T00:00:00+00:00","products":[{"name":"apache http server","fixed":["2.4.60"],"affected":">= 2.4.0, < 2.4.60","ecosystem":"vendor"},{"name":"netapp ontap 9","fixed":[],"affected":"","ecosystem":"vendor"},{"name":"sonicwall sma 200 firmware","fixed":["10.2.1.14-75sv"],"affected":"< 10.2.1.14-75sv","ecosystem":"vendor"},{"name":"sonicwall sma 210 firmware","fixed":["10.2.1.14-75sv"],"affected":"< 10.2.1.14-75sv","ecosystem":"vendor"},{"name":"sonicwall sma 400 firmware","fixed":["10.2.1.14-75sv"],"affected":"< 10.2.1.14-75sv","ecosystem":"vendor"},{"name":"sonicwall sma 410 firmware","fixed":["10.2.1.14-75sv"],"affected":"< 10.2.1.14-75sv","ecosystem":"vendor"},{"name":"sonicwall sma 500v firmware","fixed":["10.2.1.14-75sv"],"affected":"< 10.2.1.14-75sv","ecosystem":"vendor"},{"name":"Apache HTTP Server","fixed":[],"affected":"","ecosystem":"vendor"}],"ecosystems":["vendor"],"tags":["apache-httpd","exploited","mod_rewrite","runtime","self-hosted"],"not_affected_if":["managed-hosting","no-mod_rewrite-rules"],"how_to_check":null,"fix":"Upgrade Apache HTTP Server to a release that fixes CVE-2024-38475 (version not stated in the sources); CISA's required action is to apply the vendor mitigations or discontinue use if none are available.","status":"open","published_at":"2024-07-01T19:15:04+00:00","first_seen_at":"2026-10-23T19:11:51+00:00","triaged_at":"2026-10-23T20:48:41+00:00","updated_at":"2026-10-24T00:09:50+00:00","category":"runtime","confidence":0.6,"triage":{"at":"2026-10-23T20:48:41Z","model":"claude-haiku-5-5","output":{"fix":"Upgrade Apache HTTP Server to a release that fixes CVE-2024-38475 (version not stated in the sources); CISA's required action is to apply the vendor mitigations or discontinue use if none are available.","reach":"internet","summary":"Apache HTTP Server's mod_rewrite can be tricked into mapping URLs to filesystem locations that are served but not meant to be reached directly. An attacker can use this to get source code disclosed or run code on the server.","category":"runtime","who_cares":["apache-httpd","self-hosted","mod_rewrite"],"confidence":0.6,"needs_auth":"unknown","worst_case":"Attacker reads server source code or executes code on the server.","analyst_note":"Find the fixed Apache httpd version and the exact mod_rewrite rule conditions from the Apache security advisory for CVE-2024-38475 to write how_to_check and fix.","how_to_check":"unknown","needs_analyst":true,"not_affected_if":["no-mod_rewrite-rules","managed-hosting"],"user_interaction":"no","needs_special_setup":"yes","severity_if_unknown":"high"},"cost_usd":0.000455,"input_tokens":2577,"output_tokens":395,"severity_before":"unknown"},"analyst_status":null,"analyst_note":null,"search":"'-2024':22A,25A '-38475':23A,26A '2.4.59':12A,118C '200':35A '210':39A '400':43A '410':47A '500v':51A '9':32A 'affect':173C 'allow':15A,121C 'apach':9A,57B,66B,115C 'apache':27A,53A 'apache-httpd':56B 'appropri':200C 'attack':17A,92B,123C 'back':193C 'backrefer':162C 'broken':179C 'chang':182C 'code':99B,103B,149C,153C 'constrain':201C 'context':158C 'cve':21A,24A 'direct':90B 'disclos':100B 'disclosur':154C 'earlier':14A,120C 'ensur':196C 'escap':2A,108C 'execut':150C 'exploit':59B 'filesystem':79B,128C 'firmware':36A,40A,44A,48A,52A 'first':167C 'flag':186C 'get':97B 'host':65B 'http':10A,28A,54A,67B,116C 'httpd':58B 'improp':1A,107C 'intentionally/directly':142C 'locat':80B,129C 'map':19A,76B,125C 'meant':86B 'mod':6A,60B,70B,112C 'netapp':30A 'ontap':31A 'opt':192C 'output':4A,110C 'permit':132C 'reach':89B 'reachabl':143C 'result':147C 'rewiterul':176C 'rewrit':7A,61B,71B,113C,185C 'run':102B 'runtim':62B 'segment':168C 'self':64B 'self-host':63B 'serv':83B,135C 'server':11A,29A,55A,68B,106B,117C,138C,157C 'sma':34A,38A,42A,46A,50A 'sonicwall':33A,37A,41A,45A,49A 'sourc':98B,152C 'substitut':155C,171C,198C 'trick':74B 'unsaf':175C 'unsafeprefixstat':187C 'url':20A,77B,126C,146C 'use':94B,160C,190C 'variabl':164C","nicknames":[],"mitigations":[],"who_affected":null,"tier":null,"verified":{},"analyst_revisit_at":null,"first_public_at":"2024-07-01T19:15:04+00:00","kev":{"dateAdded":"2025-05-01","dueDate":"2025-05-22","requiredAction":"Apply mitigations per vendor instructions, follow applicable BOD 22-01 guidance for cloud services, or discontinue use of the product if mitigations are unavailable.","knownRansomwareCampaignUse":"Unknown"},"cvss_vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","cvss_by":"nvd@nist.gov","poc_count":0,"sources":[{"source":"kev","external_id":"CVE-2024-38475","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog?search_api_fulltext=CVE-2024-38475","severity":null,"published_at":"2025-05-01T00:00:00+00:00","modified_at":null,"first_seen_at":"2026-10-23T19:11:51+00:00","fetched_at":"2026-10-25T17:39:55+00:00","note":null},{"source":"nvd","external_id":"CVE-2024-38475","url":"https://nvd.nist.gov/vuln/detail/CVE-2024-38475","severity":null,"published_at":"2024-07-01T19:15:04+00:00","modified_at":"2026-06-17T07:40:21+00:00","first_seen_at":"2026-10-23T22:29:05+00:00","fetched_at":"2026-10-23T22:29:05+00:00","note":null}],"documents":[],"notice":"Free to read at a human pace. An API with keys and an MCP server are in preparation; early access: hello@infrastack.ai"}