[OpenSER-Users] Wrong To: Field In SIP Packet when Sending to PSTN GW
Ali Jawad
ali.jawad at splendor.net
Fri Feb 1 13:54:30 CET 2008
Hi All
I am using OpenSER as a proxy to make outbound calls my config is very
simple if the number dialled is not an openser account route it to the
PSTN gw.
if(does_uri_exist()){
# local uri does exist, is probably a user.
# lookup location
if(lookup("location")){
route(1);
return;
}
} else {
# probably a call to pstn....
route(2);
return;
}
and
route[2]
{
# pstn handling, simply route out to pstn.
sethostport("xx.xx.xx.xx:5060");
route(1);
}
The problem is that once the SIP packet arrives at the PSTN GW it does
NOT have the correct TO: set. Therefore the call does not get routed .
In the example below TO: is sip:calledNumber at myOpenserDomain instead of
sip:calledNumber at PSTN.GATEWAY.IP.IP
Caller: ali [!at] jabber.splendor.net (replace the [!at] with a @)
Callee: 009613041708
OpenSerDomain: jabber.splendor.net
U +0.289348 PSTN.GW.IP.IP:5060 -> 193.237.226.252:5060
SIP/2.0 404 Not Found .
Via: SIP/2.0/UDP 193.237.226.252;rport;branch=z9hG4bK6828.10c0315.0.
Via: SIP/2.0/UDP
192.168.0.176:65068;received=193.227.186.146;branch=z9hG4bK-d87543-be62c
55d821be10d-1--d87543-;rport=65068.
Record-Route: <sip:193.237.226.252;lr=on>.
From: "ssafass" <sip:ali at jabber.splendor.net>;tag=f36d6608.
To: "009613041705"
<sip:009613041705 at jabber.splendor.net>;tag=GR52RWG346-34.
Call-ID: 0942e159a72eab40ZmViZWY4YTVlOTRlOGJmZTM5ZDdkZGJiZjFmMTlmMjk..
CSeq: 1 INVITE.
Contact: "0000" <sip:PSTN.GW.IP.IP:5060>.
User-Agent: eyeBeam release 1003s stamp 31159.
Content-Length: 0.
I did a siptrace on the interface of the SIP proxy
http://pastebin.com/d56426d63
<http://www.voipuser.org/ship_to.php?url=http://pastebin.com/d56426d63>
This is my config:
http://pastebin.com/m128ca16e
<http://www.voipuser.org/ship_to.php?url=http://pastebin.com/m128ca16e>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20080201/feb941ef/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.gif
Type: image/gif
Size: 73 bytes
Desc: image001.gif
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20080201/feb941ef/attachment.gif>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image002.gif
Type: image/gif
Size: 73 bytes
Desc: image002.gif
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20080201/feb941ef/attachment-0001.gif>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image003.gif
Type: image/gif
Size: 73 bytes
Desc: image003.gif
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20080201/feb941ef/attachment-0002.gif>
More information about the sr-users
mailing list