Documentation
¶
Overview ¶
Package outbound provides the private per-operation TLS admission boundary.
Index ¶
Constants ¶
This section is empty.
Variables ¶
ErrEndpointUnavailable means an explicit refusal, absent DNS name, or no network/host route. It allows replacement, never resource retirement.
var ErrPeerDenied = errors.New("outbound: peer denied")
ErrPeerDenied identifies explicit TLS identity/policy refusal, not a timeout or connection failure. Callers may replace work but cannot infer retirement.
Functions ¶
This section is empty.
Types ¶
type Transport ¶
type Transport struct {
// contains filtered or unexported fields
}
Transport admits one fresh, fully verified HTTP/1.1 TLS connection per operation. There is deliberately no connection reuse or session resumption. Rebuild after credential/root rotation. Existing transports still call the current policy on every operation. Policy and TLS callbacks must cooperate with cancellation and be concurrency safe; opaque signer keys and callback captures must remain immutable. No locks are held across callbacks/network IO.
func New ¶
func New(endpoint string, config *tls.Config, timeout time.Duration, check func(context.Context, tls.ConnectionState) error) (*Transport, error)
New ignores caller HTTP dial/proxy hooks entirely. check must compose current nodewire.Guard.RecheckServer with the expected complete identity and hostname. timeout bounds TCP, TLS and cooperative policy admission, not response bodies.
func (*Transport) CloseIdleConnections ¶
func (t *Transport) CloseIdleConnections()
func (*Transport) ResponseHeaderTimeout ¶
ResponseHeaderTimeout sets the wait for the first response headers separately from TCP/TLS admission. Call only before the transport's first request. Media may wait for an encoder segment while dead endpoints must fail quickly.