CSS Inline Style Attribute Data Exfiltration Technique
First seen Jul 5, 2026 · Updated Jul 5, 2026
This is a PortSwigger web security research post describing a CSS injection technique that exfiltrates attribute data via chained conditional CSS in inline style attributes, without needing selectors or stylesheet imports. It is a general web application security finding about browsers and CSS, with no relationship to AI agents, LLMs, agent frameworks, or agent-to-agent protocols such as MCP or A2A.
Technical Analysis
The described technique abuses CSS conditional rules within HTML style attributes to leak DOM attribute values character-by-character to an attacker-controlled endpoint, a known class of side-channel exfiltration used in classic web app pentesting (e.g., stealing CSRF tokens or hidden field values via injected CSS). This is unrelated to AI agent tool layers, model planners, memory stores, or inter-agent messaging; the entry point is HTML/CSS injection in a web page rendered by a browser, not a prompt or tool call processed by an LLM agent. No agentic component, MCP/A2A protocol, or agent framework is involved or affected.
Detection Signatures
- Not applicable to AI agent ecosystems; standard web security detections would apply (CSP violations blocking inline style-based exfiltration, unexpected outbound requests correlated with CSS attribute selectors, presence of injected style attributes containing conditional CSS logic in user input).
Remediation Steps
- 1
Not an AI agent security issue
This report concerns traditional web application CSS injection and should be triaged by web app security teams, not AI agent security teams. Standard mitigations include strict Content-Security-Policy, input sanitization, and avoiding reflection of untrusted data into style attributes.
Industries Most Exposed
Respond to this threat
Pro subscribers get a full AI-generated incident-response playbook for this threat — detection, containment, eradication, and recovery steps — plus an unlimited AI Threat Advisor for questions about your environment.