pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/chat/py-xmpppy



Module Name:    pkgsrc
Committed By:   gdt
Date:           Sun Aug 10 14:36:25 UTC 2025

Modified Files:
        pkgsrc/chat/py-xmpppy: Makefile PLIST distinfo
        pkgsrc/chat/py-xmpppy/patches: patch-xmpp_transports.py

Log Message:
chat/py-xmpppy: Update to 0.7.2

pkgsrc:
  - Convert to wheel.mk (NFCI).
  - Drop ssl patch cherrypicked from upstream, now in this release.
  - Add patch with attempts to remove disabling of certificate
    validation (to match behavior of 0.7.1 in pkgsrc), and comments
    about why that doesn't work, as being on the path to working with
    upstream.

2025-08-09 0.7.2
================
- Fixed ``AttributeError: module 'ssl' has no attribute 'wrap_socket'``.
  Thanks, @juanvalino.
- Ensured certificate checking is disabled to maintain backward compatibility.
  Thanks, @juanvalino.
- Added example for sending data to a MUC room. Thanks, @sebix.


To generate a diff of this commit:
cvs rdiff -u -r1.34 -r1.35 pkgsrc/chat/py-xmpppy/Makefile
cvs rdiff -u -r1.4 -r1.5 pkgsrc/chat/py-xmpppy/PLIST
cvs rdiff -u -r1.12 -r1.13 pkgsrc/chat/py-xmpppy/distinfo
cvs rdiff -u -r1.5 -r1.6 \
    pkgsrc/chat/py-xmpppy/patches/patch-xmpp_transports.py

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/chat/py-xmpppy/Makefile
diff -u pkgsrc/chat/py-xmpppy/Makefile:1.34 pkgsrc/chat/py-xmpppy/Makefile:1.35
--- pkgsrc/chat/py-xmpppy/Makefile:1.34 Sun Nov 24 00:52:59 2024
+++ pkgsrc/chat/py-xmpppy/Makefile      Sun Aug 10 14:36:24 2025
@@ -1,8 +1,7 @@
-# $NetBSD: Makefile,v 1.34 2024/11/24 00:52:59 gdt Exp $
+# $NetBSD: Makefile,v 1.35 2025/08/10 14:36:24 gdt Exp $
 
-DISTNAME=      xmpppy-0.7.1
+DISTNAME=      xmpppy-0.7.2
 PKGNAME=       ${PYPKGPREFIX}-${DISTNAME}
-PKGREVISION=   6
 CATEGORIES=    chat python
 MASTER_SITES=  ${MASTER_SITE_GITHUB:=xmpppy/}
 GITHUB_PROJECT=        xmpppy
@@ -45,5 +44,5 @@ post-install:
                ${DESTDIR}${DOCDIR}
 
 .include "../../lang/python/batteries-included.mk"
-.include "../../lang/python/egg.mk"
+.include "../../lang/python/wheel.mk"
 .include "../../mk/bsd.pkg.mk"

Index: pkgsrc/chat/py-xmpppy/PLIST
diff -u pkgsrc/chat/py-xmpppy/PLIST:1.4 pkgsrc/chat/py-xmpppy/PLIST:1.5
--- pkgsrc/chat/py-xmpppy/PLIST:1.4     Sun Apr 10 18:49:25 2022
+++ pkgsrc/chat/py-xmpppy/PLIST Sun Aug 10 14:36:24 2025
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.4 2022/04/10 18:49:25 gdt Exp $
+@comment $NetBSD: PLIST,v 1.5 2025/08/10 14:36:24 gdt Exp $
 bin/xmpp-message
 ${PYSITELIB}/xmpp/__init__.py
 ${PYSITELIB}/xmpp/__init__.pyc
@@ -48,12 +48,12 @@ ${PYSITELIB}/xmpp/transports.pyo
 ${PYSITELIB}/xmpp/xep0106.py
 ${PYSITELIB}/xmpp/xep0106.pyc
 ${PYSITELIB}/xmpp/xep0106.pyo
-${PYSITELIB}/${EGG_INFODIR}/PKG-INFO
-${PYSITELIB}/${EGG_INFODIR}/SOURCES.txt
-${PYSITELIB}/${EGG_INFODIR}/dependency_links.txt
-${PYSITELIB}/${EGG_INFODIR}/entry_points.txt
-${PYSITELIB}/${EGG_INFODIR}/requires.txt
-${PYSITELIB}/${EGG_INFODIR}/top_level.txt
+${PYSITELIB}/${WHEEL_INFODIR}/METADATA
+${PYSITELIB}/${WHEEL_INFODIR}/RECORD
+${PYSITELIB}/${WHEEL_INFODIR}/WHEEL
+${PYSITELIB}/${WHEEL_INFODIR}/entry_points.txt
+${PYSITELIB}/${WHEEL_INFODIR}/licenses/LICENSE
+${PYSITELIB}/${WHEEL_INFODIR}/top_level.txt
 share/doc/py-xmpppy/advanced.html
 share/doc/py-xmpppy/basic.html
 share/doc/py-xmpppy/index.html
@@ -64,4 +64,5 @@ share/examples/py-xmpppy/bot.py
 share/examples/py-xmpppy/commandsbot.py
 share/examples/py-xmpppy/demo.py
 share/examples/py-xmpppy/logger.py
+share/examples/py-xmpppy/muc.py
 share/examples/py-xmpppy/xtalk.py

Index: pkgsrc/chat/py-xmpppy/distinfo
diff -u pkgsrc/chat/py-xmpppy/distinfo:1.12 pkgsrc/chat/py-xmpppy/distinfo:1.13
--- pkgsrc/chat/py-xmpppy/distinfo:1.12 Sun Nov 24 00:52:59 2024
+++ pkgsrc/chat/py-xmpppy/distinfo      Sun Aug 10 14:36:24 2025
@@ -1,7 +1,7 @@
-$NetBSD: distinfo,v 1.12 2024/11/24 00:52:59 gdt Exp $
+$NetBSD: distinfo,v 1.13 2025/08/10 14:36:24 gdt Exp $
 
-BLAKE2s (xmpppy-0.7.1.tar.gz) = e394d2554c38736ed35eb93823e11b02a87f719ab6e980d88327326b65660286
-SHA512 (xmpppy-0.7.1.tar.gz) = d7dc536282c5214007037bacc0c2d24bc64d1ea10441472a5ab23b14fe076b65f945e966a6255519e8ddca41c6d4c343ebe99b50bf1764f6775e58a3ab1b2266
-Size (xmpppy-0.7.1.tar.gz) = 191428 bytes
+BLAKE2s (xmpppy-0.7.2.tar.gz) = c67d9a8d5941a3792eaa2fffe9a80c1cf753a91791d9752b8ca430a0f8eb394a
+SHA512 (xmpppy-0.7.2.tar.gz) = e49b4b2ab4803791d93d0b37446e00c908562af578217b17e1d97a7b9003d7ce98a06b39ed02119bf8bae4b3ad8d8f824e87717287816541625b58f31d10e65e
+Size (xmpppy-0.7.2.tar.gz) = 192093 bytes
 SHA1 (patch-xmpp_debug.py) = a410b7abd534f37bba583ca9f15bf05252bc55a0
-SHA1 (patch-xmpp_transports.py) = 1e7b3f30bcbb7ac3ad5f3719adfc6a5ccb43519f
+SHA1 (patch-xmpp_transports.py) = 8ae6ccbebf7a3aadda7070e4dc762840e236cf0d

Index: pkgsrc/chat/py-xmpppy/patches/patch-xmpp_transports.py
diff -u pkgsrc/chat/py-xmpppy/patches/patch-xmpp_transports.py:1.5 pkgsrc/chat/py-xmpppy/patches/patch-xmpp_transports.py:1.6
--- pkgsrc/chat/py-xmpppy/patches/patch-xmpp_transports.py:1.5  Sun Nov 24 00:52:59 2024
+++ pkgsrc/chat/py-xmpppy/patches/patch-xmpp_transports.py      Sun Aug 10 14:36:24 2025
@@ -1,31 +1,21 @@
-$NetBSD: patch-xmpp_transports.py,v 1.5 2024/11/24 00:52:59 gdt Exp $
+$NetBSD: patch-xmpp_transports.py,v 1.6 2025/08/10 14:36:24 gdt Exp $
 
-Adapt to ssl usage in python 3.12 and up.
+Upstream disables validating certificates.  In 2025, this is a bug.
+Record how to address the bug, and why that fails.
 
-Taken from:
-  https://github.com/xmpppy/xmpppy/pull/70/
+https://github.com/xmpppy/xmpppy/issues/71
 
-This patch asks python to load the system's configured trust anchors.
-Validation and hostname matching are in theory enabled by default.
-This is a behavior change from upstream, but it is a bugfix.
-See
-  https://github.com/xmpppy/xmpppy/issues/71
-
-
---- xmpp/transports.py.orig    2022-04-10 18:25:44.000000000 +0000
+--- xmpp/transports.py.orig    2025-08-09 12:24:46.000000000 +0000
 +++ xmpp/transports.py
-@@ -383,8 +383,13 @@ class TLS(PlugIn):
-     def _startSSL(self):
-         """ Immidiatedly switch socket to TLS mode. Used internally."""
+@@ -385,6 +385,11 @@ class TLS(PlugIn):
          """ Here we should switch pending_data to hint mode."""
-+        context=ssl.create_default_context()
-+        # Uncomment if you need to work around trust anchor configuration.
-+        #context.check_hostname = False
-+        #context.verify_mode = ssl.CERT_NONE
-+
          tcpsock=self._owner.Connection
--        tcpsock._sslObj    = ssl.wrap_socket(tcpsock._sock, None, None)
-+        tcpsock._sslObj    = context.wrap_socket(tcpsock._sock, server_hostname=self._owner.Server)
-         tcpsock._sslIssuer = tcpsock._sslObj.getpeercert().get('issuer')
-         tcpsock._sslServer = tcpsock._sslObj.getpeercert().get('server')
-         tcpsock._recv = tcpsock._sslObj.read
+         context=ssl.SSLContext(ssl.PROTOCOL_TLS_CLIENT)
++        #pkgsrc:
++        #  - Choose defaults for 2025.
++        #  - https://github.com/xmpppy/xmpppy/issues/71
++        #  - \todo hostname is not set, and thus cannot be checked
++        #  - \todo "ssl.SSLCertVerificationError: (SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1010)'),)"
+         context.check_hostname = False
+         context.verify_mode = ssl.CERT_NONE
+ 



Home | Main Index | Thread Index | Old Index