package
0.0.0-20240823171402-3d22d6da4128
Repository: https://github.com/mholt/caddy-l4.git
Documentation: pkg.go.dev
# Functions
ParseCaddyfileNestedHandlers parses the Caddyfile tokens for nested handlers, and composes a list of their raw json configurations.
ParseCaddyfileNestedMatcherSet parses the Caddyfile tokens for a nested matcher set, and returns its raw module map value.
ParseCaddyfileNestedRoutes parses the Caddyfile tokens for nested named matcher sets, handlers and matching timeout, composes a list of route configurations, and adjusts the matching timeout.
SetModuleNameInline sets the string value of moduleNameKey to moduleName in raw, where raw must be a JSON encoding of a map, and returns the modified raw.
WrapConnection wraps an underlying connection into a layer4 connection that supports recording and rewinding, as well as adding context with a replacer and variable table.
# Constants
No description provided by the author
MaxMatchingBytes is the amount of bytes that are at most prefetched during matching.
# Variables
No description provided by the author
No description provided by the author
No description provided by the author
ReplacerCtxKey is the key used to store the replacer.
VarsCtxKey is the key used to store the variables table in a Connection's context.
# Structs
App is a Caddy app that operates closest to layer 4 of the OSI model.
Connection contains information about the connection as it passes through various handlers.
ListenerWrapper is a Caddy module that wraps App as a listener wrapper, it doesn't support udp.
MatchLocalIP matches requests by local IP (or CIDR range).
MatchNot matches requests by negating the results of its matcher sets.
MatchRemoteIP matches requests by remote IP (or CIDR range).
Route represents a collection of handlers that are gated by matching logic.
Server represents a Caddy layer4 server.
# Interfaces
ConnMatcher is a type that can match a connection.
Handler is a type that can handle connections.
NextHandler is a type that can handle connections as part of a middleware chain.
# Type aliases
HandlerFunc can turn a function into a Handler type.
Handlers is a list of connection handlers.
MatcherSet is a set of matchers which must all match in order for the request to be matched successfully.
MatcherSets is a group of matcher sets capable of checking whether a connection matches any of the sets.
Middleware is a function that wraps a handler.
NextHandlerFunc can turn a function into a NextHandler type.
RawMatcherSets is a group of matcher sets in their raw JSON form.
RouteList is a list of connection routes that can create a middleware chain.