proto

package
v0.0.0-...-9a70a3a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 21, 2016 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package proto is a generated protocol buffer package.

It is generated from these files:

ClientClient.proto
ClientServer.proto
DenameChatProfile.proto
LocalAccount.proto
LocalAccountConfig.proto
LocalConversationMetadata.proto
Prekeys.proto

It has these top-level messages:

Message

Package proto is a generated protocol buffer package.

It is generated from these files:

ClientServer.proto

It has these top-level messages:

ServerToClient
ClientToServer

Index

Constants

View Source
const MAX_MESSAGE_SIZE = 16 * 1024
View Source
const SERVER_MESSAGE_SIZE = MAX_MESSAGE_SIZE + 100

Variables

View Source
var ServerToClient_StatusCode_name = map[int32]string{
	0: "OK",
	1: "PARSE_ERROR",
}
View Source
var ServerToClient_StatusCode_value = map[string]int32{
	"OK":          0,
	"PARSE_ERROR": 1,
}

Functions

func Pad

func Pad(msg []byte, l int) []byte

func To32ByteList

func To32ByteList(list []Byte32) []*[32]byte

returns a slice of COPIES of the original message list

func Unpad

func Unpad(msg []byte) []byte

Types

type Byte32

type Byte32 [32]byte

func NewPopulatedByte32

func NewPopulatedByte32(r randy) *Byte32

func ToProtoByte32List

func ToProtoByte32List(list []*[32]byte) []Byte32

func (*Byte32) Equal

func (this *Byte32) Equal(that interface{}) bool

func (Byte32) Marshal

func (b Byte32) Marshal() ([]byte, error)

func (Byte32) MarshalTo

func (b Byte32) MarshalTo(data []byte) (int, error)

func (Byte32) Size

func (b Byte32) Size() int

func (*Byte32) Unmarshal

func (b *Byte32) Unmarshal(data []byte) error

type ClientToServer

type ClientToServer struct {
	CreateAccount    *bool                           `protobuf:"varint,1,opt,name=create_account" json:"create_account,omitempty"`
	DeliverEnvelope  *ClientToServer_DeliverEnvelope `protobuf:"bytes,2,opt,name=deliver_envelope" json:"deliver_envelope,omitempty"`
	DownloadEnvelope *Byte32                         `protobuf:"bytes,6,opt,name=download_envelope,customtype=Byte32" json:"download_envelope,omitempty"`
	ListMessages     *bool                           `protobuf:"varint,5,opt,name=list_messages" json:"list_messages,omitempty"`
	DeleteMessages   []Byte32                        `protobuf:"bytes,7,rep,name=delete_messages,customtype=Byte32" json:"delete_messages,omitempty"`
	UploadSignedKeys [][]byte                        `protobuf:"bytes,8,rep,name=upload_signed_keys" json:"upload_signed_keys,omitempty"`
	GetSignedKey     *Byte32                         `protobuf:"bytes,9,opt,name=get_signed_key,customtype=Byte32" json:"get_signed_key,omitempty"`
	ReceiveEnvelopes *bool                           `protobuf:"varint,10,opt,name=receive_envelopes" json:"receive_envelopes,omitempty"`
	GetNumKeys       *bool                           `protobuf:"varint,11,opt,name=get_num_keys" json:"get_num_keys,omitempty"`
	XXX_unrecognized []byte                          `json:"-"`
}

func NewPopulatedClientToServer

func NewPopulatedClientToServer(r randyClientServer, easy bool) *ClientToServer

func (*ClientToServer) Equal

func (this *ClientToServer) Equal(that interface{}) bool

func (*ClientToServer) Marshal

func (m *ClientToServer) Marshal() (data []byte, err error)

func (*ClientToServer) MarshalTo

func (m *ClientToServer) MarshalTo(data []byte) (n int, err error)

func (*ClientToServer) ProtoMessage

func (*ClientToServer) ProtoMessage()

func (*ClientToServer) Reset

func (m *ClientToServer) Reset()

func (*ClientToServer) Size

func (m *ClientToServer) Size() (n int)

func (*ClientToServer) String

func (m *ClientToServer) String() string

func (*ClientToServer) Unmarshal

func (m *ClientToServer) Unmarshal(data []byte) error

type ClientToServer_DeliverEnvelope

type ClientToServer_DeliverEnvelope struct {
	User             *Byte32 `protobuf:"bytes,3,req,customtype=Byte32" json:"User,omitempty"`
	Envelope         []byte  `protobuf:"bytes,4,req" json:"Envelope,omitempty"`
	XXX_unrecognized []byte  `json:"-"`
}

func NewPopulatedClientToServer_DeliverEnvelope

func NewPopulatedClientToServer_DeliverEnvelope(r randyClientServer, easy bool) *ClientToServer_DeliverEnvelope

func (*ClientToServer_DeliverEnvelope) Equal

func (this *ClientToServer_DeliverEnvelope) Equal(that interface{}) bool

func (*ClientToServer_DeliverEnvelope) Marshal

func (m *ClientToServer_DeliverEnvelope) Marshal() (data []byte, err error)

func (*ClientToServer_DeliverEnvelope) MarshalTo

func (m *ClientToServer_DeliverEnvelope) MarshalTo(data []byte) (n int, err error)

func (*ClientToServer_DeliverEnvelope) ProtoMessage

func (*ClientToServer_DeliverEnvelope) ProtoMessage()

func (*ClientToServer_DeliverEnvelope) Reset

func (m *ClientToServer_DeliverEnvelope) Reset()

func (*ClientToServer_DeliverEnvelope) Size

func (m *ClientToServer_DeliverEnvelope) Size() (n int)

func (*ClientToServer_DeliverEnvelope) String

func (*ClientToServer_DeliverEnvelope) Unmarshal

func (m *ClientToServer_DeliverEnvelope) Unmarshal(data []byte) error

type ConversationMetadata

type ConversationMetadata struct {
	Participants     []string `protobuf:"bytes,1,rep" json:"Participants"`
	Subject          string   `protobuf:"bytes,2,req" json:"Subject"`
	XXX_unrecognized []byte   `json:"-"`
}

func NewPopulatedConversationMetadata

func NewPopulatedConversationMetadata(r randyLocalConversationMetadata, easy bool) *ConversationMetadata

func (*ConversationMetadata) Equal

func (this *ConversationMetadata) Equal(that interface{}) bool

func (*ConversationMetadata) Marshal

func (m *ConversationMetadata) Marshal() (data []byte, err error)

func (*ConversationMetadata) MarshalTo

func (m *ConversationMetadata) MarshalTo(data []byte) (n int, err error)

func (*ConversationMetadata) ProtoMessage

func (*ConversationMetadata) ProtoMessage()

func (*ConversationMetadata) Reset

func (m *ConversationMetadata) Reset()

func (*ConversationMetadata) Size

func (m *ConversationMetadata) Size() (n int)

func (*ConversationMetadata) String

func (m *ConversationMetadata) String() string

func (*ConversationMetadata) Unmarshal

func (m *ConversationMetadata) Unmarshal(data []byte) error

type LocalAccount

type LocalAccount struct {
	Dename           string `protobuf:"bytes,1,req,name=dename" json:"dename"`
	XXX_unrecognized []byte `json:"-"`
}

func (*LocalAccount) Equal

func (this *LocalAccount) Equal(that interface{}) bool

func (*LocalAccount) Marshal

func (m *LocalAccount) Marshal() (data []byte, err error)

func (*LocalAccount) MarshalTo

func (m *LocalAccount) MarshalTo(data []byte) (n int, err error)

func (*LocalAccount) ProtoMessage

func (*LocalAccount) ProtoMessage()

func (*LocalAccount) Reset

func (m *LocalAccount) Reset()

func (*LocalAccount) Size

func (m *LocalAccount) Size() (n int)

func (*LocalAccount) String

func (m *LocalAccount) String() string

func (*LocalAccount) Unmarshal

func (m *LocalAccount) Unmarshal(data []byte) error

type LocalAccountConfig

type LocalAccountConfig struct {
	ServerAddressTCP            string `protobuf:"bytes,1,req" json:"ServerAddressTCP"`
	ServerPortTCP               int32  `protobuf:"varint,2,req" json:"ServerPortTCP"`
	ServerTransportPK           Byte32 `protobuf:"bytes,3,req,customtype=Byte32" json:"ServerTransportPK"`
	TransportSecretKeyForServer Byte32 `protobuf:"bytes,4,req,customtype=Byte32" json:"TransportSecretKeyForServer"`
	KeySigningSecretKey         []byte `protobuf:"bytes,5,req" json:"KeySigningSecretKey"`
	MessageAuthSecretKey        Byte32 `protobuf:"bytes,6,req,customtype=Byte32" json:"MessageAuthSecretKey"`
	TorAddress                  string `protobuf:"bytes,8,req" json:"TorAddress"`
	XXX_unrecognized            []byte `json:"-"`
}

func NewPopulatedLocalAccountConfig

func NewPopulatedLocalAccountConfig(r randyLocalAccountConfig, easy bool) *LocalAccountConfig

func (*LocalAccountConfig) Equal

func (this *LocalAccountConfig) Equal(that interface{}) bool

func (*LocalAccountConfig) Marshal

func (m *LocalAccountConfig) Marshal() (data []byte, err error)

func (*LocalAccountConfig) MarshalTo

func (m *LocalAccountConfig) MarshalTo(data []byte) (n int, err error)

func (*LocalAccountConfig) ProtoMessage

func (*LocalAccountConfig) ProtoMessage()

func (*LocalAccountConfig) Reset

func (m *LocalAccountConfig) Reset()

func (*LocalAccountConfig) Size

func (m *LocalAccountConfig) Size() (n int)

func (*LocalAccountConfig) String

func (m *LocalAccountConfig) String() string

func (*LocalAccountConfig) Unmarshal

func (m *LocalAccountConfig) Unmarshal(data []byte) error

type Message

type Message struct {
	Contents         []byte                                                `protobuf:"bytes,1,req,name=contents" json:"contents"`
	Subject          string                                                `protobuf:"bytes,2,req,name=subject" json:"subject"`
	Participants     []string                                              `protobuf:"bytes,3,rep,name=participants" json:"participants"`
	Date             int64                                                 `protobuf:"varint,4,req,name=date" json:"date"`
	Dename           string                                                `protobuf:"bytes,5,req,name=dename" json:"dename"`
	DenameLookup     *github_com_andres_erbsen_dename_protocol.ClientReply `` /* 136-byte string literal not displayed */
	XXX_unrecognized []byte                                                `json:"-"`
}

func (*Message) Equal

func (this *Message) Equal(that interface{}) bool

func (*Message) Marshal

func (m *Message) Marshal() (data []byte, err error)

func (*Message) MarshalTo

func (m *Message) MarshalTo(data []byte) (n int, err error)

func (*Message) ProtoMessage

func (*Message) ProtoMessage()

func (*Message) Reset

func (m *Message) Reset()

func (*Message) Size

func (m *Message) Size() (n int)

func (*Message) String

func (m *Message) String() string

func (*Message) Unmarshal

func (m *Message) Unmarshal(data []byte) error

type Prekeys

type Prekeys struct {
	PrekeySecrets    []Byte32 `protobuf:"bytes,1,rep,customtype=Byte32" json:"PrekeySecrets"`
	PrekeyPublics    []Byte32 `protobuf:"bytes,2,rep,customtype=Byte32" json:"PrekeyPublics"`
	XXX_unrecognized []byte   `json:"-"`
}

func NewPopulatedPrekeys

func NewPopulatedPrekeys(r randyPrekeys, easy bool) *Prekeys

func (*Prekeys) Equal

func (this *Prekeys) Equal(that interface{}) bool

func (*Prekeys) Marshal

func (m *Prekeys) Marshal() (data []byte, err error)

func (*Prekeys) MarshalTo

func (m *Prekeys) MarshalTo(data []byte) (n int, err error)

func (*Prekeys) ProtoMessage

func (*Prekeys) ProtoMessage()

func (*Prekeys) Reset

func (m *Prekeys) Reset()

func (*Prekeys) Size

func (m *Prekeys) Size() (n int)

func (*Prekeys) String

func (m *Prekeys) String() string

func (*Prekeys) Unmarshal

func (m *Prekeys) Unmarshal(data []byte) error

type Profile

type Profile struct {
	ServerAddressTCP  string `protobuf:"bytes,1,req" json:"ServerAddressTCP"`
	ServerPortTCP     int32  `protobuf:"varint,2,req" json:"ServerPortTCP"`
	ServerTransportPK Byte32 `protobuf:"bytes,3,req,customtype=Byte32" json:"ServerTransportPK"`
	UserIDAtServer    Byte32 `protobuf:"bytes,4,req,customtype=Byte32" json:"UserIDAtServer"`
	KeySigningKey     Byte32 `protobuf:"bytes,5,req,customtype=Byte32" json:"KeySigningKey"`
	MessageAuthKey    Byte32 `protobuf:"bytes,6,req,customtype=Byte32" json:"MessageAuthKey"`
	XXX_unrecognized  []byte `json:"-"`
}

func NewPopulatedProfile

func NewPopulatedProfile(r randyDenameChatProfile, easy bool) *Profile

func (*Profile) Equal

func (this *Profile) Equal(that interface{}) bool

func (*Profile) Marshal

func (m *Profile) Marshal() (data []byte, err error)

func (*Profile) MarshalTo

func (m *Profile) MarshalTo(data []byte) (n int, err error)

func (*Profile) ProtoMessage

func (*Profile) ProtoMessage()

func (*Profile) Reset

func (m *Profile) Reset()

func (*Profile) Size

func (m *Profile) Size() (n int)

func (*Profile) String

func (m *Profile) String() string

func (*Profile) Unmarshal

func (m *Profile) Unmarshal(data []byte) error

type ServerToClient

type ServerToClient struct {
	Status           *ServerToClient_StatusCode `protobuf:"varint,1,req,name=status,enum=proto.ServerToClient_StatusCode" json:"status,omitempty"`
	MessageList      []Byte32                   `protobuf:"bytes,3,rep,name=message_list,customtype=Byte32" json:"message_list,omitempty"`
	Envelope         []byte                     `protobuf:"bytes,4,opt,name=envelope" json:"envelope,omitempty"`
	SignedKey        []byte                     `protobuf:"bytes,5,opt,name=signed_key" json:"signed_key,omitempty"`
	MessageId        *Byte32                    `protobuf:"bytes,6,opt,name=message_id,customtype=Byte32" json:"message_id,omitempty"`
	NumKeys          *int64                     `protobuf:"varint,7,opt,name=num_keys" json:"num_keys,omitempty"`
	XXX_unrecognized []byte                     `json:"-"`
}

func NewPopulatedServerToClient

func NewPopulatedServerToClient(r randyClientServer, easy bool) *ServerToClient

func (*ServerToClient) Equal

func (this *ServerToClient) Equal(that interface{}) bool

func (*ServerToClient) Marshal

func (m *ServerToClient) Marshal() (data []byte, err error)

func (*ServerToClient) MarshalTo

func (m *ServerToClient) MarshalTo(data []byte) (n int, err error)

func (*ServerToClient) ProtoMessage

func (*ServerToClient) ProtoMessage()

func (*ServerToClient) Reset

func (m *ServerToClient) Reset()

func (*ServerToClient) Size

func (m *ServerToClient) Size() (n int)

func (*ServerToClient) String

func (m *ServerToClient) String() string

func (*ServerToClient) Unmarshal

func (m *ServerToClient) Unmarshal(data []byte) error

type ServerToClient_StatusCode

type ServerToClient_StatusCode int32
const (
	ServerToClient_OK          ServerToClient_StatusCode = 0
	ServerToClient_PARSE_ERROR ServerToClient_StatusCode = 1
)

func (ServerToClient_StatusCode) Enum

func (ServerToClient_StatusCode) String

func (x ServerToClient_StatusCode) String() string

func (*ServerToClient_StatusCode) UnmarshalJSON

func (x *ServerToClient_StatusCode) UnmarshalJSON(data []byte) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL