您正在查看 "应用源码" 分类下的文章 2007-01-09 18:13 class CFI
{
public:
int FI(char *strFileName, char *strInfo);
public:
CFI();
~CFI();
private:
BYTE Buff_H[0x400]; // 头缓冲
BYTE Buff_E[0x400]; // 入口缓冲
FILE *fp;
int File_Length; // 文件长度
int File_Type; // 文件类型 1-com 2-exe 8-pe
DWORD |
2007-01-09 18:13 //[NE0]
{"WinZIP Self Extractor", "NORMAL", "33ED559AFFFF00000BC074EE81C1000172E8890E900389369203893E9403891E96038C06980389169A0333C0509AFFFF0000FF3694039AFFFF00000BC074BBFF369403FF369203FF369803FF369603FF"},
{"PKLite 2.01", "PACKER", "41300000FFFF0000FFFF0000000000000000000000000000FFFF00000000000000000000000000000000FF2F0000FF2F0000FF2F0000FF2F0000FF2F0000FF2F0000FF2F0000FF2FFFFF0000FFFF"},
{"Shrinker 3.2", |
2007-01-09 18:12 {"EPW 1.20 [EXE]", "PASSWORD", "06571E5655525153502E8C0608008CC00510002EA30A008ED8A108002E03060A002EA30C00A10E002E03060A002EA30600A110002EA30400A114002EA30000A116002E03060A002EA302000E1FBA3200"},
{"HackStop 1.00 [EXE]", "PROTECTOR", "B430CD2186E03D00037306B0FFB44CCD2150B8EB0458EBFB9AB80033CD2150E81F048DB200B80133CD2150B8EB0658EBFB663812E80A048DEB02CA925055528CD2FA50B8EB0458EBFB9A8CC88ED0EB02"},
{"Borland PE loader", |
2007-01-09 18:11 {"Turbo C 1.0 (1987)", "COMPILER", "BA00012E89167201B43000008B2E02008B1E2C008EDAA386008C068400891E8000892E9800C7068A00FFFF8EC333C0B9FF7F8BF88BD826813D3837751D575150B03DF2AEE311268A0524DFFF068A003C"},
{"Turbo C 2.0 (1988) [EXE]", "COMPILER", "BA00002E89160001B43000008B2E02008B1E2C008EDAA300008C060000891E0000892E0000C7060000FFFFE80000C43E00008BC78BD8B9FF7F26813D38377519268B550280FA3D751080E6DFFF060000"},
{"Microsoft |
2007-01-09 18:10 {"","E800000000","WIN32 PE packed / crypted -> δ?",1},
{"","60E8000000005D81EDF31D4000B97B0900008DBD3B1E40008BF7AC","yoda's cryptor 1.2",1},
{"","60E8000000005D81ED8A1C4000B99E0000008DBD4C2340008BF733","yoda's cryptor 1.1",1},
{"","60E8000000005D81EDE71A4000E8A1000000E8D1000000E885010000F785","yoda's cryptor 1.0",1},
{"","E8000000005D8BCD81ED7A29400089AD0F6D4000","X-PEOR 0. |
2007-01-09 18:10 static FILETYPEDATA_PE FileTypeRec_PE[] =
{
{"01020304050607090B0C","8B4424085683E8744875","Microsoft Visual C++ Private Version 2",0},
{"010203040508","8B4424088374","Microsoft Visual C++ Private Version 1",0},
{"0102030408090D","6A00FF1500A300","FASM 1.3x",0},
{"01020307080C","6A00E800A300","MASM32 / TASM32",0},
{"0102030405060708090E0F10111213","558BEC8 |
2007-01-09 18:08 /*******************************************************************************
* File info V 1.0 *
******************************************************************************** |
2006-10-08 14:36
// 程序功能:结束进程中的一个模块。
// 程序日期:2006.10.8 written by wangwei.
// 程序说明:这个程序写于2003年,主要针对一些木马注入程序。以往结束远程注入木马(dll)时需要
// 结束进程,这个程序不用结束进程而直接结束单个DLL。结束后会出现一些问题,某些情况
// 下会导致整个进程异常,这是很正常的,例如结束了一个进程需要调用的DLL;或者结束后DLL
// 又被主进程加载,例如mfc42.dll。
// 程序原理:根据DLL地址范围找到进程用的DLL线程,结束这个线程即DLL。
// 调试参数:explorer.exe secur32.dll
#include <windows.h>
#include <stdio.h>
#include <TlHelp32.h>
#pragma warning(disable:4996)
#define OS_SDK 0
#define BUFSIZE 80
typedef enum _THREAD_INFORMATION_CLASS {
ThreadBasicInformation, |
2006-07-31 13:58 /******************************************************************************* * C++函数名还原器 * ******************************************************************************** * * * Name : undname.cpp Origian Place : BJ of China * * Create Data : 31/07/2006 Now Version : 1.0 * * Modify Time : Editor : WangWei * *  |
2006-07-31 13:57 /****************************************************************** * get_modifier * Parses the type modifier. Always returns a static string */ static BOOL get_modifier(char ch, const char** ret) { switch (ch) { case 'A': *ret = NULL; break; case 'B': *ret = "const"; break; case 'C': *ret = "volatile"; break; case 'D': *ret = "const volatile"; break; default: return FALSE; } return TRUE; } static const char* get_modified_type(struct parsed_symbol* sym, char modif) { const char* modifier; const char* ret = NULL; const char* str_modif; |
2006-07-31 13:56 /****************************************************************** * handle_method * Does the final parsing and handling for a function or a method in * a class. */ static BOOL handle_method(struct parsed_symbol* sym, BOOL cast_op) { const char* access = NULL; const char* member_type = NULL; struct datatype_t ct_ret; const char* call_conv; const char* modifier = NULL; const char* exported; const char* |
2006-07-25 16:27 #include <stdio.h> #include <string.h> #include <stack>
char *Strrev(char *s) { char ch; char *p = s; char *q = s + strlen(s) - 1; while (p != q) { ch = *p; *p++ = *q; *q-- = ch; } return s; } char *Strrev_Recursion(char *s, char *p) { if (s != p) { char ch = *s; *s = *p; *p = ch; Strrev_Recursion(++s, --p); } return --s; } char *_Strev(char *s) { return Strrev_Recursion(s, s + strlen(s) - 1); } char *Strrev_WithoutRecursion(char *s) { using std::stack; stack<char> aStack;
char *p = s; while (*p != '\0') aStack.push(*p++); p = s; while (!aStack.empty())   |
2006-07-25 16:27 #include <stdio.h> #include <string.h>
typedef unsigned long DWORD; // 函数功能:16进制字符串转化为数字 // 函数返回:0不是16进制数,1是十六进制数 bool HexstrToHex(char *str, DWORD &dwVal) { int nLen; int i; int pow; DWORD s; char ch; char *p; nLen = strlen(str); p = str + nLen; if (nLen > 8 || nLen == 0) return false; s = 0; pow = 1; for(i = nLen; i > 0; i --) { ch = *(--p); if ((ch >= 'a') && (ch <= 'f')) ch = ch - 'a' + 10; else if ((ch >= 'A') && (ch <= 'F')) ch = ch - 'A' + 10; else if ((ch >= '0') && (ch <= '9')) & |
2006-07-25 16:26 // 程序功能:读CS段值 #include <stdio.h> #include <windows.h> void main() { typedef void(*GETCS)(); BYTE A[0x20] = {0x50,0x0e,0x58,0xa3,0x0,0x0,0x0,0x0,0x58,0xc3}; WORD wCS = 0; GETCS GetCS = (GETCS)&A; *(DWORD*)(A + 4) = (DWORD)&wCS; GetCS(); printf("%04x\n", wCS); } /* _asm // 取得当前字符 { push eax push cs pop eax mov wCS, ax pop eax }; */
|
2006-07-25 16:25 // 函数功能:递归遍历文件 12/12/2005 #pragma warning(disable:4996) #include <stdio.h> #include <string.h> #include <io.h> int nFileNum; // 函数功能:浏览文件 void scanfile(char* pPath, char* pName) { char strFileName[256]; nFileNum++; strcpy(strFileName, pPath); strcat(strFileName, pName); printf("%s\n", strFileName); } // 函数功能:浏览目录,递归 void scandir(char *strCurPath) { char strTemp[2048]; struct _finddata_t ffblk; int nReturn = 0; strcpy(strTemp, strCurPath); strcat(strTemp, "*.*"); long lHandle = long(_findfirst(strTemp, &ffblk)); while (lHandle != -1 && nReturn != -1) { if(strcmp(ffblk.name, ".") == 0 || strcmp(ffblk.name, "..") == 0) { nReturn = _findnext(lHa |
| | |