View | Details | Raw Unified | Return to bug 131451
Collapse All | Expand All

(-)Makefile (-7 / +4 lines)
Lines 6-17 Link Here
6
#
6
#
7
7
8
PORTNAME=	suphp
8
PORTNAME=	suphp
9
PORTVERSION=	0.6.3
9
PORTVERSION=	0.7.0
10
CATEGORIES=	www
10
CATEGORIES=	www
11
MASTER_SITES=	http://www.suphp.org/download/ \
11
MASTER_SITES=	http://www.suphp.org/download/ \
12
		${MASTER_SITE_LOCAL:S|%SUBDIR%|koitsu|}
12
		${MASTER_SITE_LOCAL:S|%SUBDIR%|koitsu|}
13
13
14
MAINTAINER=	ports@FreeBSD.org
14
MAINTAINER=	yzlin@cs.nctu.edu.tw
15
COMMENT=	Securely execute PHP scripts under Apache
15
COMMENT=	Securely execute PHP scripts under Apache
16
16
17
GNU_CONFIGURE=	yes
17
GNU_CONFIGURE=	yes
Lines 26-32 Link Here
26
26
27
CONFIGURE_ARGS=	--with-apxs=${APXS}
27
CONFIGURE_ARGS=	--with-apxs=${APXS}
28
28
29
30
# WITH_SETID_MODE should be a value of "owner", "force", or "paranoid".
29
# WITH_SETID_MODE should be a value of "owner", "force", or "paranoid".
31
# It's important that you understand the differences between each mode.
30
# It's important that you understand the differences between each mode.
32
# See /usr/local/share/doc/suphp/INSTALL for details.
31
# See /usr/local/share/doc/suphp/INSTALL for details.
Lines 34-40 Link Here
34
WITH_SETID_MODE?=	owner
33
WITH_SETID_MODE?=	owner
35
CONFIGURE_ARGS+=	--with-setid-mode=${WITH_SETID_MODE}
34
CONFIGURE_ARGS+=	--with-setid-mode=${WITH_SETID_MODE}
36
35
37
38
.include <bsd.port.pre.mk>
36
.include <bsd.port.pre.mk>
39
37
40
# Apache 2.0 (www/apache2) has apr-config in LOCALBASE/lib/apache2, while
38
# Apache 2.0 (www/apache2) has apr-config in LOCALBASE/lib/apache2, while
Lines 48-54 Link Here
48
46
49
post-patch:
47
post-patch:
50
	@${REINPLACE_CMD} -e 's|2.61|2.62|g' ${WRKSRC}/aclocal.m4
48
	@${REINPLACE_CMD} -e 's|2.61|2.62|g' ${WRKSRC}/aclocal.m4
51
	@${REINPLACE_CMD} -e 's|1.10|1.10.1|g' ${WRKSRC}/aclocal.m4
52
	@${CHMOD} 755 ${WRKSRC}/config/install-sh
49
	@${CHMOD} 755 ${WRKSRC}/config/install-sh
53
50
54
post-install:
51
post-install:
Lines 56-68 Link Here
56
	@${MKDIR} ${DOCSDIR}
53
	@${MKDIR} ${DOCSDIR}
57
	@${MKDIR} ${DOCSDIR}/apache
54
	@${MKDIR} ${DOCSDIR}/apache
58
.for f in ${MYPORTDOCS}
55
.for f in ${MYPORTDOCS}
59
	@${CP} -Rfp ${WRKSRC}/doc/${f} ${DOCSDIR}/${f}
56
	@${INSTALL_DATA} ${WRKSRC}/doc/${f} ${DOCSDIR}/${f}
60
.endfor
57
.endfor
61
.endif
58
.endif
62
.if !defined(WITH_DEBUG)
59
.if !defined(WITH_DEBUG)
63
	@${STRIP_CMD} ${PREFIX}/sbin/suphp
60
	@${STRIP_CMD} ${PREFIX}/sbin/suphp
64
.endif
61
.endif
65
	@${CP} -fp ${WRKSRC}/doc/suphp.conf-example ${PREFIX}/etc/suphp.conf-example
62
	@${INSTALL_DATA} ${WRKSRC}/doc/suphp.conf-example ${PREFIX}/etc/suphp.conf-example
66
	@${CAT} ${PKGMESSAGE}
63
	@${CAT} ${PKGMESSAGE}
67
64
68
.include <bsd.port.post.mk>
65
.include <bsd.port.post.mk>
(-)distinfo (-3 / +3 lines)
Lines 1-3 Link Here
1
MD5 (suphp-0.6.3.tar.gz) = 756e8893857fefed087a89959a87645a
1
MD5 (suphp-0.7.0.tar.gz) = dac578fc8bda630cc37ed6e47d4ff213
2
SHA256 (suphp-0.6.3.tar.gz) = 0c2e64aa22d47c07e899d92c9997556dfbc242192d2f4e9d3cdce517c46d7ecc
2
SHA256 (suphp-0.7.0.tar.gz) = 0baadee9a1b6f2c2c8c84e3d11c531b89d6791f2d821a1c9c9c7dac7c5a5da8b
3
SIZE (suphp-0.6.3.tar.gz) = 377176
3
SIZE (suphp-0.7.0.tar.gz) = 389689
(-)pkg-message (-7 / +6 lines)
Lines 1-7 Link Here
1
----------------------------------------------------------------
1
----------------------------------------------------------------
2
For help on using this module, please see the suPHP homepage:
2
For help on using this module, please see the suPHP homepage:
3
3
4
    	http://www.suphp.org/
4
        http://www.suphp.org/
5
5
6
Using suPHP can break some PHP-scripts, because of Apache's CGI 
6
Using suPHP can break some PHP-scripts, because of Apache's CGI 
7
interface.
7
interface.
Lines 9-15 Link Here
9
9
10
-----------------------------------------------------------------
10
-----------------------------------------------------------------
11
For those migrating from suPHP 0.5.x, be aware there are many
11
For those migrating from suPHP 0.5.x, be aware there are many
12
changes in 0.6.x that can cause your current Apache environment
12
changes since 0.6.x that can cause your current Apache environment
13
to stop working or behave oddly.  Here are two migration tips:
13
to stop working or behave oddly.  Here are two migration tips:
14
14
15
suPHP now uses a configuration file for runtime configuration.
15
suPHP now uses a configuration file for runtime configuration.
Lines 20-26 Link Here
20
...but *has not* been created for you.  A sample configuration
20
...but *has not* been created for you.  A sample configuration
21
file has been installed here:
21
file has been installed here:
22
22
23
	/usr/local/etc/suphp.conf-example
23
        /usr/local/etc/suphp.conf-example
24
24
25
This means that many of the make.conf(5) knobs for the
25
This means that many of the make.conf(5) knobs for the
26
www/suphp port are no longer used, and are modifiable in
26
www/suphp port are no longer used, and are modifiable in
Lines 31-47 Link Here
31
for determining what content get handled by suPHP.  In 0.5.x,
31
for determining what content get handled by suPHP.  In 0.5.x,
32
you used the following Apache directives:
32
you used the following Apache directives:
33
33
34
	suPHP_Engine on
34
        suPHP_Engine on
35
        AddType application/x-httpd-php .php
35
        AddType application/x-httpd-php .php
36
        AddHandler x-httpd-php .php
36
        AddHandler x-httpd-php .php
37
37
38
In suPHP 0.6.x, you should use the following:
38
Since suPHP 0.6.x, you should use the following:
39
39
40
	suPHP_Engine on
40
        suPHP_Engine on
41
        AddType application/x-httpd-php .php
41
        AddType application/x-httpd-php .php
42
        suPHP_AddHandler application/x-httpd-php
42
        suPHP_AddHandler application/x-httpd-php
43
43
44
Otherwise, Apache will begin serving PHP files as downloadable
44
Otherwise, Apache will begin serving PHP files as downloadable
45
content, rather than parse them with the PHP interpreter.
45
content, rather than parse them with the PHP interpreter.
46
-----------------------------------------------------------------
46
-----------------------------------------------------------------
47
(-)files/patch-acinclude.m4 (-11 lines)
Removed Link Here
1
--- acinclude.m4.orig	2006-10-18 13:42:07.000000000 -0700
2
+++ acinclude.m4	2007-11-11 02:15:56.000000000 -0800
3
@@ -40,7 +40,7 @@
4
 dnl value of apr_config to fetch any necessary build/link information.
5
 dnl
6
 
7
-AC_DEFUN(APR_FIND_APR, [
8
+AC_DEFUN([APR_FIND_APR], [
9
   apr_found="no"
10
 
11
   if test "$ac_cv_emxos2" = "yes"; then
(-)files/patch-doc::suphp.conf-example (-7 / +11 lines)
Lines 1-6 Link Here
1
--- doc/suphp.conf-example.orig	2005-11-26 11:29:02.000000000 -0800
1
--- doc/suphp.conf-example.orig
2
+++ doc/suphp.conf-example	2007-12-12 09:21:02.000000000 -0800
2
+++ doc/suphp.conf-example
3
@@ -6,7 +6,7 @@
3
@@ -6,10 +6,10 @@
4
 loglevel=info
4
 loglevel=info
5
 
5
 
6
 ;User Apache is running as
6
 ;User Apache is running as
Lines 8-14 Link Here
8
+webserver_user=www
8
+webserver_user=www
9
 
9
 
10
 ;Path all scripts have to be in
10
 ;Path all scripts have to be in
11
 docroot=/
11
-docroot=/var/www:${HOME}/public_html
12
+docroot=/usr/local/www/*:${HOME}/public_html
13
 
14
 ;Path to chroot() to before executing script
15
 ;chroot=/mychroot
12
@@ -33,15 +33,15 @@
16
@@ -33,15 +33,15 @@
13
 umask=0077
17
 umask=0077
14
 
18
 
Lines 23-30 Link Here
23
 
27
 
24
 [handlers]
28
 [handlers]
25
 ;Handler for php-scripts
29
 ;Handler for php-scripts
26
-x-httpd-php=php:/usr/bin/php
30
-x-httpd-php="php:/usr/bin/php"
27
+application/x-httpd-php=php:/usr/local/bin/php-cgi
31
+application/x-httpd-php="php:/usr/local/bin/php-cgi"
28
 
32
 
29
 ;Handler for CGI-scripts
33
 ;Handler for CGI-scripts
30
 x-suphp-cgi=execute:!self
34
 x-suphp-cgi="execute:!self"
(-)files/patch-src::apache2::mod_suphp.c (-13 lines)
Removed Link Here
1
--- src/apache2/mod_suphp.c.orig	2006-11-05 16:57:12.000000000 -0800
2
+++ src/apache2/mod_suphp.c	2007-11-11 03:15:50.000000000 -0800
3
@@ -321,8 +321,8 @@
4
     AP_INIT_TAKE2("suPHP_UserGroup", suphp_handle_cmd_user_group, NULL, RSRC_CONF | ACCESS_CONF,
5
                   "User and group scripts shall be run as"),
6
 #endif
7
-    AP_INIT_ITERATE("suPHP_AddHandler", suphp_handle_cmd_add_handler, NULL, ACCESS_CONF, "Tells mod_suphp to handle these MIME-types"),
8
-    AP_INIT_ITERATE("suPHP_RemoveHandler", suphp_handle_cmd_remove_handler, NULL, ACCESS_CONF, "Tells mod_suphp not to handle these MIME-types"),
9
+    AP_INIT_ITERATE("suPHP_AddHandler", suphp_handle_cmd_add_handler, NULL, RSRC_CONF | ACCESS_CONF, "Tells mod_suphp to handle these MIME-types"),
10
+    AP_INIT_ITERATE("suPHP_RemoveHandler", suphp_handle_cmd_remove_handler, NULL, RSRC_CONF | ACCESS_CONF, "Tells mod_suphp not to handle these MIME-types"),
11
     {NULL}
12
 };
13
 

Return to bug 131451