Hello, I have a problem that my calls get rejected by he pstn gateway as my gateway is
expecting a DID number instead of a 4 digit extension as the 'from user". Let me
explain my situation:
1. I have set callfwd_busy in my user preference table.
2. In my failure route I check to see if callfwd_busy has been set, if it has then I
execute the following script:
if (t_check_status("486|408")) {
$avp(dst_number) = $rU;
if (avp_db_load("$avp(dst_number)",
"$avp(callfwd_busy)")) {
xlog("LOG: avp(callfwd_busy)=$avp(callfwd_busy),
avp(dst_number)=$avp(dst_number)\n");
}
xlog("LOG: Failure route with $rU $avp(dst_number)
\n");
$rU = $avp(callfwd_busy);
$ru = "sip:" + $rU + "@" +
$sel(cfg_get.pstn.gw_ip);
route(RELAY);
exit;
}
When I call from extension 7004 to ext 7002 ( this has callfwd_busy set to a DID number)
the trace looks as follows:
U 172.10.30.15:5080 -> 172.10.30.15:5060
SIP/2.0 486 Busy Here.
Via: SIP/2.0/UDP 54.200.xx.yy:5060;branch=z9hG4bKee75.ab791c5.0;received=172.10.30.15.
Via: SIP/2.0/UDP
192.168.1.8:5060;received=71.252.219.63;branch=z9hG4bK209939211;rport=1025.
From: "7004" <sip:7004@ajfmc1.myDomain.net>;tag=1830267367.
To: <sip:7002@ajfmc1.myDomain.net>;tag=as17cd0b40.
Call-ID: 876294364-5060-74(a)BJC.BGI.B.I.
CSeq: 731 INVITE.
Server: Asterisk PBX 1.8.17.0.
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH.
Supported: replaces, timer.
Content-Length: 0.
U 172.10.30.15:5060 -> 172.10.30.15:5080
INVITE sip:18455981234@64.136.xx.yy:5060 SIP/2.0.
Record-Route: <sip:54.200.xx.xx;lr=on;ftag=1830267367;nat=yes>.
Via: SIP/2.0/UDP 54.200.xx.xx:5060;branch=z9hG4bKee75.ab791c5.1.
Via: SIP/2.0/UDP
192.168.1.8:5060;received=71.252.xx.yy;branch=z9hG4bK209939211;rport=1025.
From: "7004" <sip:7004@ajfmc1.myDomain.net>;tag=1830267367.
To: <sip:7002@ajfmc1.myDomain.net>.
Call-ID: 876294364-5060-74(a)BJC.BGI.B.I.
CSeq: 731 INVITE.
Contact: "7004" <sip:7004@71.252.xx.yy:1025>.
Max-Forwards: 16.
User-Agent: Grandstream HT701 1.0.4.8.
Privacy: none.
P-Preferred-Identity: "7004" <sip:7004@ajfmc1.myDomain.net>.
Supported: replaces, path, timer, eventlist.
Allow: INVITE, ACK, OPTIONS, CANCEL, BYE, SUBSCRIBE, NOTIFY, INFO, REFER, UPDATE.
Content-Type: application/sdp.
Accept: application/sdp, application/dtmf-relay.
Content-Length: 453.
.
v=0.
o=7004 8000 8000 IN IP4 172.10.30.1554.200.xx.xx.
s=SIP Call.
c=IN IP4 172.10.30.1554.200.xx.xx.
t=0 0.
m=audio 6248262482 RTP/AVP 0 18 4 8 2 97 101.
a=sendrecv.
a=rtpmap:0 PCMU/8000.
a=ptime:20.
a=rtpmap:18 G729/8000.
a=fmtp:18 annexb=no.
a=rtpmap:4 G723/8000.
a=rtpmap:8 PCMA/8000.
a=rtpmap:2 G726-32/8000.
a=rtpmap:97 iLBC/8000.
a=fmtp:97 mode=20.
a=rtpmap:101 telephone-event/8000.
a=fmtp:101 0-16,32-36,54.
a=nortpproxy:yes.
a=nortpproxy:yes.
#
U 172.10.30.15:5080 -> 172.10.30.15:5060
SIP/2.0 503 Unavailable.
Via: SIP/2.0/UDP 54.200.xx.xx:5060;branch=z9hG4bKee75.ab791c5.1;received=172.10.30.15.
Via: SIP/2.0/UDP
192.168.1.8:5060;received=71.252.xx.yy;branch=z9hG4bK209939211;rport=1025.
From: "7004" <sip:7004@ajfmc1.myDomain.net>;tag=1830267367.
To: <sip:7002@ajfmc1.myDomain.net>;tag=as17cd0b40.
Call-ID: 876294364-5060-74(a)BJC.BGI.B.I.
CSeq: 731 INVITE.
Server: Asterisk PBX 1.8.17.0.
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH.
Supported: replaces, timer.
Content-Length: 0.
It looks like my gateway is expecting to see a DID number in the from header. Can someone
let me know how I can dot this? Thank you.
Arun