[Users] [openser + Asterisk] Caller don't hear callee

Atle Samuelsen clona at cyberhouse.no
Fri May 11 10:55:08 CEST 2007


Hi Bodin,

Check the function fix_nated_sdp. This will also update the
content-length to be correct.

http://www.openser.org/docs/modules/1.3.x/nathelper.html#AEN253

-A
* Bodin Bruno <bbodin01 at univ-lr.fr> [070511 10:51]:
> Bodin Bruno a ?crit :
> >Hello
> >
> >with this config, a caller can call a calle , but callee don't send any RTP message to asterisk :(
> >What 's the problem ?
> >
> >Thank,
> >
> >
> >route{
> >
> >   if (!mf_process_maxfwd_header("10")) {
> >       sl_send_reply("483","Too Many Hops");
> >       exit;
> >   };
> >
> >       if (msg:len >=  2048 ) {
> >       sl_send_reply("513", "Message too big");
> >       exit;
> >   };
> >
> >   if (!method=="REGISTER")
> >       record_route();
> >
> >   if (loose_route()) {
> >       # mark routing logic in request
> >       append_hf("P-hint: rr-enforced\r\n");
> >       route(1);
> >   };
> >
> >   if(method=="CANCEL" || method=="BYE")
> >   {
> >       setflag(10);
> >   };
> >
> >
> >       if ((src_ip==127.0.0.1) && (src_port==5062) && (dst_port==5060))
> >   {
> >       if (method=="REGISTER")
> >       {
> >           save("location");
> >           return;
> >       }
> >                      if  (!lookup("location"))         {
> >                      sl_send_reply("404", "not found");
> >                      return;
> >               };
> >           setflag(9);
> >       route(1);
> >               return;
> >       };
> >
> >   if (!uri==myself) {
> >       append_hf("P-hint: outbound\r\n");
> >       route(1);
> >   };
> >
> >   if (uri==myself)
> >   {
> >
> >       if (method=="REGISTER")
> >       {
> >           save("location");
> >           return;
> >       };
> >
> >       if (!lookup("location")) {
> >           sl_send_reply("404", "Not Found");
> >           exit;
> >       };
> >   };
> >
> >   route(1);
> >}
> >
> >
> >route[1] {
> >
> >   if(method=="INVITE" && !isflagset(10) && !isflagset(9))
> >    {
> >       revert_uri();
> >         $ru = "sip:"+$rU+"@"+$rd+":5062";
> >   };
> >
> >   if (!t_relay()) {
> >           sl_reply_error();
> >   };
> >   exit;
> >}
> >
> >
> >_______________________________________________
> >Users mailing list
> >Users at openser.org
> >http://openser.org/cgi-bin/mailman/listinfo/users
> I solve this recently, in fact i was an asterisk problem. Because of Openser use loopback to communicate with Asterisk, 
> Asterisk return session description with a wrong address, "IN IP4 127.0.0.1".
> So, to solve it fastly, I add this line in openser :
> 
> replace_body_all("IN IP4 127.0.0.1", "IN IP4 myIP");
> 
> if anyone know another fix in asterisk ...it could help me :)
> 
> 
> Thank
> 
> _______________________________________________
> Users mailing list
> Users at openser.org
> http://openser.org/cgi-bin/mailman/listinfo/users




More information about the Users mailing list