<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>Hello Anthony,</div><div><br></div><div>That seems to work better than my attempt! &nbsp;</div><div><br></div><div>Thanks for your help!</div><div>&nbsp; Richard</div><div><br></div><br><div><div>On 13 Jul 2012, at 23:19, Anthony Minessale wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div>try patch in latest head minus your plc hack.<br>I have not made any changes to mod_dingaling yet but the core should<br>not try to decode stun now.<br><br><br>On Thu, Jul 12, 2012 at 11:58 AM, Richard Screene<br>&lt;<a href="mailto:richard.screene@netdev.co.uk">richard.screene@netdev.co.uk</a>&gt; wrote:<br><blockquote type="cite">Hello Anthony,<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Thanks for your quick response!<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">does it work then? I had it disabled on purpose cos I have not<br></blockquote><blockquote type="cite">confirmed it works yet.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">That would explain it then :-)<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">I have managed to get SRTP working for the outbound voice path, but it<br></blockquote><blockquote type="cite">required a couple of hacks:<br></blockquote><blockquote type="cite">1) It was attempting to decrypt the STUN/ICE Bind Requests and failing.<br></blockquote><blockquote type="cite">I've bodged it for now by passing the SFF_PLC flag to<br></blockquote><blockquote type="cite">switch_rtp.c:read_rtp_packet() but I suspect this will stop inbound voice<br></blockquote><blockquote type="cite">paths from working!<br></blockquote><blockquote type="cite">2) In mod_dingaling.c:try_secure() the incorrect crypto_type is passed to<br></blockquote><blockquote type="cite">switch_rtp_add_crypto_key(). &nbsp;I suspect there is some confusion between the<br></blockquote><blockquote type="cite">crypto_type and crypto_send_type/crypto_recv_type members of<br></blockquote><blockquote type="cite">tech_pvt-&gt;transports. &nbsp;I've hacked it for now as shown below.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">I hope this is useful to you. &nbsp;I'm going to try with the outbound voice path<br></blockquote><blockquote type="cite">tomorrow.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Regards,<br></blockquote><blockquote type="cite"> &nbsp;Richard<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">For reference here are the diffs:<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">diff --git a/src/mod/endpoints/mod_dingaling/mod_dingaling.c<br></blockquote><blockquote type="cite">b/src/mod/endpoints/mod_dingaling/<br></blockquote><blockquote type="cite">index c47f589..1dda789 100644<br></blockquote><blockquote type="cite">--- a/src/mod/endpoints/mod_dingaling/mod_dingaling.c<br></blockquote><blockquote type="cite">+++ b/src/mod/endpoints/mod_dingaling/mod_dingaling.c<br></blockquote><blockquote type="cite">@@ -956,9 +956,11 @@ switch_status_t mdl_build_crypto(struct private_object<br></blockquote><blockquote type="cite">*tech_pvt, ldl_tran<br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;char *p;<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">+/*<br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if (!switch_test_flag(tech_pvt, TFLAG_SECURE)) {<br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return SWITCH_STATUS_SUCCESS;<br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br></blockquote><blockquote type="cite">+*/<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if (type == AES_CM_128_HMAC_SHA1_80) {<br></blockquote><blockquote type="cite">@@ -1056,10 +1058,13 @@ static switch_status_t mdl_add_crypto(struct<br></blockquote><blockquote type="cite">private_object *tech_pvt,<br></blockquote><blockquote type="cite"> static void try_secure(struct private_object *tech_pvt,<br></blockquote><blockquote type="cite">ldl_transport_type_t ttype)<br></blockquote><blockquote type="cite"> {<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">+/*<br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if (!switch_test_flag(tech_pvt, TFLAG_SECURE)) {<br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return;<br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">+*/<br></blockquote><blockquote type="cite">+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;tech_pvt-&gt;transports[ttype].crypto_type =<br></blockquote><blockquote type="cite">tech_pvt-&gt;transports[ttype].crypto_recv_type;<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//if (tech_pvt-&gt;transports[ttype].crypto_type) {<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">switch_rtp_add_crypto_key(tech_pvt-&gt;transports[ttype].rtp_session,<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">diff --git a/src/switch_rtp.c b/src/switch_rtp.c<br></blockquote><blockquote type="cite">index 7d6ad29..99b4f83 100644<br></blockquote><blockquote type="cite">--- a/src/switch_rtp.c<br></blockquote><blockquote type="cite">+++ b/src/switch_rtp.c<br></blockquote><blockquote type="cite">@@ -3234,6 +3234,7 @@ static int rtp_common_read(switch_rtp_t *rtp_session,<br></blockquote><blockquote type="cite">switch_payload_t *p<br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if (read_pretriggered) {<br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;read_pretriggered = 0;<br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;} else {<br></blockquote><blockquote type="cite">+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*flags |= SFF_PLC;<br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;status = read_rtp_packet(rtp_session,<br></blockquote><blockquote type="cite">&amp;bytes, flags, SWITCH_TRU<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">//switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH<br></blockquote><blockquote type="cite"> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">On 12 Jul 2012, at 00:13, Anthony Minessale wrote:<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">does it work then? I had it disabled on purpose cos I have not<br></blockquote><blockquote type="cite">confirmed it works yet.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">On Wed, Jul 11, 2012 at 4:47 AM, Richard Screene<br></blockquote><blockquote type="cite">&lt;<a href="mailto:richard.screene@netdev.co.uk">richard.screene@netdev.co.uk</a>&gt; wrote:<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Hello,<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Using mod_dingaling I am unable to get it to append the crypto details to<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">the session-accept Jingle stanza. &nbsp;The message is sent as:<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">&lt;snip&gt;<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">_________________________________________________________________________<br></blockquote><blockquote type="cite">Professional FreeSWITCH Consulting Services:<br></blockquote><blockquote type="cite"><a href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br></blockquote><blockquote type="cite"><a href="http://www.freeswitchsolutions.com">http://www.freeswitchsolutions.com</a><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">FreeSWITCH-powered IP PBX: The CudaTel Communication Server<br></blockquote><blockquote type="cite"><a href="http://www.cudatel.com">http://www.cudatel.com</a><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Official FreeSWITCH Sites<br></blockquote><blockquote type="cite"><a href="http://www.freeswitch.org">http://www.freeswitch.org</a><br></blockquote><blockquote type="cite"><a href="http://wiki.freeswitch.org">http://wiki.freeswitch.org</a><br></blockquote><blockquote type="cite"><a href="http://www.cluecon.com">http://www.cluecon.com</a><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Join Us At ClueCon - Aug 7-9, 2012<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">FreeSWITCH-dev mailing list<br></blockquote><blockquote type="cite"><a href="mailto:FreeSWITCH-dev@lists.freeswitch.org">FreeSWITCH-dev@lists.freeswitch.org</a><br></blockquote><blockquote type="cite"><a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev">http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev</a><br></blockquote><blockquote type="cite">UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-dev<br></blockquote><blockquote type="cite"><a href="http://www.freeswitch.org">http://www.freeswitch.org</a><br></blockquote><blockquote type="cite"><br></blockquote><br><br><br>-- <br>Anthony Minessale II<br><br>FreeSWITCH <a href="http://www.freeswitch.org/">http://www.freeswitch.org/</a><br>ClueCon <a href="http://www.cluecon.com/">http://www.cluecon.com/</a><br>Twitter: <a href="http://twitter.com/FreeSWITCH_wire">http://twitter.com/FreeSWITCH_wire</a><br><br>AIM: anthm<br>MSN:anthony_minessale@hotmail.com<br>GTALK/JABBER/PAYPAL:anthony.minessale@gmail.com<br>IRC: <a href="http://irc.freenode.net">irc.freenode.net</a> #freeswitch<br><br>FreeSWITCH Developer Conference<br><a href="sip:888@conference.freeswitch.org">sip:888@conference.freeswitch.org</a><br>googletalk:conf+888@conference.freeswitch.org<br>pstn:+19193869900<br><br>_________________________________________________________________________<br>Professional FreeSWITCH Consulting Services:<br>consulting@freeswitch.org<br>http://www.freeswitchsolutions.com<br><br>FreeSWITCH-powered IP PBX: The CudaTel Communication Server<br>http://www.cudatel.com<br><br>Official FreeSWITCH Sites<br>http://www.freeswitch.org<br>http://wiki.freeswitch.org<br>http://www.cluecon.com<br><br>Join Us At ClueCon - Aug 7-9, 2012<br><br>FreeSWITCH-dev mailing list<br>FreeSWITCH-dev@lists.freeswitch.org<br>http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev<br>UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-dev<br>http://www.freeswitch.org<br></div></blockquote></div><br><div>
<span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; font-size: medium; "><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><b><span style="font-size: 9pt; font-family: Verdana, sans-serif; ">Richard Screene<br></span></b><b><span style="font-size: 7.5pt; font-family: Verdana, sans-serif; color: rgb(254, 101, 0); ">Senior Developer<br></span></b><b><span style="font-size: 7.5pt; font-family: Verdana, sans-serif; color: rgb(127, 127, 127); ">NetDev Ltd &nbsp;&amp; Drum Collaboration&nbsp;<br></span></b><b><span style="font-size: 7.5pt; font-family: Verdana, sans-serif; ">+44 1273 936125<br><u><span style="color: blue; "><a href="http://www.netdev.co.uk/" style="color: blue; text-decoration: underline; ">www.netdev.co.uk</a></span></u><span style="color: rgb(0, 0, 254); "><o:p></o:p></span></span></b></div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><a href="http://www.thisisdrum.com/" style="color: blue; text-decoration: underline; "><b><span style="font-size: 7.5pt; font-family: Verdana, sans-serif; ">www.thisisdrum.com</span></b></a><b><span style="font-size: 7.5pt; font-family: Verdana, sans-serif; color: rgb(0, 0, 254); "><o:p></o:p></span></b></div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><b><span style="font-size: 7pt; font-family: Verdana, sans-serif; color: rgb(127, 127, 127); ">Registered in England and Wales&nbsp;<br></span></b><span style="font-size: 7pt; font-family: Verdana, sans-serif; color: rgb(127, 127, 127); ">Company Number 04741258</span></div></div></span>
</div>
<br></body></html>