transport

package
v1.7.4 Latest Latest
Warning

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

Go to latest
Published: Mar 30, 2026 License: GPL-3.0 Imports: 45 Imported by: 7

README

server/transport

Overview

Server-side transports and listener orchestration. Coordinates C2 listener lifecycles and connection routing. Key routines cover local, middleware, mTLS, and tailscale within the transport subsystem.

Go Files

  • local.go – Implements local transport listeners and helpers.
  • middleware.go – Shared middleware for transport handler pipelines.
  • mtls.go – Manages mTLS server listener setup.
  • tailscale.go – Integrates Tailscale transport support for Sliver.

Documentation

Index

Constants

View Source
const (
	Transport contextKey = iota
	Operator
)
View Source
const (

	// ServerMaxMessageSize - Server-side max GRPC message size
	ServerMaxMessageSize = 2 * gb
)

Variables

This section is empty.

Functions

func ClearTokenCache added in v1.5.0

func ClearTokenCache()

ClearTokenCache - Clear the auth token cache

func CloseOperatorStreams added in v1.7.4

func CloseOperatorStreams(operator string) int

CloseOperatorStreams cancels all tracked operator-owned gRPC streams.

func LocalListener

func LocalListener() (*grpc.Server, *bufconn.Listener, error)

LocalListener - Bind gRPC server to an in-memory listener, which is typically used for unit testing, but ... it should be fine

func StartMtlsClientListener added in v1.6.0

func StartMtlsClientListener(host string, port uint16) (*grpc.Server, net.Listener, error)

StartMtlsClientListener - Start a mutual TLS listener

func StartMtlsClientServer added in v1.7.4

func StartMtlsClientServer(ln net.Listener) (*grpc.Server, error)

StartMtlsClientServer serves the authenticated multiplayer gRPC server on an existing listener. This is primarily useful for tests that need the full mTLS + auth stack without opening a real TCP socket.

func StartTsNetClientListener added in v1.6.0

func StartTsNetClientListener(hostname string, port uint16) (*grpc.Server, net.Listener, error)

StartTsNetClientListener - Start a TSNet gRPC listener

func StartWGWrappedMtlsClientListener added in v1.7.4

func StartWGWrappedMtlsClientListener(host string, port uint16) (*grpc.Server, net.Listener, error)

StartWGWrappedMtlsClientListener exposes the multiplayer mTLS listener only inside a WireGuard tunnel while preserving the existing gRPC/mTLS auth stack.

Types

This section is empty.

Jump to

Keyboard shortcuts

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