CryptProtectMemory function crypt32

int CryptProtectMemory(
  1. Pointer<NativeType> pDataIn,
  2. int cbDataIn,
  3. int dwFlags
)

The CryptProtectMemory function encrypts memory to prevent others from viewing sensitive information in your process. For example, use the CryptProtectMemory function to encrypt memory that contains a password. Encrypting the password prevents others from viewing it when the process is paged out to the swap file. Otherwise, the password is in plaintext and viewable by others.

BOOL CryptProtectMemory(
  [in, out] LPVOID pDataIn,
  [in]      DWORD  cbDataIn,
  [in]      DWORD  dwFlags
);

Implementation

int CryptProtectMemory(Pointer pDataIn, int cbDataIn, int dwFlags) =>
    _CryptProtectMemory(pDataIn, cbDataIn, dwFlags);