[rt-users] multiple email addresses for one user

darren chamberlain darren at boston.com
Fri Mar 21 12:24:52 EST 2003


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

A while back I wrote Mail::ExpandAliases[*] to do precisely this for our RT
install.  Mail::ExpandAliases returns the username (or final alias) for
an email address, so you can do:

  use Mail::ExpandAliases;
  my $expander = Mail::ExpandAliases->new("/etc/aliases");

  sub CanonicalizeAddress {
      my $address = shift;
      my @aliases = $expander->expand($address);

      return $aliases[0];
  }

(darren)

* http://search.cpan.org/~darren/Mail-ExpandAliases/

- -- 
Although I can accept talking scarecrows, lions, and great
wizards of emerald cities, I find it hard to believe there
is no paperwork involved when your house lands on a witch.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (SunOS)

iD8DBQE+e0rjzsinjrVhZaoRAiUpAJ9cIof1ZElXBRzeg1QeOM6xxGmdOgCfXmev
FYfKTYumg+Mn3Y2cj9bKmHw=
=SaJP
-----END PGP SIGNATURE-----



More information about the rt-users mailing list