mirror of
https://github.com/x64dbg/x64dbg.git
synced 2025-02-20 13:02:35 +00:00
DBG: fixed a few plugin callback bugs
PROJECT: updated help
This commit is contained in:
parent
b7b4fb2969
commit
a8488322da
@ -1,7 +1,7 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<title>Callbacks</title>
|
||||
<title>Callback Structures</title>
|
||||
<meta name="GENERATOR" content="WinCHM">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<style>
|
||||
@ -15,68 +15,105 @@ html,body {
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<P><STRONG>Callbacks<BR></STRONG> These structures are used inside event
|
||||
<P><STRONG>Callback structures<BR></STRONG>These structures are used inside event
|
||||
callbacks (registered using _plugin_registercallback). Notice that the pointer
|
||||
'void* callbackInfo' is never NULL, but the
|
||||
members of the various structures can be NULL.</P>
|
||||
<P>struct
|
||||
<STRONG>PLUG_CB_INITDEBUG</STRONG><BR>{<BR> <STRONG>const char*</STRONG>
|
||||
'void* callbackInfo' is never NULL, but the members of the various structures
|
||||
can be NULL. Also remember that <U>you cannot use any of the provided pointers
|
||||
out of the callback function scope</U>. In general
|
||||
<U>
|
||||
<STRONG>AVOID</STRONG> time-consuming operations inside
|
||||
callbacks</U> , do these in
|
||||
separate
|
||||
|
||||
|
||||
|
||||
|
||||
threads.</P>
|
||||
<P>//Called on debug initialization, useful to initialize
|
||||
some variables.<BR>struct <STRONG>PLUG_CB_INITDEBUG</STRONG>
|
||||
<BR>{<BR> <STRONG>const char*</STRONG>
|
||||
szFileName;<BR>};</P>
|
||||
<P>struct
|
||||
<STRONG>PLUG_CB_STOPDEBUG<BR></STRONG>{<BR>
|
||||
<P>//Called when the debugging has been stopped, useful to
|
||||
reset some variables.<BR>struct <STRONG>PLUG_CB_STOPDEBUG</STRONG>
|
||||
<BR>{<BR>
|
||||
<STRONG>void*</STRONG>
|
||||
reserved;<BR>};</P>
|
||||
<P>struct
|
||||
<STRONG>PLUG_CB_CREATEPROCESS<BR></STRONG>{<BR>
|
||||
<P>//Called after process creation (in the debug loop),
|
||||
after the initialization of the symbol handler, the database file and setting
|
||||
breakpoints on TLS callbacks / the entry breakpoint.<BR>struct <STRONG>PLUG_CB_CREATEPROCESS <BR></STRONG>{<BR>
|
||||
<STRONG>CREATE_PROCESS_DEBUG_INFO*</STRONG>
|
||||
CreateProcessInfo;<BR> <STRONG>IMAGEHLP_MODULE64*</STRONG>
|
||||
modInfo;<BR> <STRONG>const char*</STRONG>
|
||||
DebugFileName;<BR>
|
||||
<STRONG>PROCESS_INFORMATION*</STRONG>
|
||||
fdProcessInfo;<BR>};</P>
|
||||
<P>struct
|
||||
<STRONG>PLUG_CB_EXITPROCESS</STRONG><BR>{<BR>
|
||||
<P>//Called after the process exits (in the debug loop),
|
||||
before the symbol handler is cleaned up.<BR>struct <STRONG>PLUG_CB_EXITPROCESS</STRONG> <BR>{<BR>
|
||||
<STRONG>EXIT_PROCESS_DEBUG_INFO*</STRONG>
|
||||
ExitProcess;<BR>};</P>
|
||||
<P>struct
|
||||
<STRONG>PLUG_CB_CREATETHREAD<BR></STRONG>{<BR>
|
||||
<P>//Called after thread creation (in the debug loop),
|
||||
after adding the thread to the internal thread list, before breaking the
|
||||
debugger on thread creation and after setting breakpoints on the thread
|
||||
entry.<BR>struct <STRONG>PLUG_CB_CREATETHREAD<BR></STRONG>{<BR>
|
||||
<STRONG>CREATE_THREAD_DEBUG_INFO*</STRONG>
|
||||
CreateThread;<BR> <STRONG>DWORD</STRONG>
|
||||
dwThreadId;<BR>};</P>
|
||||
<P>struct <STRONG> PLUG_CB_EXITTHREAD<BR></STRONG>{<BR> <STRONG>EXIT_THREAD_DEBUG_INFO*</STRONG>
|
||||
<P>//Called after thread termination (in the debug loop),
|
||||
before the thread is removed from the internal thread list, before breaking on
|
||||
thread termination.<BR>struct <STRONG>PLUG_CB_EXITTHREAD</STRONG> <BR>{<BR> <STRONG>EXIT_THREAD_DEBUG_INFO*</STRONG>
|
||||
ExitThread;<BR> <STRONG>DWORD</STRONG>
|
||||
dwThreadId;<BR>};</P>
|
||||
<P>struct <STRONG>
|
||||
PLUG_CB_SYSTEMBREAKPOINT<BR></STRONG>{<BR>
|
||||
<P>//Called at the system breakpoint (in the debug loop),
|
||||
after setting the initial dump location, before breaking the debugger on the
|
||||
system breakpoint.<BR>struct <STRONG>PLUG_CB_SYSTEMBREAKPOINT</STRONG>
|
||||
<BR>{<BR>
|
||||
<STRONG>void*</STRONG> reserved;<BR>};</P>
|
||||
<P>struct <STRONG> PLUG_CB_LOADDLL<BR></STRONG>{<BR>
|
||||
<P>//Called on DLL loading (in the debug loop), after the
|
||||
DLL has been added to the internal library list, after setting the DLL entry
|
||||
breakpoint.<BR>struct <STRONG>PLUG_CB_LOADDLL</STRONG> <BR>{<BR>
|
||||
<STRONG>LOAD_DLL_DEBUG_INFO*</STRONG>
|
||||
LoadDll;<BR> <STRONG>IMAGEHLP_MODULE64*</STRONG>
|
||||
modInfo;<BR> <STRONG>const char*</STRONG> modname;<BR>};</P>
|
||||
<P>struct <STRONG> PLUG_CB_UNLOADDLL<BR></STRONG>{<BR>
|
||||
<P>//Called on DLL unloading (in the debug loop), before
|
||||
removing the DLL from the internal library list, before breaking on DLL
|
||||
unloading.<BR>struct <STRONG>PLUG_CB_UNLOADDLL</STRONG> <BR>{<BR>
|
||||
<STRONG>UNLOAD_DLL_DEBUG_INFO*</STRONG>
|
||||
UnloadDll;<BR>};</P>
|
||||
<P>struct <STRONG>
|
||||
PLUG_CB_OUTPUTDEBUGSTRING<BR></STRONG>{<BR>
|
||||
<P>//Called on a DebugString event (in the debug loop),
|
||||
before dumping the string to the log, before breaking on a debug
|
||||
string.<BR>struct <STRONG>PLUG_CB_OUTPUTDEBUGSTRING</STRONG>
|
||||
<BR>{<BR>
|
||||
<STRONG>OUTPUT_DEBUG_STRING_INFO*</STRONG>
|
||||
DebugString;<BR>};</P>
|
||||
<P>struct <STRONG> PLUG_CB_EXCEPTION<BR></STRONG>{<BR>
|
||||
<P>//Called on an unhandled (by the debugger) exception (in
|
||||
the debug loop), after setting the continue status, after locking the debugger
|
||||
to pause.<BR>struct <STRONG>PLUG_CB_EXCEPTION</STRONG> <BR>{<BR>
|
||||
<STRONG>EXCEPTION_DEBUG_INFO*</STRONG>
|
||||
Exception;<BR>};</P>
|
||||
<P>struct <STRONG> PLUG_CB_BREAKPOINT<BR></STRONG>{<BR> <STRONG>BRIDGEBP*</STRONG>
|
||||
<P>//Called on a normal/memory/hardware breakpoint (in the
|
||||
debug loop), after locking the debugger to pause.<BR>struct <STRONG>PLUG_CB_BREAKPOINT</STRONG> <BR>{<BR> <STRONG>BRIDGEBP*</STRONG>
|
||||
breakpoint;<BR>};</P>
|
||||
<P>struct <STRONG> PLUG_CB_PAUSEDEBUG<BR></STRONG>{<BR>
|
||||
<P>//Called after the debugger has been locked to pause (in
|
||||
the debug loop), before any other callback that's before pausing the
|
||||
debugger.<BR>struct <STRONG>PLUG_CB_PAUSEDEBUG</STRONG> <BR>{<BR>
|
||||
<STRONG>void*</STRONG>
|
||||
reserved;<BR>};</P>
|
||||
<P>struct <STRONG> PLUG_CB_RESUMEDEBUG<BR></STRONG>{<BR>
|
||||
<P>//Called after the debugger has been unlocked to resume
|
||||
(outside of the debug loop).<BR>struct <STRONG>PLUG_CB_RESUMEDEBUG</STRONG> <BR>{<BR>
|
||||
<STRONG>void*</STRONG>
|
||||
reserved;<BR>};</P>
|
||||
<P>struct <STRONG> PLUG_CB_STEPPED<BR></STRONG>{<BR>
|
||||
<P>//Called after the debugger stepped (in the debug loop),
|
||||
after locking the debugger to pause.<BR>struct <STRONG>PLUG_CB_STEPPED</STRONG> <BR>{<BR>
|
||||
<STRONG>void*</STRONG>
|
||||
reserved;<BR>};</P>
|
||||
<P>struct
|
||||
<STRONG>PLUG_CB_ATTACH<BR></STRONG>{<BR>
|
||||
<P>//Called before attaching to a process.<BR>struct <STRONG>PLUG_CB_ATTACH</STRONG><BR>{<BR>
|
||||
<STRONG>DWORD</STRONG> dwProcessId;<BR>};</P>
|
||||
<P>struct
|
||||
<STRONG>PLUG_CB_DETACH<BR></STRONG>{<BR>
|
||||
<STRONG>PROCESS_INFORMATION*</STRONG> fdProcessInfo;<BR>};</P></BODY></HTML>
|
||||
<P>//Called before detaching from the process.<BR>struct <STRONG>PLUG_CB_DETACH</STRONG><BR>{<BR>
|
||||
<STRONG>PROCESS_INFORMATION*</STRONG> fdProcessInfo;<BR>};</P>
|
||||
<P>//Called on any debug event, even the ones that are
|
||||
handled internally, <U><STRONG>AVOID</STRONG> doing stuff that takes time
|
||||
here</U>, this will slow the debugger down a lot!<BR>struct <STRONG>PLUG_CB_DEBUGEVENT</STRONG> <BR>{<BR>
|
||||
<STRONG>DEBUG_EVENT*</STRONG> DebugEvent;<BR>};</P>
|
||||
<P>//Called when a menu entry created by the plugin has
|
||||
been clicked, the GUI will resume when this callback returns.<BR>struct <STRONG>PLUG_CB_MENUENTRY</STRONG><BR>{<BR>
|
||||
<STRONG>int</STRONG> hEntry;<BR>};</P></body></HTML>
|
@ -1,7 +1,7 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<title>pluginit</title>
|
||||
<title>PLUG_INITSTRUCT</title>
|
||||
<meta name="GENERATOR" content="WinCHM">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<style>
|
||||
@ -20,14 +20,14 @@ export in the plugin
|
||||
interface:</P>
|
||||
<P>struct
|
||||
<STRONG>PLUG_INITSTRUCT<BR></STRONG>{<BR> <EM>//data provided
|
||||
by the debugger to the plugin</EM><BR> [IN]
|
||||
by the debugger to the plugin.</EM><BR> [IN]
|
||||
<STRONG>int</STRONG> pluginHandle; //handle of the plugin<BR>
|
||||
<BR> <EM>//data provided by the plugin
|
||||
to the debugger (required)</EM><BR> [OUT]
|
||||
to the debugger (required).</EM><BR> [OUT]
|
||||
<STRONG>int</STRONG> sdkVersion; //plugin SDK version, use the
|
||||
PLUG_SDKVERSION define for this<BR> [OUT]
|
||||
<STRONG>int</STRONG> pluginVersion; //plugin version,
|
||||
useful for crash reports<BR> [OUT]
|
||||
<STRONG>char</STRONG> pluginName[256]; //plugin name, also
|
||||
useful for crash reports<BR>
|
||||
};</P></body>
|
||||
};</P></body>
|
28
help/PLUG_SETUPSTRUCT.htm
Normal file
28
help/PLUG_SETUPSTRUCT.htm
Normal file
@ -0,0 +1,28 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<title>PLUG_SETUPSTRUCT</title>
|
||||
<meta name="GENERATOR" content="WinCHM">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<style>
|
||||
html,body {
|
||||
/* Default Font */
|
||||
font-family: Courier New;
|
||||
font-size: 11pt;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<P><STRONG>plugsetup</STRONG><BR>This structure is used by the function that allows the
|
||||
creation of plugin menu entries:</P>
|
||||
<P>
|
||||
struct <STRONG>PLUG_SETUPSTRUCT</STRONG>
|
||||
<BR>{<BR> <EM>//data provided by the debugger to
|
||||
the plugin.</EM>
|
||||
<BR> [IN] <STRONG>HWND</STRONG> hwndDlg; //GUI window
|
||||
handle<BR> [IN]
|
||||
<STRONG>int</STRONG> hMenu; //plugin menu
|
||||
handle<BR>
|
||||
};</P></head>
|
@ -15,5 +15,6 @@ html,body {
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<P><STRONG>Scripting</STRONG><BR>This sections provides an overview of automating tasks with x64_dbg using
|
||||
scripts.</P></body>
|
||||
<P><STRONG>Scripting</STRONG><BR>This sections provides an overview of automating tasks with
|
||||
x64_dbg using scripts. See Commands for a description of all possible script commands. See Introduction for an introduction to
|
||||
expressions.</P></body>
|
@ -48,7 +48,9 @@ Rogers </DIV>
|
||||
target=_blank>Tuts4You community</A>
|
||||
</DIV>
|
||||
<LI>
|
||||
<DIV>DMichael </DIV>
|
||||
<DIV>DMichael </DIV>
|
||||
<LI>
|
||||
<DIV>TEAM DVT </DIV>
|
||||
<LI>
|
||||
<DIV>Sorry if I forgot
|
||||
you! </DIV></LI></UL></body>
|
||||
you! </DIV></LI></UL></head>
|
29
help/The_basics.htm
Normal file
29
help/The_basics.htm
Normal file
@ -0,0 +1,29 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<title>The basics</title>
|
||||
<meta name="GENERATOR" content="WinCHM">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<style>
|
||||
html,body {
|
||||
/* Default Font */
|
||||
font-family: Courier New;
|
||||
font-size: 11pt;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<P><STRONG>The basics</STRONG><BR>This page covers the
|
||||
basic principles of plugin development for x64_dbg.</P>
|
||||
<P><STRONG>Exports</STRONG><BR>A plugin has at least one
|
||||
export. This export must be called <U>pluginit</U>. See the PLUG_INITSTRUCT and
|
||||
the plugin headers for
|
||||
more information. The other valid exports are:</P>
|
||||
<P><U>plugstop</U>: called when the plugin is about to be
|
||||
unloaded. Remove all registered commands and
|
||||
callbacks here. Also clean up plugin data.</P>
|
||||
<P><U>plugsetup</U>: Called when the plugin initialization
|
||||
was successful, here you
|
||||
can register menus and other GUI-related things.</P></body>
|
@ -15,11 +15,15 @@ html,body {
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<P><STRONG>_plugin_debugpause<BR></STRONG>This function
|
||||
returns debugger control to the user. You would use this function when you write
|
||||
an unpacker that needs support from x64_dbg (for example in development).
|
||||
Calling this function will set the debug state to 'paused' and it will not
|
||||
return until the user runs the debuggee using the 'run' command.</P>
|
||||
<P><STRONG>_plugin_debugpause<BR></STRONG>This function returns debugger control to the
|
||||
user. You would use this function when you write an unpacker that needs support
|
||||
from x64_dbg (for example in development). Calling this function will set the
|
||||
debug state to 'paused' and <U>it will <STRONG>not</STRONG> return until the
|
||||
user runs the debuggee using the 'run' command</U>
|
||||
|
||||
|
||||
|
||||
.</P>
|
||||
<P><STRONG>void
|
||||
_plugin_debugpause();</STRONG></P>
|
||||
<P><STRONG>Parameters</STRONG> </P>
|
||||
@ -29,4 +33,4 @@ _plugin_debugpause();</STRONG></P>
|
||||
<BR >
|
||||
This function does not return a value.
|
||||
|
||||
</P></body>
|
||||
</P></body>
|
32
help/_plugin_debugskipexceptions.htm
Normal file
32
help/_plugin_debugskipexceptions.htm
Normal file
@ -0,0 +1,32 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<title>_plugin_debugskipexceptions</title>
|
||||
<meta name="GENERATOR" content="WinCHM">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<style>
|
||||
html,body {
|
||||
/* Default Font */
|
||||
font-family: Courier New;
|
||||
font-size: 11pt;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<P><STRONG>_plugin_debugskipexceptions<BR></STRONG>This function returns sets if the debugger should
|
||||
skip first-chance exceptions. This is useful when creating unpackers or other
|
||||
plugins that run the debuggee.</P>
|
||||
<P><STRONG>void _plugin_debugskipexceptions(<BR>bool
|
||||
</STRONG>skip //skip
|
||||
flag<BR><STRONG>);</STRONG></P>
|
||||
<P><STRONG>Parameters</STRONG> </P>
|
||||
<P><U>skip</U>: Flag if we need to skip first-chance exceptions or not.</P>
|
||||
<P>
|
||||
<STRONG>
|
||||
Return Values
|
||||
|
||||
</STRONG>
|
||||
<BR>This function does not return a value.
|
||||
</P></BODY></HTML>
|
29
help/_plugin_menuadd.htm
Normal file
29
help/_plugin_menuadd.htm
Normal file
@ -0,0 +1,29 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<title>_plugin_menuadd</title>
|
||||
<meta name="GENERATOR" content="WinCHM">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<style>
|
||||
html,body {
|
||||
/* Default Font */
|
||||
font-family: Courier New;
|
||||
font-size: 11pt;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<P><STRONG>_plugin_menuadd<BR></STRONG>This function adds a new child menu to a menu.</P>
|
||||
<P><STRONG>int _plugin_menuadd(<BR>int </STRONG>hMenu<STRONG>, </STRONG>//menu handle to add the
|
||||
new child menu to<BR><STRONG>const char* </STRONG>title //child menu title<BR><STRONG>);</STRONG></P>
|
||||
<P><STRONG>Parameters</STRONG> </P>
|
||||
<P><U>hMenu</U>: Menu handle from a previously-added child menu or from
|
||||
the main plugin menu.</P>
|
||||
<P><U>title</U>
|
||||
: Menu title.</P>
|
||||
<P>
|
||||
<STRONG>Return Values</STRONG>
|
||||
<BR > Returns the child menu handle
|
||||
(unique), -1 on failure.</P></BODY></HTML>
|
35
help/_plugin_menuaddentry.htm
Normal file
35
help/_plugin_menuaddentry.htm
Normal file
@ -0,0 +1,35 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<title>_plugin_menuaddentry</title>
|
||||
<meta name="GENERATOR" content="WinCHM">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<style>
|
||||
html,body {
|
||||
/* Default Font */
|
||||
font-family: Courier New;
|
||||
font-size: 11pt;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<P><STRONG>_plugin_menuaddentry<BR></STRONG>This function adds a menu entry to a menu.</P>
|
||||
<P><STRONG>bool _plugin_menuaddentry(<BR>int
|
||||
</STRONG>hMenu<STRONG>, </STRONG>//menu handle to add the new
|
||||
child menu to<BR><STRONG>int</STRONG> hEntry, //plugin-wide identifier for the
|
||||
menu entry<BR><STRONG>const char*
|
||||
</STRONG>title //menu entry title<BR><STRONG>);</STRONG></P>
|
||||
<P><STRONG>Parameters</STRONG> </P>
|
||||
<P><U>hMenu</U>: Menu handle from a
|
||||
previously-added child menu or from the main plugin menu.</P>
|
||||
<P><U>hEntry</U>: A plugin-wide identifier for the menu
|
||||
entry. This is the value you will get in the PLUG_CB_MENUENTRY callback
|
||||
structure.</P>
|
||||
<P><U>title</U> : Menu
|
||||
entry title.</P>
|
||||
<P><STRONG>Return Values</STRONG> <BR>Returns true when the entry was added without problems, false
|
||||
otherwise.</P>
|
||||
<P> </P></body>
|
||||
</html>
|
31
help/_plugin_menuaddseparator.htm
Normal file
31
help/_plugin_menuaddseparator.htm
Normal file
@ -0,0 +1,31 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<title>_plugin_menuaddseparator</title>
|
||||
<meta name="GENERATOR" content="WinCHM">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<style>
|
||||
html,body {
|
||||
/* Default Font */
|
||||
font-family: Courier New;
|
||||
font-size: 11pt;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<P><STRONG>_plugin_menuaddseparator<BR></STRONG>This function adds a new child menu to a menu.</P>
|
||||
<P><STRONG>bool </STRONG><STRONG>_plugin_menuaddseparator</STRONG><STRONG>(<BR>int </STRONG>hMenu<STRONG>
|
||||
</STRONG>//menu handle to add the separator to
|
||||
<BR>
|
||||
<STRONG >
|
||||
);</STRONG></P>
|
||||
<P >
|
||||
|
||||
<STRONG>
|
||||
Parameters</STRONG></P>
|
||||
<P><U>hMenu</U>: Menu handle from a
|
||||
previously-added child menu or from the main plugin menu.</P>
|
||||
<P><STRONG>Return Values</STRONG> <BR>Returns true on success.</P></body>
|
||||
</html>
|
38
help/_plugin_menuclear.htm
Normal file
38
help/_plugin_menuclear.htm
Normal file
@ -0,0 +1,38 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<title>_plugin_menuclear</title>
|
||||
<meta name="GENERATOR" content="WinCHM">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<style>
|
||||
html,body {
|
||||
/* Default Font */
|
||||
font-family: Courier New;
|
||||
font-size: 11pt;
|
||||
}
|
||||
</style>
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<P><STRONG>_plugin_menuclear<BR></STRONG>This function removes all entries and child menus
|
||||
from a menu. It will <STRONG>not </STRONG>remove the menu itself.</P>
|
||||
<P>
|
||||
<STRONG>
|
||||
bool
|
||||
</STRONG>
|
||||
<STRONG>
|
||||
_plugin_menuclear
|
||||
|
||||
</STRONG>
|
||||
<STRONG>(
|
||||
<BR > int</STRONG>hMenu
|
||||
<STRONG ></STRONG>//menu handle of the menu to clear
|
||||
|
||||
<BR>
|
||||
<STRONG>);</STRONG></P>
|
||||
<P><STRONG>Parameters</STRONG></P>
|
||||
<P><U>hMenu</U>: Menu handle from a
|
||||
previously-added child menu or from the main plugin menu.</P>
|
||||
<P><STRONG>Return Values</STRONG> <BR>Returns true on success.</P></body>
|
||||
</html>
|
@ -52,11 +52,12 @@ CB_BREAKPOINT,<BR>
|
||||
CB_PAUSEDEBUG,
|
||||
<BR>
|
||||
CB_RESUMEDEBUG,<BR> CB_STEPPED,<BR>
|
||||
CB_ATTACH,<BR>
|
||||
CB_DETACH
|
||||
CB_ATTACH,<BR> CB_DETACH,<BR>
|
||||
CB_DEBUGEVENT,<BR>
|
||||
CB_MENUENTRY
|
||||
|
||||
</P>
|
||||
<P><STRONG>Return Values<BR></STRONG>This function returns
|
||||
true when the callback was removed without problems.
|
||||
|
||||
</P></body></HTML>
|
||||
</P></body>
|
176
help/x64_dbg.wcp
176
help/x64_dbg.wcp
@ -96,7 +96,7 @@ Font=
|
||||
DefaultTopic=Introduction.htm
|
||||
|
||||
[TOPICS]
|
||||
TitleList=103
|
||||
TitleList=110
|
||||
TitleList.Title.0=Introduction
|
||||
TitleList.Level.0=0
|
||||
TitleList.Url.0=Introduction.htm
|
||||
@ -145,7 +145,7 @@ TitleList.Status.4=0
|
||||
TitleList.Keywords.4=
|
||||
TitleList.ContextNumber.4=1003
|
||||
TitleList.ApplyTemp.4=0
|
||||
TitleList.Expanded.4=1
|
||||
TitleList.Expanded.4=0
|
||||
TitleList.Kind.4=0
|
||||
TitleList.Title.5=Debug Control
|
||||
TitleList.Level.5=1
|
||||
@ -155,7 +155,7 @@ TitleList.Status.5=0
|
||||
TitleList.Keywords.5=
|
||||
TitleList.ContextNumber.5=1040
|
||||
TitleList.ApplyTemp.5=0
|
||||
TitleList.Expanded.5=1
|
||||
TitleList.Expanded.5=0
|
||||
TitleList.Kind.5=0
|
||||
TitleList.Title.6=InitDebug/initdbg/init
|
||||
TitleList.Level.6=2
|
||||
@ -985,146 +985,216 @@ TitleList.Status.88=0
|
||||
TitleList.Keywords.88=
|
||||
TitleList.ContextNumber.88=1050
|
||||
TitleList.ApplyTemp.88=0
|
||||
TitleList.Expanded.88=0
|
||||
TitleList.Expanded.88=1
|
||||
TitleList.Kind.88=0
|
||||
TitleList.Title.89=Exports
|
||||
TitleList.Title.89=The basics
|
||||
TitleList.Level.89=1
|
||||
TitleList.Url.89=Exports.htm
|
||||
TitleList.Url.89=The_basics.htm
|
||||
TitleList.Icon.89=0
|
||||
TitleList.Status.89=0
|
||||
TitleList.Keywords.89=
|
||||
TitleList.ContextNumber.89=1051
|
||||
TitleList.ContextNumber.89=1103
|
||||
TitleList.ApplyTemp.89=0
|
||||
TitleList.Expanded.89=0
|
||||
TitleList.Kind.89=0
|
||||
TitleList.Title.90=_plugin_registercallback
|
||||
TitleList.Level.90=2
|
||||
TitleList.Url.90=_plugin_registercallback.htm
|
||||
TitleList.Title.90=API
|
||||
TitleList.Level.90=1
|
||||
TitleList.Url.90=Exports.htm
|
||||
TitleList.Icon.90=0
|
||||
TitleList.Status.90=0
|
||||
TitleList.Keywords.90=
|
||||
TitleList.ContextNumber.90=1052
|
||||
TitleList.ContextNumber.90=1051
|
||||
TitleList.ApplyTemp.90=0
|
||||
TitleList.Expanded.90=0
|
||||
TitleList.Expanded.90=1
|
||||
TitleList.Kind.90=0
|
||||
TitleList.Title.91=_plugin_unregistercallback
|
||||
TitleList.Title.91=_plugin_registercallback
|
||||
TitleList.Level.91=2
|
||||
TitleList.Url.91=_plugin_unregistercallback.htm
|
||||
TitleList.Url.91=_plugin_registercallback.htm
|
||||
TitleList.Icon.91=0
|
||||
TitleList.Status.91=0
|
||||
TitleList.Keywords.91=
|
||||
TitleList.ContextNumber.91=1053
|
||||
TitleList.ContextNumber.91=1052
|
||||
TitleList.ApplyTemp.91=0
|
||||
TitleList.Expanded.91=0
|
||||
TitleList.Kind.91=0
|
||||
TitleList.Title.92=_plugin_registercommand
|
||||
TitleList.Title.92=_plugin_unregistercallback
|
||||
TitleList.Level.92=2
|
||||
TitleList.Url.92=_plugin_registercommand.htm
|
||||
TitleList.Url.92=_plugin_unregistercallback.htm
|
||||
TitleList.Icon.92=0
|
||||
TitleList.Status.92=0
|
||||
TitleList.Keywords.92=
|
||||
TitleList.ContextNumber.92=1054
|
||||
TitleList.ContextNumber.92=1053
|
||||
TitleList.ApplyTemp.92=0
|
||||
TitleList.Expanded.92=0
|
||||
TitleList.Kind.92=0
|
||||
TitleList.Title.93=_plugin_unregistercommand
|
||||
TitleList.Title.93=_plugin_registercommand
|
||||
TitleList.Level.93=2
|
||||
TitleList.Url.93=_plugin_unregistercommand.htm
|
||||
TitleList.Url.93=_plugin_registercommand.htm
|
||||
TitleList.Icon.93=0
|
||||
TitleList.Status.93=0
|
||||
TitleList.Keywords.93=
|
||||
TitleList.ContextNumber.93=1055
|
||||
TitleList.ContextNumber.93=1054
|
||||
TitleList.ApplyTemp.93=0
|
||||
TitleList.Expanded.93=0
|
||||
TitleList.Kind.93=0
|
||||
TitleList.Title.94=_plugin_logprintf
|
||||
TitleList.Title.94=_plugin_unregistercommand
|
||||
TitleList.Level.94=2
|
||||
TitleList.Url.94=_plugin_logprintf.htm
|
||||
TitleList.Url.94=_plugin_unregistercommand.htm
|
||||
TitleList.Icon.94=0
|
||||
TitleList.Status.94=0
|
||||
TitleList.Keywords.94=
|
||||
TitleList.ContextNumber.94=1056
|
||||
TitleList.ContextNumber.94=1055
|
||||
TitleList.ApplyTemp.94=0
|
||||
TitleList.Expanded.94=0
|
||||
TitleList.Kind.94=0
|
||||
TitleList.Title.95=_plugin_logputs
|
||||
TitleList.Title.95=_plugin_logprintf
|
||||
TitleList.Level.95=2
|
||||
TitleList.Url.95=_plugin_logputs.htm
|
||||
TitleList.Url.95=_plugin_logprintf.htm
|
||||
TitleList.Icon.95=0
|
||||
TitleList.Status.95=0
|
||||
TitleList.Keywords.95=
|
||||
TitleList.ContextNumber.95=1057
|
||||
TitleList.ContextNumber.95=1056
|
||||
TitleList.ApplyTemp.95=0
|
||||
TitleList.Expanded.95=0
|
||||
TitleList.Kind.95=0
|
||||
TitleList.Title.96=_plugin_debugpause
|
||||
TitleList.Title.96=_plugin_logputs
|
||||
TitleList.Level.96=2
|
||||
TitleList.Url.96=_plugin_debugpause.htm
|
||||
TitleList.Url.96=_plugin_logputs.htm
|
||||
TitleList.Icon.96=0
|
||||
TitleList.Status.96=0
|
||||
TitleList.Keywords.96=
|
||||
TitleList.ContextNumber.96=1058
|
||||
TitleList.ContextNumber.96=1057
|
||||
TitleList.ApplyTemp.96=0
|
||||
TitleList.Expanded.96=0
|
||||
TitleList.Kind.96=0
|
||||
TitleList.Title.97=Structures
|
||||
TitleList.Level.97=1
|
||||
TitleList.Url.97=Structures.htm
|
||||
TitleList.Title.97=_plugin_debugpause
|
||||
TitleList.Level.97=2
|
||||
TitleList.Url.97=_plugin_debugpause.htm
|
||||
TitleList.Icon.97=0
|
||||
TitleList.Status.97=0
|
||||
TitleList.Keywords.97=
|
||||
TitleList.ContextNumber.97=1059
|
||||
TitleList.ContextNumber.97=1058
|
||||
TitleList.ApplyTemp.97=0
|
||||
TitleList.Expanded.97=0
|
||||
TitleList.Kind.97=0
|
||||
TitleList.Title.98=Callbacks
|
||||
TitleList.Title.98=_plugin_debugskipexceptions
|
||||
TitleList.Level.98=2
|
||||
TitleList.Url.98=Callbacks.htm
|
||||
TitleList.Url.98=_plugin_debugskipexceptions.htm
|
||||
TitleList.Icon.98=0
|
||||
TitleList.Status.98=0
|
||||
TitleList.Keywords.98=
|
||||
TitleList.ContextNumber.98=1060
|
||||
TitleList.ContextNumber.98=1104
|
||||
TitleList.ApplyTemp.98=0
|
||||
TitleList.Expanded.98=0
|
||||
TitleList.Kind.98=0
|
||||
TitleList.Title.99=PLUG_INITSTRUCT
|
||||
TitleList.Title.99=_plugin_menuadd
|
||||
TitleList.Level.99=2
|
||||
TitleList.Url.99=PLUGINIT_STRUCT.htm
|
||||
TitleList.Url.99=_plugin_menuadd.htm
|
||||
TitleList.Icon.99=0
|
||||
TitleList.Status.99=0
|
||||
TitleList.Keywords.99=
|
||||
TitleList.ContextNumber.99=1061
|
||||
TitleList.ContextNumber.99=1108
|
||||
TitleList.ApplyTemp.99=0
|
||||
TitleList.Expanded.99=0
|
||||
TitleList.Kind.99=0
|
||||
TitleList.Title.100=Scripting
|
||||
TitleList.Level.100=0
|
||||
TitleList.Url.100=Scripting.htm
|
||||
TitleList.Title.100=_plugin_menuaddentry
|
||||
TitleList.Level.100=2
|
||||
TitleList.Url.100=_plugin_menuaddentry.htm
|
||||
TitleList.Icon.100=0
|
||||
TitleList.Status.100=0
|
||||
TitleList.Keywords.100=
|
||||
TitleList.ContextNumber.100=1069
|
||||
TitleList.ContextNumber.100=1107
|
||||
TitleList.ApplyTemp.100=0
|
||||
TitleList.Expanded.100=0
|
||||
TitleList.Kind.100=0
|
||||
TitleList.Title.101=Special Thanks
|
||||
TitleList.Level.101=0
|
||||
TitleList.Url.101=Special_Thanks.htm
|
||||
TitleList.Title.101=_plugin_menuaddseparator
|
||||
TitleList.Level.101=2
|
||||
TitleList.Url.101=_plugin_menuaddseparator.htm
|
||||
TitleList.Icon.101=0
|
||||
TitleList.Status.101=0
|
||||
TitleList.Keywords.101=
|
||||
TitleList.ContextNumber.101=1024
|
||||
TitleList.ContextNumber.101=1106
|
||||
TitleList.ApplyTemp.101=0
|
||||
TitleList.Expanded.101=0
|
||||
TitleList.Kind.101=0
|
||||
TitleList.Title.102=Fixed Top Style
|
||||
TitleList.Level.102=0
|
||||
TitleList.Url.102=template\fixedtop.htm
|
||||
TitleList.Title.102=_plugin_menuclear
|
||||
TitleList.Level.102=2
|
||||
TitleList.Url.102=_plugin_menuclear.htm
|
||||
TitleList.Icon.102=0
|
||||
TitleList.Status.102=0
|
||||
TitleList.Keywords.102=
|
||||
TitleList.ContextNumber.102=
|
||||
TitleList.ContextNumber.102=1105
|
||||
TitleList.ApplyTemp.102=0
|
||||
TitleList.Expanded.102=0
|
||||
TitleList.Kind.102=2
|
||||
TitleList.Kind.102=0
|
||||
TitleList.Title.103=Structures
|
||||
TitleList.Level.103=1
|
||||
TitleList.Url.103=Structures.htm
|
||||
TitleList.Icon.103=0
|
||||
TitleList.Status.103=0
|
||||
TitleList.Keywords.103=
|
||||
TitleList.ContextNumber.103=1059
|
||||
TitleList.ApplyTemp.103=0
|
||||
TitleList.Expanded.103=1
|
||||
TitleList.Kind.103=0
|
||||
TitleList.Title.104=Callback Structures
|
||||
TitleList.Level.104=2
|
||||
TitleList.Url.104=Callbacks.htm
|
||||
TitleList.Icon.104=0
|
||||
TitleList.Status.104=0
|
||||
TitleList.Keywords.104=
|
||||
TitleList.ContextNumber.104=1060
|
||||
TitleList.ApplyTemp.104=0
|
||||
TitleList.Expanded.104=0
|
||||
TitleList.Kind.104=0
|
||||
TitleList.Title.105=PLUG_INITSTRUCT
|
||||
TitleList.Level.105=2
|
||||
TitleList.Url.105=PLUGINIT_STRUCT.htm
|
||||
TitleList.Icon.105=0
|
||||
TitleList.Status.105=0
|
||||
TitleList.Keywords.105=
|
||||
TitleList.ContextNumber.105=1061
|
||||
TitleList.ApplyTemp.105=0
|
||||
TitleList.Expanded.105=0
|
||||
TitleList.Kind.105=0
|
||||
TitleList.Title.106=PLUG_SETUPSTRUCT
|
||||
TitleList.Level.106=2
|
||||
TitleList.Url.106=PLUG_SETUPSTRUCT.htm
|
||||
TitleList.Icon.106=0
|
||||
TitleList.Status.106=0
|
||||
TitleList.Keywords.106=
|
||||
TitleList.ContextNumber.106=1102
|
||||
TitleList.ApplyTemp.106=0
|
||||
TitleList.Expanded.106=0
|
||||
TitleList.Kind.106=0
|
||||
TitleList.Title.107=Scripting
|
||||
TitleList.Level.107=0
|
||||
TitleList.Url.107=Scripting.htm
|
||||
TitleList.Icon.107=0
|
||||
TitleList.Status.107=0
|
||||
TitleList.Keywords.107=
|
||||
TitleList.ContextNumber.107=1069
|
||||
TitleList.ApplyTemp.107=0
|
||||
TitleList.Expanded.107=0
|
||||
TitleList.Kind.107=0
|
||||
TitleList.Title.108=Special Thanks
|
||||
TitleList.Level.108=0
|
||||
TitleList.Url.108=Special_Thanks.htm
|
||||
TitleList.Icon.108=0
|
||||
TitleList.Status.108=0
|
||||
TitleList.Keywords.108=
|
||||
TitleList.ContextNumber.108=1024
|
||||
TitleList.ApplyTemp.108=0
|
||||
TitleList.Expanded.108=0
|
||||
TitleList.Kind.108=0
|
||||
TitleList.Title.109=Fixed Top Style
|
||||
TitleList.Level.109=0
|
||||
TitleList.Url.109=template\fixedtop.htm
|
||||
TitleList.Icon.109=0
|
||||
TitleList.Status.109=0
|
||||
TitleList.Keywords.109=
|
||||
TitleList.ContextNumber.109=
|
||||
TitleList.ApplyTemp.109=0
|
||||
TitleList.Expanded.109=0
|
||||
TitleList.Kind.109=2
|
||||
|
||||
|
@ -80,6 +80,7 @@ The icon is taken from VisualPharm (http://www.visualpharm.com/)
|
||||
- EXETools community
|
||||
- Tuts4You community
|
||||
- DMichael
|
||||
- TEAM DVT
|
||||
- Sorry if I forgot you!
|
||||
|
||||
>Lead developers:
|
||||
|
@ -427,13 +427,13 @@ static void cbStep()
|
||||
GuiSetDebugState(paused);
|
||||
PLUG_CB_STEPPED stepInfo;
|
||||
stepInfo.reserved=0;
|
||||
plugincbcall(CB_STEPPED, &stepInfo);
|
||||
//lock
|
||||
lock(WAITID_RUN);
|
||||
bSkipExceptions=false;
|
||||
PLUG_CB_PAUSEDEBUG pauseInfo;
|
||||
pauseInfo.reserved=0;
|
||||
plugincbcall(CB_PAUSEDEBUG, &pauseInfo);
|
||||
plugincbcall(CB_STEPPED, &stepInfo);
|
||||
wait(WAITID_RUN);
|
||||
}
|
||||
|
||||
@ -569,6 +569,14 @@ static void cbCreateThread(CREATE_THREAD_DEBUG_INFO* CreateThread)
|
||||
{
|
||||
threadcreate(CreateThread); //update thread list
|
||||
DWORD dwThreadId=((DEBUG_EVENT*)GetDebugData())->dwThreadId;
|
||||
|
||||
if(settingboolget("Events", "ThreadEntry"))
|
||||
{
|
||||
char command[256]="";
|
||||
sprintf(command, "bp "fhex",\"Thread %X\",ss", CreateThread->lpStartAddress, dwThreadId);
|
||||
cmddirectexec(dbggetcommandlist(), command);
|
||||
}
|
||||
|
||||
PLUG_CB_CREATETHREAD callbackInfo;
|
||||
callbackInfo.CreateThread=CreateThread;
|
||||
callbackInfo.dwThreadId=dwThreadId;
|
||||
@ -588,13 +596,6 @@ static void cbCreateThread(CREATE_THREAD_DEBUG_INFO* CreateThread)
|
||||
plugincbcall(CB_PAUSEDEBUG, &pauseInfo);
|
||||
wait(WAITID_RUN);
|
||||
}
|
||||
|
||||
if(settingboolget("Events", "ThreadEntry"))
|
||||
{
|
||||
char command[256]="";
|
||||
sprintf(command, "bp "fhex",\"Thread %X\",ss", CreateThread->lpStartAddress, dwThreadId);
|
||||
cmddirectexec(dbggetcommandlist(), command);
|
||||
}
|
||||
}
|
||||
|
||||
static void cbExitThread(EXIT_THREAD_DEBUG_INFO* ExitThread)
|
||||
@ -680,6 +681,17 @@ static void cbLoadDll(LOAD_DLL_DEBUG_INFO* LoadDll)
|
||||
}
|
||||
GuiUpdateBreakpointsView();
|
||||
|
||||
if(settingboolget("Events", "DllEntry") && !bAlreadySetEntry)
|
||||
{
|
||||
uint oep=GetPE32Data(DLLDebugFileName, 0, UE_OEP);
|
||||
if(oep)
|
||||
{
|
||||
char command[256]="";
|
||||
sprintf(command, "bp "fhex",\"DllMain (%s)\",ss", oep+(uint)base, modname);
|
||||
cmddirectexec(dbggetcommandlist(), command);
|
||||
}
|
||||
}
|
||||
|
||||
//plugin callback
|
||||
PLUG_CB_LOADDLL callbackInfo;
|
||||
callbackInfo.LoadDll=LoadDll;
|
||||
@ -699,17 +711,6 @@ static void cbLoadDll(LOAD_DLL_DEBUG_INFO* LoadDll)
|
||||
plugincbcall(CB_PAUSEDEBUG, &pauseInfo);
|
||||
wait(WAITID_RUN);
|
||||
}
|
||||
|
||||
if(settingboolget("Events", "DllEntry") && !bAlreadySetEntry)
|
||||
{
|
||||
uint oep=GetPE32Data(DLLDebugFileName, 0, UE_OEP);
|
||||
if(oep)
|
||||
{
|
||||
char command[256]="";
|
||||
sprintf(command, "bp "fhex",\"DllMain (%s)\",ss", oep+(uint)base, modname);
|
||||
cmddirectexec(dbggetcommandlist(), command);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void cbUnloadDll(UNLOAD_DLL_DEBUG_INFO* UnloadDll)
|
||||
@ -744,6 +745,7 @@ static void cbOutputDebugString(OUTPUT_DEBUG_STRING_INFO* DebugString)
|
||||
PLUG_CB_OUTPUTDEBUGSTRING callbackInfo;
|
||||
callbackInfo.DebugString=DebugString;
|
||||
plugincbcall(CB_OUTPUTDEBUGSTRING, &callbackInfo);
|
||||
|
||||
if(!DebugString->fUnicode) //ASCII
|
||||
{
|
||||
char* DebugText=(char*)emalloc(DebugString->nDebugStringLength+1, "cbOutputDebugString:DebugText");
|
||||
|
Loading…
x
Reference in New Issue
Block a user