[Serusers] how to use the pdt module?

Elena Ramona Modroiu ramona at iptel.org
Mon Mar 29 14:08:39 CEST 2004


Hi,

You need a database for your code/domain pairs. File doc/pdt.sql tells 
you how the database should look like. Please note that the prefix 
associated with a domain is called code, to avoid confusions with the 
prefix parameter of the module, which is a prefix that tells what RURIs 
will be rewritten.  RURI:    
[<prefix>]<code><userid><:password>@<mydomain.com> ...

Then you have to set the module parameters. The terminator parameter 
specifies the digit that ends the code (to know when to stop searches ) 
and can be left unset, implicit is 0. Note that in the database the code 
are stored without the ending digit, but in the RURI must appear with 
ending digit. If you want that the RURI rewrite occurs when the RURI 
starts with "0" you have to set the prefix parameter to "0".

Example:

modparam("pdt", "terminator", 0)
modparam("pdt", "prefix", "0")

One entry in the database: code=1, domain=otherdomain

URI:010xxxxxx at mydomain

New URI after applying prefix2domain is:  xxxxxx at otherdomain


Greetings,
Ramona




Shady wrote:

> I have several hardware SIP phones connected to my SER. I want to call 
> external
> URIs and that's whay, as I guess, I showd use the pdt module to handle the
> prefixes and resolve them to domains. I want to set the SER for 
> example, when
> the called number is 01xxxxxx to rewrite the URI from 
> 01xxxxxx at mydomain <mailto:01xxxxxx at mydomain> to
> xxxxxx at otherdomain <mailto:xxxxxx at otherdomain>. In the pdt's 
> documentation I can not find detailed
> instructions how to do that. Please help :)
> Thanks
>
>------------------------------------------------------------------------
>
>_______________________________________________
>Serusers mailing list
>serusers at lists.iptel.org
>http://lists.iptel.org/mailman/listinfo/serusers
>  
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20040329/dc1f81a1/attachment.htm>


More information about the sr-users mailing list