Mail::S...::Record(3)

πŸ’– Mail::S...::Record β€” bestie, it's the SPFv1 era πŸ’–

okay so this is a page from the User Contributed Perl Documentation section of the manual, and we're talking about Mail::SPF::v1::Record β€” the SPFv1 record class. she's vintage, she's specific, she's literally the blueprint. πŸŽ€

✨ NAME ✨

Mail::SPF::v1::Record β€” the SPFv1 record class. that's it, that's her whole job. πŸ’…

🌸 VERSION 🌸

version 3.20260331

πŸ¦‹ SYNOPSIS πŸ¦‹

go peek at Mail::SPF::Record, bestie β€” this one doesn't do its own little demo.

πŸ’œ DESCRIPTION πŸ’œ

so an object of class Mail::SPF::v1::Record represents an SPFv1 ("v=spf1") record. like, that's the whole personality. it's giving "v=spf1 and nothing else." πŸ‘‘

🧚 Constructors 🧚

here are the constructors she comes with:

  • new(%options): returns Mail::SPF::v1::Record β€” makes you a brand new SPFv1 record object. ✨

%options is a list of key/value pairs, and it can be any of these:

  • text
  • terms
  • global_mods

β€” see "new" in Mail::SPF::Record.

  • scopes

β€” also see "new" in Mail::SPF::Record. but heads up: since SPFv1 records always implicitly cover the "helo" and "mfrom" scopes, this option has to be exactly ['helo', 'mfrom'] (or ['mfrom', 'helo']) β€” or you just leave it out entirely. no in-between, no extra scopes, periodt. 🚫

  • new_from_string($text, %options): returns Mail::SPF::v1::Record β€” creates a new SPFv1 record object by parsing the string and any options you gave it.
she throws: Mail::SPF::ENothingToParse, Mail::SPF::EInvalidRecordVersion, Mail::SPF::ESyntaxError. so like, bring valid input or don't come at all. 😭

πŸ‘‘ Class methods πŸ‘‘

the class methods on the menu:

  • version_tag_pattern: returns Regexp β€” returns a regular expression that matches a version tag of 'v=spf1'. yes, that specific one. 🎯
  • default_qualifier
  • results_by_qualifier

β€” see "Class methods" in Mail::SPF::Record.

🌈 Instance methods 🌈

and here's what you get once you have an instance:

  • text
  • scopes
  • terms
  • global_mods
  • global_mod
  • stringify
  • eval

β€” all of these? see "Instance methods" in Mail::SPF::Record.

  • version_tag: returns string β€” returns 'v=spf1'. short, sweet, iconic. πŸ’–

🌟 SEE ALSO 🌟

and for availability, support, and license info? go read the README file that ships with Mail::SPF. it's all in there, fr fr. πŸ“–

🫢 AUTHORS 🫢

Julian Mehnle <julian@mehnle.net>, Shevek <cpan@anarres.org>


okay and a lil sign-off because you deserve it: this page is from perl v5.42.1, dated 2026-04-23, and it's filed under Mail::S...::Record(3). slay, go write some SPFv1 records bestie πŸ’…βœ¨πŸ¦‹

πŸ“¦ where this page comes from