OpenSER Routing

From OnnoWiki
Revision as of 10:50, 12 March 2008 by Onnowpurbo (talk | contribs) (New page: Beberapa tip routing sederhana. Untuk mengarahkan ke PSTN Gateway. Yang misalnya berada di alamat 192.168.0.95:5061 if(uri=~"sip:.+@*") { # forward ke PSTN gateway di 192.168.0.95...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Beberapa tip routing sederhana.

Untuk mengarahkan ke PSTN Gateway. Yang misalnya berada di alamat 192.168.0.95:5061


if(uri=~"sip:.+@*")
{
   # forward ke PSTN gateway di 192.168.0.95:5061
   rewritehostport("192.168.0.95:5061");
   route(1);
}
route[1] {
       # send it out now; use stateful forwarding as it works reliably
       # even for UDP2TCP
       if (!t_relay()) {
               sl_reply_error();
       };
       exit;
}