1 | # -*- coding: utf-8; mode: tcl; tab-width: 4; truncate-lines: t; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:et:sw=4:ts=4:sts=4 |
---|
2 | # $Id$ |
---|
3 | |
---|
4 | PortSystem 1.0 |
---|
5 | name mod_security2 |
---|
6 | version 2.6.0 |
---|
7 | categories www security |
---|
8 | platforms darwin |
---|
9 | maintainers mathiesen.info:macintosh pixilla |
---|
10 | description Apache 2 intrusion detection and prevention engine for web applications |
---|
11 | long_description ModSecurity is an open source intrusion detection and \ |
---|
12 | prevention engine for web applications. It operates \ |
---|
13 | embedded into the web server, acting as a powerful \ |
---|
14 | umbrella - shielding applications from attacks. |
---|
15 | homepage http://www.modsecurity.org |
---|
16 | master_sites sourceforge:mod-security |
---|
17 | distname modsecurity-apache_${version} |
---|
18 | worksrcdir ${distname} |
---|
19 | |
---|
20 | set apachever apache2 |
---|
21 | |
---|
22 | depends_build port:libxml2 \ |
---|
23 | port:lua \ |
---|
24 | port:pcre \ |
---|
25 | port:curl \ |
---|
26 | port:apr \ |
---|
27 | port:apr-util |
---|
28 | depends_lib port:${apachever} |
---|
29 | |
---|
30 | checksums sha1 280061a6cb49c955d7371b9526193f68a12ae2ac \ |
---|
31 | rmd160 a9d34e17d80007f394087da5bd92c6047f48d343 |
---|
32 | |
---|
33 | configure.args --with-apxs=${prefix}/${apachever}/bin/apxs \ |
---|
34 | --with-pcre=${prefix}/bin/pcre-config \ |
---|
35 | --with-apr=${prefix}/bin/apr-1-config \ |
---|
36 | --with-apu=${prefix}/bin/apu-1-config \ |
---|
37 | --with-curl=${prefix}/bin/curl-config \ |
---|
38 | --with-libxml=${prefix} \ |
---|
39 | --with-lua=${prefix} |
---|
40 | |
---|
41 | destroot.violate_mtree yes |
---|
42 | |
---|
43 | destroot { |
---|
44 | xinstall -d -m 755 ${destroot}${prefix}/${apachever}/modules |
---|
45 | xinstall -m 644 -W ${worksrcpath}/apache2/.libs mod_security2.so \ |
---|
46 | ${destroot}${prefix}/${apachever}/modules |
---|
47 | xinstall -m 755 -W ${worksrcpath}/mlogc mlogc mlogc-batch-load.pl \ |
---|
48 | ${destroot}${prefix}/bin |
---|
49 | xinstall -m 755 -W ${worksrcpath}/tools rules-updater.pl \ |
---|
50 | ${destroot}${prefix}/bin |
---|
51 | xinstall -m 755 -W ${worksrcpath}/mlogc mlogc-default.conf \ |
---|
52 | ${destroot}${prefix}/etc |
---|
53 | xinstall -d -m 755 ${destroot}${prefix}/share/doc/${name} |
---|
54 | xinstall -m 644 -W ${worksrcpath} CHANGES LICENSE NOTICE README.TXT \ |
---|
55 | ${destroot}${prefix}/share/doc/${name} |
---|
56 | xinstall -d -m 755 ${destroot}${prefix}/${apachever}/conf/extra |
---|
57 | set fp [open ${destroot}${prefix}/${apachever}/conf/extra/httpd-security.conf w] |
---|
58 | puts $fp \ |
---|
59 | "LoadFile ${prefix}/lib/libxml2.dylib |
---|
60 | LoadFile ${prefix}/lib/liblua.dylib |
---|
61 | LoadModule security2_module modules/mod_security2.so" |
---|
62 | close $fp |
---|
63 | } |
---|
64 | |
---|
65 | notes " |
---|
66 | |
---|
67 | To enable ${name} in apache2, add the following lines to |
---|
68 | ${prefix}/apache2/conf/httpd.conf |
---|
69 | # mod_security2 |
---|
70 | Include conf/extra/httpd-security.conf |
---|
71 | |
---|
72 | " |
---|