APLRecordValidator
class APLRecordValidator implements DnsRecordValidatorInterface (View source)
Validator for APL (Address Prefix List) DNS records
Validates APL records according to RFC 3123: https://tools.ietf.org/html/rfc3123
APL RR type has a value of 42 and is used for lists of address prefixes, primarily for network access control or description purposes.
Format: [!]afi:address/prefix [!]afi:address/prefix ...
Where:
- ! (optional): Negation symbol
- afi: Address Family Identifier (1 for IPv4, 2 for IPv6)
- address: Network address in appropriate format (IPv4 dotted quad or IPv6 notation)
- prefix: Prefix length (0-32 for IPv4, 0-128 for IPv6)
Multiple address prefix items can be listed, separated by whitespace. An empty APL RR is valid and represents an empty list.
Examples:
- "1:192.0.2.0/24" (IPv4 subnet)
- "2:2001:db8::/32" (IPv6 subnet)
- "!1:192.0.2.0/24 2:2001:db8::/32" (Negated IPv4 subnet plus IPv6 subnet)
Methods
validate(string $content, string $name, mixed $prio, int|string|null $ttl, int $defaultTTL, mixed ...$args)
Validate APL record
Details
__construct(ConfigurationManager $config)
Constructor
ValidationResult
validate(string $content, string $name, mixed $prio, int|string|null $ttl, int $defaultTTL, mixed ...$args)
Validate APL record