#!/usr/bin/python import cgi import cgitb; cgitb.enable() import sys import os from urllib import quote from ctf import teams, html, paths basedir = os.path.join(paths.VAR, 'tanks') links = '''
Your latest errors:
') errors = open(path).readlines() if errors: body.append('There were no errors.
') else: body.append('No error file found.
') else: body.append('Authentication failed.') body.append(''' ''') html.serve('Tanks Errors', '\n'.join(body), links=links)