CIDR netmasks with sendmail
sendmail does not support CIDR notation in its maps.
http://www.sendmail.org/faq/section3.html#3.41
http://www.sendmail.org/faq/section3.html#3.42
The cidrexpand script in the contrib subdirectory of the sendmail source may be used to expand CIDR netmasks for use in sendmail databases.
Example access map:
10. OK
192.168.1.128/25 OK
cidrexpand usage:
# ./cidrexpand < /etc/mail/access | makemap hash /etc/mail/access
In my environment, Net::CIDR is in @INC for /usr/local/bin/perl, not /usr/bin/perl, so I explicitly call the former interpreter when running cidrexpand.
# /usr/local/bin/perl cidrexpand < /etc/mail/access | makemap hash /etc/mail/access
Back to brandonhutchinson.com.
Last modified: 2006/06/19