summaryrefslogtreecommitdiff
path: root/www-apps/cgp
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2020-08-25 10:45:55 +0100
committerV3n3RiX <venerix@redcorelinux.org>2020-08-25 10:45:55 +0100
commit3cf7c3ef441822c889356fd1812ebf2944a59851 (patch)
treec513fe68548b40365c1c2ebfe35c58ad431cdd77 /www-apps/cgp
parent05b8b0e0af1d72e51a3ee61522941bf7605cd01c (diff)
gentoo resync : 25.08.2020
Diffstat (limited to 'www-apps/cgp')
-rw-r--r--www-apps/cgp/Manifest3
-rw-r--r--www-apps/cgp/cgp-1_p20190510.ebuild56
-rw-r--r--www-apps/cgp/files/cgp-1_p20190510-double-quote.patch23
3 files changed, 82 insertions, 0 deletions
diff --git a/www-apps/cgp/Manifest b/www-apps/cgp/Manifest
index bb9bdd01fb64..55ccf8375536 100644
--- a/www-apps/cgp/Manifest
+++ b/www-apps/cgp/Manifest
@@ -1,3 +1,6 @@
+AUX cgp-1_p20190510-double-quote.patch 866 BLAKE2B b222ceb7b7198aa7b73aae6793b49ff84f66c83f014ed05bccb697bdd915e0a70cc059ccf0c45a038e9a7a8a4833079708558d2a91da521250be589aac3414d3 SHA512 ca9a12c2b52554ceb85038a2b7fe67b1ce6a7a84ce702c3b100659fea143903fd3b29aab877240e3e00dc8b3f3d8b34dad835665aa4d4719054fca0f1ff1f0b2
DIST cgp-1_p20181209.tar.gz 139556 BLAKE2B 0a79ff1974b0ae50db5582121c4fdcc2db0b89ef11ecb001dfa525dd753481f0a454e424d17f24b142fd116a9ea2eeb4ba1dade6f2ffadd63943e5c065323224 SHA512 fcbf81fca2bb14ed143ea414c2f11fe09f4594891507a1ad08482720b104ec62c9986ce25b127d45a7962a8b3db54293a6775dc2359bde41f19b5419606b51eb
+DIST cgp-1_p20190510.tar.gz 139241 BLAKE2B 663d8b8f6e144b4b28ca36674f4f0b68537dba36aa481faa5d0b5ff1ea11933018b91e94750c15833e3bc9b4ce6604898276e84ff3d3d649ebff11089f6328e0 SHA512 3a6d6af25db00f8d80b0e0aa6e19763da8492d0e1cb421474bf31c325ff37357b9bf88af70459e669c4e9f740dd1a547421fcb3184526d9f3ba4333eb57fec8f
EBUILD cgp-1_p20181209.ebuild 1274 BLAKE2B 4e4f86373415213c1b88cac4828de7144732481d48d72c81d7b4156e59847af341bebd94f3f9f8e26177c324756fd99edc6973921f78e6567fbfdf01280cc69f SHA512 76a6f6b6a889d53f84b783cd67f7b60f11e472e8564c4b5caa39e14506a922a72fcce400cafd4b81b35c5508808faff5acda55041c763b2c5d0dc02a34856451
+EBUILD cgp-1_p20190510.ebuild 1323 BLAKE2B 03e60db4dcb33230e93fb1b29faf0878f97632fb1edb61da6f1d78e341bc1196ae2ab28478f154402c0f76e27aaa9147487df6f48578e1f6d154d1bb744d1046 SHA512 df6590b0a287fcd07a7e0840af1b7d1c6697b5a5f8213f99665c6df6e434bea6f836c86585e3cb1f26097252ea6dc3c9be9f757e49b84296cb80e59db308375f
MISC metadata.xml 558 BLAKE2B a2ef24fdd53e577774517c18e6030b08a375cf342aa003fc2f82fa7c73065cd9703f67ba6a2113a6e605280a6239fc7eaeca8f5d0827d587bbfcc9e49b4dc351 SHA512 87e53979d5f382d585ba2c8dbe30ed21402abc270ecad1a6bcc1147aaf7ccf9aba8090c3acfde20fd23b4cf57b4c3621f8e863d9ce175564949619a3c7853576
diff --git a/www-apps/cgp/cgp-1_p20190510.ebuild b/www-apps/cgp/cgp-1_p20190510.ebuild
new file mode 100644
index 000000000000..4821fa570298
--- /dev/null
+++ b/www-apps/cgp/cgp-1_p20190510.ebuild
@@ -0,0 +1,56 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit webapp
+
+MY_PN="${PN^^}"
+MY_PV="fd8fa70739d18d786e88f7ffa57e250e0e41af8f"
+
+DESCRIPTION="A graphical web-based front-end for visualizing RRD collected by collectd"
+HOMEPAGE="https://github.com/pommi/CGP"
+SRC_URI="https://github.com/pommi/${MY_PN}/archive/${MY_PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="CC-BY-2.0 GPL-2+ GPL-3 MIT"
+KEYWORDS="~amd64 ~x86"
+
+RDEPEND="
+ dev-lang/php[json]
+ net-analyzer/rrdtool[graph]
+ virtual/httpd-php
+"
+
+need_httpd_cgi
+
+S="${WORKDIR}/${MY_PN}-${MY_PV}"
+
+DOCS=( "README.md" "doc/CHANGELOG" "doc/nginx.conf" )
+
+PATCHES=( "${FILESDIR}/${P}-double-quote.patch" )
+
+src_install() {
+ webapp_src_preinst
+
+ einstalldocs
+
+ # Since the docs are already installed, remove them from htdocs
+ # The file doc/CHANGELOG is needed, as CGP reads from there it's version
+ rm -r .gitignore LICENSE doc/nginx.conf || die
+
+ insinto "${MY_HTDOCSDIR}"
+ doins -r .
+
+ webapp_src_install
+}
+
+pkg_postinst() {
+ webapp_pkg_postinst
+
+ einfo "The command shell_exec must not be disabled"
+ einfo "through the disable_functions php.ini directive."
+ einfo "It must allow execution of the rrdtool program."
+ einfo ""
+ einfo "An configuration file for www-servers/nginx"
+ einfo "has been installed as an example."
+}
diff --git a/www-apps/cgp/files/cgp-1_p20190510-double-quote.patch b/www-apps/cgp/files/cgp-1_p20190510-double-quote.patch
new file mode 100644
index 000000000000..1cfa7f9898d3
--- /dev/null
+++ b/www-apps/cgp/files/cgp-1_p20190510-double-quote.patch
@@ -0,0 +1,23 @@
+From aec5ed41122b1a900c6fe0a3ddc11656c150b6d5 Mon Sep 17 00:00:00 2001
+From: Conrad Kostecki <conrad@kostecki.com>
+Date: Tue, 24 Sep 2019 00:01:59 +0200
+Subject: [PATCH] inc/functions.inc.php: add double quote for whitelist
+
+Signed-off-by: Conrad Kostecki <conrad@kostecki.com>
+---
+ inc/functions.inc.php | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/inc/functions.inc.php b/inc/functions.inc.php
+index 376b6e1..48336fb 100644
+--- a/inc/functions.inc.php
++++ b/inc/functions.inc.php
+@@ -34,7 +34,7 @@ function GET($index = NULL, $value = NULL) {
+ case 'h': # host
+ case 'pi': # plugin instance
+ case 'ti': # type instance
+- if (!preg_match('/^[\w\-.: ]+$/u', $value)) {
++ if (!preg_match('/^[\w\-.:" ]+$/u', $value)) {
+ error_log(sprintf('Invalid %s in $_GET["%s"]: "%s"', $desc[$index], $index, $value));
+ return NULL;
+ }