在 Windows 中记录系统调用
我一直在寻找在 Windows 上实时获取系统调用的方法一段时间。我在 stackoverflow 和其他地方查看了几篇文章,但找不到任何足够简单的内容让我可以遵循。我看过 procmon 但它的输出相当不稳定。两个系统上的相同二进制文件生成了不同数量的条目。也许我缺乏做这些事情的先决知识。欢迎任何帮助/建议。
我之前看过这些链接:
- windows 中的系统调用 &原生 API?
- http://www.codeguru .com/cpp/wp/system/devicedriverdevelopment/article.php/c8035
- http://technet.microsoft.com/en-us/sysinternals/bb897447.aspx
问候
I have been searching for some time now on ways to get syscalls in realtime on windows. I have looked at couple of posts here at stackoverflow and elsewhere but could not find anything easy enough that I could follow. I have looked at procmon but its output has been pretty unstable. Same binary on two systems has generated different number of entries. Perhaps I lack the pre-requisite knowledge to do such stuff. Any help/recommendation is welcome.
I have looked at these link before:
- System Calls in windows & Native API?
- http://www.codeguru.com/cpp/w-p/system/devicedriverdevelopment/article.php/c8035
- http://technet.microsoft.com/en-us/sysinternals/bb897447.aspx
Regards
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
根据您使用的 Windows 版本,您的问题的答案可能是 Windows 事件跟踪 (ETW),它可以进行系统调用日志记录 [链接]
Depending on the version of Windows you are using, the answer to your question is probably Event Tracing for Windows (ETW) which can do syscall logging [link]
如果您对采样方法感到满意,那么您可以尝试以下方法:
其中
ThreadLastSystemCall = 21
If You are satisfied with sampling approach then You could try this:
where
ThreadLastSystemCall = 21