The HTTP HEAD method in general doesn't return the content of the body, unless it is a redirection page, so line `and len(response.text) > 500:` will never be true if second line of check `response = http_request(method="HEAD", url=url)` get a response. As result, devices seem no vulnerable when actually it is. Data: ``` HEAD /rom-0 HTTP/1.1 Host: 192.168.254.254 Connection: keep-alive Accept-Encoding: gzip, deflate Accept: */* User-Agent: python-requests/2.18.4 HTTP/1.1 200 OK Content-Type: application/octet-stream Date: Sat, 01 Jan 2000 00:18:54 GMT Last-Modified: Wed, 01 Jan 1930 00:18:54 GMT Content-Length: 16384 Server: RomPager/4.07 UPnP/1.0 EXT: ``` My suggestion is just to check whether content type doesn't return "text/html" as value, so it correct this issue and keep the previous false positive fixed. `and "html" not in response.headers['Content-Type']:` or `and response.headers['Content-Type'] == "application/octet-stream": That'is it.
| Name |
Last commit
|
Last update |
|---|---|---|
| .. | ||
| 2wire | Loading commit data... | |
| 3com | Loading commit data... | |
| asmax | Loading commit data... | |
| asus | Loading commit data... | |
| belkin | Loading commit data... | |
| bhu | Loading commit data... | |
| billion | Loading commit data... | |
| cisco | Loading commit data... | |
| comtrend | Loading commit data... | |
| dlink | Loading commit data... | |
| fortinet | Loading commit data... | |
| huawei | Loading commit data... | |
| ipfire | Loading commit data... | |
| juniper | Loading commit data... | |
| linksys | Loading commit data... | |
| movistar | Loading commit data... | |
| multi | Loading commit data... | |
| netcore | Loading commit data... | |
| netgear | Loading commit data... | |
| netsys | Loading commit data... | |
| shuttle | Loading commit data... | |
| technicolor | Loading commit data... | |
| thomson | Loading commit data... | |
| tplink | Loading commit data... | |
| ubiquiti | Loading commit data... | |
| zte | Loading commit data... | |
| zyxel | Loading commit data... | |
| __init__.py | Loading commit data... |