# Blocklist header injection into outbound calls

Client-supplied header names or values filtered by a blocklist before being forwarded to outbound requests

_Area: Web injection and code execution. Seen in 2 disclosed reports; 2 confirmed bounties: $100 and $35,000; latest 2026-07-02. Updated 2026-11-15._

## How it works
A component accepts header names or values from a client and forwards them into an outbound request (HTTP, SIP, email, cookie). The filter guarding that forwarding enumerates *bad* inputs (a blocklist) instead of enumerating *allowed* inputs (a whitelist). Anything the blocklist author did not anticipate passes through untouched. The assumption that breaks: "we removed the dangerous headers, so what remains is safe." In reality the set of dangerous headers is open-ended, and the downstream sink (a SIP INVITE builder, a header serializer, an email template) treats the surviving bytes as trusted structure.

## Where it shows up
- A filter that names specific headers to strip (e.g. three internal names) rather than listing the few headers a client may set [E2](https://bugbountylibrary.com/r/h1%3A3789570.md).
- Client-supplied header collections stored into a generic `extraHeaders`-style map and later concatenated into an outbound message without re-validation [E2](https://bugbountylibrary.com/r/h1%3A3789570.md).
- A parameter that is both parsed (e.g. to integer) and rendered verbatim into a header, so parser-differential terminators (null bytes) satisfy one path while raw bytes reach the other [E1](https://bugbountylibrary.com/r/blog%3Arobertchen-cc-blog-2021-04-03-github-pages-xss.md).
- User-controlled display names interpolated into transactional email templates, where a name field accepts a sentence or URL [E3](https://bugbountylibrary.com/r/blog%3Ahuntress-com-blog-meta-business-manager-phishing.md).
- Case-insensitive matching of security-relevant prefixes (`__Host-` vs `__HOST-`) [E1](https://bugbountylibrary.com/r/blog%3Arobertchen-cc-blog-2021-04-03-github-pages-xss.md).

## How to review
Find every place client data becomes an outbound header. The invariant: the set of forwarded header names and the character set of forwarded values must be defined by an allowlist, and the sink must reject anything outside it. Check: does the filter enumerate allowed or forbidden items? Does the downstream consumer re-validate, or trust the filter? For parsed-and-reflected parameters, ask whether a terminator (null, CRLF, whitespace) can satisfy the parser while the renderer emits raw bytes. For templates, ask whether a name field can contain a URL or sentence.

## How finders spotted it
- Code review showed the Prosody filter was a three-name blocklist, prompting a trace through Jigasi's `CallControl.java` and `SipGatewaySession.java` to confirm unfiltered propagation into SIP INVITEs [E2](https://bugbountylibrary.com/r/h1%3A3789570.md).
- While mapping a custom auth flow, noticed `page_id` whitespace was ignored yet reflected into `Set-Cookie`; knowing the server was openresty nginx, hypothesized an int-parse vs raw-render split and tried a null byte to terminate parsing while keeping CRLF breakout [E1](https://bugbountylibrary.com/r/blog%3Arobertchen-cc-blog-2021-04-03-github-pages-xss.md).
- Cookie nonce bypass came from reading cookie RFCs and testing `__HOST-` vs `__Host-` capitalization [E1](https://bugbountylibrary.com/r/blog%3Arobertchen-cc-blog-2021-04-03-github-pages-xss.md).
- A honeypot phishing email's awkward injected sentence revealed the partner-name field as the injection point; URLs were then followed through the delivery chain [E3](https://bugbountylibrary.com/r/blog%3Ahuntress-com-blog-meta-business-manager-phishing.md).

## Variants seen
- SIP header injection via blocklist filter, enabling Caller ID spoofing [E2](https://bugbountylibrary.com/r/h1%3A3789570.md).
- CRLF injection into `Set-Cookie` via a parsed-and-reflected integer parameter, combined with cookie-prefix case bypass and cache poisoning [E1](https://bugbountylibrary.com/r/blog%3Arobertchen-cc-blog-2021-04-03-github-pages-xss.md).
- URL injection into a transactional email template via a display-name field [E3](https://bugbountylibrary.com/r/blog%3Ahuntress-com-blog-meta-business-manager-phishing.md).

## Impact and severity
E2: authenticated users spoof Caller ID in outbound calls [E2](https://bugbountylibrary.com/r/h1%3A3789570.md). E1: XSS on private github.io pages, escalated by cache poisoning from user-interaction to persistent XSS against non-interacting users, and pivoted from an outside account to org-private pages — $35k [E1](https://bugbountylibrary.com/r/blog%3Arobertchen-cc-blog-2021-04-03-github-pages-xss.md). E3: phishing from a trusted Meta domain capturing credentials, MFA codes and ID documents, with captured accounts enabling further attacks on the victim's customers [E3](https://bugbountylibrary.com/r/blog%3Ahuntress-com-blog-meta-business-manager-phishing.md). Impact rises with trust in the emitting domain and with reach to non-interacting users.

## Evidence
- E1: https://bugbountylibrary.com/r/blog%3Arobertchen-cc-blog-2021-04-03-github-pages-xss.md
- E2: https://bugbountylibrary.com/r/h1%3A3789570.md
- E3: https://bugbountylibrary.com/r/blog%3Ahuntress-com-blog-meta-business-manager-phishing.md
