Hello,
after moving from OpenSSL-1.0.1e to OpenSSL-1.0.2-5ff68e8 our nginx
instances started crashing (very rarely, but still...) with backtraces
pointing to either "sha1_block_data_order_avx" or
"sha1_block_data_order_ssse3", depending on machine. This is happening
when nginx is acting as a client, as well when it's acting as a
server.

The OS is Linux 3.9.x and we are using relatively recent OpenSSL-1.0.2
checkout (commit: 5ff68e8f6dac3b0d8997b8bc379f9111c2bab74f).

Let me know if you need any more details.

Best regards,
Piotr Sikora


--- sha1_block_data_order_avx ---

(gdb) bt
#0  sha1_block_data_order_avx () at sha1-x86_64.s:3338
#1  0xca62c1d6ca62c1d6 in ?? ()
#2  0xca62c1d6ca62c1d6 in ?? ()
#3  0xca62c1d6ca62c1d6 in ?? ()
#4  0xca62c1d6ca62c1d6 in ?? ()
#5  0xca62c1d6ca62c1d6 in ?? ()
#6  0xca62c1d6ca62c1d6 in ?? ()
#7  0xca62c1d6ca62c1d6 in ?? ()
#8  0xca62c1d6ca62c1d6 in ?? ()
#9  0x0000000004533188 in ?? ()
#10 0x0000000000000020 in ?? ()
#11 0x000000000eabc170 in ?? ()
#12 0x000000000059903b in sha1_update (ctx=Unhandled dwarf expression
opcode 0xf3) at e_aes_cbc_hmac_sha1.c:162
#13 aesni_cbc_hmac_sha1_cipher (ctx=Unhandled dwarf expression opcode
0xf3) at e_aes_cbc_hmac_sha1.c:223
#14 0x00000000005010a9 in tls1_enc (s=0x10338110, send=1) at t1_enc.c:855
#15 0x000000000052ab87 in do_ssl3_write (s=0x10338110, type=21,
buf=0xd1c9e88 "\002F", len=2, create_empty_fragment=0) at s3_pkt.c:826
#16 0x000000000052c540 in ssl3_dispatch_alert (s=0x10338110) at s3_pkt.c:1500
#17 0x000000000052b54c in ssl3_send_alert (s=0x10338110, type=22,
buf=0x549af40 "\024", len=4, peek=0) at s3_pkt.c:1488
#18 ssl3_get_record (s=0x10338110, type=22, buf=0x549af40 "\024",
len=4, peek=0) at s3_pkt.c:536
#19 ssl3_read_bytes (s=0x10338110, type=22, buf=0x549af40 "\024",
len=4, peek=0) at s3_pkt.c:1010
#20 0x000000000052cea0 in ssl3_get_message (s=0x10338110,
st1=Unhandled dwarf expression opcode 0xf3) at s3_both.c:370
#21 0x000000000052c8bb in ssl3_get_finished (s=0x10338110, a=Unhandled
dwarf expression opcode 0xf3) at s3_both.c:233
#22 0x000000000051f27a in ssl3_accept (s=0x10338110) at s3_srvr.c:725
#23 0x0000000000468a5b in ngx_ssl_handshake (c=0x7f457adca6d0) at
src/event/ngx_event_openssl.c:1114

(gdb) info reg
rax            0x753851ae       1966625198
rbx            0x21be16be       566105790
rcx            0x1bc8df34       466149172
rdx            0x6f8554d1       1871008977
rsi            0xfe447b08       4265900808
rdi            0xec908aab       3968895659
rbp            0xee05b36e       0xee05b36e
rsp            0x7ffff63dd800   0x7ffff63dd800
r8             0xeabc324        246137636
r9             0x15364fcb       355880907
r10            0x453314b        72560971
r11            0x543300 5518080
r12            0x4533188        72561032
r13            0x0      0
r14            0x4533188        72561032
r15            0x45331cb        72561099
rip            0x5416c0 0x5416c0 <sha1_block_data_order_avx+2736>
eflags         0x202    [ IF ]
cs             0x33     51
ss             0x2b     43
ds             0x0      0
es             0x0      0
fs             0x0      0
gs             0x0      0
fctrl          0x37f    895
fstat          0x0      0
ftag           0xffff   65535
fiseg          0x0      0
fioff          0x0      0
foseg          0x0      0
fooff          0x0      0
fop            0x0      0
mxcsr          0x1f80   [ IM DM ZM OM UM PM ]


--- sha1_block_data_order_ssse3 ---

(gdb) bt
#0  sha1_block_data_order_ssse3 () at sha1-x86_64.s:2226
#1  0xca62c1d6ca62c1d6 in ?? ()
#2  0xca62c1d6ca62c1d6 in ?? ()
#3  0xca62c1d6ca62c1d6 in ?? ()
#4  0xca62c1d6ca62c1d6 in ?? ()
#5  0xca62c1d6ca62c1d6 in ?? ()
#6  0xca62c1d6ca62c1d6 in ?? ()
#7  0xca62c1d6ca62c1d6 in ?? ()
#8  0xca62c1d6ca62c1d6 in ?? ()
#9  0x0000000001d17528 in ?? ()
#10 0x0000000000000020 in ?? ()
#11 0x0000000001eb35c0 in ?? ()
#12 0x00000000005c627b in sha1_update (ctx=Unhandled dwarf expression
opcode 0xf3) at e_aes_cbc_hmac_sha1.c:162
#13 aesni_cbc_hmac_sha1_cipher (ctx=Unhandled dwarf expression opcode
0xf3) at e_aes_cbc_hmac_sha1.c:223
#14 0x000000000052e2e9 in tls1_enc (s=0x1f01200, send=1) at t1_enc.c:855
#15 0x0000000000557dc7 in do_ssl3_write (s=0x1f01200, type=21,
buf=0x1e55208 "\002F", len=2, create_empty_fragment=0) at s3_pkt.c:826
#16 0x0000000000559780 in ssl3_dispatch_alert (s=0x1f01200) at s3_pkt.c:1500
#17 0x000000000055878c in ssl3_send_alert (s=0x1f01200, type=23,
buf=0x2204b50 "...", len=8192, peek=0) at s3_pkt.c:1488
#18 ssl3_get_record (s=0x1f01200, type=23, buf=0x2204b50 "...",
len=8192, peek=0) at s3_pkt.c:536
#19 ssl3_read_bytes (s=0x1f01200, type=23, buf=0x2204b50 "...",
len=8192, peek=0) at s3_pkt.c:1010
#20 0x00000000005550dc in ssl3_read_internal (s=0x1f01200,
buf=0x2204b50, len=8192) at s3_lib.c:4426
#21 ssl3_read (s=0x1f01200, buf=0x2204b50, len=8192) at s3_lib.c:4446
#22 0x000000000046d204 in ngx_ssl_recv (c=0x7f57161d6a10,
buf=0x2204b50 "...", size=8192) at src/event/ngx_event_openssl.c:1356

______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
Development Mailing List                       openssl-dev@openssl.org
Automated List Manager                           majord...@openssl.org

Reply via email to