0
我仍然試圖完全理解鉤子和easyhook的工作方式。 我現在寫了一個簡單的例子:一個包含webbrowser元素的表單,並且我試圖掛接那個recv調用。編譯時,程序返回此錯誤:Easyhook引發System.NotSupportedException
A first chance exception of type 'System.NotSupportedException' occurred in EasyHook.dll
System.NotSupportedException: STATUS_NOT_SUPPORTED: (Code: 0)
at EasyHook.NativeAPI.Force(Int32 InErrorCode)
at EasyHook.RemoteHooking.InjectEx(Int32 InHostPID, Int32 InTargetPID, Int32 InWakeUpTID, Int32 InNativeOptions, String InLibraryPath_x86, String InLibraryPath_x64, Boolean InCanBypassWOW64, Boolean InCanCreateService, Object[] InPassThruArgs)
at EasyHook.RemoteHooking.Inject(Int32 InTargetPID, InjectionOptions InOptions, String InLibraryPath_x86, String InLibraryPath_x64, Object[] InPassThruArgs)
at Hook_Test.Form1.Run() in I:\Documents and Settings\Meme\Desktop\SimpleHook\Hook Test\Hook Test\Form1.cs:line 46
在第46行,我有這樣的代碼:
RemoteHooking.Inject(
Process.GetCurrentProcess().Id,
InjectionOptions.Default,
"TestInject.dll",
"TestInject.dll",
ChannelName);
我實在看不出是哪裏的問題,有人可以幫我嗎?
一次機會例外並不意味着太多。按F5。它實際上是否在未處理的異常上彈出? – 2011-01-05 16:28:28
不,當我運行該程序時,瀏覽器工作正常,但我無法掛鉤任何東西。 – kaharas 2011-01-06 13:19:24