|
@@ -310,6 +310,9 @@ modparam("jsonrpcs", "pretty_format", 1)
|
|
/* set the path to RPC unix socket control file */
|
|
/* set the path to RPC unix socket control file */
|
|
# modparam("ctl", "binrpc", "unix:/var/run/kamailio/kamailio_ctl")
|
|
# modparam("ctl", "binrpc", "unix:/var/run/kamailio/kamailio_ctl")
|
|
|
|
|
|
|
|
+# ----- sanity params -----
|
|
|
|
+modparam("sanity", "autodrop", 0)
|
|
|
|
+
|
|
# ----- tm params -----
|
|
# ----- tm params -----
|
|
# auto-discard branches from previous serial forking leg
|
|
# auto-discard branches from previous serial forking leg
|
|
modparam("tm", "failure_reply_mode", 3)
|
|
modparam("tm", "failure_reply_mode", 3)
|
|
@@ -595,7 +598,7 @@ route[REQINIT] {
|
|
}
|
|
}
|
|
|
|
|
|
if(!sanity_check("17895", "7")) {
|
|
if(!sanity_check("17895", "7")) {
|
|
- xlog("Malformed SIP message from $si:$sp\n");
|
|
|
|
|
|
+ xlog("Malformed SIP request from $si:$sp\n");
|
|
exit;
|
|
exit;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -951,6 +954,14 @@ branch_route[MANAGE_BRANCH] {
|
|
}
|
|
}
|
|
|
|
|
|
# Manage incoming replies
|
|
# Manage incoming replies
|
|
|
|
+reply_route {
|
|
|
|
+ if(!sanity_check("17604", "6")) {
|
|
|
|
+ xlog("Malformed SIP response from $si:$sp\n");
|
|
|
|
+ drop;
|
|
|
|
+ }
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+# Manage incoming replies in transaction context
|
|
onreply_route[MANAGE_REPLY] {
|
|
onreply_route[MANAGE_REPLY] {
|
|
xdbg("incoming reply\n");
|
|
xdbg("incoming reply\n");
|
|
if(status=~"[12][0-9][0-9]") {
|
|
if(status=~"[12][0-9][0-9]") {
|