<html>
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Thanks for the report! I've added it to our backlog.<br>
<br>
A workaround could be to start eldap on tcp (= without ssl) and then
call eldap:start_tls immediatly to upgrade the connection to tls.
Most servers support this extension.<br>
<br>
- Hans<br>
<br>
<div class="moz-cite-prefix">On 2014-11-17 11:22, Wiesław Bieniek
wrote:<br>
</div>
<blockquote cite="mid:5469CC70.2050004@comarch.pl" type="cite">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
Hello,<br>
<br>
I'm using ldaps protocol to communicate with LDAP Server<br>
<br>
Handle = case eldap:open([LDAPHost], [{port, LDAPPort}, {timeout,
Timeout}, {log, LogFun}, {ssl, true}, {sslopts, [{verify,
verify_peer}, {reuse_sessions, false}, {cacertfile, CertFile}]}])
of<br>
{ok, H} -> H;<br>
Error -> ?DEBUG("Open Error: [~p]~n",
[Error]),<br>
error(Error)<br>
end,<br>
<br>
When LDAP on LDAPHost:LDAPPort is not working and cannot respond
for request this function hangs for about 3 minutes (although the
Timeout is set to 1000 (1 sec.)) and then returns with {error,
etimedout}.<br>
<br>
I made some investigations and the root cause of this seems to be
function from eldap:<br>
<br>
do_connect(Host, Data, Opts) when Data#eldap.ldaps == false -><br>
gen_tcp:connect(Host, Data#eldap.port, Opts,
Data#eldap.timeout);<br>
do_connect(Host, Data, Opts) when Data#eldap.ldaps == true -><br>
ssl:connect(Host, Data#eldap.port, Opts++Data#eldap.tls_opts).<br>
<br>
It does not use timeout when connecting using SSL.<br>
<br>
I guess It need fixing is next release.<br>
<br>
But there is an additional question:<br>
<br>
Due to agreement with user we cannot change any part of OTP
Distributions. Only official releases of OTP can be used.<br>
Is it possible to workaround the problem without updating
eldap.erl and recompiling OTP ?<br>
<br>
<div class="moz-signature">-- <br>
<span style="font-family: Arial, Helvetica, sans-serif;
font-size: 9pt; color: #4d4d4d;"> <strong>Wiesław Bieniek</strong><br>
Projektant Telco BSS R&D<br>
<br>
tel. +48 12 646 12 66<br>
website: <a moz-do-not-send="true"
href="http://www.comarch.pl">www.comarch.pl</a> </span></div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
erlang-bugs mailing list
<a class="moz-txt-link-abbreviated" href="mailto:erlang-bugs@erlang.org">erlang-bugs@erlang.org</a>
<a class="moz-txt-link-freetext" href="http://erlang.org/mailman/listinfo/erlang-bugs">http://erlang.org/mailman/listinfo/erlang-bugs</a>
</pre>
</blockquote>
<br>
</body>
</html>