Browse Source

FIX MESSAGE-ROLE

3.20
lazedo 11 years ago
parent
commit
fdc4cf9252
1 changed files with 3 additions and 15 deletions
  1. +3
    -15
      kamailio/default.cfg

+ 3
- 15
kamailio/default.cfg View File

@ -375,22 +375,10 @@ route[HANDLE_MESSAGE]
if (is_method("MESSAGE")) {
if (isflagset(FLAG_INTERNALLY_SOURCED)) {
route(INTERNAL_TO_EXTERNAL_RELAY);
#!ifdef TRAFFIC-FILTER-ROLE
} else if (!isflagset(FLAG_TRUSTED_SOURCE)
&& $rd =~ "[0-9]{1,3}\.[0-9]{1,3}.[0-9]{1,3}\.[0-9]{1,3}") {
xlog("L_WARN", "$ci|end|dropping MESSAGE request with IP domain");
#!endif
} else {
xlog("L_WARN", "$ci|end|MESSAGE $(hdr(Content-Type))");
if( $hdr(Content-Type) == "application/im-iscomposing+xml" ) {
xlog("L_WARN", "$ci|end|dropping MESSAGE application/im-iscomposing+xml");
sl_send_reply("200", "OK");
} else {
route(DISPATCHER_FIND_ROUTES);
route(EXTERNAL_TO_INTERNAL_RELAY);
}
} else {
sl_send_reply("202", "delivered to /dev/null");
exit()
}
exit();
}
#!endif
}


Loading…
Cancel
Save