0

I have download a source code to hook and monitor files

the link: http://code.google.com/p/easyhook-continuing-detours/downloads/list

but when executing the program "FileMon." . i got the following error: Could not load file or assembly 'EasyHook, Version=2.5.0.0, Culture=neutral, PublicKeyToken=4b580fca19d0b0c5' or one of its dependencies. The system cannot find the file specified

How to solve this error?

StayOnTarget
  • 11,743
  • 10
  • 52
  • 81
Ahmed M. Taher
  • 663
  • 1
  • 7
  • 15
  • Is there a reason why you are not using `System.IO.FileSystemWatcher`? – Olivier Jacot-Descombes Jan 22 '12 at 17:49
  • Did you start FileMon by double clicking the file in the zip? That will only extract that very file, not all the supporting ones. Extract the zip and run it from there. – Joachim Isaksson Jan 22 '12 at 17:51
  • The project assumes that you have extracted the contents of the zip file somewhere, you open up the project, compile and run it. You can't really extract that one project folder and expect to compile and run it since the dependencies were placed in certain locations of the archive. – Jeff Mercado Jan 22 '12 at 17:53
  • i tried to use System.IO.FileSystemWatcher . but FileSystemWatcher isn't monitor executed files! – Ahmed M. Taher Jan 22 '12 at 18:06
  • You are using an older release of EasyHook, the code is now hosted over at http://easyhook.codeplex.com – Justin Stenning Apr 16 '12 at 09:54

1 Answers1

2

Make sure the file EasyHook.dll is in the folder with the FileMon application.

doogle
  • 3,376
  • 18
  • 23
  • There was an error while connecting to target: System.ApplicationException: Unknown error code (-1073741502): The user defined managed entry point failed in the target process. Make sure that EasyHook is registered in the GAC. Refer to event logs for more information. (Code: 13) at EasyHook.NativeAPI.Force(Int32 InErrorCode) at EasyHook.RemoteHooking.InjectEx(Int32 InHostPID, Int32 InTargetPID, Int32 InWakeUpTID, Int32 InNativeOptions, String InLibraryPath_x86, String InLibraryPa th_x64, Boolean InCanBypassWOW64, Boolean InCanCreateService, Object[] InPassThr uArgs) – Ahmed M. Taher Jan 22 '12 at 18:11
  • It says it right there, refer to your logs for more information, but more so it says in plain english: "Make sure that EasyHook is registered in the GAC". I can only assume you have not registered the dll in the GAC as your previous error clearly says it. – doogle Jan 22 '12 at 18:22