public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: dev-php/snuffleupagus/
@ 2022-04-13 17:11 Brian Evans
  0 siblings, 0 replies; 5+ messages in thread
From: Brian Evans @ 2022-04-13 17:11 UTC (permalink / raw
  To: gentoo-commits

commit:     7a6b3b7b1760583be2d969507e7f6c3af199f7cf
Author:     Brian Evans <grknight <AT> gentoo <DOT> org>
AuthorDate: Wed Apr 13 17:10:00 2022 +0000
Commit:     Brian Evans <grknight <AT> gentoo <DOT> org>
CommitDate: Wed Apr 13 17:10:00 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7a6b3b7b

dev-php/snuffleupagus: New package

A security add on script in the spirit of suhosin with modern flexibility.

Signed-off-by: Brian Evans <grknight <AT> gentoo.org>

 dev-php/snuffleupagus/Manifest                   |  1 +
 dev-php/snuffleupagus/metadata.xml               | 11 +++++
 dev-php/snuffleupagus/snuffleupagus-0.7.1.ebuild | 59 ++++++++++++++++++++++++
 3 files changed, 71 insertions(+)

diff --git a/dev-php/snuffleupagus/Manifest b/dev-php/snuffleupagus/Manifest
new file mode 100644
index 000000000000..893d570b5b49
--- /dev/null
+++ b/dev-php/snuffleupagus/Manifest
@@ -0,0 +1 @@
+DIST snuffleupagus-0.7.1.tar.gz 11962220 BLAKE2B 8504721ca08e727a5a6fa58c216a5dac7be3fe6e5a98cffcb17e44a2235628c26f02afd2159e9b1fbe8e40e26bc7c4e34a4ff027ee27b8ec29cf89865dbb8514 SHA512 21510e214f94dd50a4aa05226188c9433a6a261c0bd3d58973ed4536754b3e12356e3f625480c370b66c570482694c25d336a771fbbbeb27e1d524b1f82c7869

diff --git a/dev-php/snuffleupagus/metadata.xml b/dev-php/snuffleupagus/metadata.xml
new file mode 100644
index 000000000000..6cb8e5e502b5
--- /dev/null
+++ b/dev-php/snuffleupagus/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+  <maintainer type="project">
+    <email>php-bugs@gentoo.org</email>
+    <name>PHP</name>
+  </maintainer>
+  <upstream>
+    <remote-id type="github">jvoisin/snuffleupagus</remote-id>
+  </upstream>
+</pkgmetadata>

diff --git a/dev-php/snuffleupagus/snuffleupagus-0.7.1.ebuild b/dev-php/snuffleupagus/snuffleupagus-0.7.1.ebuild
new file mode 100644
index 000000000000..13decdb51061
--- /dev/null
+++ b/dev-php/snuffleupagus/snuffleupagus-0.7.1.ebuild
@@ -0,0 +1,59 @@
+# Copyright 2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+PHP_EXT_NAME="${PN}"
+PHP_EXT_INI="yes"
+PHP_EXT_ZENDEXT="no"
+PHP_EXT_ECONF_ARGS=( --enable-${PN} )
+PHP_EXT_S="${S}/src"
+
+USE_PHP="php7-4 php8-0"
+
+inherit php-ext-source-r3
+
+KEYWORDS="~amd64"
+
+DESCRIPTION="A PHP module to drastically raise the cost of attacks against websites"
+HOMEPAGE="https://snuffleupagus.readthedocs.io/index.html"
+SRC_URI="https://github.com/jvoisin/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="LGPL-3 PHP-3.01"
+SLOT="0"
+
+src_prepare() {
+	# fix file locations tests look for
+	ln -s "${P}/config" "${WORKDIR}/config" || die
+	# Fix path dependent tests
+	sed -i -e 's~src/tests/~~' \
+		src/tests/session_encryption/crypt_session_read_uncrypt.phpt || die
+	sed -i -e 's~%a/src~%a~' \
+		src/tests/disable_function/disabled_functions_runtime.phpt || die
+	php-ext-source-r3_src_prepare
+}
+
+src_install() {
+	einstalldocs
+	local slot x cfgdir
+	php-ext-source-r3_src_install
+	# Add the rules file which vary by install version
+	for slot in $(php_get_slots); do
+		php_init_slot_env "${slot}"
+		for x in ${PHP_EXT_SAPIS} ; do
+			cfgdir="/etc/php/${x}-${slot}"
+			php-ext-source-r3_addtoinifile "${cfgdir}/ext/${PHP_INI_NAME}.ini" \
+				 "sp.configuration_file" "${cfgdir}/${PN}.rules"
+			insinto "${cfgdir}"
+			case ${PHP_CURRENTSLOT:0:1} in
+				8) newins "${S}/config/default_php8.rules" "${PN}.rules" ;;
+				*) newins "${S}/config/default.rules" "${PN}.rules" ;;
+			esac
+		done
+	done
+}
+
+pkg_postinst() {
+	elog "This extension is configured with recommended rules enabled by default."
+	elog "Feel free to customize as necessary.  Please test outside of production first."
+	elog "Failure to test may cause unexpected results to loosely coded sites."
+}


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-php/snuffleupagus/
@ 2022-04-14 15:10 Brian Evans
  0 siblings, 0 replies; 5+ messages in thread
From: Brian Evans @ 2022-04-14 15:10 UTC (permalink / raw
  To: gentoo-commits

commit:     4cc0bda33f39d9aaee5ff1817c1280701098c84c
Author:     Brian Evans <grknight <AT> gentoo <DOT> org>
AuthorDate: Thu Apr 14 15:09:18 2022 +0000
Commit:     Brian Evans <grknight <AT> gentoo <DOT> org>
CommitDate: Thu Apr 14 15:09:18 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4cc0bda3

dev-php/snuffleupagus: Revbump to fix QA warning and wrong locations

Signed-off-by: Brian Evans <grknight <AT> gentoo.org>

 ...-0.7.1.ebuild => snuffleupagus-0.7.1-r1.ebuild} | 29 ++++++++++++++++------
 1 file changed, 22 insertions(+), 7 deletions(-)

diff --git a/dev-php/snuffleupagus/snuffleupagus-0.7.1.ebuild b/dev-php/snuffleupagus/snuffleupagus-0.7.1-r1.ebuild
similarity index 67%
rename from dev-php/snuffleupagus/snuffleupagus-0.7.1.ebuild
rename to dev-php/snuffleupagus/snuffleupagus-0.7.1-r1.ebuild
index 13decdb51061..d18383730d41 100644
--- a/dev-php/snuffleupagus/snuffleupagus-0.7.1.ebuild
+++ b/dev-php/snuffleupagus/snuffleupagus-0.7.1-r1.ebuild
@@ -33,6 +33,19 @@ src_prepare() {
 }
 
 src_install() {
+	addtoinifile() {
+		local inifile="${WORKDIR}/${1}"
+		local inidir="${inifile%/*}"
+
+		mkdir -p "${inidir}" || die "failed to create INI directory ${inidir}"
+
+		local my_added="${2}=${3}"
+		echo "${my_added}" >> "${inifile}" || die "failed to append to ${inifile}"
+		einfo "Added '${my_added}' to /${1}"
+
+		insinto "/${1%/*}"
+		doins "${inifile}"
+	}
 	einstalldocs
 	local slot x cfgdir
 	php-ext-source-r3_src_install
@@ -41,13 +54,15 @@ src_install() {
 		php_init_slot_env "${slot}"
 		for x in ${PHP_EXT_SAPIS} ; do
 			cfgdir="/etc/php/${x}-${slot}"
-			php-ext-source-r3_addtoinifile "${cfgdir}/ext/${PHP_INI_NAME}.ini" \
-				 "sp.configuration_file" "${cfgdir}/${PN}.rules"
-			insinto "${cfgdir}"
-			case ${PHP_CURRENTSLOT:0:1} in
-				8) newins "${S}/config/default_php8.rules" "${PN}.rules" ;;
-				*) newins "${S}/config/default.rules" "${PN}.rules" ;;
-			esac
+			if [[ -f "${ED}${cfgdir}/ext/${PHP_INI_NAME}.ini" ]]; then
+				addtoinifile "${cfgdir#/}/ext/${PHP_INI_NAME}.ini" \
+					"sp.configuration_file" "${cfgdir}/${PN}.rules"
+				insinto "${cfgdir}"
+				case ${PHP_CURRENTSLOT:0:1} in
+					8) newins "${S}/config/default_php8.rules" "${PN}.rules" ;;
+					*) newins "${S}/config/default.rules" "${PN}.rules" ;;
+				esac
+			fi
 		done
 	done
 }


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-php/snuffleupagus/
@ 2022-11-05 22:43 Brian Evans
  0 siblings, 0 replies; 5+ messages in thread
From: Brian Evans @ 2022-11-05 22:43 UTC (permalink / raw
  To: gentoo-commits

commit:     9d9355aa3fee7424f1c2a2ae1c1c3446efbbe2fc
Author:     Brian Evans <grknight <AT> gentoo <DOT> org>
AuthorDate: Sat Nov  5 22:40:39 2022 +0000
Commit:     Brian Evans <grknight <AT> gentoo <DOT> org>
CommitDate: Sat Nov  5 22:40:39 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9d9355aa

dev-php/snuffleupagus: Version bump for 0.8.3

Includes fixes for dependencies as well

Closes: https://bugs.gentoo.org/879899
Signed-off-by: Brian Evans <grknight <AT> gentoo.org>

 dev-php/snuffleupagus/Manifest                   |  1 +
 dev-php/snuffleupagus/snuffleupagus-0.8.3.ebuild | 78 ++++++++++++++++++++++++
 2 files changed, 79 insertions(+)

diff --git a/dev-php/snuffleupagus/Manifest b/dev-php/snuffleupagus/Manifest
index 893d570b5b49..ac8092978a6c 100644
--- a/dev-php/snuffleupagus/Manifest
+++ b/dev-php/snuffleupagus/Manifest
@@ -1 +1,2 @@
 DIST snuffleupagus-0.7.1.tar.gz 11962220 BLAKE2B 8504721ca08e727a5a6fa58c216a5dac7be3fe6e5a98cffcb17e44a2235628c26f02afd2159e9b1fbe8e40e26bc7c4e34a4ff027ee27b8ec29cf89865dbb8514 SHA512 21510e214f94dd50a4aa05226188c9433a6a261c0bd3d58973ed4536754b3e12356e3f625480c370b66c570482694c25d336a771fbbbeb27e1d524b1f82c7869
+DIST snuffleupagus-0.8.3.tar.gz 11987086 BLAKE2B 989dbb57a8375cb394dfb41f07de5c048b66936a8e5b3dd14fb3609149dd371203f7a30d1fbcfe8ef6faa2ba5864c68b209b1b209541c348c0277c8bd12b568a SHA512 426ab7509e31f712dbef1505bf60f00d3a31481de1fbb0b438e45fb45a50fbdc16204d6af18490c5522a41e62d83107f280a20ac2ffc2795da68407b0dac81d6

diff --git a/dev-php/snuffleupagus/snuffleupagus-0.8.3.ebuild b/dev-php/snuffleupagus/snuffleupagus-0.8.3.ebuild
new file mode 100644
index 000000000000..00e1998355c4
--- /dev/null
+++ b/dev-php/snuffleupagus/snuffleupagus-0.8.3.ebuild
@@ -0,0 +1,78 @@
+# Copyright 2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+PHP_EXT_NAME="${PN}"
+PHP_EXT_INI="yes"
+PHP_EXT_ZENDEXT="no"
+PHP_EXT_ECONF_ARGS=( --enable-${PN} )
+PHP_EXT_S="${S}/src"
+PHP_EXT_NEEDED_USE="session(+)"
+
+USE_PHP="php7-4 php8-0 php8-1"
+
+inherit php-ext-source-r3
+
+KEYWORDS="~amd64"
+
+DESCRIPTION="A PHP module to drastically raise the cost of attacks against websites"
+HOMEPAGE="https://snuffleupagus.readthedocs.io/index.html"
+SRC_URI="https://github.com/jvoisin/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="LGPL-3 PHP-3.01"
+SLOT="0"
+
+src_prepare() {
+	# fix file locations tests look for
+	ln -s "${P}/config" "${WORKDIR}/config" || die
+	# Fix path dependent tests
+	sed -i -e 's~src/tests/~~' \
+		src/tests/session_encryption/crypt_session_read_uncrypt.phpt || die
+	sed -i -e 's~%a/src~%a~' \
+		src/tests/disable_function/disabled_functions_runtime.phpt || die
+	# Fix bad test reference
+	sed -i -e 's~%src/~%s~' \
+		src/tests/deny_writable/deny_writable_execution_simulation.phpt || die
+	php-ext-source-r3_src_prepare
+}
+
+src_install() {
+	addtoinifile() {
+		local inifile="${WORKDIR}/${1}"
+		local inidir="${inifile%/*}"
+
+		mkdir -p "${inidir}" || die "failed to create INI directory ${inidir}"
+
+		local my_added="${2}=${3}"
+		echo "${my_added}" >> "${inifile}" || die "failed to append to ${inifile}"
+		einfo "Added '${my_added}' to /${1}"
+
+		insinto "/${1%/*}"
+		doins "${inifile}"
+	}
+	einstalldocs
+	local slot x cfgdir
+	php-ext-source-r3_src_install
+	# Add the rules file which vary by install version
+	for slot in $(php_get_slots); do
+		php_init_slot_env "${slot}"
+		for x in ${PHP_EXT_SAPIS} ; do
+			cfgdir="/etc/php/${x}-${slot}"
+			if [[ -f "${ED}${cfgdir}/ext/${PHP_INI_NAME}.ini" ]]; then
+				addtoinifile "${cfgdir#/}/ext/${PHP_INI_NAME}.ini" \
+					"sp.configuration_file" "${cfgdir}/${PN}.rules"
+				insinto "${cfgdir}"
+				case ${PHP_CURRENTSLOT:0:1} in
+					8) newins "${S}/config/default_php8.rules" "${PN}.rules" ;;
+					*) newins "${S}/config/default.rules" "${PN}.rules" ;;
+				esac
+			fi
+		done
+	done
+}
+
+pkg_postinst() {
+	elog "This extension is configured with recommended rules enabled by default."
+	elog "Feel free to customize as necessary.  Please test outside of production first."
+	elog "Failure to test may cause unexpected results to loosely coded sites."
+}


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-php/snuffleupagus/
@ 2022-11-05 22:43 Brian Evans
  0 siblings, 0 replies; 5+ messages in thread
From: Brian Evans @ 2022-11-05 22:43 UTC (permalink / raw
  To: gentoo-commits

commit:     36a571a3c53b01f7299002c6cb64ce300116150c
Author:     Brian Evans <grknight <AT> gentoo <DOT> org>
AuthorDate: Sat Nov  5 22:42:42 2022 +0000
Commit:     Brian Evans <grknight <AT> gentoo <DOT> org>
CommitDate: Sat Nov  5 22:42:42 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=36a571a3

dev-php/snuffleupagus: Drop old

Signed-off-by: Brian Evans <grknight <AT> gentoo.org>

 dev-php/snuffleupagus/Manifest                     |  1 -
 .../snuffleupagus/snuffleupagus-0.7.1-r1.ebuild    | 74 ----------------------
 2 files changed, 75 deletions(-)

diff --git a/dev-php/snuffleupagus/Manifest b/dev-php/snuffleupagus/Manifest
index ac8092978a6c..af5d6f90c9d0 100644
--- a/dev-php/snuffleupagus/Manifest
+++ b/dev-php/snuffleupagus/Manifest
@@ -1,2 +1 @@
-DIST snuffleupagus-0.7.1.tar.gz 11962220 BLAKE2B 8504721ca08e727a5a6fa58c216a5dac7be3fe6e5a98cffcb17e44a2235628c26f02afd2159e9b1fbe8e40e26bc7c4e34a4ff027ee27b8ec29cf89865dbb8514 SHA512 21510e214f94dd50a4aa05226188c9433a6a261c0bd3d58973ed4536754b3e12356e3f625480c370b66c570482694c25d336a771fbbbeb27e1d524b1f82c7869
 DIST snuffleupagus-0.8.3.tar.gz 11987086 BLAKE2B 989dbb57a8375cb394dfb41f07de5c048b66936a8e5b3dd14fb3609149dd371203f7a30d1fbcfe8ef6faa2ba5864c68b209b1b209541c348c0277c8bd12b568a SHA512 426ab7509e31f712dbef1505bf60f00d3a31481de1fbb0b438e45fb45a50fbdc16204d6af18490c5522a41e62d83107f280a20ac2ffc2795da68407b0dac81d6

diff --git a/dev-php/snuffleupagus/snuffleupagus-0.7.1-r1.ebuild b/dev-php/snuffleupagus/snuffleupagus-0.7.1-r1.ebuild
deleted file mode 100644
index d18383730d41..000000000000
--- a/dev-php/snuffleupagus/snuffleupagus-0.7.1-r1.ebuild
+++ /dev/null
@@ -1,74 +0,0 @@
-# Copyright 2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-PHP_EXT_NAME="${PN}"
-PHP_EXT_INI="yes"
-PHP_EXT_ZENDEXT="no"
-PHP_EXT_ECONF_ARGS=( --enable-${PN} )
-PHP_EXT_S="${S}/src"
-
-USE_PHP="php7-4 php8-0"
-
-inherit php-ext-source-r3
-
-KEYWORDS="~amd64"
-
-DESCRIPTION="A PHP module to drastically raise the cost of attacks against websites"
-HOMEPAGE="https://snuffleupagus.readthedocs.io/index.html"
-SRC_URI="https://github.com/jvoisin/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
-
-LICENSE="LGPL-3 PHP-3.01"
-SLOT="0"
-
-src_prepare() {
-	# fix file locations tests look for
-	ln -s "${P}/config" "${WORKDIR}/config" || die
-	# Fix path dependent tests
-	sed -i -e 's~src/tests/~~' \
-		src/tests/session_encryption/crypt_session_read_uncrypt.phpt || die
-	sed -i -e 's~%a/src~%a~' \
-		src/tests/disable_function/disabled_functions_runtime.phpt || die
-	php-ext-source-r3_src_prepare
-}
-
-src_install() {
-	addtoinifile() {
-		local inifile="${WORKDIR}/${1}"
-		local inidir="${inifile%/*}"
-
-		mkdir -p "${inidir}" || die "failed to create INI directory ${inidir}"
-
-		local my_added="${2}=${3}"
-		echo "${my_added}" >> "${inifile}" || die "failed to append to ${inifile}"
-		einfo "Added '${my_added}' to /${1}"
-
-		insinto "/${1%/*}"
-		doins "${inifile}"
-	}
-	einstalldocs
-	local slot x cfgdir
-	php-ext-source-r3_src_install
-	# Add the rules file which vary by install version
-	for slot in $(php_get_slots); do
-		php_init_slot_env "${slot}"
-		for x in ${PHP_EXT_SAPIS} ; do
-			cfgdir="/etc/php/${x}-${slot}"
-			if [[ -f "${ED}${cfgdir}/ext/${PHP_INI_NAME}.ini" ]]; then
-				addtoinifile "${cfgdir#/}/ext/${PHP_INI_NAME}.ini" \
-					"sp.configuration_file" "${cfgdir}/${PN}.rules"
-				insinto "${cfgdir}"
-				case ${PHP_CURRENTSLOT:0:1} in
-					8) newins "${S}/config/default_php8.rules" "${PN}.rules" ;;
-					*) newins "${S}/config/default.rules" "${PN}.rules" ;;
-				esac
-			fi
-		done
-	done
-}
-
-pkg_postinst() {
-	elog "This extension is configured with recommended rules enabled by default."
-	elog "Feel free to customize as necessary.  Please test outside of production first."
-	elog "Failure to test may cause unexpected results to loosely coded sites."
-}


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-php/snuffleupagus/
@ 2024-01-18  7:56 Sam James
  0 siblings, 0 replies; 5+ messages in thread
From: Sam James @ 2024-01-18  7:56 UTC (permalink / raw
  To: gentoo-commits

commit:     06b49ea0308bfed36966235026e637b4f8665281
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Thu Jan 18 07:51:50 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Thu Jan 18 07:51:50 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=06b49ea0

dev-php/snuffleupagus: cleanup php8-0

Signed-off-by: Sam James <sam <AT> gentoo.org>

 dev-php/snuffleupagus/snuffleupagus-0.8.3.ebuild | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/dev-php/snuffleupagus/snuffleupagus-0.8.3.ebuild b/dev-php/snuffleupagus/snuffleupagus-0.8.3.ebuild
index ec4d6e1da428..179ce8eb5ff4 100644
--- a/dev-php/snuffleupagus/snuffleupagus-0.8.3.ebuild
+++ b/dev-php/snuffleupagus/snuffleupagus-0.8.3.ebuild
@@ -1,4 +1,4 @@
-# Copyright 2022 Gentoo Authors
+# Copyright 2022-2024 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=8
@@ -9,7 +9,7 @@ PHP_EXT_ECONF_ARGS=( --enable-${PN} )
 PHP_EXT_S="${S}/src"
 PHP_EXT_NEEDED_USE="session(+)"
 
-USE_PHP="php8-0 php8-1"
+USE_PHP="php8-1"
 
 inherit php-ext-source-r3
 


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2024-01-18  7:56 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-11-05 22:43 [gentoo-commits] repo/gentoo:master commit in: dev-php/snuffleupagus/ Brian Evans
  -- strict thread matches above, loose matches on Subject: below --
2024-01-18  7:56 Sam James
2022-11-05 22:43 Brian Evans
2022-04-14 15:10 Brian Evans
2022-04-13 17:11 Brian Evans

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox