Double Encoding
URL-encoding characters twice to bypass filters that decode only once, allowing malicious payloads to be decoded by the application.
Double Encoding is a technique where characters are URL-encoded twice to bypass security filters that only decode input once, allowing malicious payloads to pass through and be decoded by the application.
Vulnerable Scenarios
- WAF decodes before checking, app decodes again
- Reverse proxy decodes, backend decodes again
- Multiple processing layers with decoding
Prevention
- Decode input once at a single point
- Validate after final decoding
- Reject requests with encoded characters where not expected