Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

http-banner

Grab the HTTP banner and check response headers from a web server.

Usage

iottack http http-banner --host <HOST> [OPTIONS]

Description

Sends a GET request to the target and inspects the response for security issues, version disclosure, and missing hardening headers.

Checks performed

CheckFindingSeverity
Server: header with version numberVersion disclosureMedium
Server: header without versionSoftware identityInfo
X-Powered-By: header presentFramework/runtime disclosureMedium
Port 80 with no HTTPS redirectCleartext HTTPHigh
Port 80 redirecting to HTTPSHTTPS redirect in placeInfo
Missing Strict-Transport-Security (port 443)No HSTSMedium
Missing X-Frame-Options / CSP frame-ancestorsNo clickjacking protectionLow
Missing X-Content-Type-OptionsMIME sniffing not disabledLow
Missing Content-Security-PolicyNo CSPLow
HTTP 401 with Basic schemeCredentials over cleartextHigh
HTTP 401 with other schemeAuth requiredInfo
Default installation page in bodyServer not customisedMedium
Cookie missing Secure or HttpOnly flagInsecure cookieMedium

Options

FlagShortDefaultDescription
--host <HOST>-H(required)Target hostname or IP address
--port <PORT>-p80TCP port
--path <PATH>-u/Request path
--timeout-ms <MS>-t5000Connect and read timeout (ms)
--output <FILE>-o-Save result to a file
--format <FORMAT>-ftexttext or json
--verbose-v-Increase log verbosity

Examples

Check a device web interface:

$ iottack http http-banner --host 192.168.1.1
[...]
HTTP 200 OK
  Target: 192.168.1.1:80/

Server header: Apache/2.4.51 (Debian)
  Server header discloses software version. Consider suppressing or generalizing this header.

Cleartext HTTP on port 80
  Service responds to plain HTTP without redirecting to HTTPS.

Missing X-Frame-Options / CSP frame-ancestors
  No clickjacking protection header found.

Missing X-Content-Type-Options

Missing Content-Security-Policy

Check a non-standard port:

$ iottack http http-banner --host 192.168.1.1 --port 8080 --path /admin

Check HTTPS (port 443) for HSTS and security headers:

$ iottack http http-banner --host 192.168.1.1 --port 443