{"id":"CVE-2026-126779","kind":"vulnerability","aliases":["CVE-2026-126779"],"related":[],"title":"Browsershot: root-relative HTML references let attackers read server files","description":"Spatie Browsershot 2.2.0 before 5.5.0 contains a local file read vulnerability that allows attackers to read server files by supplying root-relative references in HTML passed to setHtml(). Attackers can embed iframe, img, link or script elements referencing paths like /etc/passwd, which resolve to file:// URLs and render file contents into the returned PDF or screenshot.","summary":"Spatie Browsershot, a PHP library that renders HTML to PDF or screenshots, resolves root-relative references such as /etc/passwd in HTML passed to setHtml() to file:// URLs. An attacker who controls that HTML can read server files and see their contents in the generated PDF or screenshot.","severity":"high","cvss":8.7,"epss":null,"exploited":false,"exploited_at":null,"products":[],"ecosystems":[],"tags":["browsershot","laravel","package","pdf-generation","php"],"not_affected_if":["static-html-only","version-5.5.0-or-later"],"how_to_check":"- Check the installed version with `composer show spatie/browsershot`\n- Look for calls to `setHtml()` that include user-supplied HTML","fix":"- Spatie Browsershot: move to `5.5.0` or later (fixed version per the advisory; the sources state before 5.5.0 is affected)","status":"open","published_at":"2026-11-11T19:17:38+00:00","first_seen_at":"2026-11-11T19:28:47+00:00","triaged_at":"2026-11-11T19:29:50+00:00","updated_at":"2026-11-11T19:29:50+00:00","category":"package","confidence":0.7,"triage":{"at":"2026-11-11T19:29:50Z","model":"claude-haiku-5-5","output":{"fix":"- Spatie Browsershot: move to `5.5.0` or later (fixed version per the advisory; the sources state before 5.5.0 is affected)","reach":"internet","title":"Browsershot: root-relative HTML references let attackers read server files","impact":"medium","summary":"Spatie Browsershot, a PHP library that renders HTML to PDF or screenshots, resolves root-relative references such as /etc/passwd in HTML passed to setHtml() to file:// URLs. An attacker who controls that HTML can read server files and see their contents in the generated PDF or screenshot.","audience":"developers","category":"package","nicknames":[],"who_cares":["php","browsershot","laravel","pdf-generation"],"confidence":0.7,"fix_status":"available","needs_auth":"unknown","worst_case":"server files such as /etc/passwd readable in rendered output","analyst_note":"","how_to_check":"- Check the installed version with `composer show spatie/browsershot`\n- Look for calls to `setHtml()` that include user-supplied HTML","plain_action":"","product_name":"","needs_analyst":false,"not_affected_if":["static-html-only","version-5.5.0-or-later"],"who_is_affected":"Applications that use spatie/browsershot from 2.2.0 up to but not including 5.5.0 and pass HTML into setHtml() that can contain attacker-chosen content, such as user-submitted templates or report content. Sites that only render fixed, trusted HTML or only load URLs are less exposed; the sources do not say more.","user_interaction":"no","product_ecosystem":"","needs_special_setup":"unknown","severity_if_unknown":"high"},"cost_usd":0.000752,"input_tokens":4636,"output_tokens":576,"severity_before":"high"},"analyst_status":null,"analyst_note":null,"search":"'-126779':14A,17A '-2026':13A,16A '/etc/passwd':44B,113C '2.2.0':74C '5.5.0':76C 'allow':84C 'attack':8A,53B,85C,101C 'browsershot':1A,18B,26B,73C 'contain':77C 'content':65B,121C 'control':55B 'cve':12A,15A 'element':109C 'emb':103C 'file':11A,61B,80C,89C,120C 'generat':23B,68B 'html':5A,32B,46B,57B,97C 'ifram':104C 'img':105C 'laravel':19B 'let':7A 'librari':29B 'like':112C 'link':106C 'local':79C 'packag':20B 'pass':47B,98C 'path':111C 'pdf':22B,34B,69B,125C 'pdf-gener':21B 'php':24B,28B 'read':9A,59B,81C,87C 'refer':6A,41B,95C 'referenc':110C 'relat':4A,40B,94C 'render':31B,119C 'resolv':37B,115C 'return':124C 'root':3A,39B,93C 'root-rel':2A,38B,92C 'screenshot':36B,71B,127C 'script':108C 'see':63B 'server':10A,60B,88C 'sethtml':49B,100C 'spati':25B,72C 'suppli':91C 'url':51B,117C 'vulner':82C","nicknames":[],"mitigations":[],"who_affected":"Applications that use spatie/browsershot from 2.2.0 up to but not including 5.5.0 and pass HTML into setHtml() that can contain attacker-chosen content, such as user-submitted templates or report content. Sites that only render fixed, trusted HTML or only load URLs are less exposed; the sources do not say more.","tier":"B","verified":{},"analyst_revisit_at":null,"fix_status":"available","audience":"developers","plain_action":null,"pkeys":[],"ptokens":[],"labels":["browsershot","high","laravel","package","pdfgeneration","php"],"campaign_type":null,"search_a":"'-126779':14A,17A '-2026':13A,16A 'attack':8A 'browsershot':1A 'cve':12A,15A 'file':11A 'html':5A 'let':7A 'read':9A 'refer':6A 'relat':4A 'root':3A 'root-rel':2A 'server':10A","search_b":"'/etc/passwd':44B 'attack':53B 'browsershot':18B,26B 'content':65B 'control':55B 'file':61B 'generat':23B,68B 'html':32B,46B,57B 'laravel':19B 'librari':29B 'packag':20B 'pass':47B 'pdf':22B,34B,69B 'pdf-gener':21B 'php':24B,28B 'read':59B 'refer':41B 'relat':40B 'render':31B 'resolv':37B 'root':39B 'root-rel':38B 'screenshot':36B,71B 'see':63B 'server':60B 'sethtml':49B 'spati':25B 'url':51B","search_c":"'/etc/passwd':113C '2.2.0':74C '5.5.0':76C 'allow':84C 'attack':85C,101C 'browsershot':73C 'contain':77C 'content':121C 'element':109C 'emb':103C 'file':80C,89C,120C 'html':97C 'ifram':104C 'img':105C 'like':112C 'link':106C 'local':79C 'pass':98C 'path':111C 'pdf':125C 'read':81C,87C 'refer':95C 'referenc':110C 'relat':94C 'render':119C 'resolv':115C 'return':124C 'root':93C 'root-rel':92C 'screenshot':127C 'script':108C 'server':88C 'sethtml':100C 'spati':72C 'suppli':91C 'url':117C 'vulner':82C","cause_entry":null,"cause_path":null,"disclosures_checked_at":null,"first_public_at":"2026-11-11T19:17:38+00:00","kev":null,"cvss_vector":"CVSS:4.0/AV:N/AC:L/AT:N/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":"disclosure@vulncheck.com","poc_count":0,"sources":[{"source":"nvd","external_id":"CVE-2026-126779","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-126779","severity":null,"published_at":"2026-11-11T19:17:38+00:00","modified_at":"2026-11-11T19:17:38+00:00","first_seen_at":"2026-11-11T19:28:47+00:00","fetched_at":"2026-11-11T19:28:47+00:00","note":null}],"documents":[{"id":128124,"url":"https://github.com/spatie/browsershot/commit/eba71ab7f4aba23d9321d653ccd19d4e94432516","title":"Patch: github.com","kind":"other","source":"nvd","publisher":"vendor","text":null,"published_at":null,"relation":"fix","confidence":null,"note":"Patch: github.com"},{"id":128125,"url":"https://github.com/spatie/browsershot/releases/tag/5.5.0","title":"Release notes: github.com","kind":"release","source":"nvd","publisher":"vendor","text":null,"published_at":null,"relation":"fix","confidence":null,"note":"Release notes: github.com"},{"id":128126,"url":"https://www.vulncheck.com/advisories/spatie-browsershot-2.2.0-before-5.5.0-local-file-read-via-sethtml","title":"Third-party advisory: www.vulncheck.com","kind":"advisory","source":"nvd","publisher":"research","text":null,"published_at":null,"relation":"advisory","confidence":null,"note":"Third-party advisory: www.vulncheck.com"}],"disclosures":[],"exploit_sources":[],"notice":"Free to read, with fair use of about 60 pages a minute. For higher limits or API access: sales@infrastack.ai"}