Mail::BIMI - BIMI object
version 3.20231123
Brand Indicators for Message Identification (BIMI) retrieval, validation, and processing
# Assuming we have a message, and have verified it has exactly one From Header domain, and passes # any other BIMI and local site requirements not related to BIMI record validation... # For example, relevant DKIM coverage of any BIMI-Selector header my $message = ...Specifics of adding headers and Authentication-Results is left to the reader... my $domain = "example.com"; # domain from From header my $selector = "default"; # selector from From header my $spf = Mail::SPF->new( ...See Mail::SPF POD for options... ); my $dmarc = Mail::DMARC::PurePerl->new( ...See Mail::DMARC POD for options... ); $dmarc->validate; my $bimi = Mail::BIMI->new( dmarc_object => $dmarc, spf_object => $spf, domain => $domain, selector => $selector, ); my $auth_results = $bimi->get_authentication_results_object; my $bimi_result = $bimi->result; $message->add_auth_results($auth_results); # See Mail::AuthenticationResults POD for usage if ( $bimi_result->result eq 'pass' ) { my $headers = $result->headers; if ($headers) { $message->add_header( 'BIMI-Location', $headers->{'BIMI-Location'} if exists $headers->{'BIMI-Location'}; $message->add_header( 'BIMI-Indicator', $headers->{'BIMI-Indicator'} if exists $headers->{'BIMI-Indicator'}; } }
These values are used as inputs for lookups and verifications, they are typically set by the caller based on values found in the message being processed
is=rw
Validated Mail::DMARC::PurePerl object from parsed message
Domain to lookup/domain record was retrieved from
Net::DNS::Resolver object to use for DNS lookups; default used if not set
Selector to lookup/selector record was retrieved from
Mail::SPF::Result object from parsed message
These values are derived from lookups and verifications made based upon the input values, it is however possible to override these with other values should you wish to, for example, validate a record before it is published in DNS, or validate an Indicator which is only available locally
Relevant Mail::DMARC::PurePerl object
Relevant Mail::DMARC::Result object
Options class
Mail::BIMI::Record object
Mail::BIMI::Result object
is=ro
time of retrieval - useful in testing
Mail::BIMI::Role::HasError
Moose::Object
Finish and clean up, write cache if enabled.
Output given text if in verbose mode.
Mail::BIMI::Options
Mail::BIMI::Prelude
Mail::BIMI::Record
Mail::BIMI::Result
Mail::DMARC::PurePerl
Moose
Moose::Util::TypeConstraints
Net::DNS::Resolver
Marc Bradshaw <marc@marcbradshaw.net>
This software is copyright (c) 2020 by Marc Bradshaw.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Mail::BIMI, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Mail::BIMI
CPAN shell
perl -MCPAN -e shell install Mail::BIMI
For more information on module installation, please visit the detailed CPAN module installation guide.