Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ErrMissingDomainRecord = errors.New("missing domain record")
ErrMissingDomainRecord is returned when some record is missing in the particular domain.
Functions ¶
This section is empty.
Types ¶
type NNS ¶
type NNS interface { // CheckDomainRecord checks whether NNS domain with the specified name exists // and has given TXT record. Returns [ErrMissingDomainRecord] if domain exists // but has no given record, or any other error encountered prevented the check. // // Both domain name and record are non-empty. CheckDomainRecord(domainName string, record string) error }
NNS provides services of the NeoFS NNS consumed by Validator to process.
type Validator ¶
type Validator struct {
// contains filtered or unexported fields
}
Validator validates NNS domains declared by the storage nodes on their attempts to enter the NeoFS network map.
There is an option to specify name of the verified nodes' domain. Such domains allow to combine several nodes into a private group (kind of subnet). Access is controlled using access lists: Validator checks that any incoming node declaring private node domain is presented in the corresponding access list. Access lists are stored in the NeoFS NNS: for each private node group, there is a registered NNS domain. TXT records of each such domain are Neo addresses of the nodes' public keys. To be allowed to use a specific verified domain value, the storage node must have a Neo address from this list. Otherwise, the storage node will be denied access to the network map. Note that if domain exists but has no records, then access is forbidden for anyone.