Configuring sendmail relay behind the firewall

From: SamuraiMark (chopchop_at_127.0.0.1)
Date: 10/26/03


Date: Sun, 26 Oct 2003 13:30:14 -0000


I recently upgraded my firewall at home. My ancient i486 based machine
had become a bandwidth limiting factor so I upgraded it to a P-II 350
running OpenBSD. At the same time I decided to move all my public
services (web, mail etc) onto my Ultra 5, sitting behind the firewall,
using port redirection on the firewall to make those services
available. Moving to my Ultra 5 will also let me run more services
like a webmail interface, imap and such.

So far so good. My web sites are back online, and sendmail is too, at
least sort of. I can connect to sendmail, and I can see mail coming in,
but mail keeps getting dumped. Note that I am *note* a sendmail pro.
Right now, my email addresses (all [user]@gangwarily.ca) are simply
forwarded to ISP accounts in the aliases file:

mark: markd@kingston.net

What I see in /var/log/syslog is:

# grep h9QDMmJ7011782 syslog
Oct 26 08:22:48 rusty sendmail[11782]: [ID 801593 mail.info]
h9QDMmJ7011780: h9QDMmJ7011782: DSN: Local configuration error
Oct 26 08:22:49 rusty sendmail[11782]: [ID 801593 mail.info]
h9QDMmJ7011782: to=markd@kingston.net, delay=00:00:01,
xdelay=00:00:01, mailer=esmtp, pri=62679,
relay=kingston.net.mail1.psmtp.com. [12.158.34.245], dsn=5.1.3,
stat=User unknown
Oct 26 08:22:51 rusty sendmail[11782]: [ID 801593 mail.info]
h9QDMmJ7011782: to=<root@ssi.stantive.com>, delay=00:00:03,
xdelay=00:00:00, mailer=esmtp, pri=62679, relay=ssi.stantive.com.
[199.246.2.158], dsn=2.0.0, stat=Sent (h9QDMiJ26111 Message accepted
for delivery)
Oct 26 08:22:51 rusty sendmail[11782]: [ID 801593 mail.info]
h9QDMmJ7011782: h9QDMmJ8011782: return to sender: User unknown
Oct 26 08:22:54 rusty sendmail[11782]: [ID 801593 mail.alert]
h9QDMmJ7011782: Losing ./qfh9QDMmJ7011782: savemail panic
Oct 26 08:22:54 rusty sendmail[11782]: [ID 801593 mail.crit]
h9QDMmJ7011782: SYSERR(root): savemail: cannot save rejected email
anywhere

That is a message which I sent to mark@gangwarily.ca from a machine at
work. Obviously sendmail *tried* to forward it to markd@kingston.net but
was rejected with user unknown. That is the problem I am trying to
solve.

Here is the .mc file I used to generate my sendmail.cf:

VERSIONID(`2003102500')
OSTYPE(`solaris8')dnl
DOMAIN(`solaris-generic')dnl
MASQUERADE_AS(`gangwarily.ca')dnl
FEATURE(`masquerade_entire_domain')dnl
FEATURE(`masquerade_envelope')dnl
MAILER(`local')dnl
MAILER(`smtp')dnl

It is the same .mc file I used to generate sendmail.cf on the machine
ssi.stantive.com (in the log above) but with a differant MASQUERADE_AS
obviously, and it works fine there. That machine also forwards all it's
mail to other accounts.

Any thoughts on where to start?

-- 
Mark E. Drummond
www.gangwarily.ca


Relevant Pages

  • RE: [Full-Disclosure] Sidewinder G2
    ... Secure Computing Sidewinder G2 Firewall Stops New High-Profile Sendmail ... Technology Prevents Sendmail Attack Warned About in CERT Advisory ...
    (Full-Disclosure)
  • Re: [Full-Disclosure] Sidewinder G2
    ... > The Sidewinder G2 Firewall, ... > mail message containing this attack is processed on the Sidewinder G2 ... > internal Sendmail servers. ...
    (Full-Disclosure)
  • Re: Setting up SMTP delivery
    ... The system is using sendmail. ... You should also configure your ISPs outgoing mail relay as the ... I am with plusnet, like the OP, and have mail setup for smtp delivery. ... Port 25 should be open on the firewall, but the sendmail access file should ...
    (uk.comp.os.linux)
  • Re: Mail going to wrong server
    ... The firewall needs to be able to send messages, ... sendmail running on the firewall. ... the firewall and not to the mail server. ... Sendmail keeps a list of host names that are considered to be local. ...
    (comp.mail.sendmail)
  • Mail forwarding problem on firewall (sendmail config error ?)
    ... Sendmail is version 8.13.0. ... including the firewall, except mail. ... save rejected email anywhere ... So the correct internal view from DNS is that the mail server is at 192.168.1.1 ...
    (comp.unix.bsd.openbsd.misc)