1
0
mirror of https://github.com/getsops/sops.git synced 2026-02-05 12:45:21 +01:00
Files
sops/keyservice/keyservice.proto
2018-06-17 22:50:30 +02:00

54 lines
821 B
Protocol Buffer

syntax = "proto3";
message Key {
oneof key_type {
KmsKey kms_key = 1;
PgpKey pgp_key = 2;
GcpKmsKey gcp_kms_key = 3;
AzureKeyVaultKey azure_keyvault_key = 4;
}
}
message PgpKey {
string fingerprint = 1;
}
message KmsKey {
string arn = 1;
string role = 2;
map<string, string> context = 3;
}
message GcpKmsKey {
string resource_id = 1;
}
message AzureKeyVaultKey {
string vault_url = 1;
string name = 2;
string version = 3;
}
message EncryptRequest {
Key key = 1;
bytes plaintext = 2;
}
message EncryptResponse {
bytes ciphertext = 1;
}
message DecryptRequest {
Key key = 1;
bytes ciphertext = 2;
}
message DecryptResponse {
bytes plaintext = 1;
}
service KeyService {
rpc Encrypt (EncryptRequest) returns (EncryptResponse) {}
rpc Decrypt (DecryptRequest) returns (DecryptResponse) {}
}