Re: Can't map an address to another one
Hello, This is my configuration table domains file:/etc/mail/domaines table aliases file:/etc/mail/aliases table users file:/etc/mail/users table courriels file:/etc/mail/courriels table passwords file:/etc/mail/passwords table clients file:/etc/mail/clients max-message-size 50M pki smtp.mydomain.org certificate "/etc/ssl/certs/smtp.mydomain.org.crt" pki smtp.mydomain.org key "/etc/ssl/private/smtp.mydomain.org.key" # # INBOUND MAILS # # listen on 127.0.0.1 port 10024 tag CLAM_IN # Inbound Emails Clamav listen on 127.0.0.1 port 10028 tag DKIM_IN # Inbound Emails dkimproxy accept tagged CLAM_IN for domain virtual deliver to maildir "/var/mail/vmail/%{rcpt.domain}/%{rcpt.user}/Maildir" accept tagged CLAM_IN for local alias deliver to maildir "/var/mail/vmail/%{rcpt.domain}/%{rcpt.user}/Maildir" accept tagged DKIM_IN for any relay via smtp://127.0.0.1:10023 accept from local for domain relay via smtp://127.0.0.1:10027 accept from source for domain relay via smtp://127.0.0.1:10027 accept from any sender ! for domain relay via smtp://127.0.0.1:10027 ## # OUTBOUND MAILS # ## listen on 127.0.0.1 listen on 127.0.0.1 port 10026 tag CLAM_OUT # Outbound Emails Clamav listen on 127.0.0.1 port 10030 tag DKIM_OUT # Outbound Emails dkimproxy listen on 10.255.89.250 port 25 tls pki smtp.mydomain.org auth-optional listen on 10.255.89.250 port 587 tls-require pki smtp.mydomain.org auth accept tagged CLAM_OUT for any relay via smtp://127.0.0.1:10029 accept tagged DKIM_OUT for any relay accept from local for any relay via smtp://127.0.0.1:10025 accept from source for any relay via smtp://127.0.0.1:10025 # cat /etc/mail/courriels @mydomain.org # cat /etc/mail/users i...@mydomain.org u...@mydomain.org u...@mydomain.org vmail Logs Aug 21 09:38:04 mysmtp smtpd[1986]: smtp-in: New session efae73fbac2080c1 from host mail-x-x.google.com [x.x.218.49] Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-in: Started TLS on session efae73fbac2080c1: version=TLSv1.2, cipher=ECDHE-RSA-AES128-GCM-SHA256, bits=128 Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-in: Accepted message ab0439bc on session efae73fbac2080c1: from=, to=, size=2627, ndest=1, proto=ESMTP Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-out: Connecting to smtp://127.0.0.1:10027 (localhost) on session efae7405008428c6... Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-out: Connected on session efae7405008428c6 Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-in: New session efae74061f50e98f from host localhost [127.0.0.1] Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-in: Closing session efae73fbac2080c1 Aug 21 09:38:06 mysmtp dkimproxy.in[31732]: DKIM verify - pass; message-id=, signer=<@gmail.com>, from= Aug 21 09:38:06 mysmtp smtpd[1986]: smtp-in: Accepted message afeec3df on session efae74061f50e98f: from=, to=, size=2929, ndest=1, proto=ESMTP Aug 21 09:38:06 mysmtp smtpd[1986]: relay: Ok for ab0439bc92880b67: session=efae7405008428c6, from=, to=, rcpt=<->, source=127.0.0.1, relay=127.0.0.1 (localhost), delay=1s, stat=250 2.0.0: afeec3df Message accepted for delivery Aug 21 09:38:10 mysmtp smtpd[1986]: smtp-out: Connecting to smtp://127.0.0.1:10023 (localhost) on session efae740ed271d955... Aug 21 09:38:10 mysmtp smtpd[1986]: smtp-out: Connected on session efae740ed271d955 Aug 21 09:38:10 mysmtp clamsmtpd: 100018: accepted connection from: 127.0.0.1 Aug 21 09:38:10 mysmtp smtpd[1986]: smtp-in: New session efae740f284c98fc from host localhost [127.0.0.1] Aug 21 09:38:10 mysmtp smtpd[1986]: smtp-in: Accepted message d2dd91a7 on session efae740f284c98fc: from=, to=, size=3169, ndest=1, proto=ESMTP Aug 21 09:38:10 mysmtp clamsmtpd: 100018: from=personal...@gmail.com, to=i...@mydomain.org, status=CLEAN Aug 21 09:38:10 mysmtp smtpd[1986]: relay: Ok for afeec3df2f83edba: session=efae740ed271d955, from=, to=, rcpt=<->, source=127.0.0.1, relay=127.0.0.1 (localhost), delay=5s, stat=250 2.0.0: d2dd91a7 Message accepted for delivery Aug 21 09:38:10 mysmtp smtpd[1986]: delivery: Ok for d2dd91a7a2457a23: from=, to=, rcpt=, user=vmail, method=maildir, delay=0s, stat=Delivered Aug 21 09:38:16 mysmtp smtpd[1986]: smtp-in: Closing session efae74061f50e98f Aug 21 09:38:16 mysmtp smtpd[1986]: smtp-out: Closing session efae7405008428c6: 1 message sent. Aug 21 09:38:20 mysmtp smtpd[1986]: smtp-in: Closing session efae740f284c98fc Aug 21 09:38:20 mysmtp smtpd[1986]: smtp-out: Closing session efae740ed271d955: 1 message sent. In these logs I seeAug 21 09:38:10 mysmtp smtpd[1986]: delivery: Ok for d2dd91a7a2457a23: from=, to=, rcpt=, user=vmail, method=maildir, delay=0s, stat=Delivered But then the mail is received in its own mailbox # cat /var/mail/vmail/mydomain.org/info/Maildir/new/1471765090.2083.smtp.mydomain.org Return-Path: personaladd@gmail.comDelivered-To: i...@mydomain.org... Received: by mail-x-x.google.com with SMTP id l203so114910462oib.1 for ; Sun, 21 Aug 2016 00:38:05 -0700 (PDT) Regards
Re: Can't map an address to another one
This is the full debug -vd smtp-in: Accepted message 3ff99b9d on session 7c7d334d52c5ec39: from=, to=, size=2625, ndest=1, proto=ESMTP debug: scheduler: evp:3ff99b9d4918e017 scheduled (mta) debug: mta: received evp:3ff99b9d4918e017 for debug: mta: draining [relay:127.0.0.1,port=10027,mx] refcount=1, ntask=1, nconnector=0, nconn=0 debug: mta: querying MX for [relay:127.0.0.1,port=10027,mx]... debug: mta: [relay:127.0.0.1,port=10027,mx] waiting for MX debug: MXs for domain 127.0.0.1: 127.0.0.1 preference -1 debug: mta: ... got mx (0x4326ee92420, 127.0.0.1, [relay:127.0.0.1,port=10027,mx]) debug: mta: draining [relay:127.0.0.1,port=10027,mx] refcount=1, ntask=1, nconnector=0, nconn=0 debug: mta: querying source for [relay:127.0.0.1,port=10027,mx]... debug: mta: ... got source for [relay:127.0.0.1,port=10027,mx]: [] debug: mta: new [connector:[]->[relay:127.0.0.1,port=10027,mx],0x1] debug: mta: connecting with [connector:[]->[relay:127.0.0.1,port=10027,mx],0x0] debug: mta-routing: searching new route for [connector:[]->[relay:127.0.0.1,port=10027,mx],0x0]... debug: mta-routing: selecting candidate route [] <-> 127.0.0.1 debug: mta-routing: spawning new connection on [] <-> 127.0.0.1 debug: mta: 0x432cc955670: spawned for relay [relay:127.0.0.1,port=10027,mx] debug: mta: connecting with [connector:[]->[relay:127.0.0.1,port=10027,mx],0x0] debug: mta: cannot use [relay:127.0.0.1,port=10027,mx] before 2s debug: mta-routing: no route available for [connector:[]->[relay:127.0.0.1,port=10027,mx],0x0]: must wait a bit debug: mta: retrying to connect on [connector:[]->[relay:127.0.0.1,port=10027,mx],0x0] in 2s... debug: mta: draining [relay:127.0.0.1,port=10027,mx] refcount=3, ntask=1, nconnector=1, nconn=1 debug: mta: scheduling relay [relay:127.0.0.1,port=10027,mx] in 1s... smtp-out: Connecting to smtp://127.0.0.1:10027 (localhost) on session 7c7d335771506ae9... smtp-out: Connected on session 7c7d335771506ae9 debug: smtp: new client on listener: 0x432be182000 smtp-in: New session 7c7d33580678232e from host localhost [127.0.0.1] debug: mta-routing: route [] <-> 127.0.0.1 (localhost) is now valid. debug: mta: connecting with [connector:[]->[relay:127.0.0.1,port=10027,mx],0x2] debug: mta: cancelling connector timeout debug: mta: enough connections already debug: mta: 0x432cc955670: handling next task for relay [relay:127.0.0.1,port=10027,mx] smtp: 0x432e87af000: fd 9 from queue smtp: 0x432e87af000: fd 11 from filter debug: smtp: 0x432e87af000: data io done (2927 bytes) filter: deferring eom query... filter: running eom query... debug: 0x432e87af000: end of message, msgflags=0x smtp-in: Accepted message be9a78f5 on session 7c7d33580678232e: from=, to=, size=2927, ndest=1, proto=ESMTP debug: scheduler: evp:be9a78f5243ffd00 scheduled (mta) relay: Ok for 3ff99b9d4918e017: session=7c7d335771506ae9, from=, to=, rcpt=<->, source=127.0.0.1, relay=127.0.0.1 (localhost), delay=0s, stat=250 2.0.0: be9a78f5 Message accepted for delivery debug: mta: waiting for 1s before next transaction debug: mta: received evp:be9a78f5243ffd00 for debug: mta: draining [relay:127.0.0.1,port=10023,mx] refcount=1, ntask=1, nconnector=0, nconn=0 debug: mta: querying source for [relay:127.0.0.1,port=10023,mx]... debug: mta: ... got source for [relay:127.0.0.1,port=10023,mx]: [] debug: mta: new [connector:[]->[relay:127.0.0.1,port=10023,mx],0x1] debug: mta: connecting with [connector:[]->[relay:127.0.0.1,port=10023,mx],0x0] debug: mta-routing: searching new route for [connector:[]->[relay:127.0.0.1,port=10023,mx],0x0]... debug: mta-routing: skipping route [] <-> 127.0.0.1 (localhost): cannot use before 5s (delay after connect) debug: mta-routing: no route available for [connector:[]->[relay:127.0.0.1,port=10023,mx],0x0]: must wait a bit debug: mta: retrying to connect on [connector:[]->[relay:127.0.0.1,port=10023,mx],0x0] in 5s... debug: mta: draining [relay:127.0.0.1,port=10023,mx] refcount=2, ntask=1, nconnector=1, nconn=0 debug: mta: scheduling relay [relay:127.0.0.1,port=10023,mx] in 1s... debug: mta: flush for 3ff99b9d4918e017 (-> i...@mydomain.org) smtp-in: Closing session 7c7d334d52c5ec39 Le Dimanche 21 août 2016 9h54, Mik J a écrit : Hello, This is my configuration table domains file:/etc/mail/domaines table aliases file:/etc/mail/aliases table users file:/etc/mail/users table courriels file:/etc/mail/courriels table passwords file:/etc/mail/passwords table clients file:/etc/mail/clients max-message-size 50M pki smtp.mydomain.org certificate "/etc/ssl/certs/smtp.mydomain.org.crt" pki smtp.mydomain.org key "/etc/ssl/private/smtp.mydomain.org.key" # # INBOUND MAILS # # listen on 127.0.0.1 port 10024 tag CLAM_IN # Inbound Emails Clamav listen on 127.0.0.1 port 10028 tag DKIM_IN # Inbound Emails dkimproxy accept tagged CLAM_IN for domain virtual deliver to maildir "/var/mail/vmail/%{rcpt.domain}/%{rcpt.user}/Maildir" accept tagged CLAM_IN for local a
Re: Can't map an address to another one
On 16-08-21 07:54:12, Mik J wrote: > Hello, > This is my configuration > table domains file:/etc/mail/domaines > table aliases file:/etc/mail/aliases > table users file:/etc/mail/users > table courriels file:/etc/mail/courriels > table passwords file:/etc/mail/passwords > table clients file:/etc/mail/clients > > max-message-size 50M > > pki smtp.mydomain.org certificate "/etc/ssl/certs/smtp.mydomain.org.crt" > pki smtp.mydomain.org key "/etc/ssl/private/smtp.mydomain.org.key" > > # > # INBOUND MAILS # > # > listen on 127.0.0.1 port 10024 tag CLAM_IN # Inbound Emails Clamav > listen on 127.0.0.1 port 10028 tag DKIM_IN # Inbound Emails dkimproxy > Try this: > accept tagged CLAM_IN for domain virtual deliver to maildir > "/var/mail/vmail/%{rcpt.domain}/%{rcpt.user}/Maildir" %{dest.user} If not look below ... > accept tagged CLAM_IN for local alias deliver to maildir > "/var/mail/vmail/%{rcpt.domain}/%{rcpt.user}/Maildir" > accept tagged DKIM_IN for any relay via smtp://127.0.0.1:10023 > accept from local for domain relay via smtp://127.0.0.1:10027 > accept from source for domain relay via > smtp://127.0.0.1:10027 > accept from any sender ! for domain relay via > smtp://127.0.0.1:10027 > > ## > # OUTBOUND MAILS # > ## > listen on 127.0.0.1 > listen on 127.0.0.1 port 10026 tag CLAM_OUT # Outbound Emails Clamav > listen on 127.0.0.1 port 10030 tag DKIM_OUT # Outbound Emails dkimproxy > listen on 10.255.89.250 port 25 tls pki smtp.mydomain.org auth-optional > > listen on 10.255.89.250 port 587 tls-require pki smtp.mydomain.org auth > > > accept tagged CLAM_OUT for any relay via smtp://127.0.0.1:10029 > accept tagged DKIM_OUT for any relay > accept from local for any relay via smtp://127.0.0.1:10025 > accept from source for any relay via smtp://127.0.0.1:10025 > > # cat /etc/mail/courriels > @mydomain.org > > # cat /etc/mail/users > i...@mydomain.org u...@mydomain.org > u...@mydomain.org vmail You are mixing a userbase table with an alias table. Try something a little simpler without all the redirection. smtpd.conf table users passwd:/etc/mail/vusers.db table aliases db:/etc/mail/aliases.db listen on lo0 listen on egress accept from any for domain "example.com" userbase alias deliver to maildir /etc/mail/vusers user::5000:5000::/var/vmail:/sbin/nologin /etc/mail/aliases user: user1 > > > Logs > Aug 21 09:38:04 mysmtp smtpd[1986]: smtp-in: New session efae73fbac2080c1 > from host mail-x-x.google.com [x.x.218.49] > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-in: Started TLS on session > efae73fbac2080c1: version=TLSv1.2, cipher=ECDHE-RSA-AES128-GCM-SHA256, > bits=128 > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-in: Accepted message ab0439bc on > session efae73fbac2080c1: from=, > to=, size=2627, ndest=1, proto=ESMTP > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-out: Connecting to > smtp://127.0.0.1:10027 (localhost) on session efae7405008428c6... > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-out: Connected on session > efae7405008428c6 > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-in: New session efae74061f50e98f > from host localhost [127.0.0.1] > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-in: Closing session efae73fbac2080c1 > Aug 21 09:38:06 mysmtp dkimproxy.in[31732]: DKIM verify - pass; > message-id=, > signer=<@gmail.com>, from= > Aug 21 09:38:06 mysmtp smtpd[1986]: smtp-in: Accepted message afeec3df on > session efae74061f50e98f: from=, > to=, size=2929, ndest=1, proto=ESMTP > Aug 21 09:38:06 mysmtp smtpd[1986]: relay: Ok for ab0439bc92880b67: > session=efae7405008428c6, from=, > to=, rcpt=<->, source=127.0.0.1, relay=127.0.0.1 > (localhost), delay=1s, stat=250 2.0.0: afeec3df Message accepted for delivery > Aug 21 09:38:10 mysmtp smtpd[1986]: smtp-out: Connecting to > smtp://127.0.0.1:10023 (localhost) on session efae740ed271d955... > Aug 21 09:38:10 mysmtp smtpd[1986]: smtp-out: Connected on session > efae740ed271d955 > Aug 21 09:38:10 mysmtp clamsmtpd: 100018: accepted connection from: 127.0.0.1 > Aug 21 09:38:10 mysmtp smtpd[1986]: smtp-in: New session efae740f284c98fc > from host localhost [127.0.0.1] > Aug 21 09:38:10 mysmtp smtpd[1986]: smtp-in: Accepted message d2dd91a7 on > session efae740f284c98fc: from=, > to=, size=3169, ndest=1, proto=ESMTP > Aug 21 09:38:10 mysmtp clamsmtpd: 100018: from=personal...@gmail.com, > to=i...@mydomain.org, status=CLEAN > Aug 21 09:38:10 mysmtp smtpd[1986]: relay: Ok for afeec3df2f83edba: > session=efae740ed271d955, from=, > to=, rcpt=<->, source=127.0.0.1, relay=127.0.0.1 > (localhost), delay=5s, stat=250 2.0.0: d2dd91a7 Message accepted for delivery > Aug 21 09:38:10 mysmtp smtpd[1986]: delivery: Ok for d2dd91a7a2457a23: > from=, to=, > rcpt=, user=vmail, method=maildir, delay=0s, stat=Delivered > Aug 21 09:38:16
Re: Can't map an address to another one
Hello Edgar, Thank you very much, I couldn't locate where the problem was. The problem is solved with %{dest.user}Yes I mixed a user base table and an alias table but I just followed examples on the sitehttps://www.openbsd.org/opensmtpd/faq/example1.html#smtpd Thank you for your suggestions. You're telling me to write listen on lobut I havelisten on 127.0.0.1 port 10024 tag CLAM_IN # Inbound Emails Clamav listen on 127.0.0.1 port 10028 tag DKIM_IN # Inbound Emails dkimproxylisten on 127.0.0.1 listen on 127.0.0.1 port 10026 tag CLAM_OUT # Outbound Emails Clamav listen on 127.0.0.1 port 10030 tag DKIM_OUT # Outbound Emails dkimproxy But I think in my configuration I need the tags and lo is the same as 127.0.0.1, what's the difference ? The same forlisten on egressI wrotelisten on 10.255.89.250 port 25 tls pki smtp.mydomain.org auth-optional listen on 10.255.89.250 port 587 tls-require pki smtp.mydomain.org auth I really need to write the port and the policy, no ? Have a nice day Le Dimanche 21 août 2016 18h06, Edgar Pettijohn a écrit : On 16-08-21 07:54:12, Mik J wrote: > Hello, > This is my configuration > table domains file:/etc/mail/domaines > table aliases file:/etc/mail/aliases > table users file:/etc/mail/users > table courriels file:/etc/mail/courriels > table passwords file:/etc/mail/passwords > table clients file:/etc/mail/clients > > max-message-size 50M > > pki smtp.mydomain.org certificate "/etc/ssl/certs/smtp.mydomain.org.crt" > pki smtp.mydomain.org key "/etc/ssl/private/smtp.mydomain.org.key" > > # > # INBOUND MAILS # > # > listen on 127.0.0.1 port 10024 tag CLAM_IN # Inbound Emails Clamav > listen on 127.0.0.1 port 10028 tag DKIM_IN # Inbound Emails dkimproxy > Try this: > accept tagged CLAM_IN for domain virtual deliver to maildir > "/var/mail/vmail/%{rcpt.domain}/%{rcpt.user}/Maildir" %{dest.user} If not look below ... > accept tagged CLAM_IN for local alias deliver to maildir > "/var/mail/vmail/%{rcpt.domain}/%{rcpt.user}/Maildir" > accept tagged DKIM_IN for any relay via smtp://127.0.0.1:10023 > accept from local for domain relay via smtp://127.0.0.1:10027 > accept from source for domain relay via > smtp://127.0.0.1:10027 > accept from any sender ! for domain relay via > smtp://127.0.0.1:10027 > > ## > # OUTBOUND MAILS # > ## > listen on 127.0.0.1 > listen on 127.0.0.1 port 10026 tag CLAM_OUT # Outbound Emails Clamav > listen on 127.0.0.1 port 10030 tag DKIM_OUT # Outbound Emails dkimproxy > listen on 10.255.89.250 port 25 tls pki smtp.mydomain.org auth-optional > > listen on 10.255.89.250 port 587 tls-require pki smtp.mydomain.org auth > > > accept tagged CLAM_OUT for any relay via smtp://127.0.0.1:10029 > accept tagged DKIM_OUT for any relay > accept from local for any relay via smtp://127.0.0.1:10025 > accept from source for any relay via smtp://127.0.0.1:10025 > > # cat /etc/mail/courriels > @mydomain.org > > # cat /etc/mail/users > i...@mydomain.org u...@mydomain.org > u...@mydomain.org vmail You are mixing a userbase table with an alias table. Try something a little simpler without all the redirection. smtpd.conf table users passwd:/etc/mail/vusers.db table aliases db:/etc/mail/aliases.db listen on lo0 listen on egress accept from any for domain "example.com" userbase alias deliver to maildir /etc/mail/vusers user::5000:5000::/var/vmail:/sbin/nologin /etc/mail/aliases user: user1 > > > Logs > Aug 21 09:38:04 mysmtp smtpd[1986]: smtp-in: New session efae73fbac2080c1 > from host mail-x-x.google.com [x.x.218.49] > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-in: Started TLS on session > efae73fbac2080c1: version=TLSv1.2, cipher=ECDHE-RSA-AES128-GCM-SHA256, > bits=128 > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-in: Accepted message ab0439bc on > session efae73fbac2080c1: from=, > to=, size=2627, ndest=1, proto=ESMTP > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-out: Connecting to > smtp://127.0.0.1:10027 (localhost) on session efae7405008428c6... > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-out: Connected on session > efae7405008428c6 > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-in: New session efae74061f50e98f > from host localhost [127.0.0.1] > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-in: Closing session efae73fbac2080c1 > Aug 21 09:38:06 mysmtp dkimproxy.in[31732]: DKIM verify - pass; > message-id=, > signer=<@gmail.com>, from= > Aug 21 09:38:06 mysmtp smtpd[1986]: smtp-in: Accepted message afeec3df on > session efae74061f50e98f: from=, > to=, size=2929, ndest=1, proto=ESMTP > Aug 21 09:38:06 mysmtp smtpd[1986]: relay: Ok for ab0439bc92880b67: > session=efae7405008428c6, from=, > to=, rcpt=<->, source=127.0.0.1, relay=127.0.0.1 > (localhost), delay=1s, stat=250 2.0.0: afeec3df Message accepted for delivery > Aug
Re: Can't map an address to another one
Sent from my iPhone > On Aug 21, 2016, at 3:31 PM, Mik J wrote: > > Hello Edgar, > > Thank you very much, I couldn't locate where the problem was. The problem is > solved with %{dest.user} > Yes I mixed a user base table and an alias table but I just followed examples > on the site > https://www.openbsd.org/opensmtpd/faq/example1.html#smtpd > I hadn't seen this. > Thank you for your suggestions. You're telling me to write > Disregard below if the above fixed it. > listen on lo > but I have > listen on 127.0.0.1 port 10024 tag CLAM_IN # Inbound Emails Clamav > listen on 127.0.0.1 port 10028 tag DKIM_IN # Inbound Emails dkimproxy > listen on 127.0.0.1 > listen on 127.0.0.1 port 10026 tag CLAM_OUT # Outbound Emails Clamav > listen on 127.0.0.1 port 10030 tag DKIM_OUT # Outbound Emails dkimproxy > > But I think in my configuration I need the tags and lo is the same as > 127.0.0.1, what's the difference ? > > The same for > listen on egress > I wrote > listen on 10.255.89.250 port 25 tls pki smtp.mydomain.org auth-optional > > listen on 10.255.89.250 port 587 tls-require pki smtp.mydomain.org auth > > I really need to write the port and the policy, no ? > > Have a nice day > > Le Dimanche 21 août 2016 18h06, Edgar Pettijohn a > écrit : > > > On 16-08-21 07:54:12, Mik J wrote: > > Hello, > > This is my configuration > > table domains file:/etc/mail/domaines > > table aliases file:/etc/mail/aliases > > table users file:/etc/mail/users > > table courriels file:/etc/mail/courriels > > table passwords file:/etc/mail/passwords > > table clients file:/etc/mail/clients > > > > max-message-size 50M > > > > pki smtp.mydomain.org certificate "/etc/ssl/certs/smtp.mydomain.org.crt" > > pki smtp.mydomain.org key "/etc/ssl/private/smtp.mydomain.org.key" > > > > # > > # INBOUND MAILS # > > # > > listen on 127.0.0.1 port 10024 tag CLAM_IN # Inbound Emails Clamav > > listen on 127.0.0.1 port 10028 tag DKIM_IN # Inbound Emails dkimproxy > > > > Try this: > > > accept tagged CLAM_IN for domain virtual deliver to > > maildir "/var/mail/vmail/%{rcpt.domain}/%{rcpt.user}/Maildir" > > > %{dest.user} > > If not look below ... > > > accept tagged CLAM_IN for local alias deliver to maildir > > "/var/mail/vmail/%{rcpt.domain}/%{rcpt.user}/Maildir" > > accept tagged DKIM_IN for any relay via smtp://127.0.0.1:10023 > > accept from local for domain relay via smtp://127.0.0.1:10027 > > accept from source for domain relay via > > smtp://127.0.0.1:10027 > > accept from any sender ! for domain relay via > > smtp://127.0.0.1:10027 > > > > ## > > # OUTBOUND MAILS # > > ## > > listen on 127.0.0.1 > > listen on 127.0.0.1 port 10026 tag CLAM_OUT # Outbound Emails Clamav > > listen on 127.0.0.1 port 10030 tag DKIM_OUT # Outbound Emails dkimproxy > > listen on 10.255.89.250 port 25 tls pki smtp.mydomain.org auth-optional > > > > listen on 10.255.89.250 port 587 tls-require pki smtp.mydomain.org auth > > > > > > accept tagged CLAM_OUT for any relay via smtp://127.0.0.1:10029 > > accept tagged DKIM_OUT for any relay > > accept from local for any relay via smtp://127.0.0.1:10025 > > accept from source for any relay via smtp://127.0.0.1:10025 > > > > # cat /etc/mail/courriels > > @mydomain.org > > > > # cat /etc/mail/users > > i...@mydomain.org u...@mydomain.org > > u...@mydomain.org vmail > > You are mixing a userbase table with an alias table. Try something a little > simpler without all the redirection. > > smtpd.conf > > table users passwd:/etc/mail/vusers.db > table aliases db:/etc/mail/aliases.db > > listen on lo0 > listen on egress > > accept from any for domain "example.com" userbase alias > deliver to maildir > > /etc/mail/vusers > user::5000:5000::/var/vmail:/sbin/nologin > > /etc/mail/aliases > user:user1 > > > > > > > Logs > > Aug 21 09:38:04 mysmtp smtpd[1986]: smtp-in: New session efae73fbac2080c1 > > from host mail-x-x.google.com [x.x.218.49] > > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-in: Started TLS on session > > efae73fbac2080c1: version=TLSv1.2, cipher=ECDHE-RSA-AES128-GCM-SHA256, > > bits=128 > > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-in: Accepted message ab0439bc on > > session efae73fbac2080c1: from=, > > to=, size=2627, ndest=1, proto=ESMTP > > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-out: Connecting to > > smtp://127.0.0.1:10027 (localhost) on session efae7405008428c6... > > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-out: Connected on session > > efae7405008428c6 > > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-in: New session efae74061f50e98f > > from host localhost [127.0.0.1] > > Aug 21 09:38:05 mysmtp smtpd[1986]: smtp-in: Closing session > > efae73fbac2080c1 > > Aug 21 09:38:06 mysmtp dkimproxy.in[31732]: DKIM verify - pass; > > message-id=, > > signe