commons

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Feb 4, 2016 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MT_STRING    MSG_TYPE = 0 + iota // String
	MT_INTRO              = 1        // Introduction packet
	MT_INTRO_REQ          = 2
	MT_NENC               = 3 // Not encrypted message
	MT_ENC                = 4 // Encrypted message
	MT_PING               = 5 // Internal ping message
	MT_TEST               = 6
	MT_PROXY              = 7
)

Internal network packet type

View Source
const (
	CMD_CONN   string = "conn"
	CMD_FIND   string = "find"
	CMD_NODE   string = "node"
	CMD_PING   string = "ping"
	CMD_REGCP  string = "regcp"
	CMD_BADCP  string = "badcp"
	CMD_CP     string = "cp"
	CMD_NOTIFY string = "notify"
	CMD_LOAD   string = "load"
	CMD_STOP   string = "stop"
)

List of commands used in DHT

Variables

This section is empty.

Functions

This section is empty.

Types

type DHTRequest

type DHTRequest struct {
	Id      string "i"
	Hash    string "h"
	Command string "c"
	Port    string "p"
}

TODO: Modify these structures

type DHTResponse

type DHTResponse struct {
	Id      string "i"
	Dest    string "h"
	Command string "c"
}

type MSG_TYPE

type MSG_TYPE uint16

Jump to

Keyboard shortcuts

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