checkPolicy

fun checkPolicy(type: AccessType, domain: AccessDomain, path: Path, scope: AccessScope = AccessScope.UNSPECIFIED): AccessResponse

Subclass API: Policy check.

This method is defined by a given subclass implementation of the VFS system, and is charged with evaluating guest I/O policy for a given request. This method is called by enforce when the request is deemed sane, and the policy check is the only remaining step.

Return

Response from the policy check, indicating whether the request is allowed.

Parameters

type

Type of access which are being requested.

domain

Access domain for this request: is it coming from the guest, or the host?

path

Path to the file or directory being accessed.

scope

Whether this path is known to be a file, or directory, or it is not known.


abstract fun checkPolicy(request: AccessRequest): AccessResponse

Subclass API: Policy check.

This method is defined by a given subclass implementation of the VFS system, and is charged with evaluating guest I/O policy for a given request. This method is called by enforce when the request is deemed sane, and the policy check is the only remaining step.

Return

Response from the policy check, indicating whether the request is allowed.

Parameters

request

Materialized I/O policy check request.