# HG changeset patch # User Matthew Wild # Date 1489142177 0 # Node ID c6652d055ba32738dbea8dd82823cec16e635bab # Parent 7c3a1688e385fe2b649addefc4a92400ffe7249a mod_firewall: Add some more comments diff -r 7c3a1688e385 -r c6652d055ba3 mod_firewall/conditions.lib.lua --- a/mod_firewall/conditions.lib.lua Tue Mar 14 12:35:56 2017 +0000 +++ b/mod_firewall/conditions.lib.lua Fri Mar 10 10:36:17 2017 +0000 @@ -280,6 +280,7 @@ return "not not session.directed[from]", { "from" }; end +-- TO FULL JID? function condition_handlers.TO_FULL_JID() return "not not full_sessions[to]", { "to" }; end @@ -304,6 +305,7 @@ return ("scan_list(list_%s, %s)"):format(list_name, "tokens_"..search_name.."_"..pattern_name), { "scan_list", "tokens:"..search_name.."-"..pattern_name, "list:"..list_name }; end +-- COUNT: lines in body < 10 local valid_comp_ops = { [">"] = ">", ["<"] = "<", ["="] = "==", ["=="] = "==", ["<="] = "<=", [">="] = ">=" }; function condition_handlers.COUNT(count_expression) local pattern_name, search_name, comparator_expression = count_expression:match("(%S+) in (%S+) (.+)$");