frostfs-api-go/service/v2/verify.pb.go
2020-09-18 10:39:50 +03:00

1156 lines
28 KiB
Go

// Code generated by protoc-gen-gogo. DO NOT EDIT.
// source: service/v2/verify.proto
package v2
import (
fmt "fmt"
proto "github.com/golang/protobuf/proto"
_ "github.com/nspcc-dev/neofs-api-go/acl/v2"
_ "github.com/nspcc-dev/neofs-api-go/refs/v2"
io "io"
math "math"
math_bits "math/bits"
)
// 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.ProtoPackageIsVersion3 // please upgrade the proto package
// Signature of something in NeoFS
type Signature struct {
// Public key used for signing.
Key []byte `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
// Signature
Sign []byte `protobuf:"bytes,2,opt,name=sign,proto3" json:"sign,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Signature) Reset() { *m = Signature{} }
func (m *Signature) String() string { return proto.CompactTextString(m) }
func (*Signature) ProtoMessage() {}
func (*Signature) Descriptor() ([]byte, []int) {
return fileDescriptor_7ea2d606af3f2456, []int{0}
}
func (m *Signature) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
}
func (m *Signature) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
if deterministic {
return xxx_messageInfo_Signature.Marshal(b, m, deterministic)
} else {
b = b[:cap(b)]
n, err := m.MarshalToSizedBuffer(b)
if err != nil {
return nil, err
}
return b[:n], nil
}
}
func (m *Signature) XXX_Merge(src proto.Message) {
xxx_messageInfo_Signature.Merge(m, src)
}
func (m *Signature) XXX_Size() int {
return m.Size()
}
func (m *Signature) XXX_DiscardUnknown() {
xxx_messageInfo_Signature.DiscardUnknown(m)
}
var xxx_messageInfo_Signature proto.InternalMessageInfo
func (m *Signature) GetKey() []byte {
if m != nil {
return m.Key
}
return nil
}
func (m *Signature) GetSign() []byte {
if m != nil {
return m.Sign
}
return nil
}
// Verification info for request signed by all intermediate nodes
type RequestVerificationHeader struct {
// Request Body signature. Should be generated once by request initiator.
BodySignature *Signature `protobuf:"bytes,1,opt,name=body_signature,json=bodySignature,proto3" json:"body_signature,omitempty"`
// Request Meta signature is added and signed by any intermediate node
MetaSignature *Signature `protobuf:"bytes,2,opt,name=meta_signature,json=metaSignature,proto3" json:"meta_signature,omitempty"`
// Sign previous hops
OriginSignature *Signature `protobuf:"bytes,3,opt,name=origin_signature,json=originSignature,proto3" json:"origin_signature,omitempty"`
// Chain of previous hops signatures
Origin *RequestVerificationHeader `protobuf:"bytes,4,opt,name=origin,proto3" json:"origin,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *RequestVerificationHeader) Reset() { *m = RequestVerificationHeader{} }
func (m *RequestVerificationHeader) String() string { return proto.CompactTextString(m) }
func (*RequestVerificationHeader) ProtoMessage() {}
func (*RequestVerificationHeader) Descriptor() ([]byte, []int) {
return fileDescriptor_7ea2d606af3f2456, []int{1}
}
func (m *RequestVerificationHeader) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
}
func (m *RequestVerificationHeader) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
if deterministic {
return xxx_messageInfo_RequestVerificationHeader.Marshal(b, m, deterministic)
} else {
b = b[:cap(b)]
n, err := m.MarshalToSizedBuffer(b)
if err != nil {
return nil, err
}
return b[:n], nil
}
}
func (m *RequestVerificationHeader) XXX_Merge(src proto.Message) {
xxx_messageInfo_RequestVerificationHeader.Merge(m, src)
}
func (m *RequestVerificationHeader) XXX_Size() int {
return m.Size()
}
func (m *RequestVerificationHeader) XXX_DiscardUnknown() {
xxx_messageInfo_RequestVerificationHeader.DiscardUnknown(m)
}
var xxx_messageInfo_RequestVerificationHeader proto.InternalMessageInfo
func (m *RequestVerificationHeader) GetBodySignature() *Signature {
if m != nil {
return m.BodySignature
}
return nil
}
func (m *RequestVerificationHeader) GetMetaSignature() *Signature {
if m != nil {
return m.MetaSignature
}
return nil
}
func (m *RequestVerificationHeader) GetOriginSignature() *Signature {
if m != nil {
return m.OriginSignature
}
return nil
}
func (m *RequestVerificationHeader) GetOrigin() *RequestVerificationHeader {
if m != nil {
return m.Origin
}
return nil
}
// Verification info for response signed by all intermediate nodes
type ResponseVerificationHeader struct {
// Response Body signature. Should be generated once by answering node.
BodySignature *Signature `protobuf:"bytes,1,opt,name=body_signature,json=bodySignature,proto3" json:"body_signature,omitempty"`
// Response Meta signature is added and signed by any intermediate node
MetaSignature *Signature `protobuf:"bytes,2,opt,name=meta_signature,json=metaSignature,proto3" json:"meta_signature,omitempty"`
// Sign previous hops
OriginSignature *Signature `protobuf:"bytes,3,opt,name=origin_signature,json=originSignature,proto3" json:"origin_signature,omitempty"`
// Chain of previous hops signatures
Origin *ResponseVerificationHeader `protobuf:"bytes,4,opt,name=origin,proto3" json:"origin,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ResponseVerificationHeader) Reset() { *m = ResponseVerificationHeader{} }
func (m *ResponseVerificationHeader) String() string { return proto.CompactTextString(m) }
func (*ResponseVerificationHeader) ProtoMessage() {}
func (*ResponseVerificationHeader) Descriptor() ([]byte, []int) {
return fileDescriptor_7ea2d606af3f2456, []int{2}
}
func (m *ResponseVerificationHeader) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
}
func (m *ResponseVerificationHeader) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
if deterministic {
return xxx_messageInfo_ResponseVerificationHeader.Marshal(b, m, deterministic)
} else {
b = b[:cap(b)]
n, err := m.MarshalToSizedBuffer(b)
if err != nil {
return nil, err
}
return b[:n], nil
}
}
func (m *ResponseVerificationHeader) XXX_Merge(src proto.Message) {
xxx_messageInfo_ResponseVerificationHeader.Merge(m, src)
}
func (m *ResponseVerificationHeader) XXX_Size() int {
return m.Size()
}
func (m *ResponseVerificationHeader) XXX_DiscardUnknown() {
xxx_messageInfo_ResponseVerificationHeader.DiscardUnknown(m)
}
var xxx_messageInfo_ResponseVerificationHeader proto.InternalMessageInfo
func (m *ResponseVerificationHeader) GetBodySignature() *Signature {
if m != nil {
return m.BodySignature
}
return nil
}
func (m *ResponseVerificationHeader) GetMetaSignature() *Signature {
if m != nil {
return m.MetaSignature
}
return nil
}
func (m *ResponseVerificationHeader) GetOriginSignature() *Signature {
if m != nil {
return m.OriginSignature
}
return nil
}
func (m *ResponseVerificationHeader) GetOrigin() *ResponseVerificationHeader {
if m != nil {
return m.Origin
}
return nil
}
func init() {
proto.RegisterType((*Signature)(nil), "service.v2.Signature")
proto.RegisterType((*RequestVerificationHeader)(nil), "service.v2.RequestVerificationHeader")
proto.RegisterType((*ResponseVerificationHeader)(nil), "service.v2.ResponseVerificationHeader")
}
func init() { proto.RegisterFile("service/v2/verify.proto", fileDescriptor_7ea2d606af3f2456) }
var fileDescriptor_7ea2d606af3f2456 = []byte{
// 339 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x12, 0x2f, 0x4e, 0x2d, 0x2a,
0xcb, 0x4c, 0x4e, 0xd5, 0x2f, 0x33, 0xd2, 0x2f, 0x4b, 0x2d, 0xca, 0x4c, 0xab, 0xd4, 0x2b, 0x28,
0xca, 0x2f, 0xc9, 0x17, 0xe2, 0x82, 0x4a, 0xe8, 0x95, 0x19, 0x49, 0x09, 0x25, 0x26, 0xe7, 0x80,
0x14, 0x94, 0x54, 0x16, 0xa4, 0x16, 0x43, 0xe4, 0xa5, 0x84, 0x8b, 0x52, 0xd3, 0x8a, 0xd1, 0x04,
0x95, 0x0c, 0xb9, 0x38, 0x83, 0x33, 0xd3, 0xf3, 0x12, 0x4b, 0x4a, 0x8b, 0x52, 0x85, 0x04, 0xb8,
0x98, 0xb3, 0x53, 0x2b, 0x25, 0x18, 0x15, 0x18, 0x35, 0x78, 0x82, 0x40, 0x4c, 0x21, 0x21, 0x2e,
0x96, 0xe2, 0xcc, 0xf4, 0x3c, 0x09, 0x26, 0xb0, 0x10, 0x98, 0xad, 0x34, 0x83, 0x89, 0x4b, 0x32,
0x28, 0xb5, 0xb0, 0x34, 0xb5, 0xb8, 0x24, 0x0c, 0x64, 0x7f, 0x66, 0x72, 0x62, 0x49, 0x66, 0x7e,
0x9e, 0x47, 0x6a, 0x62, 0x4a, 0x6a, 0x91, 0x90, 0x0d, 0x17, 0x5f, 0x52, 0x7e, 0x4a, 0x65, 0x7c,
0x31, 0xcc, 0x54, 0xb0, 0x71, 0xdc, 0x46, 0xa2, 0x7a, 0x08, 0xe7, 0xe9, 0xc1, 0xad, 0x0c, 0xe2,
0x05, 0x29, 0x46, 0xb8, 0xc0, 0x86, 0x8b, 0x2f, 0x37, 0xb5, 0x24, 0x11, 0x49, 0x37, 0x13, 0x5e,
0xdd, 0x20, 0xc5, 0x08, 0xdd, 0x0e, 0x5c, 0x02, 0xf9, 0x45, 0x99, 0xe9, 0x99, 0x79, 0x48, 0xfa,
0x99, 0xf1, 0xe9, 0xe7, 0x87, 0x28, 0x47, 0x98, 0x60, 0xcb, 0xc5, 0x06, 0x11, 0x92, 0x60, 0x01,
0xeb, 0x53, 0x45, 0xd6, 0x87, 0xd3, 0xd3, 0x41, 0x50, 0x4d, 0x4a, 0xb3, 0x98, 0xb8, 0xa4, 0x82,
0x52, 0x8b, 0x0b, 0xf2, 0xf3, 0x8a, 0x53, 0x87, 0x5d, 0xd8, 0xd8, 0xa1, 0x85, 0x8d, 0x1a, 0x6a,
0xd8, 0xe0, 0xf2, 0x35, 0x2c, 0x70, 0x9c, 0x82, 0x4e, 0x3c, 0x92, 0x63, 0xbc, 0xf0, 0x48, 0x8e,
0xf1, 0xc1, 0x23, 0x39, 0xc6, 0x19, 0x8f, 0xe5, 0x18, 0xa2, 0x74, 0xd2, 0x33, 0x4b, 0x32, 0x4a,
0x93, 0xf4, 0x92, 0xf3, 0x73, 0xf5, 0xf3, 0x8a, 0x0b, 0x92, 0x93, 0x75, 0x53, 0x52, 0xcb, 0xf4,
0xf3, 0x52, 0xf3, 0xd3, 0x8a, 0x75, 0x13, 0x0b, 0x32, 0x75, 0xd3, 0xf3, 0xf5, 0x11, 0x89, 0x7d,
0x15, 0x93, 0xa0, 0x5f, 0x6a, 0xbe, 0x5b, 0xb0, 0x9e, 0x63, 0x80, 0xa7, 0x5e, 0x30, 0x44, 0x38,
0x89, 0x0d, 0x9c, 0x8a, 0x8d, 0x01, 0x01, 0x00, 0x00, 0xff, 0xff, 0x0e, 0xde, 0xf9, 0x4c, 0x15,
0x03, 0x00, 0x00,
}
func (m *Signature) Marshal() (dAtA []byte, err error) {
size := m.Size()
dAtA = make([]byte, size)
n, err := m.MarshalToSizedBuffer(dAtA[:size])
if err != nil {
return nil, err
}
return dAtA[:n], nil
}
func (m *Signature) MarshalTo(dAtA []byte) (int, error) {
size := m.Size()
return m.MarshalToSizedBuffer(dAtA[:size])
}
func (m *Signature) MarshalToSizedBuffer(dAtA []byte) (int, error) {
i := len(dAtA)
_ = i
var l int
_ = l
if m.XXX_unrecognized != nil {
i -= len(m.XXX_unrecognized)
copy(dAtA[i:], m.XXX_unrecognized)
}
if len(m.Sign) > 0 {
i -= len(m.Sign)
copy(dAtA[i:], m.Sign)
i = encodeVarintVerify(dAtA, i, uint64(len(m.Sign)))
i--
dAtA[i] = 0x12
}
if len(m.Key) > 0 {
i -= len(m.Key)
copy(dAtA[i:], m.Key)
i = encodeVarintVerify(dAtA, i, uint64(len(m.Key)))
i--
dAtA[i] = 0xa
}
return len(dAtA) - i, nil
}
func (m *RequestVerificationHeader) Marshal() (dAtA []byte, err error) {
size := m.Size()
dAtA = make([]byte, size)
n, err := m.MarshalToSizedBuffer(dAtA[:size])
if err != nil {
return nil, err
}
return dAtA[:n], nil
}
func (m *RequestVerificationHeader) MarshalTo(dAtA []byte) (int, error) {
size := m.Size()
return m.MarshalToSizedBuffer(dAtA[:size])
}
func (m *RequestVerificationHeader) MarshalToSizedBuffer(dAtA []byte) (int, error) {
i := len(dAtA)
_ = i
var l int
_ = l
if m.XXX_unrecognized != nil {
i -= len(m.XXX_unrecognized)
copy(dAtA[i:], m.XXX_unrecognized)
}
if m.Origin != nil {
{
size, err := m.Origin.MarshalToSizedBuffer(dAtA[:i])
if err != nil {
return 0, err
}
i -= size
i = encodeVarintVerify(dAtA, i, uint64(size))
}
i--
dAtA[i] = 0x22
}
if m.OriginSignature != nil {
{
size, err := m.OriginSignature.MarshalToSizedBuffer(dAtA[:i])
if err != nil {
return 0, err
}
i -= size
i = encodeVarintVerify(dAtA, i, uint64(size))
}
i--
dAtA[i] = 0x1a
}
if m.MetaSignature != nil {
{
size, err := m.MetaSignature.MarshalToSizedBuffer(dAtA[:i])
if err != nil {
return 0, err
}
i -= size
i = encodeVarintVerify(dAtA, i, uint64(size))
}
i--
dAtA[i] = 0x12
}
if m.BodySignature != nil {
{
size, err := m.BodySignature.MarshalToSizedBuffer(dAtA[:i])
if err != nil {
return 0, err
}
i -= size
i = encodeVarintVerify(dAtA, i, uint64(size))
}
i--
dAtA[i] = 0xa
}
return len(dAtA) - i, nil
}
func (m *ResponseVerificationHeader) Marshal() (dAtA []byte, err error) {
size := m.Size()
dAtA = make([]byte, size)
n, err := m.MarshalToSizedBuffer(dAtA[:size])
if err != nil {
return nil, err
}
return dAtA[:n], nil
}
func (m *ResponseVerificationHeader) MarshalTo(dAtA []byte) (int, error) {
size := m.Size()
return m.MarshalToSizedBuffer(dAtA[:size])
}
func (m *ResponseVerificationHeader) MarshalToSizedBuffer(dAtA []byte) (int, error) {
i := len(dAtA)
_ = i
var l int
_ = l
if m.XXX_unrecognized != nil {
i -= len(m.XXX_unrecognized)
copy(dAtA[i:], m.XXX_unrecognized)
}
if m.Origin != nil {
{
size, err := m.Origin.MarshalToSizedBuffer(dAtA[:i])
if err != nil {
return 0, err
}
i -= size
i = encodeVarintVerify(dAtA, i, uint64(size))
}
i--
dAtA[i] = 0x22
}
if m.OriginSignature != nil {
{
size, err := m.OriginSignature.MarshalToSizedBuffer(dAtA[:i])
if err != nil {
return 0, err
}
i -= size
i = encodeVarintVerify(dAtA, i, uint64(size))
}
i--
dAtA[i] = 0x1a
}
if m.MetaSignature != nil {
{
size, err := m.MetaSignature.MarshalToSizedBuffer(dAtA[:i])
if err != nil {
return 0, err
}
i -= size
i = encodeVarintVerify(dAtA, i, uint64(size))
}
i--
dAtA[i] = 0x12
}
if m.BodySignature != nil {
{
size, err := m.BodySignature.MarshalToSizedBuffer(dAtA[:i])
if err != nil {
return 0, err
}
i -= size
i = encodeVarintVerify(dAtA, i, uint64(size))
}
i--
dAtA[i] = 0xa
}
return len(dAtA) - i, nil
}
func encodeVarintVerify(dAtA []byte, offset int, v uint64) int {
offset -= sovVerify(v)
base := offset
for v >= 1<<7 {
dAtA[offset] = uint8(v&0x7f | 0x80)
v >>= 7
offset++
}
dAtA[offset] = uint8(v)
return base
}
func (m *Signature) Size() (n int) {
if m == nil {
return 0
}
var l int
_ = l
l = len(m.Key)
if l > 0 {
n += 1 + l + sovVerify(uint64(l))
}
l = len(m.Sign)
if l > 0 {
n += 1 + l + sovVerify(uint64(l))
}
if m.XXX_unrecognized != nil {
n += len(m.XXX_unrecognized)
}
return n
}
func (m *RequestVerificationHeader) Size() (n int) {
if m == nil {
return 0
}
var l int
_ = l
if m.BodySignature != nil {
l = m.BodySignature.Size()
n += 1 + l + sovVerify(uint64(l))
}
if m.MetaSignature != nil {
l = m.MetaSignature.Size()
n += 1 + l + sovVerify(uint64(l))
}
if m.OriginSignature != nil {
l = m.OriginSignature.Size()
n += 1 + l + sovVerify(uint64(l))
}
if m.Origin != nil {
l = m.Origin.Size()
n += 1 + l + sovVerify(uint64(l))
}
if m.XXX_unrecognized != nil {
n += len(m.XXX_unrecognized)
}
return n
}
func (m *ResponseVerificationHeader) Size() (n int) {
if m == nil {
return 0
}
var l int
_ = l
if m.BodySignature != nil {
l = m.BodySignature.Size()
n += 1 + l + sovVerify(uint64(l))
}
if m.MetaSignature != nil {
l = m.MetaSignature.Size()
n += 1 + l + sovVerify(uint64(l))
}
if m.OriginSignature != nil {
l = m.OriginSignature.Size()
n += 1 + l + sovVerify(uint64(l))
}
if m.Origin != nil {
l = m.Origin.Size()
n += 1 + l + sovVerify(uint64(l))
}
if m.XXX_unrecognized != nil {
n += len(m.XXX_unrecognized)
}
return n
}
func sovVerify(x uint64) (n int) {
return (math_bits.Len64(x|1) + 6) / 7
}
func sozVerify(x uint64) (n int) {
return sovVerify(uint64((x << 1) ^ uint64((int64(x) >> 63))))
}
func (m *Signature) Unmarshal(dAtA []byte) error {
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowVerify
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return fmt.Errorf("proto: Signature: wiretype end group for non-group")
}
if fieldNum <= 0 {
return fmt.Errorf("proto: Signature: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType)
}
var byteLen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowVerify
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
byteLen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if byteLen < 0 {
return ErrInvalidLengthVerify
}
postIndex := iNdEx + byteLen
if postIndex < 0 {
return ErrInvalidLengthVerify
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
m.Key = append(m.Key[:0], dAtA[iNdEx:postIndex]...)
if m.Key == nil {
m.Key = []byte{}
}
iNdEx = postIndex
case 2:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field Sign", wireType)
}
var byteLen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowVerify
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
byteLen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if byteLen < 0 {
return ErrInvalidLengthVerify
}
postIndex := iNdEx + byteLen
if postIndex < 0 {
return ErrInvalidLengthVerify
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
m.Sign = append(m.Sign[:0], dAtA[iNdEx:postIndex]...)
if m.Sign == nil {
m.Sign = []byte{}
}
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := skipVerify(dAtA[iNdEx:])
if err != nil {
return err
}
if skippy < 0 {
return ErrInvalidLengthVerify
}
if (iNdEx + skippy) < 0 {
return ErrInvalidLengthVerify
}
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
iNdEx += skippy
}
}
if iNdEx > l {
return io.ErrUnexpectedEOF
}
return nil
}
func (m *RequestVerificationHeader) Unmarshal(dAtA []byte) error {
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowVerify
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return fmt.Errorf("proto: RequestVerificationHeader: wiretype end group for non-group")
}
if fieldNum <= 0 {
return fmt.Errorf("proto: RequestVerificationHeader: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field BodySignature", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowVerify
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return ErrInvalidLengthVerify
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return ErrInvalidLengthVerify
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
if m.BodySignature == nil {
m.BodySignature = &Signature{}
}
if err := m.BodySignature.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
iNdEx = postIndex
case 2:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field MetaSignature", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowVerify
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return ErrInvalidLengthVerify
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return ErrInvalidLengthVerify
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
if m.MetaSignature == nil {
m.MetaSignature = &Signature{}
}
if err := m.MetaSignature.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
iNdEx = postIndex
case 3:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field OriginSignature", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowVerify
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return ErrInvalidLengthVerify
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return ErrInvalidLengthVerify
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
if m.OriginSignature == nil {
m.OriginSignature = &Signature{}
}
if err := m.OriginSignature.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
iNdEx = postIndex
case 4:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field Origin", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowVerify
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return ErrInvalidLengthVerify
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return ErrInvalidLengthVerify
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
if m.Origin == nil {
m.Origin = &RequestVerificationHeader{}
}
if err := m.Origin.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := skipVerify(dAtA[iNdEx:])
if err != nil {
return err
}
if skippy < 0 {
return ErrInvalidLengthVerify
}
if (iNdEx + skippy) < 0 {
return ErrInvalidLengthVerify
}
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
iNdEx += skippy
}
}
if iNdEx > l {
return io.ErrUnexpectedEOF
}
return nil
}
func (m *ResponseVerificationHeader) Unmarshal(dAtA []byte) error {
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowVerify
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return fmt.Errorf("proto: ResponseVerificationHeader: wiretype end group for non-group")
}
if fieldNum <= 0 {
return fmt.Errorf("proto: ResponseVerificationHeader: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field BodySignature", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowVerify
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return ErrInvalidLengthVerify
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return ErrInvalidLengthVerify
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
if m.BodySignature == nil {
m.BodySignature = &Signature{}
}
if err := m.BodySignature.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
iNdEx = postIndex
case 2:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field MetaSignature", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowVerify
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return ErrInvalidLengthVerify
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return ErrInvalidLengthVerify
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
if m.MetaSignature == nil {
m.MetaSignature = &Signature{}
}
if err := m.MetaSignature.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
iNdEx = postIndex
case 3:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field OriginSignature", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowVerify
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return ErrInvalidLengthVerify
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return ErrInvalidLengthVerify
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
if m.OriginSignature == nil {
m.OriginSignature = &Signature{}
}
if err := m.OriginSignature.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
iNdEx = postIndex
case 4:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field Origin", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowVerify
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return ErrInvalidLengthVerify
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return ErrInvalidLengthVerify
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
if m.Origin == nil {
m.Origin = &ResponseVerificationHeader{}
}
if err := m.Origin.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := skipVerify(dAtA[iNdEx:])
if err != nil {
return err
}
if skippy < 0 {
return ErrInvalidLengthVerify
}
if (iNdEx + skippy) < 0 {
return ErrInvalidLengthVerify
}
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
iNdEx += skippy
}
}
if iNdEx > l {
return io.ErrUnexpectedEOF
}
return nil
}
func skipVerify(dAtA []byte) (n int, err error) {
l := len(dAtA)
iNdEx := 0
depth := 0
for iNdEx < l {
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return 0, ErrIntOverflowVerify
}
if iNdEx >= l {
return 0, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= (uint64(b) & 0x7F) << shift
if b < 0x80 {
break
}
}
wireType := int(wire & 0x7)
switch wireType {
case 0:
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return 0, ErrIntOverflowVerify
}
if iNdEx >= l {
return 0, io.ErrUnexpectedEOF
}
iNdEx++
if dAtA[iNdEx-1] < 0x80 {
break
}
}
case 1:
iNdEx += 8
case 2:
var length int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return 0, ErrIntOverflowVerify
}
if iNdEx >= l {
return 0, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
length |= (int(b) & 0x7F) << shift
if b < 0x80 {
break
}
}
if length < 0 {
return 0, ErrInvalidLengthVerify
}
iNdEx += length
case 3:
depth++
case 4:
if depth == 0 {
return 0, ErrUnexpectedEndOfGroupVerify
}
depth--
case 5:
iNdEx += 4
default:
return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
}
if iNdEx < 0 {
return 0, ErrInvalidLengthVerify
}
if depth == 0 {
return iNdEx, nil
}
}
return 0, io.ErrUnexpectedEOF
}
var (
ErrInvalidLengthVerify = fmt.Errorf("proto: negative length found during unmarshaling")
ErrIntOverflowVerify = fmt.Errorf("proto: integer overflow")
ErrUnexpectedEndOfGroupVerify = fmt.Errorf("proto: unexpected end of group")
)