首页
社区
课程
招聘
请问OD 插件的API 有没有可以获取用户注释的接口函数?
发表于: 2013-6-22 15:37 6294

请问OD 插件的API 有没有可以获取用户注释的接口函数?

2013-6-22 15:37
6294
请问OD 插件的API 有没有可以获取用户注释的接口函数?

[课程]Android-CTF解题方法汇总!

收藏
免费 0
支持
分享
最新回复 (15)
雪    币: 1839
活跃值: (295)
能力值: ( LV9,RANK:370 )
在线值:
发帖
回帖
粉丝
2
PE文件格式的用户参考注释: 注释A,注释B。

注释A:
  PE头-->Nt头-->
  OptionalHeader.DataDirectory -->

  const DataDirectoryDescription:Array [0..15] of String=
        (
        '输出表{ Export Directory }',
        '输入表{ Import Directory }',
        '资源目录{ Resource Directory }',
        '异常处理表{ Exception Directory }',
        '安全信息{ Security Directory }',
        '重定位表{ Base Relocation Table }',
        '调试信息表{ Debug Directory } ',
        '描述字符串{ Description String }',                注释A:部分注释,在这个地址,搞个for循环全部读出来,就行了。

        '机器值{ Machine Value (MIPS GP) }',
        '线程局部存储(TLS)区{ TLS Directory }',
        '配置目录{ Load Configuration Directory }',
        '绑定输入表{ Bound Import Directory in headers }',
        '输入地址表{ Import Address Table }',
        '延迟装入信息',
        'COM描述',
        '保留'         ) ;

注释B:
  节表中,通常 rData段的字符串参考:

【字符串识别规则】
1,(Byte)Len+内容。
2,(Word)Len+内容。
3,(DWord)Len+内容。
4,内容。末尾0,截断,无Len指定。
2013-6-22 16:08
0
雪    币: 788
活跃值: (60)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
3
好的我试试哦
2013-6-22 16:11
0
雪    币: 788
活跃值: (60)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
4
[QUOTE=fosom;1191034]PE文件格式的用户参考注释: 注释A,注释B。

注释A:
  PE头-->Nt头-->
  OptionalHeader.DataDirectory -->

  const DataDirectoryDescription:Array [0..15] of String=
  ...[/QUOTE]

另外 被调试的PE 模块基址  怎么获取??????????
2013-6-22 16:17
0
雪    币: 1839
活跃值: (295)
能力值: ( LV9,RANK:370 )
在线值:
发帖
回帖
粉丝
5
给 kx啊,,还有 致谢。
2013-6-22 16:17
0
雪    币: 1839
活跃值: (295)
能力值: ( LV9,RANK:370 )
在线值:
发帖
回帖
粉丝
6
获取模块详细信息:

//枚举 模块列表
procedure CPETool.GetProcessModuleList(ListView : TListView );
var
  hSnapShot:Thandle;
  lphl :TModuleEntry32;
begin
  if ListView =nil then Raise(Exception.Create('未指定信息输出域(TListView)'));
  //初始化标题
  SetListViewAttrib(ListView);
  with ListView.Columns.Add do  begin  Caption :='hModule';       Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='modBaseAddr';   Width:=100;    end;     这里就是模块基地址。
  with ListView.Columns.Add do  begin  Caption :='modBaseSize';   Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='szModule';      Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='szExePath';     Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='th32ModuleID';  Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='dwSize';  Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='th32ProcessID';  Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='GlblcntUsage';  Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='ProccntUsage';  Width:=100;    end;
  
  hSnapShot:=CreateToolHelp32SnapShot(TH32CS_SNAPMODULE,Self.CurDbgProcessID );
  if hSnapShot=0 then exit;
  lphl.dwSize :=Sizeof(TModuleEntry32);
  if Module32First(hSnapShot,lphl) then
    repeat
      with ListView.Items.Add do
      begin
        Caption :=(IntToHex(lphl.hModule , 8));
        SubItems.Add(IntToHex(DWord (lphl.modBaseAddr) , 8));
        SubItems.Add(IntToHex(lphl.modBaseSize , 8));
        SubItems.Add(lphl.szModule );
        SubItems.Add(lphl.szExePath);
        SubItems.Add(IntToHex(lphl.th32ModuleID,8));
        SubItems.Add(IntToHex(lphl.dwSize , 8));
        SubItems.Add(IntToHex(lphl.th32ProcessID , 8));
        SubItems.Add(IntToHex(lphl.GlblcntUsage , 8));
        SubItems.Add(IntToHex(lphl.ProccntUsage , 8));

        Data :=@lphl;
      end;
    until not Module32Next(hSnapShot,lphl) ;
end;
2013-6-22 16:21
0
雪    币: 788
活跃值: (60)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
7
没问题的啊,你的方法性我会给你和致谢哦
2013-6-22 16:23
0
雪    币: 788
活跃值: (60)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
8
进程中所有模块的PE 中的Description String 都要进行遍历吗?
2013-6-22 16:24
0
雪    币: 1839
活跃值: (295)
能力值: ( LV9,RANK:370 )
在线值:
发帖
回帖
粉丝
9
晕~~,根据需求,过滤。

系统Dll模块当然可以过滤掉的。
2013-6-22 16:26
0
雪    币: 788
活跃值: (60)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
10
Self.CurDbgProcessID ??这个函数是你封装的?
2013-6-22 16:27
0
雪    币: 788
活跃值: (60)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
11
呵呵...是的,你说的很对哦
2013-6-22 16:28
0
雪    币: 1839
活跃值: (295)
能力值: ( LV9,RANK:370 )
在线值:
发帖
回帖
粉丝
12
我自己写的类OD调试工具,当然自己封装了。
2013-6-22 16:29
0
雪    币: 1839
活跃值: (295)
能力值: ( LV9,RANK:370 )
在线值:
发帖
回帖
粉丝
13
我自己写的类OD调试工具,当然自己封装了。
2013-6-22 16:30
0
雪    币: 788
活跃值: (60)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
14
呵呵那被调试进程的PID 如何获取?
2013-6-22 16:31
0
雪    币: 1839
活跃值: (295)
能力值: ( LV9,RANK:370 )
在线值:
发帖
回帖
粉丝
15
//枚举 模块列表
procedure CPETool.GetProcessModuleList(ListView : TListView );
var
  hSnapShot:Thandle;
  lphl :TModuleEntry32;
begin
  if ListView =nil then Raise(Exception.Create('未指定信息输出域(TListView)'));
  //初始化标题
  SetListViewAttrib(ListView);
  with ListView.Columns.Add do  begin  Caption :='hModule';       Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='modBaseAddr';   Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='modBaseSize';   Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='szModule';      Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='szExePath';     Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='th32ModuleID';  Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='dwSize';  Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='th32ProcessID';  Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='GlblcntUsage';  Width:=100;    end;
  with ListView.Columns.Add do  begin  Caption :='ProccntUsage';  Width:=100;    end;
  
  hSnapShot:=CreateToolHelp32SnapShot(TH32CS_SNAPMODULE,Self.CurDbgProcessID );
  if hSnapShot=0 then exit;
  lphl.dwSize :=Sizeof(TModuleEntry32);
  if Module32First(hSnapShot,lphl) then
    repeat
      with ListView.Items.Add do
      begin
        Caption :=(IntToHex(lphl.hModule , 8));
        SubItems.Add(IntToHex(DWord (lphl.modBaseAddr) , 8));
        SubItems.Add(IntToHex(lphl.modBaseSize , 8));
        SubItems.Add(lphl.szModule );
        SubItems.Add(lphl.szExePath);
        SubItems.Add(IntToHex(lphl.th32ModuleID,8));
        SubItems.Add(IntToHex(lphl.dwSize , 8));
        SubItems.Add(IntToHex(lphl.th32ProcessID , 8));
        SubItems.Add(IntToHex(lphl.GlblcntUsage , 8));
        SubItems.Add(IntToHex(lphl.ProccntUsage , 8));

        Data :=@lphl;
      end;
    until not Module32Next(hSnapShot,lphl) ;
end;
2013-6-22 16:40
0
雪    币: 1839
活跃值: (295)
能力值: ( LV9,RANK:370 )
在线值:
发帖
回帖
粉丝
16
上传的附件:
2013-6-22 16:54
0
游客
登录 | 注册 方可回帖
返回
//