mirror of
https://github.com/ultravioletrs/cocos.git
synced 2026-08-07 07:14:50 +00:00
13f7e97d82
CI / checkproto (push) Has been cancelled
CI / lint (push) Has been cancelled
CI / test (agent) (push) Has been cancelled
CI / test (cli) (push) Has been cancelled
CI / test (cmd) (push) Has been cancelled
CI / test (internal) (push) Has been cancelled
CI / test (manager, true) (push) Has been cancelled
CI / test (pkg) (push) Has been cancelled
CI / upload-coverage (push) Has been cancelled
* feat: add FetchKbsToken RPC support, update protobuf generation, and include additional binaries in CI workflow. Signed-off-by: Sammy Oina <sammyoina@gmail.com> * chore: update protoc version and add GetKbsToken mock method with updated kbsHTTPGet signature Signed-off-by: Sammy Oina <sammyoina@gmail.com> * test: inject mock attestation client into agentService for resource and KBS tests Signed-off-by: Sammy Oina <sammyoina@gmail.com> * test: update key derivation in tests to use Concat KDF instead of HKDF Signed-off-by: Sammy Oina <sammyoina@gmail.com> --------- Signed-off-by: Sammy Oina <sammyoina@gmail.com>
51 lines
1.2 KiB
Protocol Buffer
51 lines
1.2 KiB
Protocol Buffer
syntax = "proto3";
|
|
|
|
package attestation.v1;
|
|
|
|
option go_package = "github.com/ultravioletrs/cocos/internal/proto/attestation/v1;attestation";
|
|
|
|
service AttestationService {
|
|
rpc FetchAttestation (AttestationRequest) returns (AttestationResponse);
|
|
rpc FetchRawEvidence (AttestationRequest) returns (RawEvidenceResponse);
|
|
rpc FetchAzureToken (AzureTokenRequest) returns (AzureTokenResponse);
|
|
rpc FetchKbsToken (KbsTokenRequest) returns (KbsTokenResponse);
|
|
}
|
|
|
|
message KbsTokenRequest {}
|
|
|
|
message KbsTokenResponse {
|
|
bytes token = 1;
|
|
}
|
|
|
|
message AttestationRequest {
|
|
bytes report_data = 1; // 64 bytes for SNP/TDX
|
|
bytes nonce = 2; // Nonce for vTPM
|
|
PlatformType platform_type = 3;
|
|
}
|
|
|
|
message AttestationResponse {
|
|
bytes eat_token = 1; // EAT token (JWT or CBOR format)
|
|
}
|
|
|
|
message RawEvidenceResponse {
|
|
bytes evidence = 1; // Raw binary evidence (for KBS)
|
|
}
|
|
|
|
message AzureTokenRequest {
|
|
bytes nonce = 1;
|
|
}
|
|
|
|
message AzureTokenResponse {
|
|
bytes token = 1;
|
|
}
|
|
|
|
enum PlatformType {
|
|
PLATFORM_TYPE_UNSPECIFIED = 0;
|
|
PLATFORM_TYPE_SNP = 1;
|
|
PLATFORM_TYPE_TDX = 2;
|
|
PLATFORM_TYPE_VTPM = 3;
|
|
PLATFORM_TYPE_SNP_VTPM = 4;
|
|
PLATFORM_TYPE_AZURE = 5;
|
|
PLATFORM_TYPE_NO_CC = 6;
|
|
}
|