#!/usr/bin/env python3
import os
import sys
from urllib.parse import parse_qs
test = parse_qs(os.environ.get('QUERY_STRING', ''), keep_blank_values=True).get('test', [''])[0]
sys.stdout.write(
'Content-Security-Policy: script-src \'self\'; report-uri save-report.py?test={}\r\n'
'Content-Type: text/html\r\n\r\n'.format(test)
)
print('''
'''.format(test))