Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

29 lines (23 sloc) 0.855 kB
# -*- encoding: utf-8 -*-
# :authors: Arturo Filastò
# :licence: see LICENSE
from ooni.templates import http
class Example(http.HTTPTest):
inputs = ['', '',
def processResponseBody(self, body):
# XXX here shall go your logic
# for processing the body
if 'blocked' in body:['censored'] = True
else:['censored'] = False
def processResponseHeaders(self, headers):
# XXX place in here all the logic for handling the processing of HTTP
# Headers.
if headers.hasHeader('location'):['redirect'] = True
server = headers.getRawHeaders("Server")
if server:['http_server'] = str(server.pop())
Jump to Line
Something went wrong with that request. Please try again.