CMDCommand · run as root on the server · modsec family
urbestack-modsec-rule-add
First published 19 Nov 2026
0.2.30Unchanged since publicationUsage
# urbestack-modsec-rule-add [--note TEXT] [--off] < RULEDescription
From the command's --help outputAdds a server-wide custom ModSecurity rule from standard input. Supply SecRule or SecAction directives in ModSecurity syntax. A chain counts as one rule. Set the id action to a unique rule number from 1 to 89999. Use --note to record the rule's purpose. The rule is enabled by default. Use --off to save it disabled. UrbeStack tests Apache's configuration with the rule in place before applying it. If the test fails, UrbeStack discards the rule and returns Apache's error message. A rule that passes the test can still block every request to every site. The UrbeStack web interface remains reachable. Run urbestack-modsec-rule-set --rule N --enabled off to disable the rule.Usage: urbestack-modsec-rule-add [--note TEXT] [--off] < RULE Adds a server-wide custom ModSecurity rule from standard input. Supply SecRule or SecAction directives in ModSecurity syntax. A chain counts as one rule. Set the id action to a unique rule number from 1 to 89999. Use --note to record the rule's purpose. The rule is enabled by default. Use --off to save it disabled. UrbeStack tests Apache's configuration with the rule in place before applying it. If the test fails, UrbeStack discards the rule and returns Apache's error message. A rule that passes the test can still block every request to every site. The UrbeStack web interface remains reachable. Run urbestack-modsec-rule-set --rule N --enabled off to disable the rule.
Options
Find other commands that accept these optionsSame in the API
This operation runs the command.Generated from release 0.2.35 (current) · urbestack-modsec-rule-add --help outputThis entry has been unchanged since it was first published in release 0.2.30 on 19 Nov 2026.
urbestack.com/docs/commands/urbestack-modsec-rule-add/