ooni.nettests scanning Package

ooni.nettests.scanning.http_url_list Module

class ooni.nettests.scanning.http_url_list.HTTPURLList[source]

Bases: ooni.templates.httpt.HTTPTest

Performs GET, POST and PUT requests to a list of URLs specified as input and checks if the page that we get back as a result matches that of a block page given as input.

If no block page is given as input to the test it will simply collect the responses to the HTTP requests and write them to a report file.

author = 'Arturo Filast\xc3\xb2'
check_for_content_censorship(body)[source]

If we have specified what a censorship page looks like here we will check if the page we are looking at matches it.

XXX this is not tested, though it is basically what was used to detect censorship in the palestine case.

inputFile = ['file', 'f', None, 'List of URLS to perform GET and POST requests to']
name = 'HTTP URL List'
processResponseBody(body)[source]
requiresRoot = False
requiresTor = False
setUp()[source]

Check for inputs.

test_get()[source]
test_post()[source]
test_put()[source]
usageOptions

alias of UsageOptions

version = '0.1.3'
class ooni.nettests.scanning.http_url_list.UsageOptions[source]

Bases: twisted.python.usage.Options

optParameters = [['content', 'c', None, 'The file to read from containing the content of a block page'], ['url', 'u', None, 'Specify a single URL to test.']]