Mail::...Results(3pm)

πŸ“¦ version 4.0.2+svn1935691, in ubuntu stonking

πŸ’– NAME πŸ’–

Mail::SpamAssassin::Header::AuthenticationResults β€” bestie, it's a parser for Authentication-Results headers ✨ (from the User Contributed Perl Documentation, iykyk 🫢)


🌸 SYNOPSIS 🌸

okay so here's the vibe, literally copy-paste coded:

my $ar = Mail::SpamAssassin::Header::AuthenticationResults->new($hdr_value);
print $ar->authserv_id();    # 'mx.example.com'
print $ar->version();        # 1
my @names = $ar->methods();  # ('spf', 'dkim', ...)
my @results = $ar->method('dkim'); # list of result hashes

like, you feed it a header value and it just gets it πŸ’…


πŸ¦‹ DESCRIPTION πŸ¦‹

so this class inherits from ParameterHeader, and its whole thing is parsing Authentication-Results header fields per RFC 8601 ⭐

and like, ParameterHeader is already carrying the team on the annoying parts, no cap:

  • comment stripping
  • semicolon tokenization
  • quoted strings
  • line unfolding

then this class rolls up and adds the A-R-specific secondary parsing of each method's value string πŸ”₯ like it's the main character of the method-parsing arc, fr fr πŸ‘‘


πŸŽ€ METHODS πŸŽ€

  • new($value) β€” spins up a brand new instance, parsing the given raw header value 🍼✨
  • authserv_id() β€” hands you back the authserv-id (that's the first token of the header value, bestie), all lowercased πŸ’š
  • version() β€” returns the version number (default 1, iconic default behavior 🫢)
  • methods() β€” returns a list of method names that have results 🌈
  • method($name) β€” returns the result(s) for the given method name ✨ Each result is a hash containing "result", "reason", and "properties" πŸ’– In list context it returns all results; in scalar context it returns just the first one. yes, context matters, it's giving dual personality and we love that for it πŸ’…

ngl bestie, that's the whole page β€” every option, every detail, nothing skipped, periodt 🧚

cute little sign-off: this gem comes from perl v5.40.1, dated 2026-07-23, and it's filed under Mail::...Results(3pm) (the User Contributed Perl Documentation, ofc πŸ’œ). go parse those headers, you're doing amazing sweetie πŸ“πŸ‘‘

πŸ“¦ where this page comes from