package origin import ( "context" "net/netip" ) type Client struct { Addr netip.Addr UserAgent string } type key struct{} func With(ctx context.Context, c Client) context.Context { return context.WithValue(ctx, key{}, c) } func Of(ctx context.Context) Client { c, _ := ctx.Value(key{}).(Client) return c }