19 #ifndef ASYLO_IDENTITY_ATTESTATION_SGX_SGX_LOCAL_ASSERTION_GENERATOR_H_ 20 #define ASYLO_IDENTITY_ATTESTATION_SGX_SGX_LOCAL_ASSERTION_GENERATOR_H_ 24 #include "asylo/identity/additional_authenticated_data_generator.h" 25 #include "asylo/identity/attestation/enclave_assertion_generator.h" 26 #include "asylo/identity/attestation/sgx/internal/local_assertion.pb.h" 27 #include "asylo/util/mutex_guarded.h" 37 class SgxLocalAssertionGenerator
final :
public EnclaveAssertionGenerator {
71 StatusOr<sgx::LocalAssertionRequestAdditionalInfo> ParseAdditionalInfo(
72 const AssertionRequest &request)
const;
75 static constexpr EnclaveIdentityType kIdentityType = CODE_IDENTITY;
78 static const char *
const kAuthorityType;
84 std::string attestation_domain;
87 std::unique_ptr<AdditionalAuthenticatedDataGenerator> aad_generator;
92 Members() : initialized(
false) {}
95 MutexGuarded<Members> members_;
Status Initialize(const std::string &config) override
Initializes this assertion authority using the provided config.
Status CreateAssertionOffer(AssertionOffer *offer) const override
Creates an assertion offer compatible with this generator's identity type and authority type and plac...
SgxLocalAssertionGenerator()
Constructs an uninitialized SgxLocalAssertionGenerator.
StatusOr< bool > CanGenerate(const AssertionRequest &request) const override
Indicates whether the assertion requested in request can be generated by this generator.
ABSL_CONST_INIT const char kStatusMoveAssignmentMsg[]
Status Generate(const std::string &user_data, const AssertionRequest &request, Assertion *assertion) const override
Generates an assertion that satisfies the given request, if request is compatible with this generator...
std::string AuthorityType() const override
Gets the type of this assertion authority.
EnclaveIdentityType IdentityType() const override
Gets the enclave identity type handled by this assertion authority.
bool IsInitialized() const override
Indicates whether this assertion authority has been initialized successfully via a call to Initialize...