Socket Reusing Shellcode 技术解析
1. 端口绑定 shellcode 的局限性与 Socket 重用 shellcode 的优势
在处理一些远程漏洞时,端口绑定 shellcode 虽然很有用,但通常代码量较大且效率不高。特别是在利用需要建立连接的远程漏洞时,这种局限性更为明显。而 Socket 重用 shellcode 可以重复使用已建立的连接,这不仅节省了大量代码,还提高了漏洞利用成功的几率。
1.1 连接重用的概念
当我们与易受攻击的程序建立连接时,程序会使用 accept 函数来处理该连接。 accept 函数会返回一个文件描述符,用于与该 Socket 进行通信。例如,在下面的系统调用跟踪示例中:
1 603 remote_format_strin CALL socket(0x2,0x1,0x6)
2 603 remote_format_strin RET socket 3
3 603 remote_format_strin CALL bind(0x3,0xbfbffb1c,0x10)
4 603 remote_format_strin RET bind 0
5 603 remote_format_strin CALL listen(0x3,0x1)
6 603 remote_format_strin RET listen 0
7 603 remote_format_strin CALL accept(0x3,0,0)
8 603 remote_format_
超级会员免费看
订阅专栏 解锁全文
990

被折叠的 条评论
为什么被折叠?



