|
[求助]内核里面有哪些方法遍历指定进程模块
HANDLE GetModuleBaseAddressOfProcess(IN PEPROCESS pPe/*=NULL*/, IN PCWSTR lpModuleName/*=L"ntdll.dll"*/) { if(pPe ==NULL )return NULL ; HANDLE hModule = NULL; RTL_OSVERSIONINFOW os={0}; ULONG_PTR uPebPtr; ULONG_PTR uLdr=NULL ; ULONG uPebOffset=0; ULONG uLdrOffset=0xc; UNICODE_STRING usModuleName={0}; if(lpModuleName ) RtlInitUnicodeString (&usModuleName ,lpModuleName ); RtlGetVersion (&os); if(KeGetCurrentIrql() != PASSIVE_LEVEL) return NULL; if(os.dwMajorVersion==5) { switch(os.dwMinorVersion) { case 1://xp sp3 uPebOffset=0x1b0; break; case 2://2003 sp2 uPebOffset=0x1a0; break; } } else if(os.dwMajorVersion==6) { switch(os.dwMinorVersion) { case 0://2008 break; case 1: #ifdef _WIN64 //win7x64 sp1, 2008R2x64 sp1 uPebOffset=0x338; uLdrOffset=0x18; #else //win7x32 sp1 uPebOffset=0x1a8; #endif } } if(uPebOffset==0) { dprintf ("this function do not supported current os.\r\n"); return NULL ; } KeDetachProcess(); KeAttachProcess(pPe ); __try{ uPebPtr =(ULONG_PTR)((UCHAR *)pPe +uPebOffset); if((uLdr=*(ULONG_PTR*)uPebPtr)==NULL ) { return NULL; } uLdr +=uLdrOffset; PEB_LDR_DATA *pld=(PEB_LDR_DATA*)(*(ULONG_PTR*)uLdr); LIST_ENTRY *pList=pld->InLoadOrderModuleList.Flink; LIST_ENTRY *p=pList; do{ PLDR_MODULE pModule=(PLDR_MODULE)p; if(pModule->BaseAddress) { if(lpModuleName ) { if(RtlEqualUnicodeString(&usModuleName ,&pModule->BaseDllName,TRUE )) { hModule=pModule->BaseAddress; dprintf("\"%ws\" base address = %#x\r\n",pModule->BaseDllName.Buffer,hModule); break; } }else{ dprintf("BaseAddr = %#x\t ---> %ws\r\n", pModule->BaseAddress,pModule->BaseDllName.Buffer); } } p=p->Flink; }while(p!=pList); }__except (1){ dprintf ("This is an exception on GetModuleBaseAddressOfProcess()...\r\n"); } KeDetachProcess(); return hModule; } |
|
EasySYS_src_0.3.2.6.2修改版(支持生成64位驱动)
EasySYS_src_0.3.3.1 src |
|
|
|
[求助]TCP的IOCP服务端把消息广播到客户端有什么好的方法
switch( lp_io->operation ) { case IOCP_WRITE: { //cout<<"post a write data!---------------------------------------"<<endl; //if(OnIocpWritPtr(this,lp_io,lp_key))break; nRet = WSASend( lp_io->socket, &lp_io->wsaBuf, 1, &dwBytes, 0, &lp_io->ol,NULL); if( ( nRet == SOCKET_ERROR ) && ( WSAGetLastError() != WSA_IO_PENDING ) ) { cout<<"WSASend fail!------------------"<<WSAGetLastError()<<endl; closesocket( lp_io->socket ); m_io_group.RemoveAt( lp_io ); m_key_group.RemoveAt( lp_key ); return FALSE; } } break; |
|
[求助]TCP的IOCP服务端把消息广播到客户端有什么好的方法
case IOCP_COMPLETE_WRITE: { //cout<<"complete write a data!******************************"<<endl; if(!群发完毕) { 修改指针; lp_io->operation =IOCP_WRITE; }//按你所说,在这里不会占用太多时间?如果占用的时间太多,会不会错过后面的数据接收? else { InitIoContext( lp_io ); lp_io->operation = IOCP_READ; } } break; |
|
[公告]看雪论坛升级到vBulletin3.8.2
假如有得选择,还是选以前的版面 |
|
|
|
[求助]反汇编引擎的问题
Decode 有很多地方没处理好的,两年前弄过一下,发现要改的地方太多了,后来就没改了 |
|
[原创]软件保护壳技术专题 - 反汇编引擎的构建
原来也自己写过一个反汇编引擎,总是有很多问题考虑不到位,后来拿OD的那个来稍加修改,爽呆了,反汇编出来就和OD一样,指定地址反汇编再汇编,这样就可以重定位到其它地址了 |
|
|
操作理由
RANk
{{ user_info.golds == '' ? 0 : user_info.golds }}
雪币
{{ experience }}
课程经验
{{ score }}
学习收益
{{study_duration_fmt}}
学习时长
基本信息
荣誉称号:
{{ honorary_title }}
能力排名:
No.{{ rank_num }}
等 级:
LV{{ rank_lv-100 }}
活跃值:
在线值:
浏览人数:{{ visits }}
最近活跃:{{ last_active_time }}
注册时间:{{ user_info.create_date_jsonfmt }}
勋章
兑换勋章
证书
证书查询 >
能力值