obfs

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2022 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Obfuscator

type Obfuscator interface {
	Deobfuscate(in []byte, out []byte) int
	Obfuscate(in []byte, out []byte) int
}

type XPlusObfuscator

type XPlusObfuscator struct {
	Key     []byte
	RandSrc *rand.Rand
	// contains filtered or unexported fields
}

XPlusObfuscator obfuscates payload using one-time keys generated from hashing a pre-shared key and random salt. Packet format: [salt][obfuscated payload]

func NewXPlusObfuscator

func NewXPlusObfuscator(key []byte) *XPlusObfuscator

func (*XPlusObfuscator) Deobfuscate

func (x *XPlusObfuscator) Deobfuscate(in []byte, out []byte) int

func (*XPlusObfuscator) Obfuscate

func (x *XPlusObfuscator) Obfuscate(in []byte, out []byte) int

Jump to

Keyboard shortcuts

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