<div dir="ltr">Hi Giovanni,<div>what's the related OS and libcurl versions please?</div><div><br></div><div>Regards,</div><div>Giacomo</div></div><div class="gmail_extra"><br><div class="gmail_quote">On 2 November 2017 at 09:54, gmele <span dir="ltr"><<a href="mailto:giovanni.mele@nagra.com" target="_blank">giovanni.mele@nagra.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello,<br>
<br>
I'm having strange behavior with the http_async_client module and https<br>
connections. Our kamailio config use REST interfaces to send push to mobile<br>
apps when calls are initiated. We also use a REST interface to register the<br>
client in our push database (and then be able to use the info to send a<br>
push). Our REST interface use TLS to cypher exchanged data between the SIP<br>
registrar and the Pusher service.<br>
<br>
We have configured the tls connection using modparam:<br>
<br>
# ------ http async client params -------<br>
modparam("http_async_client", "workers", 16)<br>
modparam("http_async_client", "connection_timeout", 20000) # 20 seconds<br>
timeout on HTTP requests<br>
modparam("http_async_client", "hash_size", 2048) # update this value<br>
depending of the load<br>
#modparam("http_async_client", "curl_verbose", 1) # curl debug<br>
modparam("http_async_client", "tls_ca_path", "/etc/kamailio/ssl/ca")<br>
<br>
<br>
What we have noticed is when there is 1 SIP Register requests triggering and<br>
HTTPS request all works fine, but as soon as we have several HTTPS request<br>
in //, the HTTPS request fails with curl error 77: curl: (77) Problem with<br>
the SSL CA cert (path? access rights?).<br>
<br>
We tried to put the Root CA Path when building the request:<br>
<br>
    $http_req(all) = $null;     # reset the parameters<br>
    $http_req(method) = "POST";<br>
    $http_req(hdr) = "authorization: "+$hdr(authorization);<br>
    $http_req(hdr) = "Content-Type: application/json";<br>
    $http_req(suspend) = 0;  # don't suspend the transaction, continue<br>
routing script's execution<br>
    $http_req(body) = "{ 'pushRegistration':{'callId':'<wbr>" + $ci + "',<br>
'fromUri':'" + $fU + "@" + $fd + "', 'contactLine':'" + $ct + "'}}";<br>
    $http_req(tls_ca_path) = "/etc/kamailio/ssl/ca/";<br>
    http_async_query("<a href="https://pusher:443/rest/push/register" rel="noreferrer" target="_blank">https://<wbr>pusher:443/rest/push/register</a>"<wbr>,<br>
"HTTP_REGISTER_REPLY");<br>
<br>
But we have exactly the same behavior.<br>
<br>
Does the http_async_client module supports muti-thread?<br>
<br>
Regards<br>
<br>
<br>
Giovanni<br>
<br>
<br>
<br>
--<br>
Sent from: <a href="http://sip-router.1086192.n5.nabble.com/Users-f3.html" rel="noreferrer" target="_blank">http://sip-router.1086192.n5.<wbr>nabble.com/Users-f3.html</a><br>
<br>
______________________________<wbr>_________________<br>
Kamailio (SER) - Users Mailing List<br>
<a href="mailto:sr-users@lists.kamailio.org">sr-users@lists.kamailio.org</a><br>
<a href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users" rel="noreferrer" target="_blank">https://lists.kamailio.org/<wbr>cgi-bin/mailman/listinfo/sr-<wbr>users</a><br>
</blockquote></div><br></div>