IT点滴

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

11 2018 档案

摘要:先开启真机内核态kernel调试 !process 0 0 svchost.exe 找到进程cid的地址 然后进入 .process /p fffffa8032be2870 然后 .process /i; g 再次中断后继续 一定要重新加载用户态调试符号 .reload /f /user 或者 .p 阅读全文

posted @ 2018-11-13 16:31 Ady Lee 阅读(1364) 评论(0) 推荐(0)

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

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

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

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

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

posted @ 2018-11-09 17:24 Ady Lee 阅读(416) 评论(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 阅读(790) 评论(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 阅读(464) 评论(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 阅读(214) 评论(0) 推荐(0)

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

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

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

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

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

posted @ 2018-11-09 17:14 Ady Lee 阅读(192) 评论(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 阅读(519) 评论(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 阅读(800) 评论(0) 推荐(0)

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

posted @ 2018-11-09 14:44 Ady Lee 阅读(402) 评论(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 阅读(365) 评论(0) 推荐(0)

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

posted @ 2018-11-09 14:42 Ady Lee 阅读(473) 评论(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 阅读(794) 评论(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 阅读(304) 评论(0) 推荐(0)

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

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

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

posted @ 2018-11-09 14:31 Ady Lee 阅读(359) 评论(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 阅读(257) 评论(0) 推荐(0)

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

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

摘要:无意中看到一篇文章《关于基类和子类构造函数的问题》,来自:http://blog.sina.com.cn/s/blog_64d57e710100n24f.html 这时会报错: 但是运行: 仍然会输出结果: 这显然是说明虽然为a开辟了空间、构建了成员函数,但是a的数据没有初始化,a的数据是读取的随机 阅读全文

posted @ 2018-11-09 14:23 Ady Lee 阅读(1227) 评论(0) 推荐(0)

摘要: 阅读全文

posted @ 2018-11-09 14:12 Ady Lee 阅读(123) 评论(0) 推荐(0)

摘要:本文借助windbg来理解程序中的函数如何使用handle对句柄表进行查询的。所以先要开启Win7下Windbg的内和调试功能。 解决win7下内核调试的问题 win7下debug默认无法进行内核调试(!process等命令无法使用),除非是双机调试。或改用livekd进行调试。 尝试http:// 阅读全文

posted @ 2018-11-09 14:03 Ady Lee 阅读(442) 评论(0) 推荐(0)

摘要:请问如何将偏移量转换为地址? 我在使用软件定位木马特征码的时候,只得到偏移量,为什么有的人用OD转到偏移量,但我用OD的时候,显示没有这个偏移量的,请问如何将偏移量转换为地址? 在DFCG回答过,再转过来吧。+ + + + + + +| 段名称 虚拟地址 虚拟大小 物理地址 物理大小 标志 |+ + 阅读全文

posted @ 2018-11-08 21:04 Ady Lee 阅读(1544) 评论(0) 推荐(0)

摘要:DLL注入 1.首先要获取想要注入的进程句柄(OpenProcess) 2.从要注入的进程的地址空间中分配一段内存(VirtualAllocEx) 3.往分配的内存位置写入要注入的DLL名称(WriteProcessMemory) 4.从kernel32.dll中找到LoadLibrary(A或W) 阅读全文

posted @ 2018-11-07 22:19 Ady Lee 阅读(589) 评论(0) 推荐(0)