From 27ec65c7d910133edc3bc59ca1bc0dad30bfa23d Mon Sep 17 00:00:00 2001 From: Neale Pickett Date: Fri, 29 Oct 2010 00:07:03 -0600 Subject: [PATCH] Fix some last-minute bugs --- doc/problems.txt | 7 ++----- packages/mcp/service/eth0/run | 2 +- packages/mcp/service/pointsd/run | 4 ++++ packages/mcp/www/index.html | 2 +- packages/net-re/3/index.mdwn | 16 +++++++++++----- packages/pwnables/service/eth0.pwn/run | 2 +- packages/tanks/service/tanksd/tanksd | 2 +- 7 files changed, 21 insertions(+), 14 deletions(-) diff --git a/doc/problems.txt b/doc/problems.txt index c43ed39..efdc484 100644 --- a/doc/problems.txt +++ b/doc/problems.txt @@ -1,8 +1,5 @@ * claim.cgi not exiting (maybe fixed?) -* mcp/index.html: provide example token * tanks/designer.cgi: s/token/team hash/ -* net-re/3: give example of what the answer would look like -* eth0/run: wrong netmask, no router -* eth0.pwn/run: wrong netmask, no router -* tanks: player directories not getting populated +* teams.txt: Come up with a better solution to creating this at boot + diff --git a/packages/mcp/service/eth0/run b/packages/mcp/service/eth0/run index cd90d39..d114ae7 100755 --- a/packages/mcp/service/eth0/run +++ b/packages/mcp/service/eth0/run @@ -2,6 +2,6 @@ hostname mcp -ifconfig eth0 10.0.0.2 netmask 255.0.0.0 +ifconfig eth0 10.0.0.2 netmask 255.255.0.0 exec inotifyd true $(pwd):x diff --git a/packages/mcp/service/pointsd/run b/packages/mcp/service/pointsd/run index 57d4f90..a7d63bd 100755 --- a/packages/mcp/service/pointsd/run +++ b/packages/mcp/service/pointsd/run @@ -6,4 +6,8 @@ install -o ctf -m 0755 -d /var/lib/ctf/points.new install -o ctf -m 0755 -d /var/lib/ctf/points.tmp touch /var/lib/ctf/points.log +# Re-populate teams list for tanks +ls $base/teams/names | KEY="Too much cheese." /opt/mcp/bin/arc4 > $www/teams.txt.$$ +mv $www/teams.txt.$$ $www/teams.txt + exec ./pointsd diff --git a/packages/mcp/www/index.html b/packages/mcp/www/index.html index 5c2f69d..fdb8d02 100644 --- a/packages/mcp/www/index.html +++ b/packages/mcp/www/index.html @@ -28,7 +28,7 @@
team hash: - token: + token:
diff --git a/packages/net-re/3/index.mdwn b/packages/net-re/3/index.mdwn index f2cefdb..d12e396 100644 --- a/packages/net-re/3/index.mdwn +++ b/packages/net-re/3/index.mdwn @@ -83,6 +83,9 @@ proxy, it will be a full URL. `VERSION` is the version of HTTP in use. It always begins with `HTTP/` and ends with major and minor version numbers, separated by a period. +Many protocols are "HTTP-like", and provide a version beginning with +something other than `HTTP/'. Although they may look like HTTP, they +are not truly HTTP connections. `METHOD` is typically either `GET`, `HEAD`, or `POST`, but may also be `OPTIONS`, `PUT`, `DELETE`, `TRACE`, `CONNECT`, or any number of @@ -107,11 +110,14 @@ Sometimes as an analyst, you only get the first few dozen bytes of a conversation, and you may not even get an indication of whether the client or server spoke first. -What follows is a list of the first line of text sent in various -different connections. The key for this page is the list of protocols -not described on this page, ordered from lowest (1) to highest (F). In -other words, list everything that isn't the first line of an FTP, SMTP, -or HTTP connection. +You have been given the first line sent in 16 different connections and +asked to determine which warrant further investigation. You need to +rule out things that are clearly not the first line of HTTP, SMTP, or +FTP. + +The answer for this page is the list of protocols *not described on this +page*, ordered from lowest (1) to highest (F). The answer should be of +the form "1,2,3,7,8,A,B,C". 1: GET / HTTP/1.1 2: +OK example.com server ready diff --git a/packages/pwnables/service/eth0.pwn/run b/packages/pwnables/service/eth0.pwn/run index c5aeb14..7a85627 100755 --- a/packages/pwnables/service/eth0.pwn/run +++ b/packages/pwnables/service/eth0.pwn/run @@ -6,5 +6,5 @@ if [ -d /opt/mcp ]; then fi hostname pwnables -ifconfig eth0 10.0.0.10 netmask 255.0.0.0 +ifconfig eth0 10.0.0.10 netmask 255.255.0.0 exec inotifyd true $(pwd):x diff --git a/packages/tanks/service/tanksd/tanksd b/packages/tanks/service/tanksd/tanksd index 6dbb29f..6c28dec 100755 --- a/packages/tanks/service/tanksd/tanksd +++ b/packages/tanks/service/tanksd/tanksd @@ -42,7 +42,7 @@ EOF while true; do # Make sure all teams exist # XXX: pull this out into another daemon - wget -q -O - http://10.0.0.2/teams.txt | \ + wget -q -O - http://10.0.0.2/teams.html | \ KEY="Too much cheese." /opt/tokens/bin/arc4 | \ while read hash; do install -o ctf -d $p/$hash