[prev in list] [next in list] [prev in thread] [next in thread] 

List:       asterisk-dev
Subject:    Re: [asterisk-dev] [Code Review] Ensure chan_sip rejects encrypted streams without crypto info
From:       "Mark Michelson" <reviewboard () asterisk ! org>
Date:       2012-11-26 21:03:12
Message-ID: 20121126210312.14229.79912 () hotblack ! digium ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/2204/#review7434
-----------------------------------------------------------


The actual process_sdp() changes are good. Ship it!

The thing that bothers me a bit is that we don't always check the return va=
lue of process_sdp(). The times we check are when processing INVITEs, 200 O=
Ks, and ACKs. For any early media responses, we will not check the return v=
alue of process_sdp() (we will sometimes set a variable, but then we don't =
actually do anything with it). What implications might this have if someone=
 sends an early media SDP with SAVP audio but no encryption attributes?

- Mark


On Nov. 21, 2012, 2:28 p.m., opticron wrote:
> =

> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/2204/
> -----------------------------------------------------------
> =

> (Updated Nov. 21, 2012, 2:28 p.m.)
> =

> =

> Review request for Asterisk Developers.
> =

> =

> Summary
> -------
> =

> Prior to this patch, Asterisk would accept encrypted media streams (RTP/S=
AVP audio and video) without ensuring cryptographic keys were present on re=
invites.  This patch ensures that the incoming SDP is consistent with RFC45=
68 as far as having a crypto attribute present for any SAVP streams.
> =

> =

> This addresses bug AST-1040.
>     https://issues.asterisk.org/jira/browse/AST-1040
> =

> =

> Diffs
> -----
> =

>   branches/1.8/channels/chan_sip.c 376388 =

> =

> Diff: https://reviewboard.asterisk.org/r/2204/diff
> =

> =

> Testing
> -------
> =

> Tested with a broken (snom 320 with 7.3.30 firmware) and non-broken (CSIP=
Simple on Android) client to ensure reinvites were rejected when malformed.
> =

> =

> Thanks,
> =

> opticron
> =

>


[Attachment #5 (text/html)]

<html>
 <body>
  <div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
   <table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 \
solid;">  <tr>
     <td>
      This is an automatically generated e-mail. To reply, visit:
      <a href="https://reviewboard.asterisk.org/r/2204/">https://reviewboard.asterisk.org/r/2204/</a>
  </td>
    </tr>
   </table>
   <br />





 <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">The actual process_sdp() \
changes are good. Ship it!

The thing that bothers me a bit is that we don&#39;t always check the return value of \
process_sdp(). The times we check are when processing INVITEs, 200 OKs, and ACKs. For \
any early media responses, we will not check the return value of process_sdp() (we \
will sometimes set a variable, but then we don&#39;t actually do anything with it). \
What implications might this have if someone sends an early media SDP with SAVP audio \
but no encryption attributes?</pre>  <br />







<p>- Mark</p>


<br />
<p>On November 21st, 2012, 2:28 p.m., opticron wrote:</p>






<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" \
style="background-image: \
url('https://reviewboard.asterisk.org/media/rb/images/review_request_box_top_bg.png'); \
background-position: left top; background-repeat: repeat-x; border: 1px black \
solid;">  <tr>
  <td>

<div>Review request for Asterisk Developers.</div>
<div>By opticron.</div>


<p style="color: grey;"><i>Updated Nov. 21, 2012, 2:28 p.m.</i></p>




<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: \
1px solid #b8b5a0">  <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">Prior to this patch, Asterisk would accept encrypted media streams \
(RTP/SAVP audio and video) without ensuring cryptographic keys were present on \
reinvites.  This patch ensures that the incoming SDP is consistent with RFC4568 as \
far as having a crypto attribute present for any SAVP streams.</pre>  </td>
 </tr>
</table>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: \
1px solid #b8b5a0">  <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">Tested with a broken (snom 320 with 7.3.30 firmware) and non-broken \
(CSIPSimple on Android) client to ensure reinvites were rejected when \
malformed.</pre>  </td>
 </tr>
</table>



<div style="margin-top: 1.5em;">
 <b style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Bugs: </b>


 <a href="https://issues.asterisk.org/jira/browse/AST-1040">AST-1040</a>


</div>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">

 <li>branches/1.8/channels/chan_sip.c <span style="color: grey">(376388)</span></li>

</ul>

<p><a href="https://reviewboard.asterisk.org/r/2204/diff/" style="margin-left: \
3em;">View Diff</a></p>




  </td>
 </tr>
</table>








  </div>
 </body>
</html>



--
_____________________________________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-dev mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-dev

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic