diff --git a/python-proton-client.changes b/python-proton-client.changes index 9d50bfd..33dfa9a 100644 --- a/python-proton-client.changes +++ b/python-proton-client.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Mon Sep 25 14:52:52 UTC 2023 - Alexandre Vicenzi + +- Add urllib3-v2-migration.patch to fix authentication errors. + ------------------------------------------------------------------- Tue Oct 26 19:05:45 UTC 2021 - Alexandre Vicenzi diff --git a/python-proton-client.spec b/python-proton-client.spec index 1dce62f..c58bc43 100644 --- a/python-proton-client.spec +++ b/python-proton-client.spec @@ -1,7 +1,7 @@ # # spec file for package python-proton-client # -# Copyright (c) 2021 SUSE LLC +# Copyright (c) 2023 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -26,6 +26,7 @@ License: GPL-3.0-or-later Group: Development/Languages/Python URL: https://github.com/ProtonMail/proton-python-client Source: https://github.com/ProtonMail/proton-python-client/archive/refs/tags/%{version}.tar.gz#/proton-python-client-%{version}.tar.gz +Patch1: urllib3-v2-migration.patch BuildRequires: %{python_module bcrypt} BuildRequires: %{python_module gnupg} BuildRequires: %{python_module pytest} @@ -47,7 +48,7 @@ This package, originally forked from python-srp module implements a simple wrapper to Proton Technologies API, abstracting from the SRP authentication. %prep -%setup -q -n proton-python-client-%{version} +%autosetup -n proton-python-client-%{version} -p1 %build %python_build diff --git a/urllib3-v2-migration.patch b/urllib3-v2-migration.patch new file mode 100644 index 0000000..972e48f --- /dev/null +++ b/urllib3-v2-migration.patch @@ -0,0 +1,35 @@ +diff --git a/proton/cert_pinning.py b/proton/cert_pinning.py +index e39298b..29aa048 100644 +--- a/proton/cert_pinning.py ++++ b/proton/cert_pinning.py +@@ -18,7 +18,6 @@ class TLSPinningHTTPSConnectionPool(HTTPSConnectionPool): + host, + hash_dict, + port=None, +- strict=False, + timeout=Timeout.DEFAULT_TIMEOUT, + maxsize=1, + block=False, +@@ -44,7 +43,6 @@ class TLSPinningHTTPSConnectionPool(HTTPSConnectionPool): + super(TLSPinningHTTPSConnectionPool, self).__init__( + host, + port, +- strict, + timeout, + maxsize, + block, +@@ -67,7 +65,6 @@ class TLSPinningHTTPSConnectionPool(HTTPSConnectionPool): + super(TLSPinningHTTPSConnectionPool, self).__init__( + host, + port, +- strict, + timeout, + maxsize, + block, +@@ -181,5 +178,5 @@ class TLSPinningAdapter(HTTPAdapter): + ): + self.poolmanager = TLSPinningPoolManager( + num_pools=connections, maxsize=maxsize, block=block, +- strict=True, hash_dict=self.hash_dict, **pool_kwargs ++ hash_dict=self.hash_dict, **pool_kwargs + )