BTW: If you want to play with a "Near Implementation" of it? Take a look at subsystems/win32/win32k/eng/mem.c HackSecureVirtualMemory and HackUnsecureVirtualMemory. It needs work and it crashes.