/* Copyright The Kubernetes Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: api.proto package v2 import ( fmt "fmt" proto "github.com/gogo/protobuf/proto" math "math" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type EncryptedDEKSourceType int32 const ( // AES_GCM_KEY means that the plaintext of encryptedDEKSource is the DEK itself, with AES-GCM as the encryption algorithm. EncryptedDEKSourceType_AES_GCM_KEY EncryptedDEKSourceType = 0 // HKDF_SHA256_XNONCE_AES_GCM_SEED means that the plaintext of encryptedDEKSource is the pseudo random key // (referred to as the seed throughout the code) that is fed into HKDF expand. SHA256 is the hash algorithm // and first 32 bytes of encryptedData are the info param. The first 32 bytes from the HKDF stream are used // as the DEK with AES-GCM as the encryption algorithm. EncryptedDEKSourceType_HKDF_SHA256_XNONCE_AES_GCM_SEED EncryptedDEKSourceType = 1 ) var EncryptedDEKSourceType_name = map[int32]string{ 0: "AES_GCM_KEY", 1: "HKDF_SHA256_XNONCE_AES_GCM_SEED", } var EncryptedDEKSourceType_value = map[string]int32{ "AES_GCM_KEY": 0, "HKDF_SHA256_XNONCE_AES_GCM_SEED": 1, } func (x EncryptedDEKSourceType) String() string { return proto.EnumName(EncryptedDEKSourceType_name, int32(x)) } func (EncryptedDEKSourceType) EnumDescriptor() ([]byte, []int) { return fileDescriptor_00212fb1f9d3bf1c, []int{0} } // EncryptedObject is the representation of data stored in etcd after envelope encryption. type EncryptedObject struct { // EncryptedData is the encrypted data. EncryptedData []byte `protobuf:"bytes,1,opt,name=encryptedData,proto3" json:"encryptedData,omitempty"` // KeyID is the KMS key ID used for encryption operations. // keyID must satisfy the following constraints: // 1. The keyID is not empty. // 2. The size of keyID is less than 1 kB. KeyID string `protobuf:"bytes,2,opt,name=keyID,proto3" json:"keyID,omitempty"` // EncryptedDEKSource is the ciphertext of the source of the DEK used to encrypt the data stored in encryptedData. // encryptedDEKSourceType defines the process of using the plaintext of this field to determine the aforementioned DEK. // encryptedDEKSource must satisfy the following constraints: // 1. The encrypted DEK source is not empty. // 2. The size of encrypted DEK source is less than 1 kB. EncryptedDEKSource []byte `protobuf:"bytes,3,opt,name=encryptedDEKSource,proto3" json:"encryptedDEKSource,omitempty"` // Annotations is additional metadata that was provided by the KMS plugin. // Annotations must satisfy the following constraints: // 1. Annotation key must be a fully qualified domain name that conforms to the definition in DNS (RFC 1123). // 2. The size of annotations keys + values is less than 32 kB. Annotations map[string][]byte `protobuf:"bytes,4,rep,name=annotations,proto3" json:"annotations,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` // encryptedDEKSourceType defines the process of using the plaintext of encryptedDEKSource to determine the DEK. EncryptedDEKSourceType EncryptedDEKSourceType `protobuf:"varint,5,opt,name=encryptedDEKSourceType,proto3,enum=v2.EncryptedDEKSourceType" json:"encryptedDEKSourceType,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *EncryptedObject) Reset() { *m = EncryptedObject{} } func (m *EncryptedObject) String() string { return proto.CompactTextString(m) } func (*EncryptedObject) ProtoMessage() {} func (*EncryptedObject) Descriptor() ([]byte, []int) { return fileDescriptor_00212fb1f9d3bf1c, []int{0} } func (m *EncryptedObject) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_EncryptedObject.Unmarshal(m, b) } func (m *EncryptedObject) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_EncryptedObject.Marshal(b, m, deterministic) } func (m *EncryptedObject) XXX_Merge(src proto.Message) { xxx_messageInfo_EncryptedObject.Merge(m, src) } func (m *EncryptedObject) XXX_Size() int { return xxx_messageInfo_EncryptedObject.Size(m) } func (m *EncryptedObject) XXX_DiscardUnknown() { xxx_messageInfo_EncryptedObject.DiscardUnknown(m) } var xxx_messageInfo_EncryptedObject proto.InternalMessageInfo func (m *EncryptedObject) GetEncryptedData() []byte { if m != nil { return m.EncryptedData } return nil } func (m *EncryptedObject) GetKeyID() string { if m != nil { return m.KeyID } return "" } func (m *EncryptedObject) GetEncryptedDEKSource() []byte { if m != nil { return m.EncryptedDEKSource } return nil } func (m *EncryptedObject) GetAnnotations() map[string][]byte { if m != nil { return m.Annotations } return nil } func (m *EncryptedObject) GetEncryptedDEKSourceType() EncryptedDEKSourceType { if m != nil { return m.EncryptedDEKSourceType } return EncryptedDEKSourceType_AES_GCM_KEY } func init() { proto.RegisterEnum("v2.EncryptedDEKSourceType", EncryptedDEKSourceType_name, EncryptedDEKSourceType_value) proto.RegisterType((*EncryptedObject)(nil), "v2.EncryptedObject") proto.RegisterMapType((map[string][]byte)(nil), "v2.EncryptedObject.AnnotationsEntry") } func init() { proto.RegisterFile("api.proto", fileDescriptor_00212fb1f9d3bf1c) } var fileDescriptor_00212fb1f9d3bf1c = []byte{ // 329 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x91, 0xe1, 0x4b, 0xc2, 0x40, 0x18, 0xc6, 0xdb, 0xcc, 0xc0, 0xd3, 0x72, 0x1c, 0x21, 0xc3, 0x2f, 0x8d, 0xf2, 0xc3, 0xe8, 0xc3, 0x0e, 0x16, 0x85, 0x44, 0x08, 0xe6, 0xce, 0x0c, 0x49, 0x61, 0xeb, 0x43, 0xf5, 0x65, 0x9c, 0xf6, 0x22, 0x6b, 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