cURL cURL > Mailing List > Monthly Index > Single Mail

curl-tracker Archives

[curl:bugs] #1475 multithreaded httpslibcurl crash

From: Daniel Stenberg <bagder_at_users.sf.net>
Date: Fri, 20 Feb 2015 08:14:41 +0000

- **status**: open --> closed-invalid
- **Comment**:

That example only sets the lock mutexes, is doesn't do any libcurl transfers so it isn't complete.

I'm closing this report now as the lack of mutex callbacks is a reason for crashing multi-threaded SSL programs.

If you need further help or have questions, that's what we have the curl-library mailing list for!

---
** [bugs:#1475] multithreaded httpslibcurl crash**
**Status:** closed-invalid
**Labels:** libcurl multithread collectd multi-thread SSL/TLS 
**Created:** Mon Jan 26, 2015 05:49 AM UTC by Toni Moreno
**Last Updated:** Thu Feb 12, 2015 05:42 AM UTC
**Owner:** Daniel Stenberg
Hi .
We have a problem with a tool (collectd) working with libcurl that is crashing only whem doing multiple HTTPS queries over apache+ssl. (it gathers statistics data from apache mod_status and sends  to a database backend)
The tool is working good with HTTP and single HTTPS queries.
Collectd was linked with  curl-7.35.0 
System: RHEL 5.7 (Linux 2.6.18-274.el5 #1 SMP Fri Jul 8 17:36:59 EDT 2011 x86_64 x86_64 x86_64 GNU/Linux)
OpenSSL: openssl-0.9.8e-27.el5_10.3
I have also an opened Issue on collectd site
https://github.com/collectd/collectd/issues/858
The code seems correctly made for a multithread environment.
https://github.com/collectd/collectd/blob/master/src/apache.c
 but after a while running ( sometimes hours sometimes days) we get a SEGFAULT and the tool crash. This only happens when  more than one HTTPS apache instance configured
This is the backtrace generated
~~~~~~
Core was generated by `/opt/collectd/sbin/collectd -C /opt/collectd/etc/collectd.conf'.
Program terminated with signal 11, Segmentation fault.
#0  0x0000003d5787c39b in ?? ()
(gdb) backtrace
#0  0x0000003d5787c39b in ?? ()
#1  0x00000036efcdeb5e in SHA1_Update () from /lib64/libcrypto.so.6
#2  0x00000036efcdbd0f in ?? () from /lib64/libcrypto.so.6
#3  0x00000036efcdb5a6 in ?? () from /lib64/libcrypto.so.6
#4  0x00000036f001d351 in ssl3_client_hello () from /lib64/libssl.so.6
#5  0x00000036f001e7c9 in ssl3_connect () from /lib64/libssl.so.6
#6  0x00002aed7c3d180d in ossl_connect_common () from /opt/collectd/lib/libcurl.so.4
#7  0x00002aed7c3d273d in Curl_ssl_connect_nonblocking () from /opt/collectd/lib/libcurl.so.4
#8  0x00002aed7c398cde in https_connecting () from /opt/collectd/lib/libcurl.so.4
#9  0x00002aed7c3a5a3e in Curl_protocol_connect () from /opt/collectd/lib/libcurl.so.4
#10 0x00002aed7c3b888f in multi_runsingle () from /opt/collectd/lib/libcurl.so.4
#11 0x00002aed7c3b9895 in curl_multi_perform () from /opt/collectd/lib/libcurl.so.4
#12 0x00002aed7c3b33f4 in curl_easy_perform () from /opt/collectd/lib/libcurl.so.4
#13 0x00002aed7c189521 in apache_read_host (user_data=0xb96a768) at apache.c:615
#14 0x000000000041017f in plugin_read_thread (args=0x0) at plugin.c:462
#15 0x0000003d5840673d in ?? ()
#16 0x0000000000000000 in ?? ()
~~~~~~
Could you help us fix this bug ?
---
Sent from sourceforge.net because curl-tracker@cool.haxx.se is subscribed to https://sourceforge.net/p/curl/bugs/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/curl/admin/bugs/options.  Or, if this is a mailing list, you can unsubscribe from the mailing list.
Received on 2015-02-20

These mail archives are generated by hypermail.