How Can I Block Mail From Bogus Local Addresses?

Comms Community Contribution

This article has been received from the Comms Community. It has not yet been verified by Sun.

 From Ned on Info-IMS:

It turns out the capabilility is already there, even as far back as 5.2. I'm a
little unsure why it isn't documented, but setting bit bit 5 (value 16) of
returnenvelope causes exactly such a check to be performed.

How Can I Block Mail From Bogus Local Addresses?

There's no sense in allowing spammers to use obviously fake local email addresses in the envelope from. Here's how to configure Messaging Server to require that the envelope from addresses uses a valid uid in local domains.

Add the following to mappings:

FROM_ACCESS
!
! Prevent envelope from addresses that use invalid users in local domains
!
   TCP|*|25|*|*|SMTP*|*|tcp_local|*|*    $C$|INVALID_LOCAL_USER;$5|$NInvalid$ from$ address$ ($5).$E

INVALID_LOCAL_USER

 *@*    $C$|NONLOCAL_DOMAIN;$1|$N$E
 *@*    $C$|SMARTHOST_DOMAIN;$1|$N$E
 @*:*   $C$|VALID_ACCOUNT;$1|$N$E
 @*:*   $Y$E
 *      $C$|VALID_ACCOUNT;$0|$N$E
 *      $Y$E

NONLOCAL_DOMAIN

 *      $C$}$0,_domain_name_{$N$E
 *      $Y$E

SMARTHOST_DOMAIN

! override some domains (these are alias domains of smarthost domains)
 mail.department.school.edu $Y$E
 alias.organization.net $Y$E
 * $C$]ldap:///o=internet??sub?(&(inetDomainBaseDN=o=$0,o=isp)(|(mailroutingsmarthost=*)(mailroutinghosts=*)))[$Y$E
 *      $N$E

VALID_ACCOUNT

 *      $C$]ldap:///o=isp?mail?sub?(|(mail=$0)(mailalternateaddress=$0)(mailequivalentaddress=$0))[$Y$E
 *      $N$E

Labels

messagingserver messagingserver Delete
faq faq Delete
communitycontribution communitycontribution Delete
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.
  1. Aug 11, 2008

    DerekDiget says:

    I asked the Info-iMS mailing list about this page. It looks like this functiona...

    I asked the Info-iMS mailing list about this page. It looks like this functionality is already in Sun Messaging Server and has been since the version 5.2 days. The problem is that the setting was not documented. The channel keyword is returnenvelope and its bit 4 (value 16) setting is the one of interest. See [Info-iMS] How Can I Block Mail From Bogus Local Addresses? for more information.

Sign up or Log in to add a comment or watch this page.


The individuals who post here are part of the extended Sun Microsystems community and they might not be employed or in any way formally affiliated with Sun Microsystems. The opinions expressed here are their own, are not necessarily reviewed in advance by anyone but the individual authors, and neither Sun nor any other party necessarily agrees with them.

Copyright 1994-2009 Sun Microsystems, Inc.
Powered by Atlassian Confluence
Sun Guidelines on Public Discourse Privacy Policy Terms of Use Trademarks Site Map Employment Investor Relations Contact