HTTPS to HTTP redirect Misconfiguration
ID: https-to-http-redirect
Severity: info
Author: kazet,idealphase
Tags: misconfig,http,https
Description
Section titled “Description”Detects whether there is a redirect from https:// to http://
YAML Source
Section titled “YAML Source”id: https-to-http-redirect
info: name: HTTPS to HTTP redirect Misconfiguration author: kazet,idealphase severity: info description: | Detects whether there is a redirect from https:// to http:// metadata: verified: true max-request: 1 tags: misconfig,http,https
http: - method: GET path: - "{{BaseURL}}"
matchers-condition: or matchers: - type: dsl dsl: - 'startswith(tolower(location), "http://")' - 'startswith(tostring(BaseURL), "https://")' - '(status_code == 300 || status_code == 301 || status_code == 302 || status_code == 303 || status_code == 307 || status_code == 308)' condition: and
- type: dsl dsl: - 'startswith(tostring(BaseURL), "https://")' - 'status_code == 200' - 'contains(tolower(body), "<meta http-equiv=\"refresh\" content=\"0; url=http://")' condition: and# digest: 4a0a004730450221008ed60e60f3342274751ed977a185dabdf33677fb493ce8239fcc0d02594ea7510220515524b9f723e914abc402696c0444daf4cfb1030c792d7bc77c93d3ff606b73:922c64590222798bb761d5b6d8e72950Guide to check the vulnerabilities
Section titled “Guide to check the vulnerabilities”This template is used to detect vulnerabilities in web applications. It can be used with the Nuclei tool to scan for specific patterns or behaviors.
$ nuclei -u "URL" -t "http/misconfiguration/https-to-http-redirect.yaml"