IT点滴

我不去想是否能够成功 既然选择了远方 便只顾风雨兼程
  博客园  :: 首页  :: 联系 :: 订阅 订阅  :: 管理

2018年11月9日

摘要: 有关security cookie在栈保护上的研究06.10 by flyingkisser这里主要讨论栈,不是堆。首先,security cookie并不是windows系统自带的保护机制,并不是说一个确实存在溢出漏洞的程序,放到带security cookie保护的环境中,就不能正常溢出了。那么 阅读全文

posted @ 2018-11-09 20:05 Ady Lee 阅读(348) 评论(0) 推荐(0) 编辑

摘要: 在 cookie 检查中,必定先要取出初始的 cookie 值: 这个 cookie 值是属于用户进程的,在这里是 helloworld.exe 映像 现在我们来看看这个 cookie 值被初始化什么,在哪里初始化? 0:000:x86> uf 0xb21221helleworld!wWinMain 阅读全文

posted @ 2018-11-09 20:05 Ady Lee 阅读(2049) 评论(0) 推荐(0) 编辑

摘要: 载入HelloWorld.exe之后我们看看加载了哪些模块: 查看一下堆栈: 都是ntdll中的函数,我们想要运行到HelloWorld.exe的main函数中停下。 这么办: 使用!dh命令。 帮助文档中给出!dh的解释如下: The !dh extension displays the head 阅读全文

posted @ 2018-11-09 17:24 Ady Lee 阅读(373) 评论(0) 推荐(0) 编辑

摘要: 这里先介绍两个指令: sx指令: The sx* commands control the action that the debugger takes when an exception occurs in the application that is being debugged, or wh 阅读全文

posted @ 2018-11-09 17:23 Ady Lee 阅读(779) 评论(0) 推荐(0) 编辑

摘要: Common Sections The .text section is where all general-purpose code emitted by the compiler or assembler ends up. Since PE files run in 32-bit mode an 阅读全文

posted @ 2018-11-09 17:18 Ady Lee 阅读(424) 评论(0) 推荐(0) 编辑

摘要: 恢复内容开始 The format of an operating system's executable file is in many ways a mirror of the operating system. Winnt.h是一个非常重要的头文件,其中定义了大部分windows下的内部结构。 阅读全文

posted @ 2018-11-09 17:17 Ady Lee 阅读(200) 评论(0) 推荐(0) 编辑

摘要: Initializer C++ Primer上说:如果未初始化的Built-in type是定义在function外部的,那么它将自动被初始化为“0”;如果uninitialized的built-in type对象是定义在function内部的,那么它就是undefined的,那么,对它拷贝和访问就 阅读全文

posted @ 2018-11-09 17:15 Ady Lee 阅读(213) 评论(0) 推荐(0) 编辑

摘要: 我这里学习汇编语言的思路就是逆向C++源码。 先从最简单的一个程序入手: 为什么程序的开头两句总会是 push ebp mov ebp,esp ? 先来看一个程序: 这个程序调用fun()时,fun的汇编代码也是如此,开头调用这两句汇编: 其实,这里ebp中保存的是你当前的函数(main函数)的栈基 阅读全文

posted @ 2018-11-09 17:14 Ady Lee 阅读(289) 评论(0) 推荐(0) 编辑

摘要: 先贴一段代码: 跟踪后看到: 无论是给bool类型赋值为正整数 还是true,都会转变为1。 那么float和double类型如何转换为bool类型? 将bool类型赋值给int类型变量,就是借助了寄存器eax,将1byte的值放入eax,再从eax取出dword宽度的值即可。但是问题来了,程序在刚 阅读全文

posted @ 2018-11-09 17:14 Ady Lee 阅读(181) 评论(0) 推荐(0) 编辑

摘要: Creates or opens a file or I/O device. The most commonly used I/O devices are as follows: file, file stream, directory, physical disk, volume, console 阅读全文

posted @ 2018-11-09 17:10 Ady Lee 阅读(461) 评论(0) 推荐(0) 编辑

摘要: Retrieves a module handle for the specified module. The module must have been loaded by the calling process. Parameters The name of the loaded module 阅读全文

posted @ 2018-11-09 14:46 Ady Lee 阅读(770) 评论(0) 推荐(0) 编辑

摘要: 什么是重定位: 重定位就是你本来这个程序理论上要占据这个地址,但是由于某种原因,这个地址现在不能让你占用,你必须转移到别的地址,这就需要基址重定位。你可能会问,不是说过每个进程都有自己独立的虚拟地址空间吗?既然都是自己的,怎么会被占据呢?对于EXE应用程序来说,是这样的。但是动态链接库就不一样了,我 阅读全文

posted @ 2018-11-09 14:44 Ady Lee 阅读(379) 评论(0) 推荐(0) 编辑

摘要: Reserves, commits, or changes the state of a region of pages in the virtual address space of the calling process. Memory allocated by this function is 阅读全文

posted @ 2018-11-09 14:43 Ady Lee 阅读(343) 评论(0) 推荐(0) 编辑

摘要: 转载请声明出处:http://www.cnblogs.com/predator-wang/p/5076681.html 5. 无DLL注入(远程代码注入) 在第三中方法种,我们启动远程线程时,线程函数是我们从Kernel32.dll中取得的LoadLibrary函数的地址为线程函数的地址,其实我们可 阅读全文

posted @ 2018-11-09 14:42 Ady Lee 阅读(467) 评论(0) 推荐(0) 编辑

摘要: 转载请声明出处:http://www.cnblogs.com/predator-wang/p/5076279.html 3. 利用远程线程注入DLL 1)、取得远程进程的进程ID; 2)、在远程进程空间中分配一段内存用来存放要注入的DLL完整路径; 3)、将要注入的DLL的路径写到刚才分配的远程进程 阅读全文

posted @ 2018-11-09 14:41 Ady Lee 阅读(785) 评论(0) 推荐(0) 编辑

摘要: 转载请声明出处:http://www.cnblogs.com/predator-wang/p/4792976.html 参考:http://andylin02.iteye.com/blog/459483 进程注入的方法分类如下: 带DLL的注入 利用注册表注入 利用Windows Hooks注入 利 阅读全文

posted @ 2018-11-09 14:40 Ady Lee 阅读(293) 评论(0) 推荐(0) 编辑

摘要: 数组名为何物? 32位系统中,指针大小是4字节,输出结果: 所以number不是指针。 但数组名又可以直接赋值给指针: 数组名不能自加自减: 数组名是一个指针常量。 (1)数组名的内涵在于其指代实体是一种数据结构,这种数据结构就是数组;(2)数组名的外延在于其可以转换为指向其指代实体的指针,而且是一 阅读全文

posted @ 2018-11-09 14:33 Ady Lee 阅读(205) 评论(0) 推荐(0) 编辑

摘要: 形参的初始化与变量的初始化一样:如果形参具有非引用类型,则复制实参的值,如果形参为引用类型,则它只是实参的别名。 非引用形参: 普通的非引用类型的参数通过复制对应的实参实现初始化。当用实参副本初始化形参时,函数并没有访问调用所传递的实参本身,因此不会修改实参的值。 while 循环体虽然修改了 v1 阅读全文

posted @ 2018-11-09 14:31 Ady Lee 阅读(337) 评论(0) 推荐(0) 编辑

摘要: 概述 API在某个头文件中定义,被封装在某个DLL中,而这个DLL会进一步被封装在ntdll.dll中(它里面的API叫native api),比如,ReadFile在ntdll.dll中就对应着ntReadFile;然后这个API会通过sysenter的方式进入内核层。 那么,比如对于Create 阅读全文

posted @ 2018-11-09 14:27 Ady Lee 阅读(242) 评论(0) 推荐(0) 编辑

摘要: LoadDriver 首先通过OpenSCManager打开服务会话管理器,然后利用CreateService创建驱动所对应的服务,这个函数很重要,它涉及到了驱动的安装。它会在注册表的对应位置创建一个服务名。它相当于InstDrv中的安装按钮: 服务会创建在注册表位置:HKEY_LOCAL_MACH 阅读全文

posted @ 2018-11-09 14:26 Ady Lee 阅读(400) 评论(0) 推荐(0) 编辑