Hello all,
I need to execute an exec_msg command inside onreply_route code buy SER doesn't permit
this.
This is my ser.cfg:
route{
......
if (method=="INVITE"){
..........
t_relay();
route(2);
break;
};
route[2]
{
t_on_reply("2");
}
onreply_route[2]
{
if (status=~"200"){
if ( search("msrp:") ){
exec_msg("printenv SRCIP > /tmp/200ok.txt; cat >> /tmp/200ok.txt;
/bin/bash /usr/local/ser_snapshot/sbin/controlador2");
replace_all_file("msrp:\/\/[0-9\.:\/;a-z]*\r","/tmp/pathmsrp200ok.txt");
}
}
}
In onreply_route, I need to execute exec_msg to manipulate 200 ok, but SER doesn't
permit it.
What can I execute exec_msg??
I try to probe this:
route[2]
{
t_on_reply("2");
}
onreply_route[2]
{
if (status=~"200"){
if ( search("msrp:") ){
t_on_failure("2");
}
}
}
failure_route[2] {
exec_msg("printenv SRCIP > /tmp/200ok.txt; cat >> /tmp/200ok.txt; /bin/bash
/usr/local/ser_snapshot/sbin/controlador2");
replace_all_file("msrp:\/\/[0-9\.:\/;a-z]*\r","/tmp/pathmsrp200ok.txt");
t_relay();
}
But never enter in failure route!!!
Thank you in advance for any help.
_________________________________________________________________
Busca desde cualquier página Web con una protección excepcional. Consigue la Barra de
herramientas de Windows Live hoy mismo y GRATUITAMENTE.
http://www.toolbar.live.com