daemon: use per-interface features

Signed-off-by: Steffen Vogel <post@steffenvogel.de>
This commit is contained in:
Steffen Vogel
2022-09-30 08:32:26 +02:00
parent 70e437d9a6
commit 92a7ad2f7f
99 changed files with 3510 additions and 2599 deletions

View File

@@ -22,16 +22,17 @@ const (
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
type StatusResp struct {
type GetStatusParams struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Interfaces []*core.Interface `protobuf:"bytes,1,rep,name=interfaces,proto3" json:"interfaces,omitempty"`
Interface string `protobuf:"bytes,1,opt,name=interface,proto3" json:"interface,omitempty"`
Peer []byte `protobuf:"bytes,2,opt,name=peer,proto3" json:"peer,omitempty"`
}
func (x *StatusResp) Reset() {
*x = StatusResp{}
func (x *GetStatusParams) Reset() {
*x = GetStatusParams{}
if protoimpl.UnsafeEnabled {
mi := &file_rpc_daemon_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
@@ -39,13 +40,13 @@ func (x *StatusResp) Reset() {
}
}
func (x *StatusResp) String() string {
func (x *GetStatusParams) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*StatusResp) ProtoMessage() {}
func (*GetStatusParams) ProtoMessage() {}
func (x *StatusResp) ProtoReflect() protoreflect.Message {
func (x *GetStatusParams) ProtoReflect() protoreflect.Message {
mi := &file_rpc_daemon_proto_msgTypes[0]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
@@ -57,29 +58,35 @@ func (x *StatusResp) ProtoReflect() protoreflect.Message {
return mi.MessageOf(x)
}
// Deprecated: Use StatusResp.ProtoReflect.Descriptor instead.
func (*StatusResp) Descriptor() ([]byte, []int) {
// Deprecated: Use GetStatusParams.ProtoReflect.Descriptor instead.
func (*GetStatusParams) Descriptor() ([]byte, []int) {
return file_rpc_daemon_proto_rawDescGZIP(), []int{0}
}
func (x *StatusResp) GetInterfaces() []*core.Interface {
func (x *GetStatusParams) GetInterface() string {
if x != nil {
return x.Interfaces
return x.Interface
}
return ""
}
func (x *GetStatusParams) GetPeer() []byte {
if x != nil {
return x.Peer
}
return nil
}
type StatusParams struct {
type GetStatusResp struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Intf string `protobuf:"bytes,1,opt,name=intf,proto3" json:"intf,omitempty"`
Peer []byte `protobuf:"bytes,2,opt,name=peer,proto3" json:"peer,omitempty"`
Interfaces []*core.Interface `protobuf:"bytes,1,rep,name=interfaces,proto3" json:"interfaces,omitempty"`
}
func (x *StatusParams) Reset() {
*x = StatusParams{}
func (x *GetStatusResp) Reset() {
*x = GetStatusResp{}
if protoimpl.UnsafeEnabled {
mi := &file_rpc_daemon_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
@@ -87,13 +94,13 @@ func (x *StatusParams) Reset() {
}
}
func (x *StatusParams) String() string {
func (x *GetStatusResp) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*StatusParams) ProtoMessage() {}
func (*GetStatusResp) ProtoMessage() {}
func (x *StatusParams) ProtoReflect() protoreflect.Message {
func (x *GetStatusResp) ProtoReflect() protoreflect.Message {
mi := &file_rpc_daemon_proto_msgTypes[1]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
@@ -105,21 +112,14 @@ func (x *StatusParams) ProtoReflect() protoreflect.Message {
return mi.MessageOf(x)
}
// Deprecated: Use StatusParams.ProtoReflect.Descriptor instead.
func (*StatusParams) Descriptor() ([]byte, []int) {
// Deprecated: Use GetStatusResp.ProtoReflect.Descriptor instead.
func (*GetStatusResp) Descriptor() ([]byte, []int) {
return file_rpc_daemon_proto_rawDescGZIP(), []int{1}
}
func (x *StatusParams) GetIntf() string {
func (x *GetStatusResp) GetInterfaces() []*core.Interface {
if x != nil {
return x.Intf
}
return ""
}
func (x *StatusParams) GetPeer() []byte {
if x != nil {
return x.Peer
return x.Interfaces
}
return nil
}
@@ -265,6 +265,124 @@ func (x *GetConfigResp) GetSettings() map[string]string {
return nil
}
type AddPeerParams struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Interface string `protobuf:"bytes,1,opt,name=interface,proto3" json:"interface,omitempty"`
PublicKey []byte `protobuf:"bytes,2,opt,name=public_key,json=publicKey,proto3" json:"public_key,omitempty"`
Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"`
}
func (x *AddPeerParams) Reset() {
*x = AddPeerParams{}
if protoimpl.UnsafeEnabled {
mi := &file_rpc_daemon_proto_msgTypes[5]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *AddPeerParams) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*AddPeerParams) ProtoMessage() {}
func (x *AddPeerParams) ProtoReflect() protoreflect.Message {
mi := &file_rpc_daemon_proto_msgTypes[5]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use AddPeerParams.ProtoReflect.Descriptor instead.
func (*AddPeerParams) Descriptor() ([]byte, []int) {
return file_rpc_daemon_proto_rawDescGZIP(), []int{5}
}
func (x *AddPeerParams) GetInterface() string {
if x != nil {
return x.Interface
}
return ""
}
func (x *AddPeerParams) GetPublicKey() []byte {
if x != nil {
return x.PublicKey
}
return nil
}
func (x *AddPeerParams) GetName() string {
if x != nil {
return x.Name
}
return ""
}
type AddPeerResp struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Invitation *Invitation `protobuf:"bytes,1,opt,name=invitation,proto3" json:"invitation,omitempty"`
Interface *core.Interface `protobuf:"bytes,2,opt,name=interface,proto3" json:"interface,omitempty"`
}
func (x *AddPeerResp) Reset() {
*x = AddPeerResp{}
if protoimpl.UnsafeEnabled {
mi := &file_rpc_daemon_proto_msgTypes[6]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *AddPeerResp) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*AddPeerResp) ProtoMessage() {}
func (x *AddPeerResp) ProtoReflect() protoreflect.Message {
mi := &file_rpc_daemon_proto_msgTypes[6]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use AddPeerResp.ProtoReflect.Descriptor instead.
func (*AddPeerResp) Descriptor() ([]byte, []int) {
return file_rpc_daemon_proto_rawDescGZIP(), []int{6}
}
func (x *AddPeerResp) GetInvitation() *Invitation {
if x != nil {
return x.Invitation
}
return nil
}
func (x *AddPeerResp) GetInterface() *core.Interface {
if x != nil {
return x.Interface
}
return nil
}
var File_rpc_daemon_proto protoreflect.FileDescriptor
var file_rpc_daemon_proto_rawDesc = []byte{
@@ -273,69 +391,93 @@ var file_rpc_daemon_proto_rawDesc = []byte{
0x63, 0x6f, 0x72, 0x65, 0x2f, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x2e, 0x70,
0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x0c, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f,
0x74, 0x6f, 0x1a, 0x0f, 0x72, 0x70, 0x63, 0x2f, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x2e, 0x70, 0x72,
0x6f, 0x74, 0x6f, 0x22, 0x44, 0x0a, 0x0a, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73,
0x70, 0x12, 0x36, 0x0a, 0x0a, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x73, 0x18,
0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x63,
0x6f, 0x72, 0x65, 0x2e, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x52, 0x0a, 0x69,
0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x73, 0x22, 0x36, 0x0a, 0x0c, 0x53, 0x74, 0x61,
0x74, 0x75, 0x73, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x69, 0x6e, 0x74,
0x66, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x69, 0x6e, 0x74, 0x66, 0x12, 0x12, 0x0a,
0x04, 0x70, 0x65, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x70, 0x65, 0x65,
0x72, 0x22, 0x95, 0x01, 0x0a, 0x0f, 0x53, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x50,
0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x45, 0x0a, 0x08, 0x73, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67,
0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x29, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75,
0x2e, 0x72, 0x70, 0x63, 0x2e, 0x53, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x50, 0x61,
0x72, 0x61, 0x6d, 0x73, 0x2e, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x45, 0x6e, 0x74,
0x72, 0x79, 0x52, 0x08, 0x73, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x1a, 0x3b, 0x0a, 0x0d,
0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a,
0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12,
0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05,
0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x30, 0x0a, 0x0f, 0x47, 0x65, 0x74,
0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x1d, 0x0a, 0x0a,
0x6b, 0x65, 0x79, 0x5f, 0x66, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
0x52, 0x09, 0x6b, 0x65, 0x79, 0x46, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x22, 0x91, 0x01, 0x0a, 0x0d,
0x47, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x73, 0x70, 0x12, 0x43, 0x0a,
0x08, 0x73, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32,
0x27, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x47, 0x65, 0x74,
0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x73, 0x70, 0x2e, 0x53, 0x65, 0x74, 0x74, 0x69,
0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x72, 0x70, 0x63, 0x2f, 0x69, 0x6e, 0x76, 0x69, 0x74, 0x61, 0x74,
0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x43, 0x0a, 0x0f, 0x47, 0x65, 0x74,
0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x1c, 0x0a, 0x09,
0x69, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
0x09, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x65,
0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x70, 0x65, 0x65, 0x72, 0x22, 0x47,
0x0a, 0x0d, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x12,
0x36, 0x0a, 0x0a, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x73, 0x18, 0x01, 0x20,
0x03, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x63, 0x6f, 0x72,
0x65, 0x2e, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x52, 0x0a, 0x69, 0x6e, 0x74,
0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x73, 0x22, 0x95, 0x01, 0x0a, 0x0f, 0x53, 0x65, 0x74, 0x43,
0x6f, 0x6e, 0x66, 0x69, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x45, 0x0a, 0x08, 0x73,
0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x29, 0x2e,
0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x53, 0x65, 0x74, 0x43, 0x6f,
0x6e, 0x66, 0x69, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x53, 0x65, 0x74, 0x74, 0x69,
0x6e, 0x67, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x08, 0x73, 0x65, 0x74, 0x74, 0x69, 0x6e,
0x67, 0x73, 0x1a, 0x3b, 0x0a, 0x0d, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x45, 0x6e,
0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02,
0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x32,
0xda, 0x03, 0x0a, 0x06, 0x44, 0x61, 0x65, 0x6d, 0x6f, 0x6e, 0x12, 0x32, 0x0a, 0x0c, 0x47, 0x65,
0x74, 0x42, 0x75, 0x69, 0x6c, 0x64, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x0d, 0x2e, 0x63, 0x75, 0x6e,
0x69, 0x63, 0x75, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x11, 0x2e, 0x63, 0x75, 0x6e, 0x69,
0x63, 0x75, 0x2e, 0x42, 0x75, 0x69, 0x6c, 0x64, 0x49, 0x6e, 0x66, 0x6f, 0x22, 0x00, 0x12, 0x34,
0x0a, 0x0c, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x73, 0x12, 0x0d,
0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x11, 0x2e,
0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x45, 0x76, 0x65, 0x6e, 0x74,
0x22, 0x00, 0x30, 0x01, 0x12, 0x28, 0x0a, 0x06, 0x55, 0x6e, 0x57, 0x61, 0x69, 0x74, 0x12, 0x0d,
0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x0d, 0x2e,
0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x26,
0x0a, 0x04, 0x53, 0x74, 0x6f, 0x70, 0x12, 0x0d, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e,
0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22,
0x30, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x50, 0x61, 0x72, 0x61,
0x6d, 0x73, 0x12, 0x1d, 0x0a, 0x0a, 0x6b, 0x65, 0x79, 0x5f, 0x66, 0x69, 0x6c, 0x74, 0x65, 0x72,
0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x6b, 0x65, 0x79, 0x46, 0x69, 0x6c, 0x74, 0x65,
0x72, 0x22, 0x91, 0x01, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52,
0x65, 0x73, 0x70, 0x12, 0x43, 0x0a, 0x08, 0x73, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x18,
0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x72,
0x70, 0x63, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x73, 0x70,
0x2e, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x08,
0x73, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x1a, 0x3b, 0x0a, 0x0d, 0x53, 0x65, 0x74, 0x74,
0x69, 0x6e, 0x67, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79,
0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76,
0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75,
0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x60, 0x0a, 0x0d, 0x41, 0x64, 0x64, 0x50, 0x65, 0x65, 0x72,
0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x66,
0x61, 0x63, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x69, 0x6e, 0x74, 0x65, 0x72,
0x66, 0x61, 0x63, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b,
0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63,
0x4b, 0x65, 0x79, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28,
0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x7b, 0x0a, 0x0b, 0x41, 0x64, 0x64, 0x50, 0x65,
0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x12, 0x36, 0x0a, 0x0a, 0x69, 0x6e, 0x76, 0x69, 0x74, 0x61,
0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x63, 0x75, 0x6e,
0x69, 0x63, 0x75, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x49, 0x6e, 0x76, 0x69, 0x74, 0x61, 0x74, 0x69,
0x6f, 0x6e, 0x52, 0x0a, 0x69, 0x6e, 0x76, 0x69, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x34,
0x0a, 0x09, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28,
0x0b, 0x32, 0x16, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x63, 0x6f, 0x72, 0x65, 0x2e,
0x49, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x52, 0x09, 0x69, 0x6e, 0x74, 0x65, 0x72,
0x66, 0x61, 0x63, 0x65, 0x32, 0xd1, 0x04, 0x0a, 0x06, 0x44, 0x61, 0x65, 0x6d, 0x6f, 0x6e, 0x12,
0x32, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x42, 0x75, 0x69, 0x6c, 0x64, 0x49, 0x6e, 0x66, 0x6f, 0x12,
0x0d, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x11,
0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x42, 0x75, 0x69, 0x6c, 0x64, 0x49, 0x6e, 0x66,
0x6f, 0x22, 0x00, 0x12, 0x34, 0x0a, 0x0c, 0x53, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x45, 0x76, 0x65,
0x6e, 0x74, 0x73, 0x12, 0x0d, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x45, 0x6d, 0x70,
0x74, 0x79, 0x1a, 0x11, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x72, 0x70, 0x63, 0x2e,
0x45, 0x76, 0x65, 0x6e, 0x74, 0x22, 0x00, 0x30, 0x01, 0x12, 0x28, 0x0a, 0x06, 0x55, 0x6e, 0x57,
0x61, 0x69, 0x74, 0x12, 0x0d, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x45, 0x6d, 0x70,
0x74, 0x79, 0x1a, 0x0d, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x45, 0x6d, 0x70, 0x74,
0x79, 0x22, 0x00, 0x12, 0x26, 0x0a, 0x04, 0x53, 0x74, 0x6f, 0x70, 0x12, 0x0d, 0x2e, 0x63, 0x75,
0x6e, 0x69, 0x63, 0x75, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x0d, 0x2e, 0x63, 0x75, 0x6e,
0x69, 0x63, 0x75, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x29, 0x0a, 0x07, 0x52,
0x65, 0x73, 0x74, 0x61, 0x72, 0x74, 0x12, 0x0d, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e,
0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x0d, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x45,
0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x29, 0x0a, 0x07, 0x52, 0x65, 0x73, 0x74, 0x61, 0x72,
0x74, 0x12, 0x0d, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79,
0x1a, 0x0d, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22,
0x00, 0x12, 0x26, 0x0a, 0x04, 0x53, 0x79, 0x6e, 0x63, 0x12, 0x0d, 0x2e, 0x63, 0x75, 0x6e, 0x69,
0x63, 0x75, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x0d, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63,
0x75, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x3f, 0x0a, 0x09, 0x47, 0x65, 0x74,
0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x18, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e,
0x72, 0x70, 0x63, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73,
0x1a, 0x16, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x53, 0x74,
0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x22, 0x00, 0x12, 0x39, 0x0a, 0x09, 0x53, 0x65,
0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x1b, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75,
0x2e, 0x72, 0x70, 0x63, 0x2e, 0x53, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x50, 0x61,
0x72, 0x61, 0x6d, 0x73, 0x1a, 0x0d, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x45, 0x6d,
0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x45, 0x0a, 0x09, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66,
0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x26, 0x0a, 0x04, 0x53, 0x79, 0x6e, 0x63, 0x12, 0x0d,
0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x0d, 0x2e,
0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x45,
0x0a, 0x09, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x1b, 0x2e, 0x63, 0x75,
0x6e, 0x69, 0x63, 0x75, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74,
0x75, 0x73, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x19, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63,
0x75, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x47, 0x65, 0x74, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52,
0x65, 0x73, 0x70, 0x22, 0x00, 0x12, 0x39, 0x0a, 0x09, 0x53, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66,
0x69, 0x67, 0x12, 0x1b, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x72, 0x70, 0x63, 0x2e,
0x47, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a,
0x19, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x47, 0x65, 0x74,
0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x73, 0x70, 0x22, 0x00, 0x42, 0x27, 0x5a, 0x25,
0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x74, 0x76, 0x30, 0x67,
0x2f, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2f, 0x70, 0x6b, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74,
0x6f, 0x2f, 0x72, 0x70, 0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
0x53, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a,
0x0d, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00,
0x12, 0x45, 0x0a, 0x09, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x1b, 0x2e,
0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x6f,
0x6e, 0x66, 0x69, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x19, 0x2e, 0x63, 0x75, 0x6e,
0x69, 0x63, 0x75, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x69,
0x67, 0x52, 0x65, 0x73, 0x70, 0x22, 0x00, 0x12, 0x2e, 0x0a, 0x0c, 0x52, 0x65, 0x6c, 0x6f, 0x61,
0x64, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x0d, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75,
0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x0d, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e,
0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x00, 0x12, 0x3f, 0x0a, 0x07, 0x41, 0x64, 0x64, 0x50, 0x65,
0x65, 0x72, 0x12, 0x19, 0x2e, 0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x72, 0x70, 0x63, 0x2e,
0x41, 0x64, 0x64, 0x50, 0x65, 0x65, 0x72, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x17, 0x2e,
0x63, 0x75, 0x6e, 0x69, 0x63, 0x75, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x41, 0x64, 0x64, 0x50, 0x65,
0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x22, 0x00, 0x42, 0x27, 0x5a, 0x25, 0x67, 0x69, 0x74, 0x68,
0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x74, 0x76, 0x30, 0x67, 0x2f, 0x63, 0x75, 0x6e,
0x69, 0x63, 0x75, 0x2f, 0x70, 0x6b, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x72, 0x70,
0x63, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
}
var (
@@ -350,47 +492,56 @@ func file_rpc_daemon_proto_rawDescGZIP() []byte {
return file_rpc_daemon_proto_rawDescData
}
var file_rpc_daemon_proto_msgTypes = make([]protoimpl.MessageInfo, 7)
var file_rpc_daemon_proto_msgTypes = make([]protoimpl.MessageInfo, 9)
var file_rpc_daemon_proto_goTypes = []interface{}{
(*StatusResp)(nil), // 0: cunicu.rpc.StatusResp
(*StatusParams)(nil), // 1: cunicu.rpc.StatusParams
(*GetStatusParams)(nil), // 0: cunicu.rpc.GetStatusParams
(*GetStatusResp)(nil), // 1: cunicu.rpc.GetStatusResp
(*SetConfigParams)(nil), // 2: cunicu.rpc.SetConfigParams
(*GetConfigParams)(nil), // 3: cunicu.rpc.GetConfigParams
(*GetConfigResp)(nil), // 4: cunicu.rpc.GetConfigResp
nil, // 5: cunicu.rpc.SetConfigParams.SettingsEntry
nil, // 6: cunicu.rpc.GetConfigResp.SettingsEntry
(*core.Interface)(nil), // 7: cunicu.core.Interface
(*proto.Empty)(nil), // 8: cunicu.Empty
(*proto.BuildInfo)(nil), // 9: cunicu.BuildInfo
(*Event)(nil), // 10: cunicu.rpc.Event
(*AddPeerParams)(nil), // 5: cunicu.rpc.AddPeerParams
(*AddPeerResp)(nil), // 6: cunicu.rpc.AddPeerResp
nil, // 7: cunicu.rpc.SetConfigParams.SettingsEntry
nil, // 8: cunicu.rpc.GetConfigResp.SettingsEntry
(*core.Interface)(nil), // 9: cunicu.core.Interface
(*Invitation)(nil), // 10: cunicu.rpc.Invitation
(*proto.Empty)(nil), // 11: cunicu.Empty
(*proto.BuildInfo)(nil), // 12: cunicu.BuildInfo
(*Event)(nil), // 13: cunicu.rpc.Event
}
var file_rpc_daemon_proto_depIdxs = []int32{
7, // 0: cunicu.rpc.StatusResp.interfaces:type_name -> cunicu.core.Interface
5, // 1: cunicu.rpc.SetConfigParams.settings:type_name -> cunicu.rpc.SetConfigParams.SettingsEntry
6, // 2: cunicu.rpc.GetConfigResp.settings:type_name -> cunicu.rpc.GetConfigResp.SettingsEntry
8, // 3: cunicu.rpc.Daemon.GetBuildInfo:input_type -> cunicu.Empty
8, // 4: cunicu.rpc.Daemon.StreamEvents:input_type -> cunicu.Empty
8, // 5: cunicu.rpc.Daemon.UnWait:input_type -> cunicu.Empty
8, // 6: cunicu.rpc.Daemon.Stop:input_type -> cunicu.Empty
8, // 7: cunicu.rpc.Daemon.Restart:input_type -> cunicu.Empty
8, // 8: cunicu.rpc.Daemon.Sync:input_type -> cunicu.Empty
1, // 9: cunicu.rpc.Daemon.GetStatus:input_type -> cunicu.rpc.StatusParams
2, // 10: cunicu.rpc.Daemon.SetConfig:input_type -> cunicu.rpc.SetConfigParams
3, // 11: cunicu.rpc.Daemon.GetConfig:input_type -> cunicu.rpc.GetConfigParams
9, // 12: cunicu.rpc.Daemon.GetBuildInfo:output_type -> cunicu.BuildInfo
10, // 13: cunicu.rpc.Daemon.StreamEvents:output_type -> cunicu.rpc.Event
8, // 14: cunicu.rpc.Daemon.UnWait:output_type -> cunicu.Empty
8, // 15: cunicu.rpc.Daemon.Stop:output_type -> cunicu.Empty
8, // 16: cunicu.rpc.Daemon.Restart:output_type -> cunicu.Empty
8, // 17: cunicu.rpc.Daemon.Sync:output_type -> cunicu.Empty
0, // 18: cunicu.rpc.Daemon.GetStatus:output_type -> cunicu.rpc.StatusResp
8, // 19: cunicu.rpc.Daemon.SetConfig:output_type -> cunicu.Empty
4, // 20: cunicu.rpc.Daemon.GetConfig:output_type -> cunicu.rpc.GetConfigResp
12, // [12:21] is the sub-list for method output_type
3, // [3:12] is the sub-list for method input_type
3, // [3:3] is the sub-list for extension type_name
3, // [3:3] is the sub-list for extension extendee
0, // [0:3] is the sub-list for field type_name
9, // 0: cunicu.rpc.GetStatusResp.interfaces:type_name -> cunicu.core.Interface
7, // 1: cunicu.rpc.SetConfigParams.settings:type_name -> cunicu.rpc.SetConfigParams.SettingsEntry
8, // 2: cunicu.rpc.GetConfigResp.settings:type_name -> cunicu.rpc.GetConfigResp.SettingsEntry
10, // 3: cunicu.rpc.AddPeerResp.invitation:type_name -> cunicu.rpc.Invitation
9, // 4: cunicu.rpc.AddPeerResp.interface:type_name -> cunicu.core.Interface
11, // 5: cunicu.rpc.Daemon.GetBuildInfo:input_type -> cunicu.Empty
11, // 6: cunicu.rpc.Daemon.StreamEvents:input_type -> cunicu.Empty
11, // 7: cunicu.rpc.Daemon.UnWait:input_type -> cunicu.Empty
11, // 8: cunicu.rpc.Daemon.Stop:input_type -> cunicu.Empty
11, // 9: cunicu.rpc.Daemon.Restart:input_type -> cunicu.Empty
11, // 10: cunicu.rpc.Daemon.Sync:input_type -> cunicu.Empty
0, // 11: cunicu.rpc.Daemon.GetStatus:input_type -> cunicu.rpc.GetStatusParams
2, // 12: cunicu.rpc.Daemon.SetConfig:input_type -> cunicu.rpc.SetConfigParams
3, // 13: cunicu.rpc.Daemon.GetConfig:input_type -> cunicu.rpc.GetConfigParams
11, // 14: cunicu.rpc.Daemon.ReloadConfig:input_type -> cunicu.Empty
5, // 15: cunicu.rpc.Daemon.AddPeer:input_type -> cunicu.rpc.AddPeerParams
12, // 16: cunicu.rpc.Daemon.GetBuildInfo:output_type -> cunicu.BuildInfo
13, // 17: cunicu.rpc.Daemon.StreamEvents:output_type -> cunicu.rpc.Event
11, // 18: cunicu.rpc.Daemon.UnWait:output_type -> cunicu.Empty
11, // 19: cunicu.rpc.Daemon.Stop:output_type -> cunicu.Empty
11, // 20: cunicu.rpc.Daemon.Restart:output_type -> cunicu.Empty
11, // 21: cunicu.rpc.Daemon.Sync:output_type -> cunicu.Empty
1, // 22: cunicu.rpc.Daemon.GetStatus:output_type -> cunicu.rpc.GetStatusResp
11, // 23: cunicu.rpc.Daemon.SetConfig:output_type -> cunicu.Empty
4, // 24: cunicu.rpc.Daemon.GetConfig:output_type -> cunicu.rpc.GetConfigResp
11, // 25: cunicu.rpc.Daemon.ReloadConfig:output_type -> cunicu.Empty
6, // 26: cunicu.rpc.Daemon.AddPeer:output_type -> cunicu.rpc.AddPeerResp
16, // [16:27] is the sub-list for method output_type
5, // [5:16] is the sub-list for method input_type
5, // [5:5] is the sub-list for extension type_name
5, // [5:5] is the sub-list for extension extendee
0, // [0:5] is the sub-list for field type_name
}
func init() { file_rpc_daemon_proto_init() }
@@ -399,9 +550,10 @@ func file_rpc_daemon_proto_init() {
return
}
file_rpc_event_proto_init()
file_rpc_invitation_proto_init()
if !protoimpl.UnsafeEnabled {
file_rpc_daemon_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*StatusResp); i {
switch v := v.(*GetStatusParams); i {
case 0:
return &v.state
case 1:
@@ -413,7 +565,7 @@ func file_rpc_daemon_proto_init() {
}
}
file_rpc_daemon_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*StatusParams); i {
switch v := v.(*GetStatusResp); i {
case 0:
return &v.state
case 1:
@@ -460,6 +612,30 @@ func file_rpc_daemon_proto_init() {
return nil
}
}
file_rpc_daemon_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*AddPeerParams); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_rpc_daemon_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*AddPeerResp); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
}
type x struct{}
out := protoimpl.TypeBuilder{
@@ -467,7 +643,7 @@ func file_rpc_daemon_proto_init() {
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_rpc_daemon_proto_rawDesc,
NumEnums: 0,
NumMessages: 7,
NumMessages: 9,
NumExtensions: 0,
NumServices: 1,
},