Documentation ¶
Index ¶
- type Comm
- func (c *Comm) Addr() string
- func (c Comm) CloseConn(addr string)
- func (c Comm) Gossip(addr string, args *pb.State) (*pb.StateResponse, error)
- func (c *Comm) Register(p pb.GossipServer)
- func (c Comm) Send(addr string, args *pb.Msg) (*pb.MsgResponse, error)
- func (c *Comm) Start()
- func (c *Comm) Stop()
- func (c Comm) StreamMessenger(addr string, input, reply chan []byte) error
- type CryptoUnit
- func (cu *CryptoUnit) CaCertificate() *x509.Certificate
- func (cu *CryptoUnit) Certificate() *x509.Certificate
- func (cu *CryptoUnit) ContactList() []*x509.Certificate
- func (cu *CryptoUnit) NumRings() uint32
- func (cu *CryptoUnit) Priv() *ecdsa.PrivateKey
- func (cu *CryptoUnit) SaveCertificate() error
- func (cu *CryptoUnit) SavePrivateKey() error
- func (cu *CryptoUnit) Sign(data []byte) ([]byte, []byte, error)
- func (cu *CryptoUnit) Trusted() bool
- func (cu *CryptoUnit) Verify(data, r, s []byte, pub *ecdsa.PublicKey) bool
- type CryptoUnitConfig
- type UDPServer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Comm ¶
type Comm struct {
// contains filtered or unexported fields
}
func NewComm ¶
func NewComm(cert, caCert *x509.Certificate, priv *ecdsa.PrivateKey, l net.Listener) (*Comm, error)
func (*Comm) Register ¶
func (c *Comm) Register(p pb.GossipServer)
func (Comm) StreamMessenger ¶
type CryptoUnit ¶
type CryptoUnit struct {
// contains filtered or unexported fields
}
func NewCu ¶
func NewCu(config *CryptoUnitConfig) (*CryptoUnit, error)
func NewCu(identity pkix.Name, workingDir string, caAddr string, dnsLabel string) (*CryptoUnit, error) {
func (*CryptoUnit) CaCertificate ¶
func (cu *CryptoUnit) CaCertificate() *x509.Certificate
func (*CryptoUnit) Certificate ¶
func (cu *CryptoUnit) Certificate() *x509.Certificate
func (*CryptoUnit) ContactList ¶
func (cu *CryptoUnit) ContactList() []*x509.Certificate
func (*CryptoUnit) NumRings ¶
func (cu *CryptoUnit) NumRings() uint32
func (*CryptoUnit) Priv ¶
func (cu *CryptoUnit) Priv() *ecdsa.PrivateKey
func (*CryptoUnit) SaveCertificate ¶
func (cu *CryptoUnit) SaveCertificate() error
func (*CryptoUnit) SavePrivateKey ¶
func (cu *CryptoUnit) SavePrivateKey() error
func (*CryptoUnit) Trusted ¶
func (cu *CryptoUnit) Trusted() bool
type CryptoUnitConfig ¶
Click to show internal directories.
Click to hide internal directories.