Re: Configuring opensmtpd to send local mails via smarthost
And one more I use (otherwise some spam system may send warning): sendmail -v -f tomaszdrozdz -F tomaszdro...@interia.eu -- You received this mail because you are subscribed to misc@opensmtpd.org To unsubscribe, send a mail to: misc+unsubscr...@opensmtpd.org
Re: Configuring opensmtpd to send local mails via smarthost
Thank you all for helping me. 1) A) This configuration works (but only if my_password doesn't contain any special characters): /etc/opensmtpd/secrets_for_relay_via tomaszdrozdz_interia_eu tomaszdro...@interia.eu:my_password /etc/opensmtpd/smtpd.conf listen on lo table secrets_for_relay_via db:/etc/opensmtpd/secrets_for_relay_via.db accept from local for any relay via secure+auth://tomaszdrozdz_interia...@poczta.interia.pl:465 auth as tomaszdro...@interia.eu expire 4d I had to set port 465 explicite and add "as tomaszdro...@interia.eu". B) Although it takes a while to deliver message, can I speed it up somehow ? Nov 27 12:02:30 se-gips smtpd[14623]: smtp-in: session 07820a125244383a: connection from host se-gips [local] established Nov 27 12:02:30 se-gips smtpd[14623]: smtp-in: session 07820a125244383a: msgid=0d36f1ad, status=Ok, from=, to=, size=256, ndest=1, proto=ESMTP Nov 27 12:02:30 se-gips smtpd[14623]: smtp-in: session 07820a125244383a: msgid=0d36f1ad, status=Ok, from=, to=, size=256, ndest=1, proto=ESMTP Nov 27 12:02:30 se-gips smtpd[14623]: smtp-in: session 07820a125244383a: connection from host se-gips [local] closed (client sent QUIT) Nov 27 12:02:31 se-gips smtpd[14623]: smtp-out: session 07820a1f454e5abc: connecting to tls://217.74.64.236:465 (poczta.interia.pl) Nov 27 12:07:31 se-gips smtpd[14623]: smtp-out: session 07820a1f454e5abc: error: Connection timeout Nov 27 12:07:31 se-gips smtpd[14623]: smtp-out: session 07820a1f454e5abc: connecting to smtps://217.74.64.236:465 (poczta.interia.pl) Nov 27 12:07:31 se-gips smtpd[14623]: smtp-out: session 07820a1f454e5abc: TLS started version=TLSv1/SSLv3 (), cipher=ECDHE-RSA-AES256-SHA, bits=256 Nov 27 12:07:31 se-gips smtpd[14623]: smtp-out: session 07820a1f454e5abc: server certificate verification succeeded Nov 27 12:07:32 se-gips smtpd[14623]: smtp-out: session 07820a1f454e5abc: evpid=0d36f1ad24db5d95, status=Ok, from=, to=, rcpt=<->, source=192.168.8.100, relay=217.74.64.236 (poczta.interia.pl), delay=5m2s, stat=250 OK. ID: 2f0c141b6ccb40b8 Nov 27 12:07:32 se-gips smtpd[14623]: smtp-out: session 07820a1f454e5abc: evpid=0d36f1adb1744cdc, status=Ok, from=, to=, rcpt=<->, source=192.168.8.100, relay=217.74.64.236 (poczta.interia.pl), delay=5m2s, stat=250 OK. ID: 2f0c141b6ccb40b8 Nov 27 12:07:42 se-gips smtpd[14623]: smtp-out: session 07820a1f454e5abc: connection closed, 1 message sent. 2) I have double checked it. If my_passwords contains some special characters e.g: *&^%$#@! ... then I am unable to send mail: A) /var/log/maillog Nov 27 12:24:27 se-gips smtpd[14954]: smtp-in: session dfc097b5a9f80e5d: connection from host se-gips [local] established Nov 27 12:24:27 se-gips smtpd[14954]: smtp-in: session dfc097b5a9f80e5d: msgid=a4e9a93c, status=Ok, from=, to=, size=257, ndest=1, proto=ESMTP Nov 27 12:24:27 se-gips smtpd[14954]: smtp-in: session dfc097b5a9f80e5d: msgid=a4e9a93c, status=Ok, from=, to=, size=257, ndest=1, proto=ESMTP Nov 27 12:24:27 se-gips smtpd[14954]: smtp-in: session dfc097b5a9f80e5d: connection from host se-gips [local] closed (client sent QUIT) Nov 27 12:24:27 se-gips smtpd[14954]: smtp-out: session dfc097c29e8bc194: connecting to tls://217.74.64.236:465 (poczta.interia.pl) Nov 27 12:29:28 se-gips smtpd[14954]: smtp-out: session dfc097c29e8bc194: error: Connection timeout Nov 27 12:29:28 se-gips smtpd[14954]: smtp-out: session dfc097c29e8bc194: connecting to smtps://217.74.64.236:465 (poczta.interia.pl) Nov 27 12:29:29 se-gips smtpd[14954]: smtp-out: session dfc097c29e8bc194: TLS started version=TLSv1/SSLv3 (), cipher=ECDHE-RSA-AES256-SHA, bits=256 Nov 27 12:29:29 se-gips smtpd[14954]: smtp-out: session dfc097c29e8bc194: server certificate verification succeeded Nov 27 12:29:29 se-gips smtpd[14954]: smtp-out: session dfc097c29e8bc194: error: AUTH rejected: 535 5.7.8 Error: authentication failed: Nov 27 12:29:29 se-gips smtpd[14954]: smtp-out: routing: Disabling route [] <-> 217.74.64.236 (poczta.interia.pl) for 15s Nov 27 12:29:29 se-gips smtpd[14954]: smtp-out: routing: No valid route for [connector:[]->[relay:poczta.interia.pl,port=465,starttls,smtps,auth=secrets_for_relay_via:tomaszdrozdz_interia_eu,mx],0x0] Nov 27 12:29:39 se-gips smtpd[14954]: smtp-out: session : evpid=a4e9a93cd10cef67, status=TempFail, from=, to=, rcpt=<->, source=-, relay=poczta.interia.pl, delay=5m12s, stat=Network error on destination MXs Nov 27 12:29:39 se-gips smtpd[14954]: smtp-out: session : evpid=a4e9a93cf9915315, status=TempFail, from=, to=, rcpt=<->, source=-, relay=poczta.interia.pl, delay=5m12s, stat=Network error on destination MXs Nov 27 12:29:44 se-gips smtpd[14954]: smtp-out: routing: Enabling route [] <-> 217.74.64.236 (poczta.interia.pl) Nov 27 12:31:07 se-gips smtpd[14954]: smtp-out: session dfc097c5f26839ca: connecting to tls://217.74.64.236:465 (poczta.interia.pl) Nov 27 12:36:07 se-gips smtpd[14954]: smtp-out: session dfc097c5f
Re: Configuring opensmtpd to send local mails via smarthost
The website you mentioned says that the port of the outbound SMTP server is 465, but you are trying to send via the default port, which is 25. See your log: > Nov 25 16:09:50 se-gips smtpd[8102]: smtp-out: session 1b314fa0a2f272ba: > connecting to tls://217.74.64.236:25 (poczta.interia.pl) Cheers. On 25 November 2015 at 16:25, wrote: > :-( it still does not work > > > I have corrected: > > /etc/opensmtpd/secrets_for_relay_via: > label tomaszdro...@interia.eu:my_pasword > > /etc/opensmtpd/smtpd.conf: > accept from local for any relay via secure+auth://la...@poczta.interia.pl > auth > > or even to > accept from local for any relay via secure+auth://la...@poczta.interia.pl > auth as tomaszdro...@interia.eu > > or event to > accept from local for any relay via tls+auth://la...@poczta.interia.pl > auth > > But still: > a) > smtpctl show queue > > a81ab810ad07ac63|local|mta|auth|tomaszdro...@interia.eu|tomaszdro...@interia.eu|tomaszdro...@interia.eu|1448464190|1448809790|0|1|invalid||Network > error on destination MXs > > b) > smtpctl show envelope a81ab810ad07ac63 > > version: 2 > tag: local > type: mta > smtpname: se-gips > helo: localhost > hostname: se-gips > errorline: Network error on destination MXs > sockaddr: local > sender: tomaszdro...@interia.eu > rcpt: tomaszdro...@interia.eu > dest: tomaszdro...@interia.eu > ctime: 1448464190 > last-try: 0 > last-bounce: 0 > expire: 345600 > retry: 1 > flags: authenticated > dsn-notify: 0 > esc-class: 4 > esc-code: 0 > mta-relay: secure+auth://la...@poczta.interia.pl > mta-relay-auth: secrets_for_relay_via > mta-relay-flags: tls > > c) > tail -f /etc/opensmtpd/maillog > > Nov 25 16:09:50 se-gips smtpd[8102]: smtp-in: session 1b314f94e2f7cdee: > connection from host se-gips [local] established > Nov 25 16:09:50 se-gips smtpd[8102]: smtp-in: session 1b314f94e2f7cdee: > msgid=a81ab810, status=Ok, from=, > to=, size=457, ndest=1, proto=ESMTP > Nov 25 16:09:50 se-gips smtpd[8102]: smtp-in: session 1b314f94e2f7cdee: > connection from host se-gips [local] closed (client sent QUIT) > Nov 25 16:09:50 se-gips smtpd[8102]: smtp-out: session 1b314fa0a2f272ba: > connecting to tls://217.74.64.236:25 (poczta.interia.pl) > Nov 25 16:09:51 se-gips smtpd[8102]: smtp-out: session 1b314fa0a2f272ba: TLS > started version=TLSv1/SSLv3 (), cipher=ECDHE-RSA-AES256-SHA, bits=256 > Nov 25 16:09:51 se-gips smtpd[8102]: smtp-out: session 1b314fa0a2f272ba: > server certificate verification succeeded > Nov 25 16:09:51 se-gips smtpd[8102]: smtp-out: session 1b314fa0a2f272ba: > error: AUTH rejected: 535 5.7.8 Error: authentication failed: > Nov 25 16:09:51 se-gips smtpd[8102]: smtp-out: routing: Disabling route [] > <-> 217.74.64.236 (poczta.interia.pl) for 15s > Nov 25 16:09:52 se-gips smtpd[8102]: smtp-out: routing: No valid route for > [connector:[]->[relay:poczta.interia.pl,starttls,smtps,auth=secrets_for_relay_via:label,mx],0x0] > Nov 25 16:10:01 se-gips smtpd[8102]: smtp-out: session : > evpid=a81ab810ad07ac63, status=TempFail, from=, > to=, rcpt=<->, source=-, relay=poczta.interia.pl, > delay=11s, stat=Network error on destination MXs > > -- > You received this mail because you are subscribed to misc@opensmtpd.org > To unsubscribe, send a mail to: misc+unsubscr...@opensmtpd.org > -- You received this mail because you are subscribed to misc@opensmtpd.org To unsubscribe, send a mail to: misc+unsubscr...@opensmtpd.org
Re: Configuring opensmtpd to send local mails via smarthost
On 11/25/15 16:25, tomaszdro...@interia.eu wrote: > :-( it still does not work > > > I have corrected: > > /etc/opensmtpd/secrets_for_relay_via: > label tomaszdro...@interia.eu:my_pasword > > /etc/opensmtpd/smtpd.conf: > accept from local for any relay via secure+auth://la...@poczta.interia.pl > auth > > or even to > accept from local for any relay via secure+auth://la...@poczta.interia.pl > auth as tomaszdro...@interia.eu > > or event to > accept from local for any relay via tls+auth://la...@poczta.interia.pl > auth > start smtpd with -dv option, then enable tracing with smtpctl trace lookup and post the result (verify first, it may leak passwords). Cheers Giovanni -- You received this mail because you are subscribed to misc@opensmtpd.org To unsubscribe, send a mail to: misc+unsubscr...@opensmtpd.org
Re: Configuring opensmtpd to send local mails via smarthost
:-( it still does not work I have corrected: /etc/opensmtpd/secrets_for_relay_via: label tomaszdro...@interia.eu:my_pasword /etc/opensmtpd/smtpd.conf: accept from local for any relay via secure+auth://la...@poczta.interia.pl auth or even to accept from local for any relay via secure+auth://la...@poczta.interia.pl auth as tomaszdro...@interia.eu or event to accept from local for any relay via tls+auth://la...@poczta.interia.pl auth But still: a) smtpctl show queue a81ab810ad07ac63|local|mta|auth|tomaszdro...@interia.eu|tomaszdro...@interia.eu|tomaszdro...@interia.eu|1448464190|1448809790|0|1|invalid||Network error on destination MXs b) smtpctl show envelope a81ab810ad07ac63 version: 2 tag: local type: mta smtpname: se-gips helo: localhost hostname: se-gips errorline: Network error on destination MXs sockaddr: local sender: tomaszdro...@interia.eu rcpt: tomaszdro...@interia.eu dest: tomaszdro...@interia.eu ctime: 1448464190 last-try: 0 last-bounce: 0 expire: 345600 retry: 1 flags: authenticated dsn-notify: 0 esc-class: 4 esc-code: 0 mta-relay: secure+auth://la...@poczta.interia.pl mta-relay-auth: secrets_for_relay_via mta-relay-flags: tls c) tail -f /etc/opensmtpd/maillog Nov 25 16:09:50 se-gips smtpd[8102]: smtp-in: session 1b314f94e2f7cdee: connection from host se-gips [local] established Nov 25 16:09:50 se-gips smtpd[8102]: smtp-in: session 1b314f94e2f7cdee: msgid=a81ab810, status=Ok, from=, to=, size=457, ndest=1, proto=ESMTP Nov 25 16:09:50 se-gips smtpd[8102]: smtp-in: session 1b314f94e2f7cdee: connection from host se-gips [local] closed (client sent QUIT) Nov 25 16:09:50 se-gips smtpd[8102]: smtp-out: session 1b314fa0a2f272ba: connecting to tls://217.74.64.236:25 (poczta.interia.pl) Nov 25 16:09:51 se-gips smtpd[8102]: smtp-out: session 1b314fa0a2f272ba: TLS started version=TLSv1/SSLv3 (), cipher=ECDHE-RSA-AES256-SHA, bits=256 Nov 25 16:09:51 se-gips smtpd[8102]: smtp-out: session 1b314fa0a2f272ba: server certificate verification succeeded Nov 25 16:09:51 se-gips smtpd[8102]: smtp-out: session 1b314fa0a2f272ba: error: AUTH rejected: 535 5.7.8 Error: authentication failed: Nov 25 16:09:51 se-gips smtpd[8102]: smtp-out: routing: Disabling route [] <-> 217.74.64.236 (poczta.interia.pl) for 15s Nov 25 16:09:52 se-gips smtpd[8102]: smtp-out: routing: No valid route for [connector:[]->[relay:poczta.interia.pl,starttls,smtps,auth=secrets_for_relay_via:label,mx],0x0] Nov 25 16:10:01 se-gips smtpd[8102]: smtp-out: session : evpid=a81ab810ad07ac63, status=TempFail, from=, to=, rcpt=<->, source=-, relay=poczta.interia.pl, delay=11s, stat=Network error on destination MXs -- You received this mail because you are subscribed to misc@opensmtpd.org To unsubscribe, send a mail to: misc+unsubscr...@opensmtpd.org
Re: Configuring opensmtpd to send local mails via smarthost
On 11/25/15 13:41, tomaszdro...@interia.eu wrote: [...] I have something like this: > secrets_for_relay_via: > tomaszdrozdz_interia_eu:tomaszdrozdz:my_password > label tomaszdro...@interia.eu:password > makemap secrets_for_relay_via > > smtpd.conf: > listen on lo > table secrets_for_relay_via db:/etc/opensmtpd/secrets_for_relay_via.db > accept from local for any relay via > secure+auth://tomaszdrozdz_interia...@poczta.interia.pl auth > > expire 4h > accept from local for any relay via secure+auth://la...@poczta.interia.pl auth Cheers Giovanni -- You received this mail because you are subscribed to misc@opensmtpd.org To unsubscribe, send a mail to: misc+unsubscr...@opensmtpd.org
Configuring opensmtpd to send local mails via smarthost
Hello everyone. This time I have problem regarding configuring opensmtpd to send emails from local host via my internet mail account. I have an email account. I login to it like that: - I go to poczta.interia.pl - I enter my email account: tomaszdro...@interia.eu - I enter password. Parameters for email client are provided here: http://info.poczta.interia.pl/pomoc/artykuly,1276750,parametry-do-konfiguracji-programow-pocztowych and I use them to configure my thunderbird. I wont mail only from my local host to be send via this mail account. So I do: 1) /etc/opensmtpd/ -rw-r-. 1 smtpd smtpd 51 Nov 18 16:07 secrets_for_relay_via -rw-r-. 1 smtpd smtpd 12K Nov 18 16:07 secrets_for_relay_via.db -rw-r--r--. 1 root root 552 Nov 20 15:04 smtpd.conf secrets_for_relay_via: tomaszdrozdz_interia_eu:tomaszdrozdz:my_password makemap secrets_for_relay_via smtpd.conf: listen on lo table secrets_for_relay_via db:/etc/opensmtpd/secrets_for_relay_via.db accept from local for any relay via secure+auth://tomaszdrozdz_interia...@poczta.interia.pl auth expire 4h 2) But I can't sand mail mailx -v -s "111" tomaszdro...@interia.eu aaa EOT <<< 220 se-gips ESMTP OpenSMTPD >>> EHLO localhost <<< 250-se-gips Hello localhost [local], pleased to meet you <<< 250-8BITMIME <<< 250-ENHANCEDSTATUSCODES <<< 250-SIZE 36700160 <<< 250 HELP >>> MAIL FROM: <<< 250 2.0.0: Ok >>> RCPT TO: <<< 250 2.1.5 Destination address valid: Recipient ok >>> DATA <<< 354 Enter mail, end with "." on a line by itself >>> . <<< 250 2.0.0: c98a78ac Message accepted for delivery >>> QUIT <<< 221 2.0.0: Bye 3) A) smtpctl show queue 85c504ab74f51fae|local|mta|auth|tomek@se-gips|tomaszdro...@interia.eu|tomaszdro...@interia.eu|1448455016|1448800616|1448455016|0|invalid|| B) smtpctl show message 85c504ab74f51fae Received: from localhost (se-gips [local]) by se-gips (OpenSMTPD) with ESMTPA id 85c504ab for ; Wed, 25 Nov 2015 12:36:56 + (UTC) From: tomek Message-Id: <6594427050626022671.enqueue@se-gips> Date: Wed, 25 Nov 2015 13:36:56 +0100 To: tomaszdro...@interia.eu Subject: 111 User-Agent: Heirloom mailx 12.5 7/5/10 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit aaa C)smtpctl show envelope 85c504ab74f51fae version: 2 tag: local type: mta smtpname: se-gips helo: localhost hostname: se-gips errorline: Network error on destination MXs sockaddr: local sender: tomek@se-gips rcpt: tomaszdro...@interia.eu dest: tomaszdro...@interia.eu ctime: 1448455016 last-try: 0 last-bounce: 0 expire: 345600 retry: 1 flags: authenticated dsn-notify: 0 esc-class: 4 esc-code: 0 mta-relay: secure+auth://tomaszdrozdz_interia...@poczta.interia.pl mta-relay-auth: secrets_for_relay_via mta-relay-flags: tls D) tail -f /var/log/maillog Nov 25 13:36:56 se-gips smtpd[6795]: smtp-in: session 431d387c68f6bc3a: connection from host se-gips [local] established Nov 25 13:36:56 se-gips smtpd[6795]: smtp-in: session 431d387c68f6bc3a: msgid=85c504ab, status=Ok, from=, to=, size=456, ndest=1, proto=ESMTP Nov 25 13:36:56 se-gips smtpd[6795]: smtp-in: session 431d387c68f6bc3a: connection from host se-gips [local] closed (client sent QUIT) Nov 25 13:36:56 se-gips smtpd[6795]: smtp-out: session 431d36973983: connecting to tls://217.74.64.236:25 (poczta.interia.pl) Nov 25 13:36:57 se-gips smtpd[6795]: smtp-out: session 431d36973983: TLS started version=TLSv1/SSLv3 (), cipher=ECDHE-RSA-AES256-SHA, bits=256 Nov 25 13:36:57 se-gips smtpd[6795]: smtp-out: session 431d36973983: server certificate verification succeeded Nov 25 13:36:58 se-gips smtpd[6795]: smtp-out: session 431d36973983: error: AUTH rejected: 535 5.7.8 Error: authentication failed: Nov 25 13:36:58 se-gips smtpd[6795]: smtp-out: routing: Disabling route [] <-> 217.74.64.236 (poczta.interia.pl) for 15s Nov 25 13:36:59 se-gips smtpd[6795]: smtp-out: routing: No valid route for [connector:[]->[relay:poczta.interia.pl,starttls,smtps,auth=secrets_for_relay_via:tomaszdrozdz_interia_eu,mx],0x0] Nov 25 13:37:07 se-gips smtpd[6795]: smtp-out: session : evpid=85c504ab74f51fae, status=TempFail, from=, to=, rcpt=<->, source=-, relay=poczta.interia.pl, delay=11s, stat=Network error on destination MXs Nov 25 13:37:13 se-gips smtpd[6795]: smtp-out: routing: Enabling route [] <-> 217.74.64.236 (poczta.interia.pl) Please help. -- You received this mail because you are subscribed to misc@opensmtpd.org To unsubscribe, send a mail to: misc+unsubscr...@opensmtpd.org