c# - Getting handles data with MiniDump (DbgHelp.h) -


i struggling getting handles information via minidump (dbghelp.h).

i getting list of minidump_handle_descriptor_2 mapped file stream.. getting each descriptor minidump_handle_object_information using objectinforva field.

however cannot understand information minidump_handle_object_information structure gives me, couldn't find examples on web extracting meaningful information minidump_handle_object_information, , documentation not helpful.

how can use minidump_handle_object_information structure data a human readable data? mean need it? 0 @ infotype filed means - minihandleobjectinformationnone.

minidump_handle_object_information struct:

public struct minidump_handle_object_information {     public uint nextinforva;     public minidump_handle_object_information_type infotype;     public uint32 sizeofinfo; } 

i've done experiment minidump_handle_object_information struct

when getting struct, capable of reading string rva address sizeofinfo size. here allays getting 'directory' string on handles descriptors got...

link doc:

https://msdn.microsoft.com/en-us/library/windows/desktop/ms680375(v=vs.85).aspx

any appreciated :)

my process, on trying apply it, uses waitformultipleobjects , waitforsingleobject kernel32 calls.

link implementation:

https://github.com/pavel-durov/multithreading-debugging-asignments/blob/master/assignments/assignments.core/handlers/minidumphandler.cs

link windbg !handle command output execute on same dump file: https://docs.google.com/document/d/1hjid-2dcm0azrg5a1p5vrcbsysu_vqhynxdbavxv29q/edit?usp=sharing

maybe issue don't set valid values minidump_handle_object_information_type enumeration, familiar reliable source enum values declaration? didn't found official.

just make clear.

in windbj, same information minidump_handle_descriptor_2, instance if windbg !handle command has output:

handle 00000004   type                   directory handle 00000008   type                   directory handle 0000000c   type                   event handle 00000010   type                   event handle 00000014   type                   file … 

i can getthe same data minidump_handle_descriptor_2 objectname , typename of minidump_string type.

the information cannot 1 located in minidump_handle_object_information struct. not visible on !hanlde command output.

what kind of information suppose located in minidump_handle_object_information ?

after couple of rough hours - debugging managed code , comparing c++ code examples - found bug minidump_handle_object_information struct reading – didn’t calculated rva + baseminidump address appropriately.

now works, able of getting additional information handles :)

mu code can found here: https://github.com/pavel-durov/multithreading-debugging-asignments/blob/master/assignments/assignments.core/handlers/minidumphandler.cs

line 144, dealwithhandleinfo function


Comments

Popular posts from this blog

sublimetext3 - what keyboard shortcut is to comment/uncomment for this script tag in sublime -

java - No use of nillable="0" in SOAP Webservice -

ubuntu - Laravel 5.2 quickstart guide gives Not Found Error -