tls

package
v2.0.0 Latest Latest
Warning

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

Go to latest
Published: Jul 29, 2025 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Overview

Package tls provides functionality for handling tls connetions.

Index

Constants

This section is empty.

Variables

View Source
var SrcPortToDstURL = sync.Map{}

SrcPortToDstURL map is used to store the mapping between source port and DstURL for the TLS connection

Functions

func CertForClient

func CertForClient(logger *zap.Logger, clientHello *tls.ClientHelloInfo, caPrivKey any, caCertParsed *x509.Certificate, backdate time.Time) (*tls.Certificate, error)

func HandleTLSConnection

func HandleTLSConnection(_ context.Context, logger *zap.Logger, conn net.Conn, backdate time.Time) (net.Conn, error)

func IsTLSHandshake

func IsTLSHandshake(data []byte) bool

func SetupCA

func SetupCA(ctx context.Context, logger *zap.Logger) error

SetupCA setups custom certificate authority to handle TLS connections

Types

This section is empty.

Source Files

  • ca.go
  • tls.go

Jump to

Keyboard shortcuts

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