Hi @martje65,
That is an excellent observation!
We include both syntaxes intentionally to ensure 100% compatibility with all server environments, regardless of their age or configuration.
Require not ip is the modern syntax for Apache 2.4.
Deny from is the older syntax for Apache 2.2.
By wrapping them in (for modern servers) and (for older ones), we ensure that the plugin works perfectly everywhere without causing “500 Internal Server Errors” on older hosting platforms that don’t understand the new commands.
The server only executes the block that matches its version, so there is no performance penalty for having both.
Best regards,
Advanced IP Blocker Team
-
This reply was modified 4 months, 2 weeks ago by
IniLerm.
Thanks for the update @inilerm
Wy are u using IfModule !mod_authz_core.c and IfModule mod_authz_core.c ?
Hi @martje65,
As mentioned, we use both mod_authz_core (Apache 2.4+) and !mod_authz_core (Apache 2.2) to ensure the plugin works on any hosting environment without crashing.
Even though Apache 2.4 is the standard today, many legacy hosting providers still run older configurations or hybrid setups. If we only used the modern syntax (Require not ip), sites on older servers would instantly crash with a “500 Internal Server Error” upon activation.
By wrapping the rules in IfModule, we guarantee safety: the server ignores the block it doesn’t understand and executes the one it does. It’s a “safety first” approach.
Best regards,
IniLerm
Okay, thanks for the update.
-
This reply was modified 4 months, 2 weeks ago by
martje65.