<!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.2900.2722" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV>The test does the following:</DIV>
<DIV>If callee is not within the local domain (as registered in the domains 
table), check that:<BR>&nbsp;either... caller is from a local domain</DIV>
<DIV>&nbsp;or... the source is a trusted party (gw etc)</DIV>
<DIV>If not, forbidden</DIV>
<DIV>&nbsp;</DIV>
<DIV>g-)</DIV>
<DIV>&nbsp;</DIV>
<DIV>---- Original Message ----<BR>From: Alberto<BR>To: Greger V. Teigre<BR>Cc: 
serusers@lists.iptel.org<BR>Sent: Friday, September 16, 2005 08:51 AM<BR>Subject: Re: 
[Serusers] ser.cfg with PSTN gateway connectivity<BR><BR>&gt; Yes, I did it 
too.<BR>&gt; <BR>&gt; I suppose that I have to do a entry in 'trusted' table of 
the IP<BR>&gt; address of the PSTN gateway. <BR>&gt; <BR>&gt; mysql&gt; select * 
from trusted;<BR>&gt; +----------------+-------+--------------+<BR>&gt;&gt; 
src_ip&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | proto | from_pattern 
|<BR>&gt; +----------------+-------+--------------+<BR>&gt;&gt; 212.xxx.xxx.81 | 
any&nbsp;&nbsp; | ^sip:.*$&nbsp;&nbsp;&nbsp;&nbsp; |<BR>&gt; 
+----------------+-------+--------------+<BR>&gt; 1 row in set (0.01 
sec)<BR>&gt; <BR>&gt; mysql&gt; select username,domain,password from 
subscriber;<BR>&gt; +----------+-------------+-----------+<BR>&gt;&gt; username 
| domain&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | password&nbsp; |<BR>&gt; 
+----------+-------------+-----------+<BR>&gt;&gt; admin&nbsp;&nbsp;&nbsp; | 
sip&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | 
heslo&nbsp;&nbsp;&nbsp;&nbsp; |<BR>&gt;&gt; 1000&nbsp;&nbsp;&nbsp;&nbsp; | 
teching.net | 123454321 |<BR>&gt;&gt; 2000&nbsp;&nbsp;&nbsp;&nbsp; | teching.net 
| 12345&nbsp;&nbsp;&nbsp;&nbsp; |<BR>&gt;&gt; 3000&nbsp;&nbsp;&nbsp;&nbsp; | 
teching.net | 12345&nbsp;&nbsp;&nbsp;&nbsp; |<BR>&gt;&gt; 
4000&nbsp;&nbsp;&nbsp;&nbsp; | teching.net | 12345&nbsp;&nbsp;&nbsp;&nbsp; 
|<BR>&gt;&gt; 5000&nbsp;&nbsp;&nbsp;&nbsp; | teching.net | 
12345&nbsp;&nbsp;&nbsp;&nbsp; |<BR>&gt; 
+----------+-------------+-----------+<BR>&gt; 6 rows in set (0.00 sec)<BR>&gt; 
<BR>&gt; Is this correct? I believe that I do not understand it well.<BR>&gt; 
<BR>&gt; Thanks.<BR>&gt; <BR>&gt; <BR>&gt;&gt; Hi,<BR>&gt;&gt; <BR>&gt;&gt; I've 
read the SER Getting Started form http://www.onsip.org .<BR>&gt;&gt; 
<BR>&gt;&gt; When I configure the ser with PSTN Gateway (subject 8 of the guide) 
I<BR>&gt;&gt; can't register any client (403, Forbidden). I think, the problem 
is<BR>&gt;&gt; the next line of ser.cfg:<BR>&gt;&gt; 
<BR>&gt;&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if (!is_uri_host_local()) 
{<BR>&gt;&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
if (is_from_local() || allow_trusted()) 
{<BR>&gt;&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
route(4);<BR>&gt;&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
route(1);<BR>&gt;&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
} else 
{<BR>&gt;&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
sl_send_reply("403","Forbidden");<BR>&gt;&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
};<BR>&gt;&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
break;<BR>&gt;&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
};<BR>&gt;&gt; <BR>&gt;&gt; I'd copied the permissions.allow and 
permissions.deny to<BR>&gt;&gt; /usr/local/etc/ser and in the .allow file I'd 
uncomment the last line<BR>&gt;&gt; (ALL:ALL)<BR>&gt;&gt; <BR>&gt;&gt; Any idea? 
Thanks.</DIV></BODY></HTML>