<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
</head>
<body dir="ltr">
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;background-color:#FFFFFF;font-family:Calibri,Arial,Helvetica,sans-serif;">
<p><br>
</p>
<p><br>
</p>
<br>
<div style="color: rgb(0, 0, 0);">
<div>
<div id="divtagdefaultwrapper" style="font-size:12pt; color:#000000; background-color:#FFFFFF; font-family:Calibri,Arial,Helvetica,sans-serif">
<div style="color:rgb(0,0,0)">
<div id="divRplyFwdMsg" dir="ltr">Dear OpenSIPS-users,<br>
<br>
<p>I'm very beginner to the subjects about STUN, ICE and PJSIP.</p>
<p>Currently I'm working in a project with OpenSIPS, PJSIP and softphones. When a softphone 'A' calls another softphone 'B', 'A' will provide early media to 'B' as depicted in the diagram below. At least it is what we intend to do.</p>
<p><br>
</p>
<p>So, the diagram below doesn't represent what we have implemented already. It just represents what we think we can do with PJSIP and OpenSIPS, without using STUN module (OpenSIPS is in the meddle but not shown), in a overview. That is, this diagram is the
representation of what could be our final solution, if the answers for the following questions will be yes.</p>
<p><br>
</p>
<br>
</div>
<div>
<div id="divtagdefaultwrapper" style="font-size:12pt; color:#000000; background-color:#FFFFFF; font-family:Calibri,Arial,Helvetica,sans-serif">
<p> Softphone A (UAC) Softphone B (UAC)<br>
</p>
<p> |-------------------------------------- | |---------------------------------|<br>
</p>
| | | - Is behind NAT |<br>
| | | - Run PJSIP + ICE |<br>
| - Has public IP:port | | |<br>
| - Run PJSIP in a softphone| |--------------------------------|<br>
| - PJSIP + ICE | |<br>
| | |<br>
|---------------------------------------| |<br>
| |<br>
| ----------------------------------------ICE message ------------------------------------>|<br>
| |<br>
| |
<br>
|<----------------------------------------ICE message -------------------------------------|<br>
| |<br>
| |<br>
| ----------------------------------------SIP INVITE --------------------------------------->|<br>
| |<br>
| |
<br>
|<----------------------------------------SIP 183 --------------------------------------------|<br>
| |<br>
| . |<br>
| . |<br>
| . |<br>
| . |<br>
|-----------------------------------Early media--------------------------------------------->|<br>
| |<br>
<p></p>
<p><br>
</p>
<p>In our solution, one softphone will always has a public IP : PORT. Such softphone 'A' will always be the provider of early media. The softphone 'B' behind NAT will always be the consumer of the early media. The caller will be 'A' and the callee will be 'B',
always. With this scenario I ask:</p>
<p><br>
</p>
<p>1 - Is it necessary to use a STUN module, to the SIP 183 message carries the correct IP address and port, where 'A' should send its media?
<br>
</p>
<p><br>
</p>
<p><br>
</p>
<p>2 - By doing a test of this scenario and using WireShark, we can see some ICE messages being exchanged between 'A' and 'B'. We run this test without a STUN module.<br>
</p>
<p>I guess that for this specific scenario a STUN module will not be necessary, because I guess the peers using PJSIP are exchanging information about IP addresses, via ICE, what in some way is substituting a STUN work. Am I correct?
<br>
</p>
<p><br>
</p>
<p>P.S.: our test was executed in a LAN, without route to Internet. So, any STUN server was unreachable. Sorry If I am misunderstanding something.<br>
</p>
<p><br>
</p>
<p><br>
</p>
<p>Any hint will be very helpful!</p>
<p><br>
</p>
<p>Best regards.<br>
</p>
<p><br>
</p>
<p><br>
</p>
<p><br>
</p>
<div id="Signature">
<div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<div class="BodyFragment"><font size="2">
<div class="PlainText">RODRIGO PIMENTA CARVALHO<br>
Inatel Competence Center<br>
Software<br>
Ph: +55 35 3471 9200 RAMAL 979<br>
</div>
</font></div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>