Click here to Skip to main content
15,798,592 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi, I am developing driver for automated Win 7 environment. I need to execute some commands within given interval. I would like to achive this using queuing APC routine from my driver to user mode process. But APC fails due to executing code from RW only memory allocated using IoAllocateMdl, locked with MmProbeAndLockPages and mapped into user mode. Is there any way how to change protection of allocated pages?

Code-o-mat 10-Jun-12 6:38am    
I'm not into driver development, but in user space you would probably use VirtualProtect(Ex) ( ) to achieve this task. You could try finding the corresponding kernel methods for that.
patrik polakovic 10-Jun-12 13:52pm    
There is system call ZwProtectVirtualMemory, which is undocumented. But there must be a way how achieve this "properly".

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900