Documentation ¶
Index ¶
- func BytesToInt64(buf []byte) int64
- func ConnEncrypt(conn net.Conn, metakey []byte, cipherID int) (*es.EncryptedStream, error)
- func DecrptogRSA(src []byte, privateKey *rsa.PrivateKey) (res []byte, err error)
- func EncyptogRSA(src []byte, publicKey *rsa.PublicKey) (res []byte, err error)
- func Int64ToBytes(i int64) []byte
- func ListCipher() []string
- func LoadCipher(cipher string) (int, error)
- func LoadPrivateKey(path string) (privateKey *rsa.PrivateKey, err error)
- func LoadPublicKey(path string) (publicKey *rsa.PublicKey, err error)
- func NewChaCha20Poly1305Cipher(key []byte) (*es.CryptoAEADCipher, error)
- func NewXChaCha20Poly1305Cipher(key []byte) (*es.CryptoAEADCipher, error)
- func RSAGenKey(bits int, who string) error
- func Socks5DstAddrPort(buf []byte) (*net.TCPAddr, error)
- func Socks5Forward(srcConn, dstConn io.ReadWriter)
- type Config
- type Nid
- type Nothing
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BytesToInt64 ¶
func ConnEncrypt ¶
func DecrptogRSA ¶
func DecrptogRSA(src []byte, privateKey *rsa.PrivateKey) (res []byte, err error)
DecrptogRSA 对数据进行解密操作
func EncyptogRSA ¶
EncyptogRSA 对数据进行加密操作
func Int64ToBytes ¶
func ListCipher ¶
func ListCipher() []string
func LoadCipher ¶
func LoadPrivateKey ¶
func LoadPrivateKey(path string) (privateKey *rsa.PrivateKey, err error)
func NewChaCha20Poly1305Cipher ¶
func NewChaCha20Poly1305Cipher(key []byte) (*es.CryptoAEADCipher, error)
func NewXChaCha20Poly1305Cipher ¶
func NewXChaCha20Poly1305Cipher(key []byte) (*es.CryptoAEADCipher, error)
func Socks5Forward ¶
func Socks5Forward(srcConn, dstConn io.ReadWriter)
Types ¶
type Config ¶
func (*Config) NewNothing ¶
Click to show internal directories.
Click to hide internal directories.