Handle Management

Handle management is designed to allocate unique, system-wide identifiers necessary for correctly distinguishing system objects. This module is utilized by most SpaceShadow products.

A special type, HANDLE, is defined to store handle values. Its size is either 16 or 32 bits, depending on the maximum number of handles. The system supports a fixed maximum number of allocated handles, defined by the ST_MAX_HANDLE_COUNT constant. This constant must be greater than 0. The handle management module allocates memory based on this value, calculated as the product of the handle count and the size of the PVOID type.

The stHandleCheck function is an additional extension. It determines whether a handle is currently free. It is excluded from compilation by default, but may be used for testing and debugging. To make this function available, set ST_HANDLE_CHECK_FUNC to 1.

Functions such as stHandleAlloc, stHandleRelease, stHandleInfo, and stHandleInit are utilized internally by SpaceShadow products and should not be used by the user. These interfaces may change in future product releases.

SpaceShadow documentation