go/src/crypto/tls/handshake_messages.go

type marshalingFunction

func (f marshalingFunction) Marshal(b *cryptobyte.Builder) error {}

// addBytesWithLength appends a sequence of bytes to the cryptobyte.Builder. If
// the length of the sequence is not the value specified, it produces an error.
func addBytesWithLength(b *cryptobyte.Builder, v []byte, n int) {}

// addUint64 appends a big-endian, 64-bit value to the cryptobyte.Builder.
func addUint64(b *cryptobyte.Builder, v uint64) {}

// readUint64 decodes a big-endian, 64-bit value into out and advances over it.
// It reports whether the read was successful.
func readUint64(s *cryptobyte.String, out *uint64) bool {}

// readUint8LengthPrefixed acts like s.ReadUint8LengthPrefixed, but targets a
// []byte instead of a cryptobyte.String.
func readUint8LengthPrefixed(s *cryptobyte.String, out *[]byte) bool {}

// readUint16LengthPrefixed acts like s.ReadUint16LengthPrefixed, but targets a
// []byte instead of a cryptobyte.String.
func readUint16LengthPrefixed(s *cryptobyte.String, out *[]byte) bool {}

// readUint24LengthPrefixed acts like s.ReadUint24LengthPrefixed, but targets a
// []byte instead of a cryptobyte.String.
func readUint24LengthPrefixed(s *cryptobyte.String, out *[]byte) bool {}

type clientHelloMsg

func (m *clientHelloMsg) marshalMsg(echInner bool) ([]byte, error) {}

func (m *clientHelloMsg) marshal() ([]byte, error) {}

// marshalWithoutBinders returns the ClientHello through the
// PreSharedKeyExtension.identities field, according to RFC 8446, Section
// 4.2.11.2. Note that m.pskBinders must be set to slices of the correct length.
func (m *clientHelloMsg) marshalWithoutBinders() ([]byte, error) {}

// updateBinders updates the m.pskBinders field. The supplied binders must have
// the same length as the current m.pskBinders.
func (m *clientHelloMsg) updateBinders(pskBinders [][]byte) error {}

func (m *clientHelloMsg) unmarshal(data []byte) bool {}

func (m *clientHelloMsg) originalBytes() []byte {}

func (m *clientHelloMsg) clone() *clientHelloMsg {}

type serverHelloMsg

func (m *serverHelloMsg) marshal() ([]byte, error) {}

func (m *serverHelloMsg) unmarshal(data []byte) bool {}

func (m *serverHelloMsg) originalBytes() []byte {}

type encryptedExtensionsMsg

func (m *encryptedExtensionsMsg) marshal() ([]byte, error) {}

func (m *encryptedExtensionsMsg) unmarshal(data []byte) bool {}

type endOfEarlyDataMsg

func (m *endOfEarlyDataMsg) marshal() ([]byte, error) {}

func (m *endOfEarlyDataMsg) unmarshal(data []byte) bool {}

type keyUpdateMsg

func (m *keyUpdateMsg) marshal() ([]byte, error) {}

func (m *keyUpdateMsg) unmarshal(data []byte) bool {}

type newSessionTicketMsgTLS13

func (m *newSessionTicketMsgTLS13) marshal() ([]byte, error) {}

func (m *newSessionTicketMsgTLS13) unmarshal(data []byte) bool {}

type certificateRequestMsgTLS13

func (m *certificateRequestMsgTLS13) marshal() ([]byte, error) {}

func (m *certificateRequestMsgTLS13) unmarshal(data []byte) bool {}

type certificateMsg

func (m *certificateMsg) marshal() ([]byte, error) {}

func (m *certificateMsg) unmarshal(data []byte) bool {}

type certificateMsgTLS13

func (m *certificateMsgTLS13) marshal() ([]byte, error) {}

func marshalCertificate(b *cryptobyte.Builder, certificate Certificate) {}

func (m *certificateMsgTLS13) unmarshal(data []byte) bool {}

func unmarshalCertificate(s *cryptobyte.String, certificate *Certificate) bool {}

type serverKeyExchangeMsg

func (m *serverKeyExchangeMsg) marshal() ([]byte, error) {}

func (m *serverKeyExchangeMsg) unmarshal(data []byte) bool {}

type certificateStatusMsg

func (m *certificateStatusMsg) marshal() ([]byte, error) {}

func (m *certificateStatusMsg) unmarshal(data []byte) bool {}

type serverHelloDoneMsg

func (m *serverHelloDoneMsg) marshal() ([]byte, error) {}

func (m *serverHelloDoneMsg) unmarshal(data []byte) bool {}

type clientKeyExchangeMsg

func (m *clientKeyExchangeMsg) marshal() ([]byte, error) {}

func (m *clientKeyExchangeMsg) unmarshal(data []byte) bool {}

type finishedMsg

func (m *finishedMsg) marshal() ([]byte, error) {}

func (m *finishedMsg) unmarshal(data []byte) bool {}

type certificateRequestMsg

func (m *certificateRequestMsg) marshal() ([]byte, error) {}

func (m *certificateRequestMsg) unmarshal(data []byte) bool {}

type certificateVerifyMsg

func (m *certificateVerifyMsg) marshal() ([]byte, error) {}

func (m *certificateVerifyMsg) unmarshal(data []byte) bool {}

type newSessionTicketMsg

func (m *newSessionTicketMsg) marshal() ([]byte, error) {}

func (m *newSessionTicketMsg) unmarshal(data []byte) bool {}

type helloRequestMsg

func (*helloRequestMsg) marshal() ([]byte, error) {}

func (*helloRequestMsg) unmarshal(data []byte) bool {}

type transcriptHash

// transcriptMsg is a helper used to hash messages which are not hashed when
// they are read from, or written to, the wire. This is typically the case for
// messages which are either not sent, or need to be hashed out of order from
// when they are read/written.
//
// For most messages, the message is marshalled using their marshal method,
// since their wire representation is idempotent. For clientHelloMsg and
// serverHelloMsg, we store the original wire representation of the message and
// use that for hashing, since unmarshal/marshal are not idempotent due to
// extension ordering and other malleable fields, which may cause differences
// between what was received and what we marshal.
func transcriptMsg(msg handshakeMessage, h transcriptHash) error {}