<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2800.1106" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>We have downloaded the latest ser software from cvs 
in order to support appending of remote party id while using mysql as the ser 
database.</FONT></DIV>
<DIV><FONT face=Arial size=2>After compiling and installing the ser software we 
included the&nbsp;auth and auth_db parameters and also the append_rpid_hf() 
function&nbsp;in our ser.cfg file as shown below.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>SER server starts and&nbsp;registration is 
successfull however when forwarding to the pstn gateway, ser will not append the 
remote party id header, even if the rpid and uri columns in mysql 
database&nbsp;are populated accordingly using the serctl add rpid command. Calls 
are also successfull however the gateway will not include the calling party 
number in the setup message because the rpid header is missing.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Any ideas please?</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Thanks</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Charles and Andrew</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2># ----------- global configuration parameters 
------------------------</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial 
size=2>#debug=3&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; # debug level 
(cmd line: -dddddddddd)<BR>#fork=yes<BR>#log_stderror=no&nbsp;# (cmd line: 
-E)</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>/* Uncomment these lines to enter debugging mode 
<BR>debug=7<BR>fork=no<BR>log_stderror=yes<BR>*/</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>check_via=no&nbsp;# (cmd. line: 
-v)<BR>dns=no&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; # 
(cmd. line: -r)<BR>rev_dns=no&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; # (cmd. line: 
-R)<BR>#port=5060<BR>#children=4<BR>fifo="/tmp/ser_fifo"</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2># ------------------ module loading 
----------------------------------</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>loadmodule 
"/our_downloads/sip_router/modules/mysql/mysql.so"<BR>#loadmodule 
"//lib/ser/modules/mysql.so"</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>loadmodule "//lib/ser/modules/sl.so"<BR>loadmodule 
"//lib/ser/modules/tm.so"<BR>loadmodule "//lib/ser/modules/rr.so"<BR>loadmodule 
"//lib/ser/modules/maxfwd.so"<BR>loadmodule 
"//lib/ser/modules/usrloc.so"<BR>loadmodule 
"//lib/ser/modules/registrar.so"<BR>loadmodule 
"//lib/ser/modules/textops.so"</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2># Uncomment this if you want digest 
authentication<BR># mysql.so must be loaded !<BR>loadmodule 
"//lib/ser/modules/auth.so"<BR>loadmodule 
"//lib/ser/modules/auth_db.so"</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV><FONT face=Arial size=2>
<DIV><BR>#loadmodule "//lib/ser/modules/acc.so"</DIV>
<DIV>&nbsp;</DIV>
<DIV># ----------------- setting module-specific parameters 
---------------</DIV>
<DIV>&nbsp;</DIV>
<DIV># -- usrloc params --</DIV>
<DIV>&nbsp;</DIV>
<DIV>#modparam("usrloc", "db_mode",&nbsp;&nbsp; 0)</DIV>
<DIV>&nbsp;</DIV>
<DIV># Uncomment this if you want to use SQL database <BR># for persistent 
storage and comment the previous line<BR>modparam("usrloc", "db_mode", 1)</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV># -- auth params --</DIV>
<DIV>&nbsp;</DIV>
<DIV><BR>modparam("auth_db", "use_rpid", 1)<BR>modparam("auth_db", 
"rpid_column", "rpid")<BR>modparam("auth", "rpid_prefix", 
"&lt;sip:")<BR>modparam("auth", "rpid_suffix", 
"@testphone.com&gt;:party=calling;screen=no;privacy=off")</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV><BR># Uncomment if you are using auth module<BR>#<BR>modparam("auth_db", 
"calculate_ha1", yes)<BR>#<BR># If you set "calculate_ha1" parameter to yes 
(which true in this config), <BR># uncomment also the following 
parameter)<BR>#<BR>modparam("auth_db", "password_column", "password")</DIV>
<DIV>&nbsp;</DIV>
<DIV># -- rr params --<BR># add value to ;lr param to make some broken UAs 
happy<BR>modparam("rr", "enable_full_lr", 1)</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV># -------------------------&nbsp; request routing logic 
-------------------</DIV>
<DIV>&nbsp;</DIV>
<DIV># main routing logic</DIV>
<DIV>&nbsp;</DIV>
<DIV>route{<BR>&nbsp;<BR></DIV>
<DIV>&nbsp;# initial sanity checks -- messages with<BR>&nbsp;# max_forwards==0, 
or excessively long requests<BR>&nbsp;if (!mf_process_maxfwd_header("10")) 
{<BR>&nbsp;&nbsp;sl_send_reply("483","Too Many 
Hops");<BR>&nbsp;&nbsp;break;<BR>&nbsp;};<BR>&nbsp;if ( msg:len &gt; max_len ) 
{<BR>&nbsp;&nbsp;sl_send_reply("513", "Message too 
big");<BR>&nbsp;&nbsp;break;<BR>&nbsp;};</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;<BR>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;# we record-route all messages -- to make sure that<BR>&nbsp;# 
subsequent messages will go through our proxy; that's<BR>&nbsp;# particularly 
good if upstream and downstream entities<BR>&nbsp;# use different transport 
protocol<BR>&nbsp;record_route();&nbsp;<BR>&nbsp;# loose-route 
processing<BR>&nbsp;if (loose_route()) 
{<BR>&nbsp;&nbsp;t_relay();<BR>&nbsp;&nbsp;break;<BR>&nbsp;};</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;<BR>&nbsp;# if the request is for other domain use UsrLoc<BR>&nbsp;# 
(in case, it does not work, use the following command<BR>&nbsp;# with proper 
names and addresses in it)<BR>&nbsp;if (uri=~"testphone.com")&nbsp; 
{<BR>&nbsp;&nbsp;lookup("aliases");<BR>&nbsp;&nbsp;if (method=="REGISTER") 
{</DIV>
<DIV>&nbsp;</DIV>
<DIV>#Uncomment this if you want to use digest 
authentication<BR>&nbsp;&nbsp;&nbsp;if (!www_authorize("testphone.com", 
"subscriber")) {<BR>&nbsp;&nbsp;&nbsp;&nbsp;www_challenge("testphone.com", 
"0");<BR>&nbsp;&nbsp;&nbsp;&nbsp;append_rpid_hf();<BR>&nbsp;&nbsp;&nbsp;&nbsp;break;<BR>&nbsp;&nbsp;&nbsp;};</DIV>
<DIV>&nbsp;</DIV>
<DIV><BR>&nbsp;&nbsp;&nbsp;<BR>&nbsp;&nbsp;&nbsp;save("location");<BR>&nbsp;&nbsp;&nbsp;break;<BR>&nbsp;&nbsp;};</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
if (uri=~"^sip:21") {<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; 
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; 
append_rpid_hf();<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;forward(a 
valid ip address for the gateway was inserted 
here);<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; 
break;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
}</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
if (uri=~"^sip:123") 
{<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
forward(a valid ip address for the gareway was inserted 
here);<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;break;<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
}</DIV>
<DIV>&nbsp;</DIV>
<DIV><BR>&nbsp;&nbsp;# native SIP destinations are handled using our USRLOC 
DB<BR>&nbsp;&nbsp;if (!lookup("location")) 
{<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sl_send_reply("404", 
"Not Found");<BR>&nbsp;&nbsp;&nbsp;break;<BR>&nbsp;&nbsp;};<BR>&nbsp;};</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV><BR>&nbsp;# forward to current uri now; use stateful forwarding; 
that<BR>&nbsp;# works reliably even if we forward from TCP to UDP<BR>&nbsp;if 
(!t_relay()) 
{<BR>&nbsp;&nbsp;sl_reply_error();<BR>&nbsp;};<BR>&nbsp;<BR>&nbsp;<BR>}</DIV>
<DIV>&nbsp;</DIV>
<DIV></FONT>&nbsp;</DIV></BODY></HTML>