course assignment program, add forensic tokens

This commit is contained in:
Neale Pickett 2012-01-30 17:08:41 -07:00
parent 13ae96c2e5
commit 6ec47e8513
2 changed files with 172 additions and 0 deletions

72
doc/2012-02-TF4/assignments.py Executable file
View File

@ -0,0 +1,72 @@
#! /usr/bin/python3
## Course assignments
import csv
import smtplib
msg = '''From: Neale Pickett <neale@lanl.gov>
To: %(recip)s
Subject: Tracer FIRE 4 course assignment: %(course)s
Hello! Your course assignment for Tracer FIRE 4 is:
%(course)s
Please see http://csr.lanl.gov/tf/tf4.html for information on
what you need to bring to the course.
Course questions should be directed to the appropriate instructor:
Network RE: Neale Pickett <neale@lanl.gov>
Malware RE: Danny Quist <dquist@lanl.gov>
Host Forensics: Kevin Nauer <ksnauer@sandia.gov>
Incident Coordination: Alex Kent <alex@lanl.gov>
General questions about Tracer FIRE may be sent to
Neale Pickett <neale@lanl.gov>
Looking forward to seeing you in Santa Fe next week,
--
Neale Pickett <neale@lanl.gov>
Advanced Computing Solutions, Los Alamos National Laboratory
'''
limits = {'Malware RE': 26,
'Network RE': 40}
assignments = {}
assigned = set(l.strip() for l in open('assigned.txt'))
c = csv.reader(open('/tmp/g.csv'))
c.__next__()
for row in c:
assert '@' in row[2]
t = row[5]
if (len(assignments.get(t, '')) == limits.get(t, 50)):
if (row[6] == row[5]):
print("Jackass detected: %s" % row[2])
t = row[6]
l = assignments.setdefault(t, [])
l.append(row)
s = smtplib.SMTP('mail.lanl.gov')
for t in ('Incident Coordinator', 'Network RE', 'Malware RE', 'Forensics'):
print('%s (%s)' % (t, len(assignments[t])))
for row in assignments[t]:
e = row[2]
if e in assigned:
print(' %s' % e)
else:
print(' * %s' % e)
ret = s.sendmail('neale@lanl.gov', [e], msg % {'course': t, 'recip': e})
if ret:
print(' ==> %s' % ret)
else:
assigned.add(e)
s.quit()
a = open('assigned.txt', 'w')
for e in assigned:
a.write('%s\n' % e)

View File

@ -398,3 +398,103 @@ re:97:xutim-munef-sevox
re:98:xenod-nomyf-ruvax
re:99:xepov-lotap-fozyx
re:100:xoras-mynaf-sosix
forensic:1:xicoz-gykyl-mazax
forensic:2:xuzod-nigec-lynyx
forensic:3:xiseb-mefyf-regyx
forensic:4:xusit-ruzur-nunyx
forensic:5:xolor-suveh-fygyx
forensic:6:xilil-nerub-tatex
forensic:7:xihom-nibaz-ronyx
forensic:8:xuzoh-gyfed-pehix
forensic:9:xuson-hutyr-zemyx
forensic:10:xucac-hemav-zizux
forensic:11:xifig-forur-kecix
forensic:12:xonoh-cobig-tyfax
forensic:13:xedof-pivad-notex
forensic:14:xolaf-kahek-vitox
forensic:15:xebak-livec-gugox
forensic:16:xidic-kahap-corox
forensic:17:xufaz-cakoh-bosyx
forensic:18:xetad-befon-sitax
forensic:19:xigit-zynid-busix
forensic:20:xopom-tafis-dubix
forensic:21:xelid-hosiv-nuhux
forensic:22:xulez-kyceh-sukex
forensic:23:xufak-hygur-vodex
forensic:24:xurok-sahon-mykix
forensic:25:xohin-cohic-hanyx
forensic:26:xunac-ditil-rykux
forensic:27:ximoh-sycik-fytux
forensic:28:xival-zovos-cazox
forensic:29:xogiz-sebyn-lifix
forensic:30:xicog-hivan-nabix
forensic:31:xuven-kyvam-hupyx
forensic:32:xedez-hekat-lemyx
forensic:33:xupam-zufim-hynix
forensic:34:xozib-mazed-cufax
forensic:35:xotob-vymem-befax
forensic:36:xokiv-labym-hozax
forensic:37:xipag-guvof-tonux
forensic:38:xurom-hyhim-vonux
forensic:39:xihop-pykek-camox
forensic:40:xebiv-zinut-hirox
forensic:41:xomig-sycyc-dysex
forensic:42:xifol-rudec-dygux
forensic:43:xohen-nukuc-silyx
forensic:44:xover-pydur-lyzax
forensic:45:xuhis-caloh-momex
forensic:46:xinez-kydan-mosix
forensic:47:xupat-vynyh-kemyx
forensic:48:xipir-nylik-bydox
forensic:49:xupov-facec-zymyx
forensic:50:xovid-dugiv-helux
forensic:51:xezim-pegez-tirox
forensic:52:xugac-kuzin-bibex
forensic:53:xebib-pevah-nigex
forensic:54:xihel-capuz-focex
forensic:55:xepib-gycyf-dylyx
forensic:56:xemif-dimaf-rukax
forensic:57:xukeb-likur-zozex
forensic:58:xosod-tigiz-tudux
forensic:59:xugop-mebem-synax
forensic:60:xozov-zopik-behox
forensic:61:xekof-sutat-lasix
forensic:62:xucaz-pekom-nimyx
forensic:63:xegim-moruv-synox
forensic:64:xesek-mihuv-tezux
forensic:65:xegon-kebad-kelyx
forensic:66:xedev-vivag-ladax
forensic:67:xilat-zumus-dutux
forensic:68:xefof-dasib-vacex
forensic:69:xukak-nifin-mypix
forensic:70:xudag-zizen-fityx
forensic:71:xoziz-ferim-selux
forensic:72:ximed-humok-serex
forensic:73:xetir-pycel-locyx
forensic:74:xinel-vecis-tipux
forensic:75:xusel-zovam-kutyx
forensic:76:xodac-cucal-hudex
forensic:77:xipoc-nanuz-pakyx
forensic:78:xomab-navah-kirox
forensic:79:xusog-gadem-tacex
forensic:80:xerel-cesov-ferox
forensic:81:xupis-sedur-zevix
forensic:82:xehed-fulog-fibix
forensic:83:xufez-celaf-ruhex
forensic:84:xepez-feryf-kovox
forensic:85:xugic-gepuc-dufox
forensic:86:xogeh-kuryl-comox
forensic:87:xitek-rikih-kopix
forensic:88:xefis-gepol-fafex
forensic:89:xodar-dirub-sabox
forensic:90:xolom-rubyf-darox
forensic:91:xuteg-pecys-dakux
forensic:92:xukig-basuk-duvyx
forensic:93:xivat-fohom-virox
forensic:94:xizog-decuc-fanox
forensic:95:xusoz-pikos-cyzyx
forensic:96:xiboc-kapys-tazox
forensic:97:xubor-kares-gikux
forensic:98:xovar-kalyl-kufex
forensic:99:xusap-fipon-nafax
forensic:100:xusot-hydob-leryx