From 8ae5dc35445c265d180373b39181b8243cf25ce3 Mon Sep 17 00:00:00 2001 From: Matthieu Saulnier Date: Apr 21 2021 04:42:19 +0000 Subject: Initial import (#1916510). --- diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..9f4fc3f --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/v0.5.9-beta.tar.gz diff --git a/XEdDSA-version-bump.patch b/XEdDSA-version-bump.patch new file mode 100644 index 0000000..eb2cae9 --- /dev/null +++ b/XEdDSA-version-bump.patch @@ -0,0 +1,11 @@ +--- setup.py.orig 2019-07-21 13:25:23.000000000 +0200 ++++ setup.py 2021-01-18 02:51:45.714537335 +0100 +@@ -34,7 +34,7 @@ setup( + author_email = "me@syndace.dev", + license = "MIT", + packages = find_packages(), +- install_requires = [ "cryptography>=1.7.1", "XEdDSA>=0.4.7,<0.5" ], ++ install_requires = [ "cryptography>=1.7.1", "XEdDSA>=0.6,<0.7" ], + python_requires = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, <4", + zip_safe = False, + classifiers = [ diff --git a/python-x3dh.spec b/python-x3dh.spec new file mode 100644 index 0000000..2f3ab26 --- /dev/null +++ b/python-x3dh.spec @@ -0,0 +1,94 @@ +Name: python-x3dh +Version: 0.5.9~beta +Release: 4%{?dist} +Summary: Python implementation of the X3DH key agreement protocol + +License: MIT +URL: https://github.com/Syndace/%{name} +Source0: https://github.com/Syndace/%{name}/archive/v%{version_no_tilde}.tar.gz +# backport from upstream +# commit: a38d9ecff2f2735b220d1416c003c757ac3eff57 +# XEdDSA 0.6.0 has been released +Patch0: XEdDSA-version-bump.patch +# For files and directories +%global version_main %(c=%version; echo $c|cut -d~ -f1) + +BuildArch: noarch +BuildRequires: python3-devel +BuildRequires: python3-cryptography +BuildRequires: python3-xeddsa +# For tests +# "nacl" is also a runtime requirement +BuildRequires: python3-pynacl +BuildRequires: python3-pytest + +%description +This python library offers an implementation of the Extended Triple +Diffie-Hellman key agreement protocol (X3DH). + +X3DH establishes a shared secret key between two parties who mutually +authenticate each other based on public keys. X3DH provides forward +secrecy and cryptographic deniability. + + + +%package -n python3-x3dh +Summary: Python implementation of the X3DH key agreement protocol +Requires: python3-pynacl + +%description -n python3-x3dh +This python library offers an implementation of the Extended Triple +Diffie-Hellman key agreement protocol (X3DH). + +X3DH establishes a shared secret key between two parties who mutually +authenticate each other based on public keys. X3DH provides forward +secrecy and cryptographic deniability. + + + +%prep +%autosetup -n %{name}-%{version_no_tilde} + + +%build +%py3_build + + +%install +%py3_install + + +%check +%pytest + + + +%files -n python3-x3dh +%license LICENSE +%doc README.md +# For noarch packages: sitelib +%{python3_sitelib}/x3dh/ +%{python3_sitelib}/X3DH-%{version_main}-py%{python3_version}.egg-info/ + + + +%changelog +* Sat Apr 17 2021 Matthieu Saulnier - 0.5.9~beta-4 +- Package Review RHBZ#1916510: + - Short the Summary + - Add nacl python module as build requirement and runtime requirement + - Use %%pytest to run tests suite + +* Sun Feb 14 2021 Matthieu Saulnier - 0.5.9~beta-3 +- Package Review RHBZ#1916510: + - Add more explicit description + - Remove %%{srcname} variable truely used once + - Fix the Version tag to match upstream version + - Use %%{python3_version} in %%files section + +* Mon Jan 18 2021 Matthieu Saulnier - 0.5.9-2 +- Add Patch0 to fix installation package + Backport from upstream commit: a38d9ecf + +* Thu Dec 10 2020 Matthieu Saulnier - 0.5.9-1 +- Initial package diff --git a/sources b/sources new file mode 100644 index 0000000..048fe95 --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA512 (v0.5.9-beta.tar.gz) = f8d134448fd6ddb7264dea1ac6aeaccf9b78d5eb44de82733083f1154f28c676792596b1c2c3318e6e24ace0345ef6cd73653933df3392bbba62a05db377a876