Skip to content

Instantly share code, notes, and snippets.

@193s

193s/- Secret

Created February 29, 2016 10:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save 193s/68b0cd8708c70c6c8b7d to your computer and use it in GitHub Desktop.
Save 193s/68b0cd8708c70c6c8b7d to your computer and use it in GitHub Desktop.
#!/usr/bin/env python
comments = open('./comments').read()
f = open('./path').read().splitlines()
from zipfile import ZipFile
z = ZipFile(open('./gomi/pwd.zip'))
names = z.namelist()
flag = ''
for line in f:
flag += comments[names.index(line + '.txt')]
print repr(flag)
open('white', 'w').write(flag)
open('w2', 'w').write(flag.replace('\n', '').replace(' ', '0').replace('\t', '1'))
b = open('./w2').read()
t = ''
for i in xrange(0, len(b), 8):
t += chr(int(b[i:i+8], 2))
print t
#print flag
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment