Documentation
¶
Index ¶
- Constants
- func BuildRemovedX25519MLKEM768HandshakeState(c *UConn) error
- func BuildWebsocketHandshakeState(c *UConn) error
- func GetRealityConn(ctx context.Context, conn net.Conn, fingerprint UClientHelloID, ...) (net.Conn, error)
- func GetTLSConnectionState(conn net.Conn) (tlsState tls.ConnectionState)
- func NewListener(inner net.Listener, config *Config) net.Listener
- func UCertificate(it tls.Certificate) utls.Certificate
- func UConfig(config *tls.Config) *utls.Config
- func UEncryptedClientHelloKey(it tls.EncryptedClientHelloKey) utls.EncryptedClientHelloKey
- type Certificate
- type Config
- type Conn
- type ConnectionState
- type EncryptedClientHelloKey
- type RealityConfig
- type UClientHelloID
- type UConn
Constants ¶
View Source
const RealityMaxShortIDLen = 8
View Source
const VersionTLS12 = utls.VersionTLS12
View Source
const VersionTLS13 = utls.VersionTLS13
Variables ¶
This section is empty.
Functions ¶
func BuildWebsocketHandshakeState ¶
BuildWebsocketHandshakeState it will only send http/1.1 in its ALPN. Copy from https://github.com/XTLS/Xray-core/blob/main/transport/internet/tls/tls.go
func GetRealityConn ¶
func GetRealityConn(ctx context.Context, conn net.Conn, fingerprint UClientHelloID, serverName string, realityConfig *RealityConfig) (net.Conn, error)
func GetTLSConnectionState ¶
func GetTLSConnectionState(conn net.Conn) (tlsState tls.ConnectionState)
func UCertificate ¶
func UCertificate(it tls.Certificate) utls.Certificate
func UEncryptedClientHelloKey ¶
func UEncryptedClientHelloKey(it tls.EncryptedClientHelloKey) utls.EncryptedClientHelloKey
Types ¶
type Certificate ¶
type Certificate = utls.Certificate
type ConnectionState ¶
type ConnectionState = utls.ConnectionState
type EncryptedClientHelloKey ¶
type EncryptedClientHelloKey = utls.EncryptedClientHelloKey
type RealityConfig ¶
type RealityConfig struct {
PublicKey *ecdh.PublicKey
ShortID [RealityMaxShortIDLen]byte
SupportX25519MLKEM768 bool
}
type UClientHelloID ¶
type UClientHelloID = utls.ClientHelloID
func GetFingerprint ¶
func GetFingerprint(clientFingerprint string) (UClientHelloID, bool)
Click to show internal directories.
Click to hide internal directories.