Device Access example

The Device Access example demonstrates use of the Privilege Separation pattern.

Example architecture

The example contains the following three entities: Device, LoginManager and Storage.

In this example, the Device entity queries the Storage entity to receive information and queries the LoginManager entity for authorization.

The Device entity obtains access to the Storage entity after successful authorization.

secure_logger_uml

This example demonstrates the capability to separate the authorization logic and the data access logic into independent security domains. This separation guarantees that data access can be opened only after successful authorization. The security module monitors whether authorization was successfully completed. This architecture also enables independent development and testing of the authorization logic and the data access provision logic.

A security policy in the Device Access example has the following characteristics:

Building the example

The example is built using the CMake build system that is included in KasperskyOS Community Edition.

Files containing the code of the example and build scripts are available at the following path:

/opt/KasperskyOS-Community-Edition-<version>/examples/device_access

To build and run the example, run the following script:

/opt/KasperskyOS-Community-Edition-<version>/examples/device_access/cross-build.sh

In this section

Description files in the Device Access example

Implementation of the Device entity in the Device Access example

Implementation of the Storage entity in the Device Access example

Implementation of the LoginManager entity in the Device Access example

Page top