Documentation ¶
Index ¶
- func UnsafeDebugForEnclave(sgxs []byte) ([]byte, error)
- type Option
- func WithAttributes(attributes sgx.Attributes) Option
- func WithAttributesMask(attributesMask [2]uint64) Option
- func WithBuildDate(date time.Time) Option
- func WithEnclaveHash(enclaveHash sgx.MrEnclave) Option
- func WithISVProdID(isvProdID uint16) Option
- func WithISVSVN(isvSVN uint16) Option
- func WithMiscSelect(miscSelect uint32) Option
- func WithMiscSelectMask(miscSelectMask uint32) Option
- func WithSwDefined(swDefined [4]byte) Option
- type Sigstruct
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func UnsafeDebugForEnclave ¶
UnsafeDebugForEnclave returns the SIGSTRUCT corresponding to the provided SGX enclave binary, signed using the Fortanix Rust SDK's dummy signing key.
This routine is deterministic, and MUST only ever be used for testing.
Types ¶
type Option ¶
type Option func(*Sigstruct)
Option is an option used when constructing a Sigstruct.
func WithAttributes ¶
func WithAttributes(attributes sgx.Attributes) Option
WithAttributes sets the ATTRIBUTES field.
func WithAttributesMask ¶
WithAttributesMask sets the ATTRIBUTESMASK field.
func WithBuildDate ¶
WithBuildDate sets the BUILDDATE field.
func WithEnclaveHash ¶
WithEnclaveHash sets the ENCLAVEHASH field.
func WithISVProdID ¶
WithISVProdID sets the ISVPRODID field.
func WithMiscSelect ¶
WithMiscSelect sets the MISCSELECT field.
func WithMiscSelectMask ¶
WithMiscSelectMask sets the MISCSELECTMASK field.
func WithSwDefined ¶
WithSwDefined sets the SWDEFINED field.
type Sigstruct ¶
type Sigstruct struct { BuildDate time.Time SwDefined [4]byte MiscSelect uint32 MiscSelectMask uint32 Attributes sgx.Attributes AttributesMask [2]uint64 EnclaveHash sgx.MrEnclave ISVProdID uint16 ISVSVN uint16 }
Sigstruct is an SGX enclave SIGSTRUCT.
The most recent version of the Intel documentation defines more fields that were formerly reserved, however support for setting such things is currently not implemented.