Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

can processhacker plugin support individual file op ? #82

Open
yangjian123 opened this issue Dec 9, 2020 · 6 comments
Open

can processhacker plugin support individual file op ? #82

yangjian123 opened this issue Dec 9, 2020 · 6 comments

Comments

@yangjian123
Copy link

I am a heavy user of processhack, sometimes i need to analysis file operation(read,write), Hope processhack can have such a plugin

@dmex
Copy link
Member

dmex commented Dec 9, 2020

@yangjian123
Copy link
Author

yangjian123 commented Dec 11, 2020

hi, dmex, do you know why EventRecord->EventHeader->ProcessId and EventRecord->EventHeader->ThreadId always -1 in windows7 on file io event . i modify the etwmon.c code as below, and the question still exist, can dmex have idea about this?

` EtpTraceProperties->Wnode.BufferSize = bufferSize;

    EtpTraceProperties->Wnode.Guid = *EtpActualSessionGuid;

    EtpTraceProperties->Wnode.ClientContext = 1;

    EtpTraceProperties->Wnode.Flags = WNODE_FLAG_TRACED_GUID;

    EtpTraceProperties->MinimumBuffers = 1;

    EtpTraceProperties->LogFileMode = EVENT_TRACE_REAL_TIME_MODE;

    EtpTraceProperties->FlushTimer = 1;

    EtpTraceProperties->EnableFlags = EVENT_TRACE_FLAG_DISK_IO | EVENT_TRACE_FLAG_DISK_FILE_IO | EVENT_TRACE_FLAG_NETWORK_TCPIP|EVENT_TRACE_FLAG_FILE_IO| EVENT_TRACE_FLAG_FILE_IO_INIT| EVENT_TRACE_FLAG_PROCESS | EVENT_TRACE_FLAG_THREAD;

    EtpTraceProperties->LoggerNameOffset = sizeof(EVENT_TRACE_PROPERTIES);`

@dmex
Copy link
Member

dmex commented Dec 11, 2020

ThreadId always -1

You ignore these for the ID included in the event message.

@yangjian123
Copy link
Author

where can we get the correct process id and threadid? can dmex supply some helps ?

@dmex
Copy link
Member

dmex commented Dec 12, 2020

The kernel generally returns files to the application from cache not disk. components like superfetch speculatively load files before the process is created so when the ID is zero you default to processId 4 for system.

@yangjian123
Copy link
Author

hi,dmex,do you have any update?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants