简体   繁体   English

VB.net或C#.net中的系统监视器

[英]System watcher in VB.net or C#.net

I want to write a simple program, which should inform me before any files getting open (like as User account control in Windows Vista or Windows 7). 我想编写一个简单的程序,它应该在任何文件打开之前通知我(如Windows Vista或Windows 7中的用户帐户控制)。 I came to know that all antiviruses use this technique to detect viruses before they are affecting the system. 我开始知道所有的防病毒软件都会在病毒影响系统之前使用这种技术来检测病毒。 My program must ask me as "Are you allow this file to run?" 我的程序必须问我“你允许这个文件运行吗?” and allow it if I allow otherwise terminate the file. 并允许它,如果我允许否则终止文件。 Please help me and I kindly expect the sample code in VB.Net or C#.Net. 请帮助我,我希望VB.Net或C#.Net中的示例代码。

Please accept my apologize for my poor language and thanks in advance. 请接受我为我的语言道歉而道歉,并提前致谢。

没有外部代码的帮助,这在VB.NET或C#中是不可能的。

You want to hook into Process Monitor... here is the code you will need to do that: Easy Hook into ProcessMonitor 您想要挂钩进程监视器......以下是您需要执行此操作的代码: Easy Hook into ProcessMonitor

To prove that EasyHook really makes hooking simple, look at the following demo application, which will log all file accesses from a given process. 为了证明EasyHook真的很简单,请查看以下演示应用程序,它将记录给定进程的所有文件访问。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM