Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func NewGRPCTransport ¶
func NewGRPCTransport(callbacks plugintk.TransportCallbacks) plugintk.TransportAPI
Types ¶
type Config ¶
type Config struct { // optional remote hostname to return in local transport details ExternalHostname *string `json:"externalHostname"` // TLS configuration details TLS pldconf.TLSConfig `json:"tls"` // address to listen on Address *string `json:"address"` // port to listen on Port *int `json:"port"` // If true (default) a network can be built by publishing self-signed certs to a registry without a common CA. // This disables the default certificate verification chain, and instead performs a direct comparison // of the certificate against the registered certificate for the extracted node name. DirectCertVerification *bool `json:"directCertVerification,omitempty"` // By default directCertVerification will expect the CN of the subject to be the exact registered node name. // Optionally certSubjectMatcher can supply a regexp containing a SINGLE CAPTURE GROUP that can be used to extract the name from the subject string CertSubjectMatcher *string `json:"certSubjectMatcher,omitempty"` }
type PublishedTransportDetails ¶
type PublishedTransportDetails struct { Endpoint string `json:"endpoint"` // a GRPC target string that other nodes can use to connect to this node // A node specific PEM certificate/certificate-set to use to validate the certificate provided by a node // - used in direct certificate validation mode only // - can be the certificate itself for self-signed // - must be the direct parent (not the root of a chain - for that use normal CA verification) Issuers string `json:"issuers,omitempty"` }
This is the JSON structure that any node in the network must share to be connectable by this plugin. We require the local node's registered information to be available at configuration time otherwise we cannot start up.
Click to show internal directories.
Click to hide internal directories.