aboutsummaryrefslogtreecommitdiff
path: root/mail/milter-regex
diff options
context:
space:
mode:
authorDirk Meyer <dinoex@FreeBSD.org>2019-05-02 19:07:34 +0000
committerDirk Meyer <dinoex@FreeBSD.org>2019-05-02 19:07:34 +0000
commitcf0df21e647e484ba1f7d25b7841e335283c1ebd (patch)
treea849b54e3dc4449b6542018d50219683ebc5e466 /mail/milter-regex
parent51189d41669a6b0d0910ac00dd64d01f7fb93d25 (diff)
downloadports-cf0df21e647e484ba1f7d25b7841e335283c1ebd.tar.gz
ports-cf0df21e647e484ba1f7d25b7841e335283c1ebd.zip
- update to 2.6
patches have been merged into upstream
Notes
Notes: svn path=/head/; revision=500679
Diffstat (limited to 'mail/milter-regex')
-rw-r--r--mail/milter-regex/Makefile2
-rw-r--r--mail/milter-regex/distinfo6
-rw-r--r--mail/milter-regex/files/COPYRIGHT2
-rw-r--r--mail/milter-regex/files/milterregex.in1
-rw-r--r--mail/milter-regex/files/patch-milter-regex.827
-rw-r--r--mail/milter-regex/files/patch-milter-regex.c82
-rw-r--r--mail/milter-regex/pkg-descr10
7 files changed, 8 insertions, 122 deletions
diff --git a/mail/milter-regex/Makefile b/mail/milter-regex/Makefile
index ca1b6c7893e0..ba1fc69f2a7c 100644
--- a/mail/milter-regex/Makefile
+++ b/mail/milter-regex/Makefile
@@ -2,7 +2,7 @@
# $FreeBSD$
PORTNAME= milter-regex
-PORTVERSION= 2.4
+PORTVERSION= 2.6
CATEGORIES= mail
MASTER_SITES= https://www.benzedrine.ch/
diff --git a/mail/milter-regex/distinfo b/mail/milter-regex/distinfo
index 65ea2cff865a..28965d24d8bd 100644
--- a/mail/milter-regex/distinfo
+++ b/mail/milter-regex/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1554320086
-SHA256 (milter-regex-2.4.tar.gz) = e6cafefa4d9f103a7b831afb8a0e99a3b8436be4367be6da3d0df5dad5429df9
-SIZE (milter-regex-2.4.tar.gz) = 20347
+TIMESTAMP = 1556518633
+SHA256 (milter-regex-2.6.tar.gz) = 1dc52b9e52ea896fd494c6429ac1c5cd3a631d1354de04ff295ffc8fcce3efc9
+SIZE (milter-regex-2.6.tar.gz) = 20517
diff --git a/mail/milter-regex/files/COPYRIGHT b/mail/milter-regex/files/COPYRIGHT
index 01275b4b1a17..f56576699652 100644
--- a/mail/milter-regex/files/COPYRIGHT
+++ b/mail/milter-regex/files/COPYRIGHT
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2003-2006 Daniel Hartmeier
+ * Copyright (c) 2003-2019 Daniel Hartmeier
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/mail/milter-regex/files/milterregex.in b/mail/milter-regex/files/milterregex.in
index de4ef12fa921..8c3dcae175af 100644
--- a/mail/milter-regex/files/milterregex.in
+++ b/mail/milter-regex/files/milterregex.in
@@ -30,6 +30,7 @@ command="%%PREFIX%%/libexec/milter-regex"
pidfile="${spooldir}/milter-regex.pid"
required_files="%%PREFIX%%/etc/milter-regex.conf"
stop_postcmd="milterregex_poststop"
+command_args="-r ${pidfile}"
milterregex_poststop() {
/bin/rm -f ${pidfile}
diff --git a/mail/milter-regex/files/patch-milter-regex.8 b/mail/milter-regex/files/patch-milter-regex.8
deleted file mode 100644
index c304bc2f8a89..000000000000
--- a/mail/milter-regex/files/patch-milter-regex.8
+++ /dev/null
@@ -1,27 +0,0 @@
---- milter-regex.8.orig 2019-04-02 15:47:26 UTC
-+++ milter-regex.8
-@@ -36,7 +36,9 @@
- .Sh SYNOPSIS
- .Nm
- .Op Fl d
-+.Op Fl q
- .Op Fl c Ar config
-+.Op Fl r Ar pid-file
- .Op Fl f Ar facility
- .Op Fl j Ar dirname
- .Op Fl l Ar loglevel
-@@ -59,9 +61,14 @@ The options are as follows:
- .It Fl d
- Don't detach from controlling terminal and produce verbose debug
- output on stdout.
-+.It Fl q
-+Don't send to syslog messages with priority higher than LOG_NOTICE.
- .It Fl c Ar config
- Use the specified configuration file instead of the default,
- /etc/milter-regex.conf.
-+.It Fl r Ar pid-file
-+Use the specified pid file to write to. Default is:
-+/var/spool/milter-regex/milter-regex.pid
- .It Fl f Ar facility
- Use the specified syslog facility instead of the default, daemon.
- .It Fl j Ar dirname
diff --git a/mail/milter-regex/files/patch-milter-regex.c b/mail/milter-regex/files/patch-milter-regex.c
deleted file mode 100644
index f414c1420712..000000000000
--- a/mail/milter-regex/files/patch-milter-regex.c
+++ /dev/null
@@ -1,82 +0,0 @@
---- milter-regex.c.orig 2019-04-02 15:47:26 UTC
-+++ milter-regex.c
-@@ -62,6 +62,7 @@ extern int parse_ruleset(const char *,
-
- static const char *rule_file_name = "/etc/milter-regex.conf";
- static int debug = 0;
-+static int quiet = 0;
- static unsigned maxlines = 0;
- static pthread_mutex_t mutex;
-
-@@ -99,6 +100,7 @@ static void msg(int, struct context *,
-
- #define USER "_milter-regex"
- #define OCONN "unix:/var/spool/milter-regex/sock"
-+#define OPID "/var/spool/milter-regex/milter-regex.pid"
- #define RCODE_REJECT "554"
- #define RCODE_TEMPFAIL "451"
- #define XCODE_REJECT "5.7.1"
-@@ -647,6 +649,9 @@ msg(int priority, struct context *contex
- va_list ap;
- char msg[8192];
-
-+ if (LOG_PRI(priority) > LOG_INFO && quiet)
-+ return;
-+
- va_start(ap, fmt);
- if (context != NULL)
- snprintf(msg, sizeof(msg), "%s [%s]: ", context->host_name,
-@@ -685,6 +690,7 @@ main(int argc, char **argv)
- {
- int ch, maskpri = LOG_INFO;
- const char *oconn = OCONN;
-+ const char *pid_file_name = OPID;
- const char *user = USER;
- const char *jail = NULL;
- sfsistat r = MI_FAILURE;
-@@ -693,8 +699,10 @@ main(int argc, char **argv)
- const char *puser = NULL;
- mode_t pperm = 0600;
- int facility = LOG_DAEMON;
-+ pid_t pid;
-+ FILE *pid_fd = NULL;
-
-- while ((ch = getopt(argc, argv, "c:df:j:l:m:p:u:G:P:U:")) != -1) {
-+ while ((ch = getopt(argc, argv, "c:df:j:l:m:p:qr:u:G:P:U:")) != -1) {
- switch (ch) {
- case 'c':
- rule_file_name = optarg;
-@@ -724,6 +732,12 @@ main(int argc, char **argv)
- case 'p':
- oconn = optarg;
- break;
-+ case 'q':
-+ quiet = 1;
-+ break;
-+ case 'r':
-+ pid_file_name = optarg;
-+ break;
- case 'u':
- user = optarg;
- break;
-@@ -845,6 +859,20 @@ main(int argc, char **argv)
- }
-
- msg(LOG_INFO, NULL, "started: %s", rcsid);
-+
-+ umask(0006);
-+
-+ if((pid_fd = fopen(pid_file_name, "w")) == NULL) {
-+ msg(LOG_ERR, NULL, "can't open file: %s", pid_file_name);
-+ goto done;
-+ } else {
-+ pid = getpid();
-+ fprintf(pid_fd, "%d", (int) pid);
-+ fclose(pid_fd);
-+ }
-+
-+ umask(0117); /* make socket group writeable */
-+
- r = smfi_main();
- if (r != MI_SUCCESS)
- msg(LOG_ERR, NULL, "smfi_main: terminating due to error");
diff --git a/mail/milter-regex/pkg-descr b/mail/milter-regex/pkg-descr
index bbafac178d1e..9a8e766627c3 100644
--- a/mail/milter-regex/pkg-descr
+++ b/mail/milter-regex/pkg-descr
@@ -2,15 +2,9 @@ Milter-regex is a sendmail milter plugin that allows to reject mail
based on regular expressions matching SMTP envelope parameters and
mail headers and body.
-In order to build milter-regex, sendmail needs to be compiled with
-milter support, installing the libmilter library.
-
-This is the default for the sendmail in the base system.
-Some of the sendmail ports omit libmilter by default (SENDMAIL_WITHOUT_MILTER).
-
-This program is developed on OpenBSD by the maintainer.
+This program is developed on OpenBSD by the author.
LICENSE: BSD
-Copyright (c) 2003-2006 Daniel Hartmeier
+Copyright (c) 2003-2019 Daniel Hartmeier
WWW: https://www.benzedrine.ch/milter-regex.html