From owner-freebsd-questions@FreeBSD.ORG Tue Jun 24 21:13:22 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A1487106564A for ; Tue, 24 Jun 2008 21:13:22 +0000 (UTC) (envelope-from freebsd@akruijff.dds.nl) Received: from hpsmtp-eml15.kpnxchange.com (hpsmtp-eml15.kpnxchange.com [213.75.38.115]) by mx1.freebsd.org (Postfix) with ESMTP id 43DA48FC1A for ; Tue, 24 Jun 2008 21:13:22 +0000 (UTC) (envelope-from freebsd@akruijff.dds.nl) Received: from cpsmtp-eml103.kpnxchange.com ([213.75.84.103]) by hpsmtp-eml15.kpnxchange.com with Microsoft SMTPSVC(6.0.3790.1830); Tue, 24 Jun 2008 23:01:18 +0200 Received: from ip51cc8423.speed.planet.nl ([81.204.132.35]) by cpsmtp-eml103.kpnxchange.com with Microsoft SMTPSVC(6.0.3790.1830); Tue, 24 Jun 2008 23:01:18 +0200 Received: from Alex1.kruijff.org (localhost [127.0.0.1]) by ip51cc8423.speed.planet.nl (8.14.2/8.14.2) with ESMTP id m5OL1Ih6015213 for ; Tue, 24 Jun 2008 23:01:18 +0200 (CEST) (envelope-from freebsd@akruijff.dds.nl) Received: (from akruijff@localhost) by Alex1.kruijff.org (8.14.2/8.14.2/Submit) id m5OL1HTl015212 for freebsd-questions@freebsd.org; Tue, 24 Jun 2008 23:01:17 +0200 (CEST) (envelope-from freebsd@akruijff.dds.nl) X-Authentication-Warning: Alex1.kruijff.org: akruijff set sender to freebsd@akruijff.dds.nl using -f Date: Tue, 24 Jun 2008 23:01:17 +0200 From: Alex de Kruijff To: FreeBSD Questions Message-ID: <20080624210117.GA81991@Alex1.kruijff.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.2.3i X-OriginalArrivalTime: 24 Jun 2008 21:01:18.0372 (UTC) FILETIME=[72942640:01C8D63D] Subject: Sendmail Masquerade Problem X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd@akruijff.dds.nl List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 24 Jun 2008 21:13:22 -0000 I have problem with sendmail that is giving me a headake. I can send mails als long when I give the from adres, but when I leave this out the server enters the localname and my ISP isn't accepting the mail. (i.e. echo 'test' | mail -vs test to@mail.com -ffrom@mail works, but without the -f option it gets accepted but is rejected by the isp) I have masquerade setup, but that doesn't seem to do the trick. However check on shows that it handeled oke. I added to private.mc > MASQUERADE_AS(`public') > MASQUERADE_DOMAIN(`localhost') > MASQUERADE_DOMAIN(`localhost.lan') > MASQUERADE_DOMAIN(`private') > MASQUERADE_DOMAIN(`private') > > FEATURE(masquerade_envelope) > FEATURE(masquerade_entire_domain) > FEATURE(allmasquerade) > > Dwwww > Dmpublic > define(`confDOMAIN_NAME', `www.public') > define(`SMART_HOST', `smtp.isp') > > define(`confBIND_OPTS', `WorkAroundBrokenAAAA') > define(`confNO_RCPT_ACTION', `add-to-undisclosed') > define(`confPRIVACY_FLAGS', `authwarnings,noexpn,novrfy') > define(`confTO_QUEUERETURN', `360d') > MAILER(local) > MAILER(smtp) I found in private.cf C{E}root C{M}localhost C{M}localhost.lan C{M}private C{M}private.private # who I masquerade as (null for no masquerading) (see also $=M) DMpublic >From /var/log/maillog > Jun 24 18:22:14 private sendmail[68231]: m5OGMDGG068231: from=www, > size=1238, class=0, nrcpts=1, > msgid=<6dd0e8227154db3d06e70aafd68437ab@prs.public>, > relay=www@localhost > Jun 24 18:22:14 private sm-mta[68232]: m5OGMEXU068232: > from=, size=1351, class=0, nrcpts=1, > msgid=<6dd0e8227154db3d06e70aafd68437ab@prs.public>, proto=ESMTP, > daemon=IPv4, relay=localhost [127.0.0.1] > Jun 24 18:22:14 private sm-mta[68232]: m5OGMEXU068232: Milter add: > header: X-Virus-Scanned: ClamAV 0.92.1/7550/Tue Jun 24 16:52:37 2008 > on private > Jun 24 18:22:14 private sm-mta[68232]: m5OGMEXU068232: Milter add: > header: X-Virus-Status: Clean > Jun 24 18:22:14 private sendmail[68231]: m5OGMDGG068231: > to="=?UTF-8?B?QWxmYXRyaW9u?=" , ctladdr=www > (80/80), delay=00:00:01, xdelay=00:00:00, mailer=relay, pri=31238, > relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (m5OGMEXU068232 > Message accepted for delivery) > Jun 24 18:22:14 private sm-mta[68234]: m5OGMEXU068232: > to=, ctladdr= (0/0), > delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=31351, > relay=smtp.isp. [195.241.79.132], dsn=4.3.0, stat=Deferred: 451 > Temporary local problem - please try later >From the mail it self. > H??Received: from private (localhost [127.0.0.1]) > by public (8.13.6/8.13.6) with ESMTP id m5OGMEXU068232 > for ; Tue, 24 Jun 2008 18:22:14 +0200 > (CEST) > (envelope-from www@private) > H?x?Full-Name: Charlie Root > H??Received: (from www@localhost) > by private (8.13.6/8.13.6/Submit) id m5OGMDGG068231; > Tue, 24 Jun 2008 18:22:13 +0200 (CEST) > (envelope-from www) But when I run > sendmail -bt > /tryflags hs > /try esmtp > /quit it gives me > canonify input: < user @ private > > Canonify2 input: user < @ private > > Canonify2 returns: user < @ private . > > canonify returns: user < @ private . > > 1 input: user < @ private . > > 1 returns: user < @ private . > > HdrFromSMTP input: user < @ private . > > PseudoToReal input: user < @ private . > > PseudoToReal returns: user < @ private . > > MasqSMTP input: user < @ private . > > MasqSMTP returns: user < @ private . > > MasqHdr input: user < @ private . > > MasqHdr returns: user < @ public . > > HdrFromSMTP returns: user < @ public . > > final input: user < @ public . > > final returns: user @ public > Rcode = 0, addr = Running "sendmail -d0.1 -bt Version 8.13.6 > Compiled with: DNSMAP LOG MAP_REGEX MATCHGECOS MILTER MIME7TO8 > MIME8TO7 > NAMED_BIND NETINET NETINET6 NETUNIX NEWDB NIS > PIPELINING SCANF > STARTTLS TCPWRAPPERS USERDB XDEBUG > > ============ SYSTEM IDENTITY (after readcf) ============ > (short domain name) $w = www > (canonical domain name) $j = www.public > (subdomain name) $m = public > (node name) $k = private > ======================================================== > > ADDRESS TEST MODE (ruleset 3 NOT automatically invoked) > Enter
-- Alex Please copy the original recipients, otherwise I may not read your reply.