Hi all
I am using SER+NAT+rtpproxy as proxy servers. I have serched
seruser mailing list for solution and I didn't find any. Please help
me in below senerio.
Elements
-----------------
1) UA 'PUBLIC' ( in public internet with IP
211.95.122.XXX.XXX)
2) SIP SER with NAT helper(CVS version) + rtp proxy on same
machine(http://www.portaone.com/~sobomax/rtpproxy.tar ) with one
external public IP and internal privite IP)
3) UA 'PRIVATE' - in side private domain with 192.17.1.XXX) ip address.
4) UA 'PUBLIC' not register to ser. UA 'PRIVATE' have registerd to ser.
I am trying to accomplish to make call from UA 'PRIVATE' to UA 'PUBLIC'.
i'e
calls from private IP to public IP using SER as my signalling proxy
and rtpproxy as proxy for RTP.
SER is succussfully etablishing connection between two user agents and
but it is failed to forward rtp between two UAs. No voice. Request as
'INVITE'
ser proxy change SDP's ip and port, but reply as stats 200 and 183 did
not change
SDP's ip and report, so UA 'PUBLIC' can hear UA 'PRIVATE', but UA
'PRIVATE' can't
hear from UA 'PUBLIC'.
Is it MUST that UA 'PUBLIC' register to ser?
This is my ser.cfg:
# main routing logic
route
{
/*================================ ROUTINE CHECKS
=============================================*/
# filter too old messages
if (!mf_process_maxfwd_header("10"))
{
log("LOG: Too many hops\n");
sl_send_reply("483","Too Many Hops");
break;
}
if (msg:len > max_len)
{
sl_send_reply("513", "Message too big");
break;
}
# compulsory processing of Route header fields and adding RR
loose_route();
# These devices need rtp proxy
#if (search("User-Agent:"))
#{
setflag(2); # remember this needs rtp proxy
force_rport();
# fix_nated_contact();
#}
# registration (uses rewritten contacts)
if (method=="REGISTER")
{
if(!radius_proxy_authorize("REGISTER"))
{
sl_send_reply("401", "Forbidden");
break;
}
save("location");
break;
}
# Invite authentication
if (method=="INVITE")
{
record_route();
if (isflagset(2))
{
if(!radius_proxy_authorize("INVITE"))
{
sl_send_reply("401", "Forbidden");
break;
}
force_rtp_proxy();
}
/* set up reply processing */
t_on_reply("1");
}
# Forward
if(uri=~"^sip:5[0-9][0-9]*@")
{
rewritehost("211.95.122.158");
prefix("66123");
forward(211.95.122.158, 5060);
break;
}
# Look up the callee
if (method == "INVITE" || method == "CANCEL")
{
if (!lookup("location"))
{
sl_send_reply("404", "Not Found");
break;
}
}
# forward the request statefuly now; (we need *stateful*
forwarding,
# because the stateful mode correlates requests with replies and
# drops retranmissions; otherwise, we would have to report on
# every single message received)
setflag(1); # set for accounting (the same value as in log_flag!)
if(!t_relay())
{
sl_reply_error();
break;
}
}
# all incoming replies for t_onrepli-ed transactions enter here
onreply_route[1]
{
if (status=~"(183)|2[0-9][0-9]")
{
force_rtp_proxy();
}
}
Thanks for help.
Regards,
robert