TO BE CONTINUE 这两天做了hacklu2017,随便写写,有空再补了。其实比较倒霉,6点比赛结束,6点02算出了LostKey的flag……手速还是不行啊,得多练……
Pwn
bit
40072b:4 - > loop overwrite main ret instruction to long jump to start of main function input logic and reflip 40072b:4. Then write the shellcode to 0400741, and finally reflip 40072b:4 to get shellcode execute.
Rev
The Maya Society
13.0.0.0 on the home page is not a ip address, it’s 2012.12.21 in Maya calendar, just set the time to 2012.12.11 and run the program to get the flag.
if s.check() == z3.sat: m = s.model() print m flag = map(lambda sym: m[sym], y) flag = map(lambda val: chr(int(str(val))), flag) # wtf printlen(flag) print''.join(flag)
LostKey
4 processes created by clone, shared memory. When the program init, some rops will be filled in each process’s stack, and the rops are the thing that check your flag.
anti-debug will be used in perior 3 processes, and generate the key to decode the input in thread 4.
So just track the right rops to get the algorithm. And write some scripts to calculate the flag.
Web,Rev
Triangle
Use chrome to decode the ARM binary code, we got two function, encode and test. Write a script to solve the problem.
x = [z3.BitVec(i, 8) for i inrange(32)] y = [0] * 32 s = z3.Solver()
a = "XYzaSAAX_PBssisodjsal_sSUVWZYYYb" b = map(ord, a)
flag = 0 for i inrange(32): ch = x[i] ch = z3.If(flag == 1, ch + (i & 3), ch) temp = ch + 6 flag = temp & 1 y[i] = temp
for i inrange(32): ch = y[i] + 5 if i & 1: ch = y[i] + 2 s.add(ch == b[i])
if s.check() == z3.sat: m = s.model() print m flag = map(lambda sym: m[sym], x) flag = map(lambda val: chr(int(str(val))), flag) # wtf print''.join(flag)
Misc, Web
DnSoSecure
source audit, download the source.zip git log and checkout last branch
get private and public key for setting up DNSSEC server.