load

static EnclaveHost load(String enclaveClassName)

Load the signed enclave for the given enclave class name.

Parameters

enclaveClassName

The name of the enclave class to load.

Throws

if there is no enclave file for the given class name.

if more than one enclave file is found.

if the enclave does not load correctly or if the platform does not support hardware enclaves or if enclave support is disabled.

if the mode is not mock and the host OS is not Linux or if the CPU doesn't support SGX enclave in simulation mode or higher.

static EnclaveHost load()

Scan the classpath and load the single signed enclave that is found.

Throws

if no enclave file is found or more than one enclave file is found.

if the enclave does not load correctly or if the platform does not support hardware enclaves or if enclave support is disabled.

if the mode is not mock and the host OS is not Linux or if the CPU doesn't support SGX enclave in simulation mode or higher.

static EnclaveHost load(String enclaveClassName, MockConfiguration mockConfiguration)

Load the signed enclave for the given enclave class name.

Parameters

enclaveClassName

The name of the enclave class to load.

mockConfiguration

Defines the configuration to use when loading the enclave in mock mode. If no configuration is provided when using mock mode then a default set of configuration parameters are used. This parameter is ignored when not using mock mode.

Throws

if there is no enclave file for the given class name or if an unexpected error occurs when trying to check platform support.

if more than one enclave file is found.

if the enclave does not load correctly or if the platform does not support enclaves in the required mode.

if the mode is not mock and the host OS is not Linux or if the CPU doesn't support SGX enclave in simulation mode or higher.

static EnclaveHost load(MockConfiguration mockConfiguration)

Scan the classpath and load the single signed enclave that is found.

Parameters

mockConfiguration

Defines the configuration to use when loading the enclave in mock mode. If no configuration is provided when using mock mode then a default set of configuration parameters are used. This parameter is ignored when not using mock mode.

Throws

if no enclave file is found or if more than one enclave file is found.

if the enclave does not load correctly or if the platform does not support enclaves in the required mode.

if the mode is not mock and the host OS is not Linux or if the CPU doesn't support SGX enclave in simulation mode or higher.