Documentation ¶
Overview ¶
Package hooks provides functionality for managing hooks.
Index ¶
- func GetPortToSendToKernel(_ context.Context, rules []config.BypassRule) []uint
- func IPv4ToUint32(ipStr string) (uint32, error)
- func ToIPv4MappedIPv6(ipv4 string) ([4]uint32, error)
- type Hooks
- func (h *Hooks) CleanProxyEntry(srcPort uint16) error
- func (h *Hooks) Delete(_ context.Context, srcPort uint16) error
- func (h *Hooks) Get(_ context.Context, srcPort uint16) (*core.NetworkAddress, error)
- func (h *Hooks) GetDestinationInfo(srcPort uint16) (*structs.DestInfo, error)
- func (h *Hooks) Load(ctx context.Context, id uint64, opts core.HookCfg) error
- func (h *Hooks) Record(ctx context.Context, _ uint64, opts models.IncomingOptions) (<-chan *models.TestCase, error)
- func (h *Hooks) SendAgentInfo(agentInfo structs.AgentInfo) error
- func (h *Hooks) SendClientInfo(id uint64, appInfo structs.ClientInfo) error
- func (h *Hooks) SendDockerAppInfo(_ uint64, dockerAppInfo structs.DockerAppInfo) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetPortToSendToKernel ¶
func GetPortToSendToKernel(_ context.Context, rules []config.BypassRule) []uint
func IPv4ToUint32 ¶
IPv4ToUint32 converts a string representation of an IPv4 address to a 32-bit integer.
func ToIPv4MappedIPv6 ¶
ToIPv4MappedIPv6 converts an IPv4 address to an IPv4-mapped IPv6 address.
Types ¶
type Hooks ¶
type Hooks struct {
// contains filtered or unexported fields
}
func (*Hooks) CleanProxyEntry ¶
func (*Hooks) GetDestinationInfo ¶
GetDestinationInfo retrieves destination information associated with a source port.
func (*Hooks) SendClientInfo ¶
func (h *Hooks) SendClientInfo(id uint64, appInfo structs.ClientInfo) error
func (*Hooks) SendDockerAppInfo ¶
func (h *Hooks) SendDockerAppInfo(_ uint64, dockerAppInfo structs.DockerAppInfo) error
Click to show internal directories.
Click to hide internal directories.