Mail::...odeSRS(3pm)
π NAME π
Mail::Milter::Wrapper::DecodeSRS β bestie it's a milter wrapper that decodes your SRS-encoded return path β¨
πΈ SYNOPSIS πΈ
use Mail::Milter::Wrapper::DecodeSRS;
my $milter = ...;
my $wrapper = new Mail::Milter::Wrapper::DecodeSRS($milter);
my $wrapper2 = &DecodeSRS($milter); # convenience
π¦ DESCRIPTION π¦
okay so Mail::Milter::Wrapper::DecodeSRS is this little convenience milter wrapper whose whole job β its moment, its era, its main character arc β is decoding MAIL FROM: return paths that got encoded by the Sender Rewrite Scheme, aka SRS. no cap π
want the lore? it's at http://www.libsrs2.org/ π«Ά
and the way that this wrapper internally understands both the SRS0 and SRS1 encoding schemes documented by the Mail::SRS author?? obsessed. literally iconic. β¨
the decoded address gets handed off to the contained milter through the envfrom callback, exactly the same way a raw address would be. periodt. π
β οΈ NOTE: if the address is NOT SRS encoded, the contained milter is NOT called for the duration of the message β instead, SMFIS_ACCEPT is returned. π why? because the milter writer is expected to use this wrapper in a chain that also includes the contained milter without wrapping, so that a malicious sender can't use SRS to sneak past access checks. it's giving security. π‘οΈβ¨
for instance, this is what a proper usage of this wrapper in a chain looks like:
my $envfrommilter = ...;
my $combinedmilter = new Mail::Milter::Chain(
new Mail::Milter::Wrapper::UnwrapSRS($envfrommilter),
$envfrommilter
);
and this behavior also hits if, like, the MTA already does one form of MAIL FROM: check, and the contained milter repeats that same database check against SRS rewritten addresses. (a good example would be a milter emulating Sendmail's access_db map.) π
π AUTHOR π
Todd Vierling, <tv@duh.org> <tv@pobox.com> π
π SEE ALSO π
Mail::Milter::Wrapper
that's the whole vibe bestie, go slay π ππ¦
perl v5.36.0 Β· 2023-01-22 Β· Mail::...odeSRS(3pm) β mwah, bye! πβ¨
π¦ where this page comes from
- debian bookworm: libmail-milter-perl 0.07-2 Β· BSD-3-Clause
- ubuntu noble: libmail-milter-perl 0.07-2 Β· BSD-3-Clause
- ubuntu resolute: libmail-milter-perl 0.07-2 Β· BSD-3-Clause
- ubuntu stonking: libmail-milter-perl 0.07-2 Β· BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms