![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
pediy
Wwoc
时间不会停
展开
-
pediy18-2
整数溢出 存储大于最大支持值的值称为整数溢出。整数溢出本身不会导致任意代码执行,但是整数溢出可能会导致堆溢出或者栈溢出,从而导致任意代码执行。 数据类型大小以及范围: 对于代码: //vuln.c #include <stdio.h> #include <string.h> #include <stdlib.h> void store_passw...原创 2019-03-20 21:48:51 · 347 阅读 · 0 评论 -
pediy18-6
绕过ASLR -- 第一部分 漏洞代码 #include <stdio.h> #include <string.h> /* Eventhough shell() function isnt invoked directly, its needed here since 'system@PLT' and 'exit@PLT' stub code should be p...原创 2019-03-24 23:38:10 · 151 阅读 · 0 评论 -
pediy18-7
绕过 ASLR -- 第二部分 漏洞代码 //vuln.c #include <stdio.h> #include <string.h> int main(int argc, char* argv[]) { char buf[256]; strcpy(buf,argv[1]); printf("%s\n",buf); fflush(stdout); ret...原创 2019-03-25 16:14:30 · 161 阅读 · 0 评论 -
pediy18-8
绕过 ASLR -- 第三部分 漏洞代码 // vuln.c #include <stdio.h> #include <string.h> #include <stdlib.h> int main (int argc, char **argv) { char buf[256]; int i; seteuid(getuid()); if(argc ...原创 2019-04-28 16:32:49 · 210 阅读 · 0 评论 -
pediy18-3
Off-By-One 漏洞(基于栈) 将源字符串复制到目标缓冲区可能会导致off-by-one 1.源字符串的长度等于缓冲区的长度。因为字符串的结尾会有一个\00。会溢出到目标缓冲区的上方。如果EBP恰好位于该缓冲区上方,则可导致任意代码执行。 漏洞源代码: //vuln.c #include <stdio.h> #include <string.h> void...原创 2019-03-22 11:14:41 · 216 阅读 · 0 评论 -
pediy18-4
使用 return-to-libc 绕过 NX 位 与之前做的基本rop基本相同,但是由于是课程作业,得做一下 漏洞程序代码 //vuln.c #include <stdio.h> #include <string.h> int main(int argc, char* argv[]) { char buf[256]; /* [1] */ strcpy(bu...原创 2019-03-23 16:20:52 · 212 阅读 · 0 评论 -
pediy18-5
使用链式 return-to-libc 绕过 NX 位 漏洞代码 //vuln.c #include <stdio.h> #include <string.h> int main(int argc, char* argv[]) { char buf[256]; seteuid(getuid()); /* Temporarily drop privileges *...原创 2019-03-24 16:08:40 · 282 阅读 · 1 评论 -
Pediy-18-10-House of Force
Pediy-18-10-houseof系列堆溢出 House of Force 源码: /* House of force vulnerable program. */ #include <stdio.h> #include <stdlib.h> #include <string.h> int main(int argc, char *argv[]) { ...原创 2019-04-23 20:02:31 · 308 阅读 · 0 评论