<html><head></head><body><div style="color:#000; background-color:#fff; font-family:Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:13px"><div dir="ltr" id="yui_3_16_0_1_1497252692473_239219"><span id="yui_3_16_0_1_1497252692473_239220">I was on OTP 20 rc2, master fixes that issue. Another issue I found is this.<br><br>I have a send_after procing every 100 ms sending binary:copy(<<"a">>, N*1024) bytes. Client to server.<br><br>If N is 1-7 the server receives the bytes, as soon as N becomes 8 or higher, even N=8*1024-32, the server gets an error:<br><br>SSL: {connection, {alert,2,20,{"dtls_record.erl,538},undefined}: ssl_connection.erl:845: Fatal error: unexpected message<br><br></span></div><div dir="ltr" id="yui_3_16_0_1_1497252692473_239221">** Reason for termination ==</div><div dir="ltr" id="yui_3_16_0_1_1497252692473_239222">** {{key_exists,{{10,66,50,37},58874}},</div><div dir="ltr" id="yui_3_16_0_1_1497252692473_239223"> [{gb_trees,insert_1,4,[{file,"gb_trees.erl"},{line,319}]},</div><div dir="ltr" id="yui_3_16_0_1_1497252692473_239224"> {gb_trees,insert,3,[{file,"gb_trees.erl"},{line,278}]},</div><div dir="ltr" id="yui_3_16_0_1_1497252692473_239225"> {dtls_udp_listener,setup_new_connection,5,</div><div dir="ltr" id="yui_3_16_0_1_1497252692473_239226"> [{file,"dtls_udp_listener.erl"},{line,238}]},</div><div dir="ltr" id="yui_3_16_0_1_1497252692473_239227"> {dtls_udp_listener,handle_info,2,</div><div dir="ltr" id="yui_3_16_0_1_1497252692473_239228"> [{file,"dtls_udp_listener.erl"},{line,138}]},</div><div dir="ltr" id="yui_3_16_0_1_1497252692473_239229"> {gen_server,try_dispatch,4,[{file,"gen_server.erl"},{line,616}]},</div><div dir="ltr" id="yui_3_16_0_1_1497252692473_239230"> {gen_server,handle_msg,6,[{file,"gen_server.erl"},{line,686}]},</div><div dir="ltr"></div><div dir="ltr" id="yui_3_16_0_1_1497252692473_239231"> {proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,247}]}]}</div> <div class="qtdSeparateBR"><br><br></div><div class="yahoo_quoted" style="display: block;"> <div style="font-family: Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 13px;"> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;"> <div dir="ltr"><font size="2" face="Arial"> On Tuesday, June 13, 2017 4:22 PM, Ingela Andin <ingela.andin@gmail.com> wrote:<br></font></div> <br><br> <div class="y_msg_container"><div id="yiv6222384417"><div><div dir="ltr"><div class="yiv6222384417gmail_extra"><div id="yiv6222384417gmail-m_3744951176913730053yui_3_16_0_1_1497252692473_110259"><span>Hi!</span></div><div id="yiv6222384417gmail-m_3744951176913730053yui_3_16_0_1_1497252692473_110259"><span><br clear="none"></span></div><div id="yiv6222384417gmail-m_3744951176913730053yui_3_16_0_1_1497252692473_110259"><span>This particular problem described below is fixed on latest master. And there are some mor fixes in testing that probably will make OTP 20.</span></div><div id="yiv6222384417gmail-m_3744951176913730053yui_3_16_0_1_1497252692473_110259"><span> DTLS support will however be experimental in 20 as we have not had time to battle tested it as much as we want to to be able to ensure the same quality as for TLS.</span></div><div id="yiv6222384417gmail-m_3744951176913730053yui_3_16_0_1_1497252692473_110259"><br clear="none"></div><div id="yiv6222384417gmail-m_3744951176913730053yui_3_16_0_1_1497252692473_110259"><span>Regards Ingela Erlang/OTP team - Ericsson AB</span></div><div dir="ltr" id="yiv6222384417gmail-m_3744951176913730053yui_3_16_0_1_1497252692473_110259"><span><br clear="none"></span></div><div dir="ltr" id="yiv6222384417gmail-m_3744951176913730053yui_3_16_0_1_1497252692473_110259"><span><br clear="none"></span></div><div dir="ltr" id="yiv6222384417gmail-m_3744951176913730053yui_3_16_0_1_1497252692473_110259"><span id="yiv6222384417gmail-m_3744951176913730053yui_3_16_0_1_1497252692473_110258">Slight problem now.<br clear="none"><br clear="none">Testing on localhost everything works fine. Now I am testing on a remote server with large latency and I keep getting this error on the client,<br clear="none">SSL: {connection, flight_retransmission_timeout} Fatal error: unexpected message.<br clear="none"><br clear="none">I tested using pydtls as the client and this error does not happen. <br clear="none"><br clear="none">Also the server shows a "unexpected message" tls_alert. Does not happen with pydtls as the client.</span></div><div class="yiv6222384417gmail-yj6qo yiv6222384417gmail-ajU" style="margin:2px 0px 0px;"><div class="yiv6222384417gmail-ajR" id="yiv6222384417gmail-:3eq"><img class="yiv6222384417gmail-ajT" src="https://ssl.gstatic.com/ui/v1/icons/mail/images/cleardot.gif" style=""></div></div><div class="yiv6222384417gmail-adL"><div class="yiv6222384417gmail-adm"></div><div class="yiv6222384417gmail-im"><div class="yiv6222384417gmail-m_3744951176913730053qtdSeparateBR"><br clear="none"><br clear="none"></div><div class="yiv6222384417gmail-m_3744951176913730053yahoo_quoted"><div style=""><div style="font-family:HelveticaNeue,;"><div dir="ltr"><font size="2" face="Arial">On Tuesday, June 13, 2017 3:51 AM, Vans S <<a rel="nofollow" shape="rect" ymailto="mailto:vans_163@yahoo.com" target="_blank" href="mailto:vans_163@yahoo.com">vans_163@yahoo.com</a>> wrote:<br clear="none"></font></div><br clear="none"><br clear="none"><div class="yiv6222384417gmail-m_3744951176913730053y_msg_container"><div id="yiv6222384417gmail-m_3744951176913730053yiv2740310384"><div style="color:rgb(0,0,0);"><div id="yiv6222384417gmail-m_3744951176913730053yiv2740310384yui_3_16_0_1_1497252692473_98435"><span id="yiv6222384417gmail-m_3744951176913730053yiv2740310384yui_3_16_0_1_1497252692473_98434">Thank you for the encouragement, I got it working, the key was to call transport_accept then ssl_accept, I was calling one or the other.</span></div><div class="yiv6222384417gmail-m_3744951176913730053yiv2740310384qtdSeparateBR"><br clear="none"><br clear="none"></div><div class="yiv6222384417gmail-m_3744951176913730053yiv2740310384yahoo_quoted"><div style="font-family:HelveticaNeue,;"><div class="yiv6222384417gmail-m_3744951176913730053yiv2740310384yqt7845448513" id="yiv6222384417gmail-m_3744951176913730053yiv2740310384yqtfd61290"><div dir="ltr"><font size="2" face="Arial">On Monday, June 12, 2017 8:34 AM, Ingela Andin <<a rel="nofollow" shape="rect" ymailto="mailto:ingela@andin.se" target="_blank" href="mailto:ingela@andin.se">ingela@andin.se</a>> wrote:<br clear="none"></font></div><br clear="none"><br clear="none"><div class="yiv6222384417gmail-m_3744951176913730053yiv2740310384y_msg_container"><div id="yiv6222384417gmail-m_3744951176913730053yiv2740310384"><div dir="ltr"><div><div>Hi!<br clear="none"><br clear="none"></div>Only difference to TLS is that you need to provide the option {protocol, dtls}. <br clear="none"><br clear="none"></div>Regards Ingela <br clear="none"><div><div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div><div class="yiv6222384417gmail_quote">2017-06-12 9:45 GMT+02:00 Andreas Schultz <span dir="ltr"><<a rel="nofollow" shape="rect" ymailto="mailto:aschultz@tpip.net" target="_blank" href="mailto:aschultz@tpip.net">aschultz@tpip.net</a>></span>:<br clear="none"><blockquote class="yiv6222384417gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex;"><div class="yiv6222384417yqt3371435773" id="yiv6222384417yqt74604"><div><div style="font-family:arial, helvetica, sans-serif;font-size:12pt;color:rgb(0,0,0);"><div>Hi Vans,</div><div><br clear="none"></div><div>I haven't played with it yet, but with the DTLS stack in R20 creating a DTLS server should be mostly identical to a TLS server.</div><div><br clear="none"></div><div>For an example on how this works with my old, patched version, you could check out the CAPWAP [1] project.</div><div><br clear="none"></div><div>Regards</div><div>Andreas</div><div><br clear="none"></div><div>[1]: <a rel="nofollow" shape="rect" target="_blank" href="https://github.com/travelping/capwap">https://github.com/ travelping/capwap</a></div><div><br clear="none"></div><span id="yiv6222384417gmail-m_8279183655885648874zwchr">----- On Jun 12, 2017, at 9:34 AM, Vans S <<a rel="nofollow" shape="rect" ymailto="mailto:vans_163@yahoo.com" target="_blank" href="mailto:vans_163@yahoo.com">vans_163@yahoo.com</a>> wrote:<br clear="none"></span><div><blockquote style="border-left:2px solid rgb(16,16,255);margin-left:5px;padding-left:5px;color:rgb(0,0,0);font-weight:normal;font-style:normal;text-decoration:none;font-family:Helvetica, Arial, sans-serif;font-size:12pt;"><div style="color:rgb(0,0,0);background-color:rgb(255,255,255);"><div dir="ltr" id="yiv6222384417gmail-m_8279183655885648874yui_3_16_0_1_1497252692473_2527">I am trying to implement a DTLS server but having trouble.<br clear="none"><br clear="none">The DTLS client works great, used RoadRunners patches and example.<br clear="none"><br clear="none">For the server side I had success to what I think was accepting a peer using the undocumented 'dtls' module directly, but I cannot send to the socket.<br clear="none"><br clear="none" id="yiv6222384417gmail-m_8279183655885648874yui_3_16_0_1_1497252692473_2576">Does anyone have a clue how to create a DTLS server in erlang?</div></div><br clear="none">______________________________ _________________<br clear="none">erlang-questions mailing list<br clear="none"><a rel="nofollow" shape="rect" ymailto="mailto:erlang-questions@erlang.org" target="_blank" href="mailto:erlang-questions@erlang.org">erlang-questions@erlang.org</a><br clear="none"><a rel="nofollow" shape="rect" target="_blank" href="http://erlang.org/mailman/listinfo/erlang-questions">http://erlang.org/mailman/ listinfo/erlang-questions</a><br clear="none"></blockquote></div></div></div></div><br clear="none">______________________________ _________________<br clear="none">
erlang-questions mailing list<br clear="none">
<a rel="nofollow" shape="rect" ymailto="mailto:erlang-questions@erlang.org" target="_blank" href="mailto:erlang-questions@erlang.org">erlang-questions@erlang.org</a><br clear="none">
<a rel="nofollow" shape="rect" target="_blank" href="http://erlang.org/mailman/listinfo/erlang-questions">http://erlang.org/mailman/ listinfo/erlang-questions</a><br clear="none">
<br clear="none"></blockquote></div><br clear="none"></div></div></div></div><br><br></div> </div> </div> </div></div></body></html>