[OpenSER-Users] T_replicate Bad Request Issue

Ali Jawad ali.jawad at splendor.net
Wed Jun 4 11:27:25 CEST 2008


Hi 

 

All I have the following setup

 

Openser Server A --> Uses Localhost MySQL Server

Openser Server B --> Uses ServerA MySQL server

 

Each server is in a different location.  Both servers share the same
database. I.e. in other words a user can successfully logon to either
server. Both servers have a similar configuration file. My problem at
hand is the following

 

User A and User C logon to Server A

User  B logs on to Server B

 

I need user A or user C to be able to call user B.

 

I am using t_replicate for this setup. The relevant config section is
found below:

 

if(src_ip == OTHERSERVER)

{

   xlog("L_INFO","PACKET FROM 9 PEER SERVER");

   save("location");

}else{

   xlog("L_INFO","NORMAL Packet");

 

   if(is_method("REGISTER")){

     if(!www_authorize("sero.test.net", "subscriber")){

                                    www_challenge("sero.ahwar.net",
"1");

                                    return;

      }

      save("location");

      t_replicate("sip:OTHERSERVER:5060");

      return;

                                           

}

 

 

I have looked at traces and it seems to me that if a user logs on to a
server t_replcicate forwards those register packets to the second
server. However the second server is not reponding to those register
packets it is replying with Bad Request replies

 

U OriginatingServer:5060 -> Target_of_Treplicate:5060

REGISTER sip:OriginatingServer SIP/2.0.

Via: SIP/2.0/UDP OriginatingServer;branch=z9hG4bKe47f.4bd99ca4.0.

Via: SIP/2.0/UDP
192.168.0.176:45374;received=193.227.186.146;branch=z9hG4bK-d87543-00509
f6c6f4a047f-1--d87543-;rport=45374.

Max-Forwards: 69.

Contact:
<sip:9613041705 at 193.227.186.146:45374;rinstance=1367153d6d22ca20>;expire
s=0.

To: "9613041705"<sip:9613041705 at OriginatingServer>.

From: "9613041705"<sip:9613041705 at OriginatingServer>;tag=7d242230.

Call-ID: MmE3MTlmZDhiYWI0NjNmZjI5NWU5Njg1MmNhNDUwMDU..

CSeq: 6 REGISTER.

Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE,
SUBSCRIBE, INFO.

User-Agent: X-Lite release 1006e stamp 34025.

Authorization: Digest
username="9613041705",realm="sero.ahwar.net",nonce="484653b8b642971aef30
31dfa8d894fa90a4faf3",uri="sip:OriginatingServer",response="fd7943d66556
832aff9abcba071a9d85",cnonce="4f6aa73e9cba374f",nc=00000001,qop=auth,alg
orithm=MD5.

Content-Length: 0.

.

 

 

U Target_of_Treplicate:5060 -> OriginatingServer:5060

SIP/2.0 200 OK.

Via: SIP/2.0/UDP OriginatingServer;branch=z9hG4bKe47f.4bd99ca4.0.

Via: SIP/2.0/UDP
192.168.0.176:45374;received=193.227.186.146;branch=z9hG4bK-d87543-00509
f6c6f4a047f-1--d87543-;rport=45374.

To:
"9613041705"<sip:9613041705 at OriginatingServer>;tag=991a35e6ab26c1f4ea62d
e8176a0818c.502f.

From: "9613041705"<sip:9613041705 at OriginatingServer>;tag=7d242230.

Call-ID: MmE3MTlmZDhiYWI0NjNmZjI5NWU5Njg1MmNhNDUwMDU..

CSeq: 6 REGISTER.

Server: OpenSER (1.3.2-notls (i386/linux)).

Content-Length: 0.

.

 

 

U OriginatingServer:5060 -> Target_of_Treplicate:5060

REGISTER sip:OriginatingServer SIP/2.0.

Via: SIP/2.0/UDP OriginatingServer;branch=z9hG4bK4cef.3d1bfc.0.

Via: SIP/2.0/UDP
192.168.0.176:7988;received=193.227.186.146;branch=z9hG4bK-d87543-221288
3e6a0dc710-1--d87543-;rport=7988.

Max-Forwards: 69.

Contact: <sip:9613041705 at 192.168.0.176:7988;rinstance=c1ac0eda25c39951>.

To: "9613041705"<sip:9613041705 at OriginatingServer>.

From: "9613041705"<sip:9613041705 at OriginatingServer>;tag=7f0b7450.

Call-ID: MGJhNmM1ZDdlZmNmNWQ2ODZkOWE4YWEwNzkzNmEzMzA..

CSeq: 2 REGISTER.

Expires: 3600.

Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE,
SUBSCRIBE, INFO.

User-Agent: X-Lite release 1006e stamp 34025.

Authorization: Digest
username="9613041705",realm="sero.ahwar.net",nonce="484653c5b066afdc9b4d
3bc20faa9e549e1bbe93",uri="sip:OriginatingServer",response="fc7ee7ed4e3c
68f85de2a298f7579421",cnonce="42f3c2c5b71b4623",nc=00000001,qop=auth,alg
orithm=MD5.

Content-Length: 0.

.

 

 

U Target_of_Treplicate:5060 -> OriginatingServer:5060

SIP/2.0 400 Bad Request.

Via: SIP/2.0/UDP OriginatingServer;branch=z9hG4bK4cef.3d1bfc.0.

Via: SIP/2.0/UDP
192.168.0.176:7988;received=193.227.186.146;branch=z9hG4bK-d87543-221288
3e6a0dc710-1--d87543-;rport=7988.

To:
"9613041705"<sip:9613041705 at OriginatingServer>;tag=991a35e6ab26c1f4ea62d
e8176a0818c.7860.

From: "9613041705"<sip:9613041705 at OriginatingServer>;tag=7f0b7450.

Call-ID: MGJhNmM1ZDdlZmNmNWQ2ODZkOWE4YWEwNzkzNmEzMzA..

CSeq: 2 REGISTER.

Contact:
<sip:9613041705 at 192.168.0.176:7988;rinstance=c1ac0eda25c39951>;expires=5
67.

P-Registrar-Error: Invalid CSeq number.

Server: OpenSER (1.3.2-notls (i386/linux)).

Content-Length: 0.

.

 

 

U OriginatingServer:5060 -> Target_of_Treplicate:5060

REGISTER sip:OriginatingServer SIP/2.0.

Via: SIP/2.0/UDP OriginatingServer;branch=z9hG4bK5cef.dfe76626.0.

Via: SIP/2.0/UDP
192.168.0.176:7988;received=193.227.186.146;branch=z9hG4bK-d87543-022b94
01307f967e-1--d87543-;rport=7988.

Max-Forwards: 69.

Contact:
<sip:9613041705 at 192.168.0.176:7988;rinstance=c1ac0eda25c39951>;expires=0
.

To: "9613041705"<sip:9613041705 at OriginatingServer>.

From: "9613041705"<sip:9613041705 at OriginatingServer>;tag=7f0b7450.

Call-ID: MGJhNmM1ZDdlZmNmNWQ2ODZkOWE4YWEwNzkzNmEzMzA..

CSeq: 3 REGISTER.

Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE,
SUBSCRIBE, INFO.

User-Agent: X-Lite release 1006e stamp 34025.

Authorization: Digest
username="9613041705",realm="sero.ahwar.net",nonce="484653c5b066afdc9b4d
3bc20faa9e549e1bbe93",uri="sip:OriginatingServer",response="9ded822006fa
51735838d3fdea96800b",cnonce="68a12fcb5c00aeaf",nc=00000002,qop=auth,alg
orithm=MD5.

Content-Length: 0.

.

 

 

U Target_of_Treplicate:5060 -> OriginatingServer:5060

SIP/2.0 200 OK.

Via: SIP/2.0/UDP OriginatingServer;branch=z9hG4bK5cef.dfe76626.0.

Via: SIP/2.0/UDP
192.168.0.176:7988;received=193.227.186.146;branch=z9hG4bK-d87543-022b94
01307f967e-1--d87543-;rport=7988.

To:
"9613041705"<sip:9613041705 at OriginatingServer>;tag=991a35e6ab26c1f4ea62d
e8176a0818c.93c8.

From: "9613041705"<sip:9613041705 at OriginatingServer>;tag=7f0b7450.

Call-ID: MGJhNmM1ZDdlZmNmNWQ2ODZkOWE4YWEwNzkzNmEzMzA..

CSeq: 3 REGISTER.

Server: OpenSER (1.3.2-notls (i386/linux)).

Content-Length: 0.

.

 

 

U OriginatingServer:5060 -> Target_of_Treplicate:5060

REGISTER sip:OriginatingServer SIP/2.0.

Via: SIP/2.0/UDP OriginatingServer;branch=z9hG4bK2cef.bec40741.0.

Via: SIP/2.0/UDP
192.168.0.176:7988;received=193.227.186.146;branch=z9hG4bK-d87543-ea14ff
1ac524e10c-1--d87543-;rport=7988.

Max-Forwards: 69.

Contact:
<sip:9613041705 at 193.227.186.146:7988;rinstance=7d4ba8842a9e4a7e>.

To: "9613041705"<sip:9613041705 at OriginatingServer>.

From: "9613041705"<sip:9613041705 at OriginatingServer>;tag=7f0b7450.

Call-ID: MGJhNmM1ZDdlZmNmNWQ2ODZkOWE4YWEwNzkzNmEzMzA..

CSeq: 4 REGISTER.

Expires: 3600.

Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE,
SUBSCRIBE, INFO.

User-Agent: X-Lite release 1006e stamp 34025.

Authorization: Digest
username="9613041705",realm="sero.ahwar.net",nonce="484653c5b066afdc9b4d
3bc20faa9e549e1bbe93",uri="sip:OriginatingServer",response="f126d934be4b
12c32a8ec783097a2ff6",cnonce="e3d03c6f36863764",nc=00000003,qop=auth,alg
orithm=MD5.

Content-Length: 0.

.

 

 

U Target_of_Treplicate:5060 -> OriginatingServer:5060

SIP/2.0 400 Bad Request.

Via: SIP/2.0/UDP OriginatingServer;branch=z9hG4bK2cef.bec40741.0.

Via: SIP/2.0/UDP
192.168.0.176:7988;received=193.227.186.146;branch=z9hG4bK-d87543-ea14ff
1ac524e10c-1--d87543-;rport=7988.

To:
"9613041705"<sip:9613041705 at OriginatingServer>;tag=991a35e6ab26c1f4ea62d
e8176a0818c.5d32.

From: "9613041705"<sip:9613041705 at OriginatingServer>;tag=7f0b7450.

Call-ID: MGJhNmM1ZDdlZmNmNWQ2ODZkOWE4YWEwNzkzNmEzMzA..

CSeq: 4 REGISTER.

Contact:
<sip:9613041705 at 193.227.186.146:7988;rinstance=7d4ba8842a9e4a7e>;expires
=566.

P-Registrar-Error: Invalid CSeq number.

Server: OpenSER (1.3.2-notls (i386/linux)).

Content-Length: 0.

.

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kamailio.org/pipermail/users/attachments/20080604/b4434b36/attachment.htm 


More information about the Users mailing list