On 11/11/16 17:08, Ricardo Mestre wrote:
> Hi,
>
> I can confirm this, just alerted gilles@ of the issue, essentially it's this:
>
> "So basically I'm able to receive emails, no problem there, but when I try to
> relay an email to the internet using my ISP's server as soon as STARTTLS is
> sent then the lka process receives a SIGCHLD with errno 4 (interrupted
> syscall)
> which is due to a kevent(2) call. At first I thought it must have been my
> ISP's
> fault so I also tried Gmail, but the issue reveals itself exactly the same."
>
> This is most likely some of the several changes made lately to LibreSSL and
> that smtpd(8) didn't update some function(s).
>
> Please find attached the ktrace and debug logs of showing this happening.
>
some more infos coming from mutt attached:
#0 ASN1_STRING_free (a=0xdfdfdfdfdfdfdfdf)
at /usr/src/lib/libcrypto/asn1/asn1_lib.c:439
439 if (a->data != NULL && !(a->flags & ASN1_STRING_FLAG_NDEF)) {
Giovanni
> mestre@
>
> On 09:33 Fri 11 Nov , Ted Wynnychenko wrote:
>> I tried sending this to bugs@, but it does not seem to have been accepted.
>> So, I decide to send it to misc@.
>> I hope that's ok.
>>
>> -----Original Message-----
>> Sent: Friday, November 11, 2016 8:44 AM
>> To: '[email protected]'
>> Subject: smtpd dies on current
>>
>> Hello
>> I updated current a few days ago.
>> At that point, I noticed that no mail was going out.
>> Looking at /var/log/maillog, I saw that smtpd was dying with a fatal error
>> immediately on startup.
>>
>> I just updated again to the new snapshot.
>> Same problem.
>> I hope this is the right place to send this, and that I have included enough
>> information.
>> I can't directly use sendbug, since the system can't send the mail out...
>>
>> But, from sendbug:
>>
>>> Synopsis: sendmail dies on startup with fatal error
>>> Category: <PR category (one line)>
>>> Environment:
>> System : OpenBSD 6.0
>> Details : OpenBSD 6.0-current (GENERIC.MP) #0: Thu Nov 10
>> 22:14:46
>> MST 2016
>>
>> [email protected]:/usr/src/sys/arch/amd64/compile/GENERIC.MP
>>
>> Architecture: OpenBSD.amd64
>> Machine : amd64
>>> Description:
>> When booting up, or starting smtpd manually, the demon dies with a
>> fatal
>> error
>> From /var/log/maillog:
>>
>> Nov 11 08:24:21 system smtpd[31422]: info: OpenSMTPD 6.0.0 starting
>> Nov 11 08:24:22 system smtpd[17404]: ab291948ab3ce73f mta event=connecting
>> address=tls://96.114.157.81:587 host=omta-po.sys.comcast.net
>> Nov 11 08:24:22 system smtpd[17404]: ab291948ab3ce73f mta event=connected
>> Nov 11 08:24:22 system smtpd[17404]: ab291949645ed964 smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: ab29194ca0da4904 smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: ab2919546f1001e9 smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: ab2919563f86cc18 smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: ab291949645ed964 smtp event=message
>> address=local host=system.domain.com msgid=3dc96514
>> from=<[email protected]> to=<[email protected]> size=8083 ndest=1
>> proto=ESMTP
>> Nov 11 08:24:22 system smtpd[17404]: ab29194ca0da4904 smtp event=message
>> address=local host=system.domain.com msgid=791261cf
>> from=<[email protected]> to=<[email protected]> size=704 ndest=1
>> proto=ESMTP
>> Nov 11 08:24:22 system smtpd[17404]: ab291949645ed964 smtp event=closed
>> address=local host=system.domain.com reason=quit
>> Nov 11 08:24:22 system smtpd[17404]: ab29194ca0da4904 smtp event=closed
>> address=local host=system.domain.com reason=quit
>> Nov 11 08:24:22 system smtpd[17404]: ab291967e3dfd3fa smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: ab2919546f1001e9 smtp event=message
>> address=local host=system.domain.com msgid=c62f2f22
>> from=<[email protected]> to=<[email protected]> size=95641 ndest=1
>> proto=ESMTP
>> Nov 11 08:24:22 system smtpd[17404]: ab2919546f1001e9 smtp event=closed
>> address=local host=system.domain.com reason=quit
>> Nov 11 08:24:22 system smtpd[17404]: ab2919563f86cc18 smtp event=message
>> address=local host=system.domain.com msgid=3ac75830
>> from=<[email protected]> to=<[email protected]> size=65992 ndest=1
>> proto=ESMTP
>> Nov 11 08:24:22 system smtpd[17404]: ab2919563f86cc18 smtp event=closed
>> address=local host=system.domain.com reason=quit
>> Nov 11 08:24:22 system smtpd[17404]: ab291967e3dfd3fa smtp event=message
>> address=local host=system.domain.com msgid=16b1e1ba
>> from=<[email protected]> to=<[email protected]> size=95641 ndest=1
>> proto=ESMTP
>> Nov 11 08:24:22 system smtpd[17404]: ab291967e3dfd3fa smtp event=closed
>> address=local host=system.domain.com reason=quit
>> Nov 11 08:24:22 system smtpd[17404]: ab29197127bb2edb smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: ab29197127bb2edb smtp event=message
>> address=local host=system.domain.com msgid=b605e6ae
>> from=<[email protected]> to=<[email protected]> size=8326 ndest=1
>> proto=ESMTP
>> Nov 11 08:24:22 system smtpd[17404]: ab29197127bb2edb smtp event=closed
>> address=local host=system.domain.com reason=quit
>> Nov 11 08:24:22 system smtpd[17404]: ab2919791af498ee smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: ab2919791af498ee smtp event=message
>> address=local host=system.domain.com msgid=6bd27110
>> from=<[email protected]> to=<[email protected]> size=8083 ndest=1
>> proto=ESMTP
>> Nov 11 08:24:22 system smtpd[17404]: ab2919791af498ee smtp event=closed
>> address=local host=system.domain.com reason=quit
>> Nov 11 08:24:22 system smtpd[17404]: ab291981a25b9195 smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: ab291981a25b9195 smtp event=message
>> address=local host=system.domain.com msgid=d75b3657
>> from=<[email protected]> to=<[email protected]> size=541 ndest=1
>> proto=ESMTP
>> Nov 11 08:24:22 system smtpd[17404]: ab291981a25b9195 smtp event=closed
>> address=local host=system.domain.com reason=quit
>> Nov 11 08:24:22 system smtpd[17404]: ab29198900552ba7 smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: ab29198ed20ba2db smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: ab291997985a89d7 smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: ab291997985a89d7 smtp event=message
>> address=local host=system.domain.com msgid=7a76079a
>> from=<[email protected]> to=<[email protected]> size=8083 ndest=1
>> proto=ESMTP
>> Nov 11 08:24:22 system smtpd[17404]: ab291997985a89d7 smtp event=closed
>> address=local host=system.domain.com reason=quit
>> Nov 11 08:24:22 system smtpd[17404]: ab29198ed20ba2db smtp event=message
>> address=local host=system.domain.com msgid=ea3b5a3c
>> from=<[email protected]> to=<[email protected]> size=95641 ndest=1
>> proto=ESMTP
>> Nov 11 08:24:22 system smtpd[17404]: ab29198ed20ba2db smtp event=closed
>> address=local host=system.domain.com reason=quit
>> Nov 11 08:24:22 system smtpd[17404]: ab2919a024262e5d smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: ab2919a204a13de7 smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: ab2919a4a41192a3 smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: ab2919a4a41192a3 smtp event=message
>> address=local host=system.domain.com msgid=bd61d378
>> from=<[email protected]> to=<[email protected]> size=8326 ndest=1
>> proto=ESMTP
>> Nov 11 08:24:22 system smtpd[17404]: ab2919a4a41192a3 smtp event=closed
>> address=local host=system.domain.com reason=quit
>> Nov 11 08:24:22 system smtpd[17404]: ab2919b63f1f3724 smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: ab2919bde5dbace1 smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: ab2919bde5dbace1 smtp event=message
>> address=local host=system.domain.com msgid=41311048
>> from=<[email protected]> to=<[email protected]> size=8326 ndest=1
>> proto=ESMTP
>> Nov 11 08:24:22 system smtpd[17404]: ab2919bde5dbace1 smtp event=closed
>> address=local host=system.domain.com reason=quit
>> Nov 11 08:24:22 system smtpd[17404]: ab2919c5b658c8fc smtp event=connected
>> address=local host=system.domain.com
>> Nov 11 08:24:22 system smtpd[17404]: 0000000000000000 mda event=delivery
>> evpid=b690012bf587d7a2 from=<[email protected]> to=<[email protected]>
>> rcpt=<[email protected]>, user=tdomain method=mda delay=10h27m47s
>> result=Ok
>> stat=Delivered
>> Nov 11 08:24:22 system smtpd[17404]: ab291948ab3ce73f mta event=starttls
>> ciphers=version=TLSv1.2, cipher=DHE-RSA-AES256-GCM-SHA384, bits=256
>> Nov 11 08:24:22 system smtpd[17404]: ab2919c5b658c8fc smtp event=message
>> address=local host=system.domain.com msgid=09e71476
>> from=<[email protected]> to=<[email protected]> size=8083 ndest=1
>> proto=ESMTP
>> Nov 11 08:24:22 system smtpd[17404]: ab2919c5b658c8fc smtp event=closed
>> address=local host=system.domain.com reason=quit
>> Nov 11 08:24:22 system smtpd[17404]: ab29198900552ba7 smtp event=message
>> address=local host=system.domain.com msgid=4c2ed024
>> from=<[email protected]> to=<[email protected]> size=1100162 ndest=1
>> proto=ESMTP
>> Nov 11 08:24:22 system smtpd[17404]: ab29198900552ba7 smtp event=closed
>> address=local host=system.domain.com reason=quit
>> Nov 11 08:24:22 system smtpd[69428]: fatal: process lka socket closed
>>
>>
>> The smtpd.conf has been unchanged for many months, and is apparently fine:
>>
>> # smtpd -n
>> configuration OK
>>
>>
>>> Fix:
>> unknown
>>
>>
>> dmesg:
>> OpenBSD 6.0-current (GENERIC.MP) #0: Thu Nov 10 22:14:46 MST 2016
>> [email protected]:/usr/src/sys/arch/amd64/compile/GENERIC.MP
>>
>>
>> Please let me know if there is anything else I should supply. I am sorry
>> that I
>> could not use the sendbug utility directly.
>> Thanks
>> Ted
>>
Script started on Fri Nov 11 17:50:55 2016
$ mutt -n -f imaps://imap.gmail.com
$ gdb mutt mutt.core
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "amd64-unknown-openbsd6.0"...
Core was generated by `mutt'.
Program terminated with signal 10, Bus error.
Reading symbols from /usr/lib/libpthread.so.23.0...done.
Loaded symbols for /usr/lib/libpthread.so.23.0
Loaded symbols for /usr/local/bin/mutt
Reading symbols from /usr/lib/libncursesw.so.14.0...done.
Loaded symbols for /usr/lib/libncursesw.so.14.0
Reading symbols from /usr/lib/libssl.so.41.0...done.
Loaded symbols for /usr/lib/libssl.so.41.0
Reading symbols from /usr/lib/libcrypto.so.40.0...done.
Loaded symbols for /usr/lib/libcrypto.so.40.0
Reading symbols from /usr/lib/libz.so.5.0...done.
Loaded symbols for /usr/lib/libz.so.5.0
Reading symbols from /usr/local/lib/libkyotocabinet.so.0.0...done.
Loaded symbols for /usr/local/lib/libkyotocabinet.so.0.0
Reading symbols from /usr/local/lib/libidn.so.17.2...done.
Loaded symbols for /usr/local/lib/libidn.so.17.2
Reading symbols from /usr/local/lib/libintl.so.6.0...done.
Loaded symbols for /usr/local/lib/libintl.so.6.0
Reading symbols from /usr/local/lib/libiconv.so.6.0...done.
Loaded symbols for /usr/local/lib/libiconv.so.6.0
Reading symbols from /usr/lib/libc.so.89.2...done.
Loaded symbols for /usr/lib/libc.so.89.2
Symbols already loaded for /usr/lib/libpthread.so.23.0
Reading symbols from /usr/lib/libstdc++.so.57.0...done.
Loaded symbols for /usr/lib/libstdc++.so.57.0
Reading symbols from /usr/lib/libm.so.10.0...done.
Loaded symbols for /usr/lib/libm.so.10.0
Reading symbols from /usr/libexec/ld.so...done.
Loaded symbols for /usr/libexec/ld.so
#0 ASN1_STRING_free (a=0xdfdfdfdfdfdfdfdf)
at /usr/src/lib/libcrypto/asn1/asn1_lib.c:439
439 if (a->data != NULL && !(a->flags & ASN1_STRING_FLAG_NDEF)) {
(gdb) bt
#0 ASN1_STRING_free (a=0xdfdfdfdfdfdfdfdf)
at /usr/src/lib/libcrypto/asn1/asn1_lib.c:439
#1 0x00000d603980e8df in ASN1_primitive_free (pval=0xd5fc1f82910,
it=0xd6039b887e0) at /usr/src/lib/libcrypto/asn1/tasn_fre.c:239
#2 0x00000d603980ec87 in ASN1_template_free (pval=0xd5fc1f82910,
tt=0xd6039b9e3d0) at /usr/src/lib/libcrypto/asn1/tasn_fre.c:185
#3 0x00000d603980eb73 in asn1_item_combine_free (pval=0x7f7ffffd7920,
it=0xd6039b968c0, combine=0) at /usr/src/lib/libcrypto/asn1/tasn_fre.c:158
#4 0x00000d603980ecc2 in ASN1_item_free (val=0xd5fc1f82900, it=Variable "it" is not available.
)
at /usr/src/lib/libcrypto/asn1/tasn_fre.c:73
#5 0x00000d603982af4f in X509_INFO_free (x=0xd603a33c500)
at /usr/src/lib/libcrypto/asn1/x_info.c:100
#6 0x00000d60398ae6c0 in sk_pop_free (st=0xd5f8c709120,
func=0xd603982af10 <X509_INFO_free>)
at /usr/src/lib/libcrypto/stack/stack.c:281
#7 0x00000d603984dccb in X509_load_cert_crl_file (ctx=0xd5fe46add80, file=Variable "file" is not available.
)
at /usr/src/lib/libcrypto/x509/by_file.c:271
#8 0x00000d603984dd7f in by_file_ctrl (ctx=0xd5fe46add80, cmd=Variable "cmd" is not available.
)
at /usr/src/lib/libcrypto/x509/by_file.c:110
#9 0x00000d60397df18e in X509_STORE_load_locations (ctx=0xd5fb50d4f00,
file=0xd6030864e80 "/home/giovanni/.mutt_certificates", path=0x0)
at /usr/src/lib/libcrypto/x509/x509_d2.c:96
#10 0x00000d5d7da9b2f5 in ssl_check_preauth (cert=0xd604b64a300,
---Type <return> to continue, or q <return> to quit---
host=0xd60757cb100 "imap.gmail.com") at mutt_ssl.c:652
#11 0x00000d5d7da9b7ba in ssl_negotiate (conn=0xd60757cb000,
ssldata=0xd5f8220c5e0) at mutt_ssl.c:984
#12 0x00000d5d7da9ba33 in ssl_socket_open (conn=0xd60757cb000)
at mutt_ssl.c:391
#13 0x00000d5d7daa32b5 in imap_open_connection (idata=0xd5fb52ed800)
at imap.c:408
#14 0x00000d5d7daa3650 in imap_conn_find (account=0x7f7ffffd8220, flags=Variable "flags" is not available.
)
at imap.c:370
#15 0x00000d5d7daa42c4 in imap_open_mailbox (ctx=0xd5fddfdef00) at imap.c:574
#16 0x00000d5d7da472a0 in mx_open_mailbox (path=0xd5d7da1ab30 "H\201ìØ",
flags=0, pctx=Variable "pctx" is not available.
) at mx.c:682
#17 0x00000d5d7da3c2aa in main (argc=4, argv=0x7f7ffffd9798) at main.c:898
(gdb) q
$ ^D
Script done on Fri Nov 11 17:51:23 2016