stream

package
v0.0.0-...-7e11129 Latest Latest
Warning

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

Go to latest
Published: Sep 10, 2020 License: GPL-3.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cipher

type Cipher struct {
	net.Conn

	Method string

	Enc cipher.Stream
	Dec cipher.Stream

	Info *cipherInfo
	// contains filtered or unexported fields
}

Cipher cipher

func NewCipher

func NewCipher(method string) *Cipher

NewCipher create cipher

func (*Cipher) Init

func (c *Cipher) Init(key []byte, conn net.Conn)

Init set key and conn

func (*Cipher) KeySize

func (c *Cipher) KeySize() int

KeySize return key size

func (*Cipher) Read

func (c *Cipher) Read(p []byte) (n int, err error)

Read read from client

func (*Cipher) Write

func (c *Cipher) Write(p []byte) (n int, err error)

Write write to client

Jump to

Keyboard shortcuts

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