Mail::SpamAssassin::RegistryBoundaries(3pm)

Mail::SpamAssassin::RegistryBoundaries3pm

Domain delegation rules

Methods

($hostname, $domain) = split_domain ($fqdn, $is_ascii)

Cut a fully-qualified hostname into the hostname part and the domain part, splitting at the DNS registry boundary.

Examples:

    "www.foo.com" => ( "www", "foo.com" )
    "www.foo.co.uk" => ( "www", "foo.co.uk" )

If $is_ascii given and true, skip idn_to_ascii() conversion

$domain = trim_domain($fqdn, $is_ascii)

Cut a fully-qualified hostname into the hostname part and the domain part, returning just the domain.

Examples:

    "www.foo.com" => "foo.com"
    "www.foo.co.uk" => "foo.co.uk"

If $is_ascii given and true, skip idn_to_ascii() conversion

$ok = is_domain_valid($dom, $is_ascii)

Return 1 if the domain/hostname uses valid known TLD, "undef" otherwise.

If $is_ascii given and true, skip idn_to_ascii() conversion.

Note that this only checks the TLD validity and nothing else. To verify that the complete fqdn is in a valid legal format, Util::is_fqdn_valid() can additionally be used.

Releases

6 releases since Debian 9 (Stretch); the text changed 5 times.

  1. 9
  2. 10
  3. 11
  4. 12
  5. 13
  6. Arch

From spamassassin 4.0.2-3 in Arch Linux 2026-11-01. Parsed by carta from the page's man source.