Conditions as follows :
* SER runs on a Public IP
* SER works without auth & database modules,
* Nearly all user behind NAT (but routers configured to do port forwarding for TCP/UDP
5060) to help SER in some cases,
* Users numbers in format of 833XXXXXXX 834XXXXXXX and they should call each P2P-SIP-Calls
(if not behind NAT),
* If a user need to call PSTN end point (SIP Gateway located at 212.154.32.154) the call
traffic should flow over SER to SIP Gateway via T1 connection already located between that
systems so SER handles all voice traffic by help of RTP Proxy.
* UA's registers on SER (Zyxel Prestige 2000, Zyxel Prestige 200W, Cisco ATA186 etc.)
Problem is users cannot call each other (if i comment lines for nathelper they can call)
It's clear i think, and below is my ser.cfg, what do i need extra or erase. (It was
successful without nathelper module and added dial plan)
I get this error :
root@sipproxy/usr/local/etc/ser> ser 127.0.0.1 -n 1 -ddddddd -D -E
0(4419) read 23490987 from /dev/random
0(4419) seeding PRNG with 1133443665
0(4419) test random number 1528986547
0(4419) shm_mem_init: success
0(4419) DEBUG: register_fifo_cmd: new command (print) registered
0(4419) DEBUG: register_fifo_cmd: new command (uptime) registered
0(4419) DEBUG: register_fifo_cmd: new command (version) registered
0(4419) DEBUG: register_fifo_cmd: new command (pwd) registered
0(4419) DEBUG: register_fifo_cmd: new command (arg) registered
0(4419) DEBUG: register_fifo_cmd: new command (which) registered
0(4419) DEBUG: register_fifo_cmd: new command (ps) registered
0(4419) DEBUG: register_fifo_cmd: new command (kill) registered
0(4419) parse error (60,46-47): parse error
0(4419) parse error (60,46-47): bad command
0(4419) parse error (60,46-47): bad command
0(4419) parse error (60,48-49): bad command
0(4419) parse error (65,6-7): parse error
0(4419) parse error (65,6-7):
ERROR: bad config file (6 errors)
root@sipproxy/usr/local/etc/ser>
<<< ser.cfg. starts here <<<
#
# /usr/local/etc/ser/ser.cfg 2005/04/03 12:00:00 by Ozan Blotter $
#
# simple quick-start config script with nathelper/rtpproxy
# for IPv4/IPv6 gatewaying
#
# ----------- global configuration parameters ------------------------
debug=3 # debug level
#fork=yes
#log_stderror=no #
check_via=no # (cmd. line: -v)
dns=no # (cmd. line: -r)
rev_dns=no # (cmd. line: -R)
port=5060
children=2 # count of ser processes per interface
fifo="/tmp/ser_fifo"
# ------------------ module loading ----------------------------------
loadmodule "/usr/local/lib/ser/modules/sl.so"
loadmodule "/usr/local/lib/ser/modules/tm.so"
loadmodule "/usr/local/lib/ser/modules/rr.so"
loadmodule "/usr/local/lib/ser/modules/maxfwd.so"
loadmodule "/usr/local/lib/ser/modules/usrloc.so"
loadmodule "/usr/local/lib/ser/modules/registrar.so"
#Nathelper for RTPproxy
loadmodule "/usr/local/lib/ser/modules/nathelper.so"
# ----------------- setting module-specific parameters ---------------
# -- usrloc params --
modparam("usrloc", "db_mode", 0)
# -- rr params --
# add value to ;lr param to make some broken UAs happy
modparam("rr", "enable_full_lr", 1)
modparam ("nathelper", "rtpproxy_sock",
"/var/run/rtpproxy.sock")
# ------------------------- request routing logic -------------------
# main routing logic
route {
# initial sanity checks -- messages with
# max_forwards==0, or excessively long requests
if (!mf_process_maxfwd_header("10")) {
sl_send_reply("483","Too Many Hops");
break;
};
if ( msg:len > max_len ) {
sl_send_reply("513", "Message Too Big");
break;
};
# route invitation request to other domains
if (!uri == myself) && method == "INVITE") {
record_route();
if (!t_relay())
sl_reply_error();
break;
};
if (method == "REGISTER") {
if (af == inet) {
save ("location_inet4");
} else if (af ==inet6) {
save ("location_inet6");
} else {
sl_send_reply("403", "Call Cannot Be Served Here");
};
break;
};
if (method == "INVITE") {
if (lookup("location_inet4")) {
# Comment Out Three Lines Below If You Want
# RTP for IPv4>IPv4 Calls To Go Directly
# Between UAs
if (af == inet)
if (force_rtp_proxy("FAII"))
t_on_reply("1");
# Proxy Session From An Internal IPv4
# Phone To An External IPv6 Address
if (af == inet6)
if (force_rtp_proxy("FAIE"))
t_on_reply("1");
} else if (lookup("location_inet6")) {
# Proxy Session From An External IPv6
# Phone To An Internal IPv4 Address
if (af == inet)
if (force_rtp_proxy(FAEI"))
t_on_reply("1");
# Comment Out Three Lines Below If You Want
# RTP for IPv6>IPv6 Calls To Go Directly
# Between UAs
if (af == inet6)
if (force_rtp_proxy("FAEE"))
t_on_reply("1");
} else {
sl_send_reply("403", "Call Cannot Be Served Here");
break;
};
};
if (method == "BYE" || method == "CANCEL")
unforce_rtp_proxy();
#Do Strict Routing If Pre-Loaded Route Headers Present
if (loose_route()) {
t_relay();
break;
};
if (method == "INVITE")
record_route();
if (!t_relay())
sl_reply_error();
}
onreply_route[1] {
if (!(status=~"183" || status=~"200"))
break;
force_rtp_proxy("FA");
}
>> ser.cfg. ends here >>>