Issue with mod_security3

SoftwareInforJam softwareinforjam at gmail.com
Wed Jan 23 00:18:12 UTC 2019


Well I am making some progress I guess. Now modsecurity is installed and not orphaned. My challenge now is that I have been reading several documents and all of them say I need to add the following to nginx.conf

load_module modules/ngx_http_modsecurity.so;

My challenge now is I can’t seem to find this module anywhere. I am not sure what to do now. Isn’t this module needed for this to work?

root at proxy:/usr/local/etc/nginx # find / -name "ngx_http_modsecurity*"
/usr/ports/www/nginx/work/nginx-1.14.2/objs/addon/src/ngx_http_modsecurity_body_filter.o
/usr/ports/www/nginx/work/nginx-1.14.2/objs/addon/src/ngx_http_modsecurity_rewrite.o
/usr/ports/www/nginx/work/nginx-1.14.2/objs/addon/src/ngx_http_modsecurity_log.o
/usr/ports/www/nginx/work/nginx-1.14.2/objs/addon/src/ngx_http_modsecurity_pre_access.o
/usr/ports/www/nginx/work/nginx-1.14.2/objs/addon/src/ngx_http_modsecurity_header_filter.o
/usr/ports/www/nginx/work/nginx-1.14.2/objs/addon/src/ngx_http_modsecurity_module.o
/usr/ports/www/nginx/work/ModSecurity-nginx-71ede63/src/ngx_http_modsecurity_body_filter.c
/usr/ports/www/nginx/work/ModSecurity-nginx-71ede63/src/ngx_http_modsecurity_common.h
/usr/ports/www/nginx/work/ModSecurity-nginx-71ede63/src/ngx_http_modsecurity_header_filter.c
/usr/ports/www/nginx/work/ModSecurity-nginx-71ede63/src/ngx_http_modsecurity_log.c
/usr/ports/www/nginx/work/ModSecurity-nginx-71ede63/src/ngx_http_modsecurity_module.c
/usr/ports/www/nginx/work/ModSecurity-nginx-71ede63/src/ngx_http_modsecurity_pre_access.c
/usr/ports/www/nginx/work/ModSecurity-nginx-71ede63/src/ngx_http_modsecurity_rewrite.c



Sent from Mail for Windows 10

From: SoftwareInforJam
Sent: Tuesday, January 22, 2019 2:14 PM
To: Gregory Byshenk; freebsd-stable at freebsd.org
Subject: RE: Issue with mod_security3

Ah. Got that. Thank you. I had just assumed that the name would be the same as the name of the port. I am going to try again. Thanks again.


Sent from Mail for Windows 10

From: Gregory Byshenk
Sent: Tuesday, January 22, 2019 1:54 PM
To: freebsd-stable at freebsd.org; SoftwareInforJam
Subject: Re: Issue with mod_security3

On Tue, Jan 22, 2019 at 11:29:01AM -0500, SoftwareInforJam wrote:

> I am have a queer problem with the port mod_security3. I
> actually want to set it up to work with NGINX. The port
> /usr/ports/www/mod_security3 exists but when I do a 
> # pkg install mod_security3 
> I get 
> ???pkg: No packages available to install matching 'mod_security3'
> have been found in the repositories???
> 
> When I do a pkg search ???mod_security*??? only
> ap24-mod_security-2.9.2_3 Intrusion detection and prevention
> engine. So only version 2.9 shows up. Not sure why this is
> happening. Can anyone shed some light on this please?

I'm no expert on mod_security, but my guess, based on reading
https://www.linuxjournal.com/content/modsecurity-and-nginx,
is that previous (to v3) versions of mod_security worked
_only_ with apache.

And it seems likely that the port has not yet been updated to
the newest v3.

Also based on the article, it seems that getting even mod_security
v3 to work with nginx is slightly complicated, as building it
depends on the specific version of nginx that is installed.

-- 
gregory byshenk  -  gbyshenk at byshenk.net  -  Leiden, NL




More information about the freebsd-stable mailing list