[OpenSER-Users-ES] llamada asterisk a openser, ruri modificado?

David Villasmil david.villasmil.work at gmail.com
Fri Feb 1 18:21:01 CET 2008


Buenas, Lista (que eres una lista!) jeje

     Estoy madando una llamada desde asterisk al openser SIN AUTHORIZATION y
openser no encuentra el cliente... mi config:

Estoy mandando 88887059999 at my.domain.com desde asterisk y quiero
reescribirlo a 7059999.... y forward la llamda al cliente, pero openser dice
que no encuentra el usuario, El usuario existe y está registrado... seguro.

ip1 y ip2 son las ips del asterisk, no quiero hacer autentificación, sé que
ésto se puede hacer con "permission", pero a ver quién entiende la
documentación de los módulos....  :S

esto está muy simplificado!

route{
          if (method=="INVITE") {
               #    CUSTOMER-CUSTOMER CALL
             if($si=="ip1"||$si=="ip2"){
                    xlog("L_ERR", "\n************** CUSTOMER-CUSTOMER CALL
(ASTERISK->OPENSER) ************\n");
                    if (uri=~"^sip:8888"){
                         strip(4);
                    }
                    if (!lookup("location")) {
                         sl_send_reply("404", "Not Found");
                         exit;
                    };
               }
          }

  if (!lookup("location")) {
   sl_send_reply("404", "Not Found");
   exit;
  };
  append_hf("P-hint: usrloc applied\r\n");
 };


da como resultado:

11(20554) SIP Request:
11(20554)  method:  <INVITE>
11(20554)  uri:     <sip:88887059999 at 192.168.1.203>
11(20554)  version: <SIP/2.0>
11(20554) parse_headers: flags=2
11(20554) Found param type 232, <branch> = <z9hG4bK0b646e90>; state=6
11(20554) Found param type 235, <rport> = <n/a>; state=17
11(20554) end of header reached, state=5
11(20554) parse_headers: Via found, flags=2
11(20554) parse_headers: this is the first via
11(20554) After parse_msg...
11(20554) preparing to run routing scripts...
11(20554) parse_headers: flags=100
11(20554) DEBUG:parse_to:end of header reached, state=10
11(20554) DBUG:parse_to: display={}, ruri={sip:88887059999 at 192.168.1.203}
11(20554) DEBUG: get_hdr_field: <To> [35]; uri=[
sip:88887059999 at 192.168.1.203]
11(20554) DEBUG: to body [<sip:88887059999 at 192.168.1.203>
]
11(20554) get_hdr_field: cseq <CSeq>: <102> <INVITE>
11(20554) DEBUG:maxfwd:is_maxfwd_present: value = 70
11(20554) check_via_address(192.168.1.202, 192.168.1.202, 0)
11(20554) parse_headers: flags=80
11(20554) DEBUG: add_param: tag=as458d0183
11(20554) DEBUG:parse_to:end of header reached, state=29
11(20554) DBUG:parse_to: display={"David Villasmil"}, ruri={
sip:7059999 at my.domain.com}
11(20554) parse_headers: flags=200
11(20554) DEBUG: get_hdr_body : content_length=340
11(20554) found end of header
11(20554) find_first_route: No Route headers found
11(20554) loose_route: There is no Route HF
11(20554) grep_sock_info - checking if host==us: 15==9 &&  [192.168.1.203]
== [127.0.0.1]
11(20554) grep_sock_info - checking if port 5060 matches port 5060
11(20554) grep_sock_info - checking if host==us: 15==15 &&  [192.168.1.203]
== [192.168.1.203]
11(20554) grep_sock_info - checking if port 5060 matches port 5060
11(20554) grep_sock_info - checking if host==us: 15==9 &&  [192.168.1.203]
== [127.0.0.1]
11(20554) grep_sock_info - checking if port 5060 matches port 5060
11(20554) grep_sock_info - checking if host==us: 15==15 &&  [192.168.1.203]
== [192.168.1.203]
11(20554) grep_sock_info - checking if port 5060 matches port 5060
11(20554) comp_scriptvar: str 20 : 200.198.182.202
11(20554)
************** CUSTOMER-CUSTOMER CALL (ASTERISK->OPENSER) ************
11(20554) rewrite_uri: Rewriting Request-URI with 'sip:s at 192.168.1.253'
11(20554) ******* setting for branch 0 flags 0
11(20554) lookup(): 's' Not found in usrloc
11(20554) parse_headers: flags=ffffffffffffffff
11(20554) check_via_address(192.168.1.202, 192.168.1.202, 0)
11(20554) DEBUG:destroy_avp_list: destroying list (nil)
11(20554) receive_msg: cleaning up



porqué el username termina siendo "s"????? claro, así nunca lo encontrará!


saludos


David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kamailio.org/pipermail/sr-users-es/attachments/20080201/c5af7a52/attachment-0002.htm 


More information about the Users-es mailing list