aboutsummaryrefslogtreecommitdiff
path: root/www/mod_remoteip
diff options
context:
space:
mode:
authorPhilip M. Gollucci <pgollucci@FreeBSD.org>2010-05-12 22:49:44 +0000
committerPhilip M. Gollucci <pgollucci@FreeBSD.org>2010-05-12 22:49:44 +0000
commit34b4b07b1afef064b5f93dd364b1852d57e2748d (patch)
tree3a0875776971f3f820095c3db5b40c51306b9e85 /www/mod_remoteip
parentb9e936ae8f90f2584d6b3cd5da3be277648cc7ae (diff)
downloadports-34b4b07b1afef064b5f93dd364b1852d57e2748d.tar.gz
ports-34b4b07b1afef064b5f93dd364b1852d57e2748d.zip
Notes
Diffstat (limited to 'www/mod_remoteip')
-rw-r--r--www/mod_remoteip/Makefile23
-rw-r--r--www/mod_remoteip/distinfo3
-rw-r--r--www/mod_remoteip/files/patch-modules__metadata__mod_remoteip.c47
-rw-r--r--www/mod_remoteip/pkg-descr5
4 files changed, 78 insertions, 0 deletions
diff --git a/www/mod_remoteip/Makefile b/www/mod_remoteip/Makefile
new file mode 100644
index 000000000000..c1911ffc48a9
--- /dev/null
+++ b/www/mod_remoteip/Makefile
@@ -0,0 +1,23 @@
+# New ports collection makefile for: mod_remoteip
+# Date created: 2010-05-11
+# Whom: Jim Riggs <ports@christianserving.org>
+#
+# $FreeBSD$
+#
+
+PORTNAME= mod_remoteip
+PORTVERSION= 2.3.5.a
+CATEGORIES= www
+MASTER_SITES= ${MASTER_SITE_APACHE_HTTPD}
+DISTNAME= httpd-2.3.5-alpha
+
+MAINTAINER= ports@christianserving.org
+COMMENT= Replaces the client IP address/hostname with that given by a proxy
+
+USE_APACHE= 2.2+
+AP_FAST_BUILD= YES
+AP_GENPLIST= YES
+
+SRC_FILE= modules/metadata/${PORTNAME}.c
+
+.include <bsd.port.mk>
diff --git a/www/mod_remoteip/distinfo b/www/mod_remoteip/distinfo
new file mode 100644
index 000000000000..d17181f664f7
--- /dev/null
+++ b/www/mod_remoteip/distinfo
@@ -0,0 +1,3 @@
+MD5 (httpd-2.3.5-alpha.tar.gz) = 625c9c0bf4a171cbc176a0ddcf00aea2
+SHA256 (httpd-2.3.5-alpha.tar.gz) = f1c1b322342653445db4acf049637997f9a37f478babd0277587fa58b27ae9b8
+SIZE (httpd-2.3.5-alpha.tar.gz) = 5038492
diff --git a/www/mod_remoteip/files/patch-modules__metadata__mod_remoteip.c b/www/mod_remoteip/files/patch-modules__metadata__mod_remoteip.c
new file mode 100644
index 000000000000..87a64cf5c0f5
--- /dev/null
+++ b/www/mod_remoteip/files/patch-modules__metadata__mod_remoteip.c
@@ -0,0 +1,47 @@
+--- modules/metadata/mod_remoteip.c.orig 2010-05-11 21:33:43.631571954 -0500
++++ modules/metadata/mod_remoteip.c 2010-05-11 21:34:15.374903181 -0500
+@@ -127,7 +127,7 @@
+ return (*ipstr == '\0');
+ }
+
+-static const char *proxies_set(cmd_parms *cmd, void *internal,
++static const char *proxies_set(cmd_parms *cmd, void *cfg,
+ const char *arg)
+ {
+ remoteip_config_t *config = ap_get_module_config(cmd->server->module_config,
+@@ -142,7 +142,7 @@
+ if (!config->proxymatch_ip)
+ config->proxymatch_ip = apr_array_make(cmd->pool, 1, sizeof(*match));
+ match = (remoteip_proxymatch_t *) apr_array_push(config->proxymatch_ip);
+- match->internal = internal;
++ match->internal = cmd->info;
+
+ if (looks_like_ip(ip)) {
+ /* Note s may be null, that's fine (explicit host) */
+@@ -168,7 +168,7 @@
+ break;
+ match = (remoteip_proxymatch_t *)
+ apr_array_push(config->proxymatch_ip);
+- match->internal = internal;
++ match->internal = cmd->info;
+ }
+ }
+
+@@ -182,7 +182,7 @@
+ return NULL;
+ }
+
+-static const char *proxylist_read(cmd_parms *cmd, void *internal,
++static const char *proxylist_read(cmd_parms *cmd, void *cfg,
+ const char *filename)
+ {
+ char lbuf[MAX_STRING_LEN];
+@@ -205,7 +205,7 @@
+ while (*(arg = ap_getword_conf(cmd->temp_pool, &args)) != '\0') {
+ if (*arg == '#' || *arg == '\0')
+ break;
+- errmsg = proxies_set(cmd, internal, arg);
++ errmsg = proxies_set(cmd, cfg, arg);
+ if (errmsg) {
+ errmsg = apr_psprintf(cmd->pool, "%s at line %d of %s",
+ errmsg, cfp->line_number, filename);
diff --git a/www/mod_remoteip/pkg-descr b/www/mod_remoteip/pkg-descr
new file mode 100644
index 000000000000..fdb7f65bff79
--- /dev/null
+++ b/www/mod_remoteip/pkg-descr
@@ -0,0 +1,5 @@
+Backport of the Apache 2.3 module that replaces the apparent client
+remote IP address and hostname for the request with the IP address
+list presented by a proxy or load balancer via the request headers.
+
+WWW: http://httpd.apache.org/docs/2.3/mod/mod_remoteip.html