Le 22/05/2025 21:15, Jim Seymour via Postfix-users a écrit :
Hi All,

Yes, it's been a while. About 11 years, in fact. But I finally got
around to doing some updates and pushing a new release out the door.

This one goes direct to "Production" status because all it is is
what's been in the Debian distros, with one thoroughly-vetted
addition and a maintenance/debugging change.

>From the ChangeLog:

rel-1.1.6       20250521

     Renamed from "pflogsumm.pl" to "pflogsumm"

     Merged Debian patches through 1.1.5-8. Following are excerpted
     from Debian changelog.

        Fix regex in milter-rejects patch. Kudos to Andreas Jaggi
        <debian...@jaggi.info> for the report and patch. (Closes:
        #1027829)

        Update postscreen-rejects patch with a fix for IPv6
        addresses. Kudos to Juri Haberland <j...@sapienti-sat.org>
        for the fix. (Closes: #955627)

        Add patch to count milter rejects provided by Matus Uhlar.

        Import postscreen support patch provided by Matus Uhlar
        d/patches/postscreen-rejects (Closes: #861402)

     Now matches "traditional" log date strings with either leading
     space or leading zero on single-digit days. (Debian bug report
     1068425)

     Improvement to "unprocessed" debugging code used for
     maintenance only.

You can fetch it from

     https://jimsun.linxnet.com/postfix_contrib.html

Going Forward

I *plan* to actually get back to maintaining pflogsumm. I've some
enhancements and bug-fixes I've added and used locally over the
years, but have been too lazy to formalize and publish. I went back
to 1.1.5 to merge the Debian patches and run the test harness on it.
Next I'll put all that other stuff back in.

I'll also finally remove the stuff that's been deprecated for years.

I apologize for allowing pflogsumm to become nearly abandonware.

Regards,
Jim


Hi Jim,

May I suggest a patch I use from years to handle IPv6 addresses :

--- pflogsumm-1.1.6/pflogsumm 2025-05-22 20:57:37.000000000 +0200
+++ pflogsumm    2025-04-18 14:52:39.000000000 +0200

@@ -1541,14 +1536,14 @@
     # split domain/ipaddr into separates
     # newer versions of Postfix have them "dom.ain[i.p.add.ress]"
     # older versions of Postfix have them "dom.ain/i.p.add.ress"
-    unless((($domain, $ipAddr) = /^([^\[]*)\[((?:\d{1,3}\.){3}\d{1,3})\]/) == 2||
-           (($domain, $ipAddr) = /^([^\/]*)\/([0-9a-f.:]+)/i) == 2) {
+    unless((($domain, $ipAddr) = /^([^\[]+)\[((?:\d{1,3}\.){3}\d{1,3}|[0-9a-f:]+)\]/o) == 2 ||
+           (($domain, $ipAddr) = /^([^\/]+)\/([0-9a-f.:]+)/i) == 2) {

Regards,

Xavier

--
Xavier HUMBERT - Unix/Win/MacOSX Sysadmin/Network Engineer
https://www.amdh.fr

_______________________________________________
Postfix-users mailing list -- postfix-users@postfix.org
To unsubscribe send an email to postfix-users-le...@postfix.org

Reply via email to