diff --git a/doc/Architecture.md b/doc/Architecture.md index 65355290..6f4a61cc 100644 --- a/doc/Architecture.md +++ b/doc/Architecture.md @@ -65,6 +65,12 @@ The *snpdriver* interfaces with the AMD SEV-SNP SP. It retrieves SNP measurement an SNP attestation report as well as the certificate chain for this attestation report from the respective AMD servers. Currently, it can only act as *Measurement* interface. +__sgxdriver:__ +The *sgxdriver* interfaces with the Intel SGX CPU. It retrieves SGX measurements in the form of an SGX attestation report signed by the SGX quoting enclave. It implements a small caching mechanism to fetch and store the certificate chain used for report verification from the Intel SGX API. Currently, the driver only acts as a *Measurement* interface. + +__tdxdriver:__ +*Will be implemented as soon as Intel TDX hardware is available.* + __swdriver:__ The *swdriver* simply creates keys in software for testing purposes and can be used as *Signer* interface. **Note**: This should mainly be used for testing purposes. diff --git a/doc/architecture.drawio b/doc/architecture.drawio index 3c265bf6..0601147c 100644 --- a/doc/architecture.drawio +++ b/doc/architecture.drawio @@ -1 +1,139 @@ -7Vvtc6I4GP9rnNn90A4QsfZjq7V7M+tu5+zcXT+mEDC3gXAhvu1ffwkEIYZat6LSujqj5EmIye95f4IdMIiW9wwm0zH1Eek4lr/sgGHHcWzQ7YsvSVnllH7Xzgkhw74aVBIm+CdSREtRZ9hHqTaQU0o4TnSiR+MYeVyjQcboQh8WUKL/agJDZBAmHiQm9W/s86nahWuV9C8Ih9Pil21L9USwGKwI6RT6dFEhgbsOGDBKeX4VLQeISPAKXPL7Ri/0rhfGUMx3ueHb6JElkD/RyXg4jOF0cf/z+4VznU8zh2SmdqxWy1cFBIzOYh/JWawOuF1MMUeTBHqydyGYLmhTHhHRssVlQGOuuGjL4QEmZEAJZdlcwHdR3+8KesoZ/YEqPX3nGfR6osfcl9rqHDGOlhWS2uc9ohHibCWGLHXhUTIHivai5KDTV7RphXsFV6ESmnA9c4mruFDQ/grMznFhDlz5VuMq9PxVB38vezULfwXutVocB277rOC+Pjne1lnhrVuXGvRrjcuaTY3Df2WAjXzhxFSTMj6lIY0huSuptzo7yj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Bozt7SmAcfj4NQu8jxNhU7cOeBO56vu78WjRxYV1egeIc6izO3Htbh+tH7kcNbfqGGc0DmMz/MZQIsd4vkWkkcdF52jN9z3GPUJ0659NkttfmR+nAVd2TjCb69sHQNw+DKkdogyLCPkBsRlDAWxeZbWgHqNGO2gdND6cdZrrUrHY0IdPdtgm1mZLk0ZCgPQj3Lv8BcSYCvelb6yT6uKfP5qNF2Znhyd3iBk7OqXEyq8s346EU4MlDC9BqGViHtpIn+VPP5rOlJ7eroOa8n81Snh1LjzCLLors3PoCmZ8HEedhZ50d7KwNjqoTZjay9n1WkFVPwvyh4bwml/OtWl+tJC9Zainzl3Mutdax9KhlusIe1JZas2pqwugc++jAGvhOGFbnlpp6SkQ0yz+y5gWE8u/A4O5/ \ No newline at end of file + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/doc/architecture.drawio.svg b/doc/architecture.drawio.svg index 197e804b..73b8807b 100644 --- a/doc/architecture.drawio.svg +++ b/doc/architecture.drawio.svg @@ -1,4 +1,4 @@ - + -Generate(), Sign(), Verify()Generate(), Sign(), Verify()cmcdcmcd/dev/sev-guest/dev/sev-guestSNP driverSNP driverSoftware driverSoftware driv.../dev/tpm0/dev/tpm0TPM driverTPM driverOne or multiple drivers can be used at onceOne or multiple drivers can be...aTLSaTLStesttool (client)testtool (client)testtool (server)testtool (server)CMC Interface (gRPC)CMC Interface (gRPC)Daemon reachable to attesting / verifying componentsDaemon reachable to attesting...Example application making use of the cmcdExample application making us...Measurer and/or Signer Interface (golang)Measurer and/or...attestationreportattestationreportSoftware ComponentSoftware Componentgolang Packagegolang PackageTPMTPMAMD PSPAMD PSPTrusted Firm- and HardwareTrusted Firm- and HardwarePackage for generating and verifying attestation reportsPackage for generating and ve...Example of provided HardwareExample of provided HardwareText is not SVG - cannot display \ No newline at end of file +Generate(), Sign(), Verify()cmcd/dev/sev-guestSNP driverSGX driver/dev/tpm0TPM driverOne or multiple drivers can be used at onceaTLStesttool (client)testtool (server)CMC Interface (gRPC)Daemon reachable to attesting / verifying componentsExample application making use of the cmcdMeasurer and/or Signer Interface (golang)attestationreportSoftware Componentgolang PackageTPMAMD PSPTrusted Firm- and HardwarePackage for generating and verifying attestation reportsExample of provided HardwareIntel SGX CPUSoftware driver \ No newline at end of file diff --git a/doc/attestation_report.drawio b/doc/attestation_report.drawio index 01bfb5cc..a908566d 100644 --- a/doc/attestation_report.drawio +++ b/doc/attestation_report.drawio @@ -1 +1,629 @@ -7V1Zd5s4G/41PmfmIjnsy2XiZmknSd04X9LpzXdkI9s0GBzAcdxfPxKLDZJYbANeQmdOawRi0fNIeje96ojd6ceNC2aTe8eAVkfgjI+O+KUjCJKuob9xwTIs4HWJD0vGrmlEZeuCvvkHpgvnpgG9VJHvOJZvztKFQ8e24dBPlQHXdRbpy0aOFT2UCwtmYJx+IC7oD4FFl76Yhj8JSzU5Uf0WmuNJ/GSei85MQXxxVOBNgOEsEkXiVUfsuo7jh7+mH11o4bYzU294nXF29WIutP0yFYD0ML/p/ZKXxqX3+mTcPbw9u2e8EN7mHVjz6Iujt/WXcRO4ztw2IL4L1xEvFxPTh/0ZGOKzC4Q5Kpv4Uwsd8ejnyLH9rmM5blBX5II/uNy0rLjcgCMwt9BLX9LfEH3WO3R9+JEoir7pBjpT6LtLdEl0VpfEsEpEsDM5xmaxxksXo8+aJLCSImqCiCLj1b3XrYh+RA3JbtSbr/KP7vD9Vr9aeD8fnmfWXf8WNapOterFbIYK7oFtjqDnU23sLcypBWwYtWA/OoNbbjgxLeMOLJ05fm/PB8PX+Ohy4rjmH3Q9iJsfnXb9qBMJSuqKPq4Z3dOFHrqmF7c7TxTdg4/UhXfA8+O3cSwLzDxzELwfrjgF7ti0Lx3fd6bRRUmwEQkMGWqGFLyd67zCxBlNGIiKUg0Re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wGoN+X1lBXofkpDjIHNIi5SmVHn8zPWqInoUjVClNaop0okA6Z2FfTviuAGSdTAovq7S2I0Q7eqW1nc0zmqJD18FTzlrqw8DcOwbEV/wH \ No newline at end of file + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/doc/attestation_report.drawio.svg b/doc/attestation_report.drawio.svg index d3c53e69..0beeaccb 100644 --- a/doc/attestation_report.drawio.svg +++ b/doc/attestation_report.drawio.svg @@ -1,4 +1,4 @@ - + -App ManifestType: App ManifestName (unique)VersionOSs (list)Reference Values (list)...App DescriptionType: App DescriptionName (unique)App Manifest...Device DescriptionType: Device DescriptionFQDN (unique)App Descriptions (list)OS ManifestRTM Manifest...Attestation ReportType: Attestation ReportVersion (of AR Scheme)Measurements (list)RTM ManifestOS ManifestApp Manifests (list)Device Description...Software Reference ValueType: SW Reference ValueNameSHA-512TPM MeasurementType: TPM MeasurementTPM Quote [Nonce, ...]Hash Chain (list)Certificate ChainSoftware MeasurementType: SW MeasurementNameSHA-512RTM ManifestType: RTM ManifestName (unique)VersionReference Values (list)...OS ManifestType: OS ManifestName (unique)VersionRTMs (list)Reference Values (list)...Following blockdirectly integratedFollowing...Hash ChainType: Hash ChainPCR (int)SHA256 (list)Link to the following blockthrough unique nameLink to the following b...SNP MeasurementType: SNP MeasurementSNP Report [Nonce, ...]Certificate ChainIAS MeasurementType: IAS MeasurementIAT [Nonce, ...]Certificate ChainSNP Reference ValueType: SNP Reference ValueNameSHA-384SNP MetadataTPM Reference ValueType: TPM Reference ValueNameSHA-256PCR (int)signed by operator andpossibly certifierssigned by operator and...Signed by the HW Trust Anchor, generated at runtimeSigned by the HW Trust Anc...Signed by the device, generated at runtimeSigned by the device...Signed by software provider and possibly certifiersSigned by software provide...Explanation of Graphical ElementsExplanation of Graphical ElementsText is not SVG - cannot display \ No newline at end of file +App ManifestType: App ManifestName (unique)VersionOSs (list)Reference Values (list)...App DescriptionType: App DescriptionName (unique)App Manifest...Device DescriptionType: Device DescriptionFQDN (unique)App Descriptions (list)OS ManifestRTM Manifest...Attestation ReportType: Attestation ReportVersion (of AR Scheme)Measurements (list)RTM ManifestOS ManifestApp Manifests (list)Device Description...Software Reference ValueType: SW Reference ValueNameSHA-512TPM MeasurementType: TPM MeasurementTPM Quote [Nonce, ...]Hash Chain (list)Certificate ChainSoftware MeasurementType: SW MeasurementNameSHA-512RTM ManifestType: RTM ManifestName (unique)VersionReference Values (list)...OS ManifestType: OS ManifestName (unique)VersionRTMs (list)Reference Values (list)...Following blockdirectly integratedHash ChainType: Hash ChainPCR (int)SHA256 (list)Link to the following blockthrough unique nameSNP MeasurementType: SNP MeasurementSNP Report [Nonce, ...]Certificate ChainIAS MeasurementType: IAS MeasurementIAT [Nonce, ...]Certificate ChainSNP Reference ValueType: SNP Reference ValueNameSHA-384SNP MetadataTPM Reference ValueType: TPM Reference ValueNameSHA-256PCR (int)signed by operator andpossibly certifiersSigned by the HW Trust Anchor, generated at runtimeSigned by the device, generated at runtimeSigned by software provider and possibly certifiersExplanation of Graphical ElementsSGX MeasurementType: SGX MeasurementSGX Report [Nonce, ...]Certificate ChainSGX Reference ValueType: SGX Reference ValueNameSHA-256SGX MetadataTDX Reference ValueType: TDX Reference ValueNameSHA-384TDX MetadataTDX MeasurementType: TDX MeasurementTDX Report [Nonce, ...]Certificate Chain \ No newline at end of file diff --git a/doc/build.md b/doc/build.md index 6edaae13..a191aa75 100644 --- a/doc/build.md +++ b/doc/build.md @@ -77,4 +77,19 @@ go install google.golang.org/protobuf/cmd/protoc-gen-go@v1.28 go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@v1.2 cd grpcapi/ make -``` \ No newline at end of file +``` + +### SGX Build + +The SGX integration is build on top of the [EGo Framework](https://github.com/edgelesssys/ego) for the development of confidential apps in Go. +Since SGX enclaves are designed to execute only one process inside an isolated environment, the libapi implementation has to be used for the generation and verification of attestation reports. + +Once you have developed your application and integrated the cmc library following the instructions provided in the [integration documentation](integration.md), compile, sign and run it like this: +``` +CGO_CFLAGS=-D_FORTIFY_SOURCE=0 ego-go build && ego sign testtool +ego run testtool +``` + +Additional information for the enclave such as heapSize, mount points, security version (ISV SVN) and enclave product ID (ISV Prod ID) can be specified in the enclave.json file. + +See https://docs.edgeless.systems/ego/reference/config for more information. diff --git a/doc/manual-setup.md b/doc/manual-setup.md index fd8c72e4..a212582d 100644 --- a/doc/manual-setup.md +++ b/doc/manual-setup.md @@ -149,7 +149,10 @@ tbd ##### Intel SGX Reference Values -tbs +The reference values for Intel SGX consist of a fingerprint of the Intel Root CA certificate, the TCB Info and QE Identity structures, the enclave product ID (ISV Prod ID), the security version of the enclave (ISVSVN), expected enclave attributes (e.g. DEBUG, Mode64Bit, etc.), a hash of the enclave measurement (MRENCLAVE) and a hash of the enclave signing key (MRSIGNER). + +The Root CA certificate, TCB Info and QE Identity structures can be retrieved from the [Intel API](https://api.portal.trustedservices.intel.com/content/documentation.html). ISV SVN and ISV Prod ID are assigned by the enclave author. The EGo framework sets these values to 1 by default. +The MRENCLAVE and MRSIGNER values for an enclave can be retrieved via the EGo CLI tool with the commands ```ego uniqueid $ENCLAVE_PROGRAM``` and ```ego signerid $ENCLAVE_PROGRAM```. ### 4. Sign the metadata diff --git a/doc/overview.drawio b/doc/overview.drawio index bab21c86..959a408e 100644 --- a/doc/overview.drawio +++ b/doc/overview.drawio @@ -1 +1,177 @@ -7VxdU6s4GP41ndm90AFS2nqp1npmR4+dqTt73JudCGlhDYQNqW3Pr98EQvkIp0ULFK11RslLCOR53q+8ofbAtbe+pTBw7omNcM/Q7HUPjHuGoYP+iP8Rkk0sGfX1WLCgri07pYKZ+xNJoSalS9dGYa4jIwQzN8gLLeL7yGI5GaSUrPLd5gTn7xrABVIEMwtiVfqXazNHzsLUUvk35C6c5M66Js94MOksBaEDbbLKiMBND1xTQlh85K2vERbgJbjE101+cXb7YBT5rMoF3yePNIDsiczux2MfOqvbnw9nxkU8zCvESzlj+bRsk0BAydK3kRhF64GrleMyNAugJc6uOOlc5jAP85bOD+fEZ5JFXXSfuxhfE0xoNBawTTSy+1weMkpeUObMyHgGgwE/o85LTvUVUYbWGZGc5y0iHmJ0w7us88ojdQ4k7VXKoDGSMifDXsIqlEqz2I6c4soPJLRvgdloF+a5KX5kv4w8/pTBP4g+9cKfgXtrFu3ArZ8U3BdHx1s7Kbzz3qUE/VLnsqWpdviHCtjI5kFMNgllDlkQH+KbVHqVpyPtc0dIIEn4FzG2kSzAJSN5itDaZT/E5eembD1lzozXcuSosUkaPp9u5iLRfMqeSy+LWsl1Ngyd6Fn1XQyGZEkttAMnXeYiDNIFYjs6mnE/geJOhaAIQ+a+5lOFMnrlpVPi8mdOFal/cX6R/eT0Sh8V9CWenxyjoDLbh3q/Fo2+tKheLRp8JC26pBRuMt0C0SHccVcz7wUTrzj5RX+jv7M/P4ifoFaV1itkt59M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KoVatF7S0dZQAxS3xSIjuwmlTMqfpa/3xYGGXvDkMy1mD/WHFlrY5vb5SSqSZkD4HwjRDHK2Vv6W9L1ycS9AqkgLKvyRkNBb1SjqoUpt9kcF23Mb3MLLT003+fuQ3fNmzDlqfWqO5cfxvzTtL0hu1ZHm+mX6GPKU3/EQG4+R8= \ No newline at end of file + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/doc/overview.drawio.svg b/doc/overview.drawio.svg index 1769c929..8d27fc6a 100644 --- a/doc/overview.drawio.svg +++ b/doc/overview.drawio.svg @@ -1,4 +1,4 @@ - + -cmcdcmcdSNP driverSNP driverSoftware driverSoftware driv...TPM driverTPM driverOne or multiple drivers can be used at onceOne or multiple drivers can be...aTLSaTLStesttool (client)testtool (client)testtool (server)testtool (server)Daemon reachable to attesting / verifying componentsDaemon reachable to attesting...Example application making use of the cmcdExample application making us...attestationreportattestationreportSoftware ComponentSoftware Componentgolang Packagegolang PackageTPMTPMAMD PSPAMD PSPTrusted Firm- and HardwareTrusted Firm- and HardwarePackage for generating and verifying attestation reportsPackage for generating and ve...Example of provided HardwareExample of provided HardwareOptional CommunicationOptional CommunicationLine of CommunicationLine of CommunicationText is not SVG - cannot display \ No newline at end of file +cmcdSNP driverSGX driverSoftware driverOne or multiple drivers can be used at onceaTLStesttool (client)testtool (server)Daemon reachable to attesting / verifying componentsExample application making use of the cmcdattestationreportSoftware Componentgolang PackageTPMAMD PSPTrusted Firm- and HardwarePackage for generating and verifying attestation reportsExample of provided HardwareOptional CommunicationLine of CommunicationIntel SGX CPUTPM driver \ No newline at end of file diff --git a/doc/sgx-reference-value.drawio b/doc/sgx-reference-value.drawio new file mode 100644 index 00000000..b9c9a099 --- /dev/null +++ b/doc/sgx-reference-value.drawio @@ -0,0 +1,111 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/doc/sgx-reference-value.drawio.svg b/doc/sgx-reference-value.drawio.svg new file mode 100644 index 00000000..4924a1bb --- /dev/null +++ b/doc/sgx-reference-value.drawio.svg @@ -0,0 +1,4 @@ + + + +SGX Reference ValueType: SGX Reference ValueNameSHA-256SGX MetadataSGX MetadataVersionCollateralCA FingerprintISV Prod IDMRSIGNERISV SVNAttributesIntel CollateralTEE TypeTCB InfoTCB Info SizeQE IdentityQE Identity SizeSGX AttributesInnitedDebugMode 64 BitProvision KeyEnclave Init TokenKSSLegacyAVX \ No newline at end of file