Function sgx_tprotected_fs::export_auto_key[][src]

pub fn export_auto_key(filename: &CStr) -> SysResult<sgx_key_128bit_t>

The export_auto_key function is used for exporting the latest key used for the file encryption.

Description

export_auto_key is used to export the last key that was used in the encryption of the file. With this key you can import the file in a different enclave or system.

Parameters

filename

The name of the file to be exported. This should be the name of a file created with the open_auto_key API.

Requirements

Header: sgx_tprotected_fs.edl

Library: libsgx_tprotected_fs.a

Return value

If the function succeeds, it returns the latest encryption key. otherwise, error code is returned.