Documentation ¶
Overview ¶
Package msg is all the wire types and their packing.
Index ¶
Constants ¶
View Source
const ( OVtErrType = iota // illegal OVtRootType OVtDirType OVtPointerType0 OVtPointerType1 OVtPointerType2 OVtPointerType3 OVtPointerType4 OVtPointerType5 OVtPointerType6 OVtPointerType7 // not used OVtPointerType8 // not used OVtPointerType9 // not used OVtDataType )
View Source
const ( VtDataType = iota << 3 VtDirType VtRootType VtCorruptType = 0xFF )
View Source
const ( KindRerror uint8 KindTping KindRping KindThello KindRhello KindTgoodbye KindRgoodbye /* not used */ KindTauth0 /* auth messages not implemented */ KindRauth0 /* auth messages not implemented */ KindTauth1 /* auth messages not implemented */ KindRauth1 /* auth messages not implemented */ KindTread KindRread KindTwrite KindRwrite KindTsync KindRsync KindTmax )
These are a bunch of constants for message types.
Variables ¶
View Source
var ErrBufTooSmall = fmt.Errorf("msg: destination buffer too small")
ErrBufTooSmall is returned when a buffer is too small for a message to write itself into.
Functions ¶
This section is empty.
Types ¶
type Thello ¶
Thello initiates the handshake.
Cribbing from the venti(7) manpage:
Venti connections must begin with a hello transaction. The VtThello message contains the protocol version that the client has chosen to use. The fields strength, crypto, and codec could be used to add authentication, encryption, and compression to the Venti session but are currently ignored. The rcrypto, and rcodec fields in the VtRhello response are similarly ignored. The uid and sid fields are intended to be the identity of the client and server but, given the lack of authentication, should be treated only as advisory. The initial hello should be the only hello transaction during the session.
type Tping ¶
type Tping struct {
Tag byte
}
Tping is the client pinging the server.
The ping message has no effect and is used mainly for debug- ging. Servers should respond immediately to pings.
Click to show internal directories.
Click to hide internal directories.