mitm

package
v0.0.0-...-2e9020c Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2023 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var MaxSerialNumber = big.NewInt(0).SetBytes(bytes.Repeat([]byte{255}, 20))

Functions

func NewAuthority

func NewAuthority(name, organization string, validity time.Duration) (*x509.Certificate, *rsa.PrivateKey, error)

Types

type Config

type Config struct {
	// contains filtered or unexported fields
}

func NewConfig

func NewConfig(ca *x509.Certificate, privateKey interface{}) (*Config, error)

func (*Config) HandshakeErrorCallback

func (c *Config) HandshakeErrorCallback(r *http.Request, err error)

func (*Config) SetHandshakeErrorCallback

func (c *Config) SetHandshakeErrorCallback(cb func(*http.Request, error))

func (*Config) SetOrganization

func (c *Config) SetOrganization(org string)

func (*Config) SetValidity

func (c *Config) SetValidity(validity time.Duration)

func (*Config) SkipTLSVerify

func (c *Config) SkipTLSVerify(skip bool)

func (*Config) TLS

func (c *Config) TLS() *tls.Config

func (*Config) TLSForHost

func (c *Config) TLSForHost(hostname string) *tls.Config

Jump to

Keyboard shortcuts

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