SER example redirect

Ser as a stateless SIP redirect server

This example shows use of ser as stateless redirect server

  1. $Id: redirect.cfg,v 1.5 2002/12/09 02:32:57 jiri Exp $

  1. ------------------ module loading ----------------------------------

loadmodule "modules/sl/sl.so"


  1. ------------------------- request routing logic -------------------

  1. main routing logic

route{
  1. for testing purposes, simply okay all REGISTERs
if (method=="REGISTER") {
log("REGISTER");
sl_send_reply("200", "ok");
break;
};
  1. rewrite current URI, which is always part of destination ser
rewriteuri("sip:parallel@iptel.org:9");
  1. append one more URI to the destination ser
append_branch("sip:redirect@iptel.org:9");
  1. redirect now
sl_send_reply("300", "Redirect");
}

See also




Back to SER tips and tricks

Ser as a stateless SIP redirect server

This example shows use of ser as stateless redirect server

  1. $Id: redirect.cfg,v 1.5 2002/12/09 02:32:57 jiri Exp $

  1. ------------------ module loading ----------------------------------

loadmodule "modules/sl/sl.so"


  1. ------------------------- request routing logic -------------------

  1. main routing logic

route{
  1. for testing purposes, simply okay all REGISTERs
if (method=="REGISTER") {
log("REGISTER");
sl_send_reply("200", "ok");
break;
};
  1. rewrite current URI, which is always part of destination ser
rewriteuri("sip:parallel@iptel.org:9");
  1. append one more URI to the destination ser
append_branch("sip:redirect@iptel.org:9");
  1. redirect now
sl_send_reply("300", "Redirect");
}

See also




Back to SER tips and tricks
Created by: oej, Last modification: Wed 26 of Jan, 2005 (20:33 UTC) by flobi
Please update this page with new information, just login and click on the "Edit" or "Discussion" tab. Get a free login here: Register Thanks! - Find us on Google+