From nobody Tue Feb 06 15:00:56 2024 X-Original-To: dev-commits-ports-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4TTmf11FXZz59PqQ; Tue, 6 Feb 2024 15:00:57 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4TTmf10Vdrz4hXn; Tue, 6 Feb 2024 15:00:57 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1707231657; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VQMv7TtjPEG+oqS3cbX4gsAoZi+/rOdzcvmLQFR13Zg=; b=ClhkOgjqyjuLGotM8uynspf1wGoQOHqRZwkBzB18BNx0aivvuJvVP0f13Vuwza4gBABOcX eoIUcuWm2ekk5YjL1Idb+Kz+zxP3Kochu2NENlIbdThbNB1Yf8fI/J0JSo9OU3tS85gfyF sh8cNvMPHLXabd7NLBU3SIalinPfjdCNwE2EMdGtgY49r4zqEwvGprE0KNHTAAEs6Gk7lB o1UGDP6NFtsk8Q8bJ4xL4WRnt89b21DLjIFIaHS9dBS+RMUMPEmJud3dY8+YRqvs8WW9nA lcxB66fXoEGRiBh9QoujZIMvW22WMFULyq1oFxTdHPRqzLlKxac8h83T/Udotg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1707231657; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VQMv7TtjPEG+oqS3cbX4gsAoZi+/rOdzcvmLQFR13Zg=; b=wdIONXD10qEIWrBwYjKz+XXTFhmCwoOanKea2nw3EtYpyqEE797dOiqENmssj8bZAVsHEq RIHgqMBx2rPpaIMO8WXudJr+UQbNLDadqCh8DgiGBuemfXoelk9sYOD/bTxaBaSBS6j+i+ aYNHJtTGdg465CCZ2vZRmcCDZRFp7BytVbK4nqSEIHysovQ7BpkYNjVOO6I8bh96fusdtH wHXj/QXKJe5wTpBhmFrb5L2BeJiZwkgP/llhfontVa8GfCZjM2wpez3kq0/Drr9umC7ips 4EIadRcZhI85ymDVzUtumnCmInHtk3MnM1R7v53foD1cjy0G+oYmMYviP5Cf2g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1707231657; a=rsa-sha256; cv=none; b=wwrc1ePzAbdCnUC0tk8IhLhkZC2hT9XzxfyLdQrj6FIwAnGoVFXKpM0AdfgqT4HuDMW+qA AKHn57XVq5zlhRLjyiFEcI2NV9EGiJ+To6WFd73B2kMKW0K2hZ1uouqPG2vI1A+l9SMGjX WSmUjuRcsuEwJcDx2KOc3YJ9IntpRyN+cTIFim11rLl+lb5T6BTU5SG5V+memJNi1uhRwK jLTVX3Hnk1Aly59U7UwnIDQmhyPmpss6oC+luhScUX4/+6A1R8xm6H2Eh3qxoiFosegTf+ NS+y3pH6Ko88Ec0e2RIRIhXGUdSv4PEtxgwOI+1/xbztC8u+xLiDgGSIKx3Xqw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4TTmf06hKbzSPR; Tue, 6 Feb 2024 15:00:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 416F0u80027783; Tue, 6 Feb 2024 15:00:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 416F0ujJ027780; Tue, 6 Feb 2024 15:00:56 GMT (envelope-from git) Date: Tue, 6 Feb 2024 15:00:56 GMT Message-Id: <202402061500.416F0ujJ027780@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Norikatsu Shigemura Subject: git: 0a8ad0114db6 - main - www/dmarcts-report-viewer: Add new port List-Id: Commit messages for all branches of the ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-all@freebsd.org X-BeenThere: dev-commits-ports-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: nork X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 0a8ad0114db64fb9211238cfe6dff06e8e4bc40c Auto-Submitted: auto-generated The branch main has been updated by nork: URL: https://cgit.FreeBSD.org/ports/commit/?id=0a8ad0114db64fb9211238cfe6dff06e8e4bc40c commit 0a8ad0114db64fb9211238cfe6dff06e8e4bc40c Author: Norikatsu Shigemura AuthorDate: 2024-02-06 14:58:55 +0000 Commit: Norikatsu Shigemura CommitDate: 2024-02-06 14:58:55 +0000 www/dmarcts-report-viewer: Add new port A PHP viewer for DMARC records that have been parsed by John Levine's rddmarc script or the dmarcts-report-parser.pl into a MySQL or PostgreSQL database. Reviewed by: hrs (mentor) Approved by: hrs (mentor) --- www/Makefile | 1 + www/dmarcts-report-viewer/Makefile | 51 ++++++++++++++++++++++ www/dmarcts-report-viewer/distinfo | 3 ++ .../files/patch-dmarcts-report-viewer-common.php | 11 +++++ .../files/patch-dmarcts-report-viewer-options.php | 11 +++++ .../patch-dmarcts-report-viewer-report-data.php | 11 +++++ .../patch-dmarcts-report-viewer-report-list.php | 11 +++++ .../files/patch-dmarcts-report-viewer.php | 11 +++++ www/dmarcts-report-viewer/pkg-descr | 2 + www/dmarcts-report-viewer/pkg-plist | 17 ++++++++ 10 files changed, 129 insertions(+) diff --git a/www/Makefile b/www/Makefile index e93e6ba2d583..d14fd96c1eca 100644 --- a/www/Makefile +++ b/www/Makefile @@ -138,6 +138,7 @@ SUBDIR += devd SUBDIR += dezoomify-rs SUBDIR += dillo2 + SUBDIR += dmarcts-report-viewer SUBDIR += dojo SUBDIR += dokuwiki SUBDIR += dolibarr diff --git a/www/dmarcts-report-viewer/Makefile b/www/dmarcts-report-viewer/Makefile new file mode 100644 index 000000000000..5f974a8bd5e8 --- /dev/null +++ b/www/dmarcts-report-viewer/Makefile @@ -0,0 +1,51 @@ +PORTNAME= dmarcts-report-viewer +PORTVERSION= 2.0.0.20230615.${GH_TAGNAME} +CATEGORIES= www mail +PKGNAMESUFFIX= ${PHP_PKGNAMESUFFIX} +DIST_SUBDIR= ${PORTNAME} + +MAINTAINER= nork@FreeBSD.org +COMMENT= PHP viewer for DMARC records +WWW= https://www.techsneeze.com/dmarc-report/ + +LICENSE= BSD3CLAUSE GPLv3 +LICENSE_COMB= multi +LICENSE_FILE_GPLv3= ${WRKSRC}/LICENSE +LICENSE_FILE_BSD3CLAUSE= ${WRKSRC}/highlight.js/LICENSE + +USES= php +USE_PHP= dom pdo xml +USE_GITHUB= yes +GH_ACCOUNT= techsneeze +GH_TAGNAME= 4730985 + +NO_ARCH= yes +NO_BUILD= yes +PLIST_SUB= PORTNAME=${PORTNAME} +ETCDIR= ${PREFIX}/etc + +OPTIONS_DEFINE= MYSQL PGSQL +OPTIONS_DEFAULT= MYSQL PGSQL +MYSQL_USE= PHP=pdo_mysql +PGSQL_USE= PHP=pdo_pgsql + +post-patch: + cd ${PATCH_WRKSRC} && ${REINPLACE_CMD} \ + -e 's|%%ETCDIR%%|${ETCDIR}|' \ + -e 's|%%PORTNAME%%|${PORTNAME}|' \ + dmarcts-report-viewer-common.php \ + dmarcts-report-viewer-options.php \ + dmarcts-report-viewer-report-data.php \ + dmarcts-report-viewer-report-list.php \ + dmarcts-report-viewer.php + +pre-install: + @${MKDIR} ${STAGEDIR}${WWWDIR}/highlight.js/styles + +do-install: + ${INSTALL_DATA} /dev/null ${STAGEDIR}${WWWDIR}/index.html + cd ${WRKSRC} && ${COPYTREE_SHARE} . ${STAGEDIR}${WWWDIR} \ + "-name *\.js -o -name *\.css -o -name *\.png -o -name *\.php" + ${INSTALL_DATA} ${WRKSRC}/${PORTNAME}-config.php.sample ${STAGEDIR}${ETCDIR} + +.include diff --git a/www/dmarcts-report-viewer/distinfo b/www/dmarcts-report-viewer/distinfo new file mode 100644 index 000000000000..8ed1180081c6 --- /dev/null +++ b/www/dmarcts-report-viewer/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1704737908 +SHA256 (dmarcts-report-viewer/techsneeze-dmarcts-report-viewer-2.0.0.20230615.4730985-4730985_GH0.tar.gz) = 55a6563f5fe06616a16a2415d432c7ca9546e96017ae63d0df0963697be14033 +SIZE (dmarcts-report-viewer/techsneeze-dmarcts-report-viewer-2.0.0.20230615.4730985-4730985_GH0.tar.gz) = 82271 diff --git a/www/dmarcts-report-viewer/files/patch-dmarcts-report-viewer-common.php b/www/dmarcts-report-viewer/files/patch-dmarcts-report-viewer-common.php new file mode 100644 index 000000000000..059f1539c677 --- /dev/null +++ b/www/dmarcts-report-viewer/files/patch-dmarcts-report-viewer-common.php @@ -0,0 +1,11 @@ +--- dmarcts-report-viewer-common.php.orig 2023-07-15 05:56:09 UTC ++++ dmarcts-report-viewer-common.php +@@ -251,7 +251,7 @@ function main() { + + function main() { + +- include "dmarcts-report-viewer-config.php"; ++ include "%%ETCDIR%%/%%PORTNAME%%-config.php"; + } + + // This function sets variables for the DMARC Result portion (left half-circle) in the Report List diff --git a/www/dmarcts-report-viewer/files/patch-dmarcts-report-viewer-options.php b/www/dmarcts-report-viewer/files/patch-dmarcts-report-viewer-options.php new file mode 100644 index 000000000000..44c32346224b --- /dev/null +++ b/www/dmarcts-report-viewer/files/patch-dmarcts-report-viewer-options.php @@ -0,0 +1,11 @@ +--- dmarcts-report-viewer-options.php.orig 2023-07-15 05:56:09 UTC ++++ dmarcts-report-viewer-options.php +@@ -255,7 +255,7 @@ function create_select($option_name, $option = array() + //#################################################################### + + // These files must exist, in the same folder as this script. +-include "dmarcts-report-viewer-config.php"; ++include "%%ETCDIR%%/%%PORTNAME%%-config.php"; + include "dmarcts-report-viewer-common.php"; + + // Get all configuration options diff --git a/www/dmarcts-report-viewer/files/patch-dmarcts-report-viewer-report-data.php b/www/dmarcts-report-viewer/files/patch-dmarcts-report-viewer-report-data.php new file mode 100644 index 000000000000..0c4b9a4e6481 --- /dev/null +++ b/www/dmarcts-report-viewer/files/patch-dmarcts-report-viewer-report-data.php @@ -0,0 +1,11 @@ +--- dmarcts-report-viewer-report-data.php.orig 2023-07-15 05:56:09 UTC ++++ dmarcts-report-viewer-report-data.php +@@ -257,7 +257,7 @@ function formatXML($raw_xml, $reportnumber) { + //#################################################################### + + // These files are expected to be in the same folder as this script, and must exist. +-include "dmarcts-report-viewer-config.php"; ++include "%%ETCDIR%%/%%PORTNAME%%-config.php"; + include "dmarcts-report-viewer-common.php"; + + // Get all configuration options diff --git a/www/dmarcts-report-viewer/files/patch-dmarcts-report-viewer-report-list.php b/www/dmarcts-report-viewer/files/patch-dmarcts-report-viewer-report-list.php new file mode 100644 index 000000000000..2afdc6278210 --- /dev/null +++ b/www/dmarcts-report-viewer/files/patch-dmarcts-report-viewer-report-list.php @@ -0,0 +1,11 @@ +--- dmarcts-report-viewer-report-list.php.orig 2023-07-15 05:56:09 UTC ++++ dmarcts-report-viewer-report-list.php +@@ -105,7 +105,7 @@ function tmpl_reportList($reports, $sort) { + //#################################################################### + + // These files are expected to be in the same folder as this script, and must exist. +-include "dmarcts-report-viewer-config.php"; ++include "%%ETCDIR%%/%%PORTNAME%%-config.php"; + include "dmarcts-report-viewer-common.php"; + + // Get all configuration options diff --git a/www/dmarcts-report-viewer/files/patch-dmarcts-report-viewer.php b/www/dmarcts-report-viewer/files/patch-dmarcts-report-viewer.php new file mode 100644 index 000000000000..63bbe3e7ef3a --- /dev/null +++ b/www/dmarcts-report-viewer/files/patch-dmarcts-report-viewer.php @@ -0,0 +1,11 @@ +--- dmarcts-report-viewer.php.orig 2023-07-15 05:56:09 UTC ++++ dmarcts-report-viewer.php +@@ -224,7 +224,7 @@ function html ($domains = array(), $orgs = array(), $p + //#################################################################### + + // These files must exist, in the same folder as this script. +-include "dmarcts-report-viewer-config.php"; ++include "%%ETCDIR%%/%%PORTNAME%%-config.php"; + include "dmarcts-report-viewer-common.php"; + + // Get all configuration options diff --git a/www/dmarcts-report-viewer/pkg-descr b/www/dmarcts-report-viewer/pkg-descr new file mode 100644 index 000000000000..9384cb9fd2a2 --- /dev/null +++ b/www/dmarcts-report-viewer/pkg-descr @@ -0,0 +1,2 @@ +A PHP viewer for DMARC records that have been parsed by John Levine's rddmarc +script or the dmarcts-report-parser.pl into a MySQL or PostgreSQL database. diff --git a/www/dmarcts-report-viewer/pkg-plist b/www/dmarcts-report-viewer/pkg-plist new file mode 100644 index 000000000000..9fcf38806cd1 --- /dev/null +++ b/www/dmarcts-report-viewer/pkg-plist @@ -0,0 +1,17 @@ +%%WWWDIR%%/default.css +%%WWWDIR%%/dusk2dawn.css +%%WWWDIR%%/%%PORTNAME%%.js +%%WWWDIR%%/%%PORTNAME%%-common.php +%%WWWDIR%%/%%PORTNAME%%-options.php +%%WWWDIR%%/%%PORTNAME%%-report-data.php +%%WWWDIR%%/%%PORTNAME%%-report-list.php +%%WWWDIR%%/%%PORTNAME%%.php +%%WWWDIR%%/html.png +%%WWWDIR%%/highlight.js/highlight.pack.js +%%WWWDIR%%/highlight.js/styles/default.css +%%WWWDIR%%/highlight.js/styles/dusk2dawn.css +%%WWWDIR%%/index.html +%%WWWDIR%%/menu_icon_default.css.png +%%WWWDIR%%/menu_icon_dusk2dawn.css.png +%%WWWDIR%%/xml.png +@sample %%ETCDIR%%/%%PORTNAME%%-config.php.sample