protocol

package
v0.0.0-...-25c57ca Latest Latest
Warning

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

Go to latest
Published: Jan 17, 2018 License: BSD-2-Clause Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Copernicus                    = "0.0.1"
	BitcoinProtocolVersion uint32 = 70012
	PeerAddressTimeVersion uint32 = 31402
	MaxUserAgentLen               = 256
	MultipleAddressVersion uint32 = 209
	MaxProtocolVersion     uint32 = 70012
	RejectVersion          uint32 = 70002
	Bip0037Version         uint32 = 70001
	Bip0031Version         uint32 = 60000
	Bip0111Version         uint32 = 70011

	MaxKnownInventory = 1000
)
View Source
const (
	SFNodeNetworkAsFullNode = 1 << iota
	SFNodeGetUtxo
	SFNodeBloomFilter
)
View Source
const CommandSize = 12
View Source
const MaxMessagePayload = 1024 * 1024 * 32

Variables

View Source
var LocalUserAgent string

Functions

func ReadElement

func ReadElement(reader io.Reader, element interface{}) error

func ReadElements

func ReadElements(r io.Reader, elements ...interface{}) error

func ValidateUserAgent

func ValidateUserAgent(useAgent string) error

func WriteElement

func WriteElement(w io.Writer, element interface{}) error

func WriteElements

func WriteElements(w io.Writer, elements ...interface{}) error

Types

type BloomUpdateType

type BloomUpdateType uint8

BloomUpdateType specifies how the filter is updated when a match is found

type Int64Time

type Int64Time time.Time

type InventoryType

type InventoryType uint32

InventoryType represents the allowed types of inventory vectors. See InvVect.

type RejectCode

type RejectCode uint8

RejectCode represents a numeric value by which a remote p2p indicates why a msg was rejected.

type ServiceFlag

type ServiceFlag uint64

func (ServiceFlag) ToString

func (f ServiceFlag) ToString() string

type Uint32Time

type Uint32Time time.Time

Jump to

Keyboard shortcuts

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