Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Discoverer ¶
Discoverer can be used to discover remote hidden path instances.
func (*Discoverer) Discover ¶
func (d *Discoverer) Discover(ctx context.Context, dsAddr net.Addr) (hiddenpath.Servers, error)
Discover discovers hidden path services at the discovery service that is given by the address.
type Register ¶
type Register struct {
// Dialer dials a new gRPC connection.
Dialer libgrpc.Dialer
// RegularRegistration is the regular segment registration.
RegularRegistration beaconing.RPC
}
Register can be used to register segments to remotes.
func (Register) RegisterSegment ¶
func (s Register) RegisterSegment(ctx context.Context, reg hiddenpath.SegmentRegistration, remote net.Addr) error
RegisterSegment registers the segment at the remote. If the hidden path group ID is not defined it is registered via a normal segment registration message
type RegistrationServer ¶
type RegistrationServer struct {
Registry hiddenpath.Registry
}
RegistrationServer handles gRPC segment registration requests.
func (RegistrationServer) HiddenSegmentRegistration ¶
func (s RegistrationServer) HiddenSegmentRegistration(ctx context.Context, req *hspb.HiddenSegmentRegistrationRequest) (*hspb.HiddenSegmentRegistrationResponse, error)
HiddenSegmentRegistration handles the gRPC hidden segment registration request.
type Requester ¶
type Requester struct {
// Dialer dials a new gRPC connection.
Dialer libgrpc.Dialer
// HPGroups is used to fetch hidden segments when the destination IA belongs
// to the writers of a group configuration.
HPGroups hiddenpath.Groups
// RegularLookup is the regular segment lookup.
RegularLookup segfetcher.RPC
}
Requester fetches segments from a remote using gRPC.
type SegmentServer ¶
type SegmentServer struct {
Lookup hiddenpath.Lookuper
Authoritative bool
}
SegmentServer serves segments from a lookuper.
func (*SegmentServer) HiddenSegments ¶
func (s *SegmentServer) HiddenSegments(ctx context.Context, pbReq *hspb.HiddenSegmentsRequest) (*hspb.HiddenSegmentsResponse, error)
HiddenSegments serves hidden segments requests using the provided lookup.