summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDiego Elio Pettenò <flameeyes@gentoo.org>2011-08-31 15:42:19 +0000
committerDiego Elio Pettenò <flameeyes@gentoo.org>2011-08-31 15:42:19 +0000
commit549d8bb9a1701ee8ceb8cbba37826996b90b6d2c (patch)
tree6acada3055d5ff4147944af435e9696945fb9bf7 /www-apache/mod_auth_token
parent[sys-cluster/slurm] Version bump (diff)
downloadgentoo-2-549d8bb9a1701ee8ceb8cbba37826996b90b6d2c.tar.gz
gentoo-2-549d8bb9a1701ee8ceb8cbba37826996b90b6d2c.tar.bz2
gentoo-2-549d8bb9a1701ee8ceb8cbba37826996b90b6d2c.zip
Initial import of mod_auth_token; ebuild by Pavel Stratil (proxied maintainer), fix for ap_pstrcat function call by me.
(Portage version: 2.2.0_alpha51/cvs/Linux x86_64)
Diffstat (limited to 'www-apache/mod_auth_token')
-rw-r--r--www-apache/mod_auth_token/ChangeLog12
-rw-r--r--www-apache/mod_auth_token/files/75_mod_auth_token.conf26
-rw-r--r--www-apache/mod_auth_token/files/mod_auth_token-1.0.6_beta-ap_pstrcat.patch13
-rw-r--r--www-apache/mod_auth_token/metadata.xml12
-rw-r--r--www-apache/mod_auth_token/mod_auth_token-1.0.6_beta.ebuild31
5 files changed, 94 insertions, 0 deletions
diff --git a/www-apache/mod_auth_token/ChangeLog b/www-apache/mod_auth_token/ChangeLog
new file mode 100644
index 000000000000..c90f761e212b
--- /dev/null
+++ b/www-apache/mod_auth_token/ChangeLog
@@ -0,0 +1,12 @@
+# ChangeLog for www-apache/mod_auth_token
+# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/www-apache/mod_auth_token/ChangeLog,v 1.1 2011/08/31 15:42:19 flameeyes Exp $
+
+*mod_auth_token-1.0.6_beta (31 Aug 2011)
+
+ 31 Aug 2011; Diego E. Pettenò <flameeyes@gentoo.org>
+ +files/75_mod_auth_token.conf, +mod_auth_token-1.0.6_beta.ebuild,
+ +files/mod_auth_token-1.0.6_beta-ap_pstrcat.patch, +metadata.xml:
+ Initial import of mod_auth_token; ebuild by Pavel Stratil (proxied
+ maintainer), fix for ap_pstrcat function call by me.
+
diff --git a/www-apache/mod_auth_token/files/75_mod_auth_token.conf b/www-apache/mod_auth_token/files/75_mod_auth_token.conf
new file mode 100644
index 000000000000..3962fc66a708
--- /dev/null
+++ b/www-apache/mod_auth_token/files/75_mod_auth_token.conf
@@ -0,0 +1,26 @@
+<IfDefine AUTH_TOKEN>
+
+ LoadModule auth_token_module modules/mod_auth_token.so
+
+ # The token is an hex-encoded MD5 hash of the secret password, relative file
+ # path and the timestamp. It is encoded onto the URI as:
+ # <uri-prefix><token>/<timestamp-in-hex><rel-path
+ # where the token is generated as
+ # md5("secret" + "/path/to/file.txt" + dechex(time_now()))
+ # To add the IP of client into the in the md5 hash, enable AuthTokenLimitByIp.
+
+ #<Location /protected/>
+ #AuthTokenSecret "secret"
+ #AuthTokenPrefix /protected/
+ #AuthTokenTimeout 60
+ #AuthTokenLimitByIp off
+ #</Location>
+
+ # Example:
+ # /protected/dee0ed6174a894113d5e8f6c98f0e92b/43eaf9c5/path/to/file.txt
+ # maps to
+ # /protected/path/to/file.txt
+
+</IfDefine>
+
+# vim: ts=4 filetype=apache \ No newline at end of file
diff --git a/www-apache/mod_auth_token/files/mod_auth_token-1.0.6_beta-ap_pstrcat.patch b/www-apache/mod_auth_token/files/mod_auth_token-1.0.6_beta-ap_pstrcat.patch
new file mode 100644
index 000000000000..54a00e072fa4
--- /dev/null
+++ b/www-apache/mod_auth_token/files/mod_auth_token-1.0.6_beta-ap_pstrcat.patch
@@ -0,0 +1,13 @@
+Index: mod_auth_token/mod_auth_token.c
+===================================================================
+--- mod_auth_token.orig/mod_auth_token.c
++++ mod_auth_token/mod_auth_token.c
+@@ -64,7 +64,7 @@ static const char *auth_token_set_prefix
+ auth_token_config_rec *conf = (auth_token_config_rec*)config;
+
+ if (arg[len - 1] != '/') {
+- ap_set_string_slot(cmd, config, apr_pstrcat(cmd->pool, arg, '/'));
++ ap_set_string_slot(cmd, config, apr_pstrcat(cmd->pool, arg, "/", NULL));
+ conf->prefix_len = len + 1;
+ }
+ else {
diff --git a/www-apache/mod_auth_token/metadata.xml b/www-apache/mod_auth_token/metadata.xml
new file mode 100644
index 000000000000..e12def24c0a2
--- /dev/null
+++ b/www-apache/mod_auth_token/metadata.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>no-herd</herd>
+ <maintainer>
+ <email>flameeyes@gentoo.org</email>
+ </maintainer>
+ <maintainer>
+ <email>pavel.stratil-jun@fenix.cz</email>
+ <description>Proxied co-maintainer, CC on all bugs</description>
+ </maintainer>
+</pkgmetadata>
diff --git a/www-apache/mod_auth_token/mod_auth_token-1.0.6_beta.ebuild b/www-apache/mod_auth_token/mod_auth_token-1.0.6_beta.ebuild
new file mode 100644
index 000000000000..6b98598d8d5f
--- /dev/null
+++ b/www-apache/mod_auth_token/mod_auth_token-1.0.6_beta.ebuild
@@ -0,0 +1,31 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $
+
+EAPI=3
+
+inherit apache-module
+
+MY_P="${PN}-${PV/_/-}"
+DESCRIPTION="Token based URI access module for Apache2."
+HOMEPAGE="http://code.google.com/p/mod-auth-token/"
+SRC_URI="http://mod-auth-token.googlecode.com/files/${MY_P}.tar.gz"
+
+KEYWORDS="~amd64"
+LICENSE="Apache-2.0"
+SLOT="0"
+IUSE=""
+
+DEPEND=""
+RDEPEND=""
+
+APACHE2_MOD_CONF="75_${PN}"
+APACHE2_MOD_DEFINE="AUTH_TOKEN"
+
+need_apache2_2
+
+S="${WORKDIR}/${PN}"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-ap_pstrcat.patch
+}