Hello community,

here is the log from the commit of package python-josepy for openSUSE:Factory 
checked in at 2018-05-04 11:30:30
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-josepy (Old)
 and      /work/SRC/openSUSE:Factory/.python-josepy.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-josepy"

Fri May  4 11:30:30 2018 rev:3 rq:603639 version:1.1.0

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-josepy/python-josepy.changes      
2018-02-07 18:41:35.807667474 +0100
+++ /work/SRC/openSUSE:Factory/.python-josepy.new/python-josepy.changes 
2018-05-04 11:30:33.501435784 +0200
@@ -1,0 +2,9 @@
+Thu May  3 09:57:33 UTC 2018 - [email protected]
+
+- update to 1.1.0
+  - Deprecated support for Python 2.6 and 3.3.
+  - Use the sign and verify methods when they are available in 
+    cryptography instead of the deprecated methods signer and 
+    verifier.
+
+-------------------------------------------------------------------

Old:
----
  josepy-1.0.1.tar.gz
  josepy-1.0.1.tar.gz.asc

New:
----
  josepy-1.1.0.tar.gz
  josepy-1.1.0.tar.gz.asc

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-josepy.spec ++++++
--- /var/tmp/diff_new_pack.ge3Too/_old  2018-05-04 11:30:34.621394691 +0200
+++ /var/tmp/diff_new_pack.ge3Too/_new  2018-05-04 11:30:34.625394545 +0200
@@ -22,7 +22,7 @@
 %bcond_with     test
 
 Name:           python-%{libname}
-Version:        1.0.1
+Version:        1.1.0
 Release:        0
 Summary:        JOSE protocol implementation in Python
 License:        Apache-2.0

++++++ josepy-1.0.1.tar.gz -> josepy-1.1.0.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/josepy-1.0.1/.travis.yml new/josepy-1.1.0/.travis.yml
--- old/josepy-1.0.1/.travis.yml        2017-10-13 10:31:33.000000000 +0200
+++ new/josepy-1.1.0/.travis.yml        2018-04-13 16:47:09.000000000 +0200
@@ -2,7 +2,9 @@
 sudo: false
 cache: pip
 python:
+  - "2.6"
   - "2.7"
+  - "3.3"
   - "3.4"
   - "3.5"
   - "3.6"
@@ -12,3 +14,5 @@
   - tox -v
 after_success:
   - codecov
+notifications:
+  email: false
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/josepy-1.0.1/PKG-INFO new/josepy-1.1.0/PKG-INFO
--- old/josepy-1.0.1/PKG-INFO   2017-10-25 20:31:12.000000000 +0200
+++ new/josepy-1.1.0/PKG-INFO   2018-04-13 16:48:03.000000000 +0200
@@ -1,13 +1,26 @@
-Metadata-Version: 1.1
+Metadata-Version: 2.1
 Name: josepy
-Version: 1.0.1
+Version: 1.1.0
 Summary: JOSE protocol implementation in Python
-Home-page: https://github.com/jezdez/josepy
+Home-page: https://github.com/certbot/josepy
 Author: Certbot Project
 Author-email: [email protected]
 License: Apache License 2.0
-Description-Content-Type: UNKNOWN
-Description: UNKNOWN
+Description: JOSE protocol implementation in Python using cryptography
+        
+        .. image:: https://travis-ci.org/certbot/josepy.svg?branch=master
+          :target: https://travis-ci.org/certbot/josepy
+        
+        .. image:: 
https://codecov.io/gh/certbot/josepy/branch/master/graph/badge.svg
+          :target: https://codecov.io/gh/certbot/josepy
+        
+        .. image:: 
https://readthedocs.org/projects/josepy/badge/?version=latest
+          :target: http://josepy.readthedocs.io/en/latest/?badge=latest
+        
+        Originally developed as part of the ACME_ protocol implementation.
+        
+        .. _ACME: https://pypi.python.org/pypi/acme
+        
 Platform: UNKNOWN
 Classifier: Development Status :: 3 - Alpha
 Classifier: Intended Audience :: Developers
@@ -23,3 +36,6 @@
 Classifier: Programming Language :: Python :: 3.6
 Classifier: Topic :: Internet :: WWW/HTTP
 Classifier: Topic :: Security
+Provides-Extra: docs
+Provides-Extra: tests
+Provides-Extra: dev
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/josepy-1.0.1/README.rst new/josepy-1.1.0/README.rst
--- old/josepy-1.0.1/README.rst 2017-10-13 10:30:36.000000000 +0200
+++ new/josepy-1.1.0/README.rst 2018-04-13 16:47:09.000000000 +0200
@@ -1,10 +1,10 @@
 JOSE protocol implementation in Python using cryptography
 
-.. image:: https://travis-ci.org/jezdez/josepy.svg?branch=master
-  :target: https://travis-ci.org/jezdez/josepy
+.. image:: https://travis-ci.org/certbot/josepy.svg?branch=master
+  :target: https://travis-ci.org/certbot/josepy
 
-.. image:: https://codecov.io/gh/jezdez/josepy/branch/master/graph/badge.svg
-  :target: https://codecov.io/gh/jezdez/josepy
+.. image:: https://codecov.io/gh/certbot/josepy/branch/master/graph/badge.svg
+  :target: https://codecov.io/gh/certbot/josepy
 
 .. image:: https://readthedocs.org/projects/josepy/badge/?version=latest
   :target: http://josepy.readthedocs.io/en/latest/?badge=latest
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/josepy-1.0.1/docs/conf.py 
new/josepy-1.1.0/docs/conf.py
--- old/josepy-1.0.1/docs/conf.py       2017-10-25 20:29:54.000000000 +0200
+++ new/josepy-1.1.0/docs/conf.py       2018-04-13 16:47:09.000000000 +0200
@@ -63,9 +63,9 @@
 # built documents.
 #
 # The short X.Y version.
-version = u'1.0'
+version = u'1.1'
 # The full version, including alpha/beta/rc tags.
-release = u'1.0.1'
+release = u'1.1.0'
 
 # The language for content autogenerated by Sphinx. Refer to documentation
 # for a list of supported languages.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/josepy-1.0.1/pytest.ini new/josepy-1.1.0/pytest.ini
--- old/josepy-1.0.1/pytest.ini 2017-10-13 10:30:43.000000000 +0200
+++ new/josepy-1.1.0/pytest.ini 2018-04-13 16:47:09.000000000 +0200
@@ -1,4 +1,4 @@
 [pytest]
-addopts = -v --flake8 --isort --cov-report xml --cov-report=term-missing 
--cov=josepy --cov-config .coveragerc
+addopts = -v --flake8 --cov-report xml --cov-report=term-missing --cov=josepy 
--cov-config .coveragerc
 norecursedirs = *.egg .eggs dist build docs .tox
 flake8-ignore = E501
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/josepy-1.0.1/setup.py new/josepy-1.1.0/setup.py
--- old/josepy-1.0.1/setup.py   2017-10-25 20:30:02.000000000 +0200
+++ new/josepy-1.1.0/setup.py   2018-04-13 16:47:09.000000000 +0200
@@ -1,9 +1,10 @@
+import io
 import sys
 
 from setuptools import find_packages, setup
 from setuptools.command.test import test as TestCommand
 
-version = '1.0.1'
+version = '1.1.0'
 
 # Please update tox.ini when modifying dependency version requirements
 install_requires = [
@@ -20,7 +21,6 @@
 
 testing_requires = [
     'coverage>=4.0',
-    'pytest-isort',
     'pytest-cache>=1.0',
     'pytest-cov',
     'flake8',
@@ -47,6 +47,10 @@
 ]
 
 
+with io.open('README.rst', encoding='UTF-8') as f:
+    long_description = f.read()
+
+
 class PyTest(TestCommand):
     user_options = []
 
@@ -66,7 +70,8 @@
     name='josepy',
     version=version,
     description='JOSE protocol implementation in Python',
-    url='https://github.com/jezdez/josepy',
+    long_description=long_description,
+    url='https://github.com/certbot/josepy',
     author="Certbot Project",
     author_email='[email protected]',
     license='Apache License 2.0',
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/josepy-1.0.1/src/josepy/__init__.py 
new/josepy-1.1.0/src/josepy/__init__.py
--- old/josepy-1.0.1/src/josepy/__init__.py     2017-10-12 15:27:47.000000000 
+0200
+++ new/josepy-1.1.0/src/josepy/__init__.py     2018-04-13 16:47:09.000000000 
+0200
@@ -25,6 +25,9 @@
 .. _ACME: https://pypi.python.org/pypi/acme
 
 """
+import sys
+import warnings
+
 # flake8: noqa
 from josepy.b64 import (
     b64decode,
@@ -84,3 +87,11 @@
     ComparableRSAKey,
     ImmutableMap,
 )
+
+for (major, minor) in [(2, 6), (3, 3)]:
+    if sys.version_info[:2] == (major, minor):
+        warnings.warn(
+                "Python {0}.{1} support will be dropped in the next release of 
"
+                "josepy. Please upgrade your Python version.".format(major, 
minor),
+                DeprecationWarning,
+        )
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/josepy-1.0.1/src/josepy/jwa.py 
new/josepy-1.1.0/src/josepy/jwa.py
--- old/josepy-1.0.1/src/josepy/jwa.py  2017-10-12 15:27:47.000000000 +0200
+++ new/josepy-1.1.0/src/josepy/jwa.py  2018-04-13 16:47:09.000000000 +0200
@@ -103,7 +103,11 @@
 
     def sign(self, key, msg):
         """Sign the ``msg`` using ``key``."""
+        # If cryptography library supports new style api (v1.4 and later)
+        new_api = hasattr(key, "sign")
         try:
+            if new_api:
+                return key.sign(msg, self.padding, self.hash)
             signer = key.signer(self.padding, self.hash)
         except AttributeError as error:
             logger.debug(error, exc_info=True)
@@ -120,10 +124,16 @@
 
     def verify(self, key, msg, sig):
         """Verify the ``msg` and ``sig`` using ``key``."""
-        verifier = key.verifier(sig, self.padding, self.hash)
-        verifier.update(msg)
+        # If cryptography library supports new style api (v1.4 and later)
+        new_api = hasattr(key, "verify")
+        if not new_api:
+            verifier = key.verifier(sig, self.padding, self.hash)
+            verifier.update(msg)
         try:
-            verifier.verify()
+            if new_api:
+                key.verify(sig, msg, self.padding, self.hash)
+            else:
+                verifier.verify()
         except cryptography.exceptions.InvalidSignature as error:
             logger.debug(error, exc_info=True)
             return False
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/josepy-1.0.1/src/josepy/jwa_test.py 
new/josepy-1.1.0/src/josepy/jwa_test.py
--- old/josepy-1.0.1/src/josepy/jwa_test.py     2017-10-12 15:27:47.000000000 
+0200
+++ new/josepy-1.1.0/src/josepy/jwa_test.py     2018-04-13 16:47:09.000000000 
+0200
@@ -1,6 +1,8 @@
 """Tests for josepy.jwa."""
 import unittest
 
+import mock
+
 from josepy import errors, test_util
 
 RSA256_KEY = test_util.load_rsa_private_key('rsa256_key.pem')
@@ -96,6 +98,40 @@
         self.assertFalse(PS256.verify(
             RSA1024_KEY.public_key(), b'foo', sig + b'!'))
 
+    def test_sign_new_api(self):
+        from josepy.jwa import RS256
+        key = mock.MagicMock()
+        RS256.sign(key, "message")
+        self.assertTrue(key.sign.called)
+
+    def test_sign_old_api(self):
+        from josepy.jwa import RS256
+        key = mock.MagicMock(spec=[u'signer'])
+        signer = mock.MagicMock()
+        key.signer.return_value = signer
+        RS256.sign(key, "message")
+        self.assertTrue(all([
+            key.signer.called,
+            signer.update.called,
+            signer.finalize.called]))
+
+    def test_verify_new_api(self):
+        from josepy.jwa import RS256
+        key = mock.MagicMock()
+        RS256.verify(key, "message", "signature")
+        self.assertTrue(key.verify.called)
+
+    def test_verify_old_api(self):
+        from josepy.jwa import RS256
+        key = mock.MagicMock(spec=[u'verifier'])
+        verifier = mock.MagicMock()
+        key.verifier.return_value = verifier
+        RS256.verify(key, "message", "signature")
+        self.assertTrue(all([
+            key.verifier.called,
+            verifier.update.called,
+            verifier.verify.called]))
+
 
 if __name__ == '__main__':
     unittest.main()  # pragma: no cover
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/josepy-1.0.1/src/josepy.egg-info/PKG-INFO 
new/josepy-1.1.0/src/josepy.egg-info/PKG-INFO
--- old/josepy-1.0.1/src/josepy.egg-info/PKG-INFO       2017-10-25 
20:31:12.000000000 +0200
+++ new/josepy-1.1.0/src/josepy.egg-info/PKG-INFO       2018-04-13 
16:48:03.000000000 +0200
@@ -1,13 +1,26 @@
-Metadata-Version: 1.1
+Metadata-Version: 2.1
 Name: josepy
-Version: 1.0.1
+Version: 1.1.0
 Summary: JOSE protocol implementation in Python
-Home-page: https://github.com/jezdez/josepy
+Home-page: https://github.com/certbot/josepy
 Author: Certbot Project
 Author-email: [email protected]
 License: Apache License 2.0
-Description-Content-Type: UNKNOWN
-Description: UNKNOWN
+Description: JOSE protocol implementation in Python using cryptography
+        
+        .. image:: https://travis-ci.org/certbot/josepy.svg?branch=master
+          :target: https://travis-ci.org/certbot/josepy
+        
+        .. image:: 
https://codecov.io/gh/certbot/josepy/branch/master/graph/badge.svg
+          :target: https://codecov.io/gh/certbot/josepy
+        
+        .. image:: 
https://readthedocs.org/projects/josepy/badge/?version=latest
+          :target: http://josepy.readthedocs.io/en/latest/?badge=latest
+        
+        Originally developed as part of the ACME_ protocol implementation.
+        
+        .. _ACME: https://pypi.python.org/pypi/acme
+        
 Platform: UNKNOWN
 Classifier: Development Status :: 3 - Alpha
 Classifier: Intended Audience :: Developers
@@ -23,3 +36,6 @@
 Classifier: Programming Language :: Python :: 3.6
 Classifier: Topic :: Internet :: WWW/HTTP
 Classifier: Topic :: Security
+Provides-Extra: docs
+Provides-Extra: tests
+Provides-Extra: dev
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/josepy-1.0.1/src/josepy.egg-info/requires.txt 
new/josepy-1.1.0/src/josepy.egg-info/requires.txt
--- old/josepy-1.0.1/src/josepy.egg-info/requires.txt   2017-10-25 
20:31:12.000000000 +0200
+++ new/josepy-1.1.0/src/josepy.egg-info/requires.txt   2018-04-13 
16:48:03.000000000 +0200
@@ -13,7 +13,6 @@
 
 [tests]
 coverage>=4.0
-pytest-isort
 pytest-cache>=1.0
 pytest-cov
 flake8
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/josepy-1.0.1/tox.ini new/josepy-1.1.0/tox.ini
--- old/josepy-1.0.1/tox.ini    2017-10-13 10:30:20.000000000 +0200
+++ new/josepy-1.1.0/tox.ini    2018-04-13 16:47:09.000000000 +0200
@@ -1,7 +1,7 @@
 [tox]
 envlist =
-    py27
-    py3{4,5,6}
+    py2{6,7}
+    py3{3,4,5,6}
 
 [testenv]
 commands =
@@ -10,5 +10,25 @@
     # installs the test dependencies as specified in setup.py
     .[tests]
 
+[testenv:py26]
+commands =
+    {[testenv]commands}
+deps:
+    cryptography<2.0
+    flake8<3.0
+    pytest-flake8==0.5
+    # installs the test dependencies as specified in setup.py
+    .[tests]
+
+[testenv:py33]
+commands =
+    {[testenv]commands}
+deps:
+    cryptography<2.0
+    flake8<3.0
+    pytest-flake8==0.5
+    # installs the test dependencies as specified in setup.py
+    .[tests]
+
 [flake8]
 ignore = E501

++++++ python-josepy.keyring ++++++
++++ 4323 lines (skipped)
++++ between python-josepy.keyring
++++ and /work/SRC/openSUSE:Factory/.python-josepy.new/python-josepy.keyring


Reply via email to