The SentinelOne Annual Threat Report - A Defenders Guide from the FrontlinesThe SentinelOne Annual Threat ReportGet the Report
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI for Security
      Leading the Way in AI-Powered Security Solutions
    • Securing AI
      Accelerate AI Adoption with Secure AI Tools, Apps, and Agents.
    • How It Works
      The Singularity XDR Difference
    • Singularity Marketplace
      One-Click Integrations to Unlock the Power of XDR
    • Pricing & Packaging
      Comparisons and Guidance at a Glance
    Data & AI
    • Purple AI
      Accelerate SecOps with Generative AI
    • Singularity Hyperautomation
      Easily Automate Security Processes
    • AI-SIEM
      The AI SIEM for the Autonomous SOC
    • AI Data Pipelines
      Security Data Pipeline for AI SIEM and Data Optimization
    • Singularity Data Lake
      AI-Powered, Unified Data Lake
    • Singularity Data Lake for Log Analytics
      Seamlessly Ingest Data from On-Prem, Cloud or Hybrid Environments
    Endpoint Security
    • Singularity Endpoint
      Autonomous Prevention, Detection, and Response
    • Singularity XDR
      Native & Open Protection, Detection, and Response
    • Singularity RemoteOps Forensics
      Orchestrate Forensics at Scale
    • Singularity Threat Intelligence
      Comprehensive Adversary Intelligence
    • Singularity Vulnerability Management
      Application & OS Vulnerability Management
    • Singularity Identity
      Identity Threat Detection and Response
    Cloud Security
    • Singularity Cloud Security
      Block Attacks with an AI-Powered CNAPP
    • Singularity Cloud Native Security
      Secure Cloud and Development Resources
    • Singularity Cloud Workload Security
      Real-Time Cloud Workload Protection Platform
    • Singularity Cloud Data Security
      AI-Powered Threat Detection for Cloud Storage
    • Singularity Cloud Security Posture Management
      Detect and Remediate Cloud Misconfigurations
    Securing AI
    • Prompt Security
      Secure AI Tools Across Your Enterprise
  • Why SentinelOne?
    Why SentinelOne?
    • Why SentinelOne?
      Cybersecurity Built for What’s Next
    • Our Customers
      Trusted by the World’s Leading Enterprises
    • Industry Recognition
      Tested and Proven by the Experts
    • About Us
      The Industry Leader in Autonomous Cybersecurity
    Compare SentinelOne
    • Arctic Wolf
    • Broadcom
    • CrowdStrike
    • Cybereason
    • Microsoft
    • Palo Alto Networks
    • Sophos
    • Splunk
    • Trellix
    • Trend Micro
    • Wiz
    Verticals
    • Energy
    • Federal Government
    • Finance
    • Healthcare
    • Higher Education
    • K-12 Education
    • Manufacturing
    • Retail
    • State and Local Government
  • Services
    Managed Services
    • Managed Services Overview
      Wayfinder Threat Detection & Response
    • Threat Hunting
      World-Class Expertise and Threat Intelligence
    • Managed Detection & Response
      24/7/365 Expert MDR Across Your Entire Environment
    • Incident Readiness & Response
      DFIR, Breach Readiness, & Compromise Assessments
    Support, Deployment, & Health
    • Technical Account Management
      Customer Success with Personalized Service
    • SentinelOne GO
      Guided Onboarding & Deployment Advisory
    • SentinelOne University
      Live and On-Demand Training
    • Services Overview
      Comprehensive Solutions for Seamless Security Operations
    • SentinelOne Community
      Community Login
  • Partners
    Our Network
    • MSSP Partners
      Succeed Faster with SentinelOne
    • Singularity Marketplace
      Extend the Power of S1 Technology
    • Cyber Risk Partners
      Enlist Pro Response and Advisory Teams
    • Technology Alliances
      Integrated, Enterprise-Scale Solutions
    • SentinelOne for AWS
      Hosted in AWS Regions Around the World
    • Channel Partners
      Deliver the Right Solutions, Together
    • SentinelOne for Google Cloud
      Unified, Autonomous Security Giving Defenders the Advantage at Global Scale
    • Partner Locator
      Your Go-to Source for Our Top Partners in Your Region
    Partner Portal→
  • Resources
    Resource Center
    • Case Studies
    • Data Sheets
    • eBooks
    • Reports
    • Videos
    • Webinars
    • Whitepapers
    • Events
    View All Resources→
    Blog
    • Feature Spotlight
    • For CISO/CIO
    • From the Front Lines
    • Identity
    • Cloud
    • macOS
    • SentinelOne Blog
    Blog→
    Tech Resources
    • SentinelLABS
    • Ransomware Anthology
    • Cybersecurity 101
  • About
    About SentinelOne
    • About SentinelOne
      The Industry Leader in Cybersecurity
    • Investor Relations
      Financial Information & Events
    • SentinelLABS
      Threat Research for the Modern Threat Hunter
    • Careers
      The Latest Job Opportunities
    • Press & News
      Company Announcements
    • Cybersecurity Blog
      The Latest Cybersecurity Threats, News, & More
    • FAQ
      Get Answers to Our Most Frequently Asked Questions
    • DataSet
      The Live Data Platform
    • S Foundation
      Securing a Safer Future for All
    • S Ventures
      Investing in the Next Generation of Security, Data and AI
  • Pricing
Get StartedContact Us
CVE Vulnerability Database
Vulnerability Database/CVE-2026-4519

CVE-2026-4519: Python Command Injection Vulnerability

CVE-2026-4519 is a command injection flaw in Python's webbrowser.open() API that allows malicious URLs with leading dashes to be interpreted as command options. This article covers technical details, affected versions, and mitigation.

Updated: May 14, 2026

CVE-2026-4519 Overview

CVE-2026-4519 affects the Python standard library webbrowser module. The webbrowser.open() API accepted URLs containing leading dashes, which certain web browsers parse as command line options rather than as a URL target. An attacker who can influence the URL string passed to webbrowser.open() can therefore smuggle arbitrary browser flags into the underlying browser process. The issue is classified as Improper Input Validation [CWE-20]. Updated Python builds reject leading dashes, and the Python Security Response Team recommends sanitizing URLs before passing them to webbrowser.open().

Critical Impact

A crafted URL string can be interpreted as browser command line flags, enabling local argument injection that may compromise confidentiality and integrity of the user session.

Affected Products

  • CPython webbrowser module across maintained 3.x branches
  • Python 3.15.0 pre-release builds (alpha1 through alpha7)
  • Applications and libraries that pass untrusted input to webbrowser.open()

Discovery Timeline

  • 2026-03-20 - CVE CVE-2026-4519 published to NVD
  • 2026-04-16 - Last updated in NVD database

Technical Details for CVE-2026-4519

Vulnerability Analysis

The webbrowser module in CPython launches an external browser by building a command line and invoking the browser binary through the subprocess family of APIs. The URL argument is appended directly to the browser command without validating that it is structurally a URL. Many browsers accept long-form flags such as --app=, --remote-debugging-port=, or --user-data-dir= as positional arguments. If a URL begins with - or --, the browser process treats it as an option, not a navigation target.

Attackers leverage this to alter browser behavior at launch. Examples include forcing the browser into application mode pointing at attacker content, redirecting the user profile to a writable directory, or enabling remote debugging interfaces that expose the browsing session. The vulnerability requires that attacker-controlled data reach webbrowser.open(), which is common in desktop tools, help systems, and CLI utilities that resolve documentation or external links.

Root Cause

The root cause is missing input validation on the URL parameter to webbrowser.open(). The module trusted the caller to provide a well-formed URL and forwarded the string to the browser as an argv element. Because POSIX and Windows browsers treat leading - tokens as switches, the argument boundary between option and URL collapses. The fix in CPython rejects URLs whose first character is -, restoring the expected separation between flags and the target URL.

Attack Vector

The attack vector is local and requires user interaction. The adversary supplies a malicious URL through a channel that a Python application later opens with webbrowser.open(). Typical sources include shortcut files, registered URL handlers, configuration files, command line arguments parsed by a Python tool, or content rendered in a desktop application. When the application calls webbrowser.open(url) with a value like --remote-debugging-port=9222, the browser starts with the attacker-chosen flag rather than navigating to a site.

No verified public exploit code is available at this time. Refer to the Python Security Announcement Thread and GitHub Issue #143930 for additional technical context.

Detection Methods for CVE-2026-4519

Indicators of Compromise

  • Browser child processes spawned by python or python3 with command line arguments beginning with - or -- instead of http:// or https://.
  • Unexpected use of browser flags such as --remote-debugging-port, --user-data-dir, --app, or --load-extension immediately after a Python process executes.
  • New browser profile directories or extension loads originating from Python-launched browser sessions.

Detection Strategies

  • Audit source code and dependencies for calls to webbrowser.open(), webbrowser.open_new(), and webbrowser.open_new_tab() that consume untrusted input.
  • Use EDR process telemetry to alert when a Python interpreter is the parent of a browser process whose first URL argument starts with -.
  • Apply static analysis rules (Bandit, Semgrep) that flag webbrowser.open(x) where x is not a literal or validated string.

Monitoring Recommendations

  • Centralize process creation events from Windows, macOS, and Linux endpoints to identify anomalous browser launch flags.
  • Track Python application updates and confirm that runtime versions include the fix commits listed in the CPython advisory.
  • Alert on Python tools that launch browsers with debugging or extension-loading flags outside of approved developer workflows.

How to Mitigate CVE-2026-4519

Immediate Actions Required

  • Upgrade to a CPython release that includes the fix commits referenced in the CPython security patch series.
  • Inventory internal applications that call webbrowser.open() and validate every URL argument against a strict allowlist scheme such as http, https, mailto, or file.
  • Reject any URL whose first character is - before invoking the webbrowser module.

Patch Information

The Python maintainers landed a series of commits across supported branches that reject URLs beginning with a leading dash. Relevant fixes include commit 3681d47a, commit 43fe06b9, and the consolidating pull request #143931. Apply distribution updates that ship these commits, or upgrade to the next patch release on each supported 3.x branch.

Workarounds

  • Wrap calls with a validator: parse the URL using urllib.parse.urlsplit, require a known scheme, and abort if the raw string begins with -.
  • Prefix relative or scheme-less inputs with https:// after validation to ensure the argument cannot be interpreted as a flag.
  • For applications that cannot upgrade immediately, replace webbrowser.open() with a controlled wrapper that invokes the browser through subprocess using an explicit -- argument separator where the target browser supports it.
bash
# Configuration example: sanitize before calling webbrowser.open()
python - <<'PY'
import sys
from urllib.parse import urlsplit
import webbrowser

def safe_open(url: str) -> bool:
    if not url or url[0] == '-':
        return False
    parts = urlsplit(url)
    if parts.scheme not in {'http', 'https', 'mailto', 'file'}:
        return False
    return webbrowser.open(url)

sys.exit(0 if safe_open(sys.argv[1]) else 1)
PY

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

  • Vulnerability Details
  • TypeOther

  • Vendor/TechPython

  • SeverityHIGH

  • CVSS Score7.0

  • EPSS Probability0.01%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:A/VC:H/VI:H/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
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityHigh
  • AvailabilityNone
  • CWE References
  • CWE-20
  • Technical References
  • OpenWall OSS Security Discussion
  • Vendor Resources
  • GitHub CPython Commit Update

  • GitHub CPython Commit Update

  • GitHub CPython Commit Update

  • GitHub CPython Commit Update

  • GitHub CPython Commit Update

  • GitHub CPython Commit Update

  • GitHub CPython Commit Update

  • GitHub CPython Commit Update

  • GitHub CPython Commit Update

  • GitHub CPython Commit Update

  • GitHub CPython Commit Update

  • GitHub CPython Commit Update

  • GitHub Issue #143930

  • GitHub Pull Request #143931

  • Python Security Announcement Thread
  • Related CVEs
  • CVE-2025-13462: Python tarfile Module Parsing Vulnerability

  • CVE-2021-23336: Python Web Cache Poisoning Vulnerability

  • CVE-2024-6923: CPython Email Header Injection Flaw

  • CVE-2020-26116: Python HTTP Client CRLF Injection Flaw
Default Legacy - Prefooter | Experience the World’s Most Advanced Cybersecurity Platform

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.

Try SentinelOne
  • Get Started
  • Get a Demo
  • Product Tour
  • Why SentinelOne
  • Pricing & Packaging
  • FAQ
  • Contact
  • Contact Us
  • Customer Support
  • SentinelOne Status
  • Language
  • Platform
  • Singularity Platform
  • Singularity Endpoint
  • Singularity Cloud
  • Singularity AI-SIEM
  • Singularity Identity
  • Singularity Marketplace
  • Purple AI
  • Services
  • Wayfinder TDR
  • SentinelOne GO
  • Technical Account Management
  • Support Services
  • Verticals
  • Energy
  • Federal Government
  • Finance
  • Healthcare
  • Higher Education
  • K-12 Education
  • Manufacturing
  • Retail
  • State and Local Government
  • Cybersecurity for SMB
  • Resources
  • Blog
  • Labs
  • Case Studies
  • Videos
  • Product Tours
  • Events
  • Cybersecurity 101
  • eBooks
  • Webinars
  • Whitepapers
  • Press
  • News
  • Ransomware Anthology
  • Company
  • About Us
  • Our Customers
  • Careers
  • Partners
  • Legal & Compliance
  • Security & Compliance
  • Investor Relations
  • S Foundation
  • S Ventures

©2026 SentinelOne, All Rights Reserved.

Privacy Notice Terms of Use

English