pwnlib.util.web
— Utilities for working with the WWW¶
-
pwnlib.util.web.
wget
(url, save=None, timeout=5) → str[source]¶ Downloads a file via HTTP/HTTPS.
Parameters: Example
>>> url = 'https://httpbin.org/robots.txt' >>> result = wget(url, timeout=60) >>> result 'User-agent: *\nDisallow: /deny\n' >>> result2 = wget(url, True, timeout=60) >>> result == file('robots.txt').read() True