Windows Native API

Source: Wikipedia, the free encyclopedia.

The Native API is a lightweight

kernel32.dll that implement the Windows API
, the API based on which most of the Windows components are created.

Most of the Native API calls are implemented in

(SSDT).

Function groups

The Native API comprises many functions. They include

heap
to allocate memory from and the second and third because they use the console, accessed only via KERNEL32.DLL). The vast majority of other Native API routines, by convention, have a 2 or 3 letter prefix, which is:

user32.dll and gdi32.dll include several other calls that execute an interrupt into kernel mode. These were not part of the original Windows NT design, as can be seen in Windows NT 3.5. However, due to performance issues of hardware of that age, it was decided to move the graphics subsystem into kernel mode. As such, system call in the range of 0x1000-0x1FFF are satisfied by win32k.sys (instead of ntoskrnl.exe as done for 0-0x0FFF), and are declared in user32.dll and gdi32.dll. These functions have the NtUser and NtGdi prefix (e.g. NtUserLockWorkStation and NtGdiEnableEudc).

Uses

Uses of Native API functions includes but not limited to:

  • Enabling and disabling privileges (RtlAdjustPrivilege)
  • Creating remote thread within processes that are running in different session (RtlCreateUserThread)
  • Running native application (RtlCreateUserProcess)
  • Performing force shutdown (NtShutdownSystem)
  • Cause a BSOD in User mode (NtRaiseHardError)
  • Display a string in Native Mode (NtDisplayString)

See also

References

  1. ^ The NT Insider (August 27, 2003). "Nt vs. Zw - Clearing Confusion On The Native API". OSR Online. 10 (4). OSR Open Systems Resources. Retrieved 2013-09-16.
  2. Microsoft Corporation
    . Retrieved 2009-06-13.

External links