How-to: set the API security mode

Important

Versions of the Microsoft Rights Management Service SDK released prior to March 2020 are deprecated; applications using earlier versions must be updated to use the March 2020 release. For full details, see the deprecation notice.

No further enhancements are planned for the Microsoft Rights Management Service SDK. We strongly recommend adoption of the Microsoft Information Protection SDK for classification, labeling, and protection services.

You can choose which security mode your File API application runs in by using the IpcSetGlobalProperty function.

To initialize your application to run in server mode, call the IpcSetGlobalProperty function and set the security mode to IPC_API_MODE_SERVER. By default, your application will run in client mode, IPC_API_MODE_CLIENT.

For more information on server mode, see Application types.

Important  The security mode should be set before any other Rights Management Services SDK 2.1 function is called. After the security mode has been set, it cannot be changed for the current process.