diff --git a/0001-switch-requirement-from-pykerberos-back-to-kerberos.patch b/0001-switch-requirement-from-pykerberos-back-to-kerberos.patch new file mode 100644 index 0000000..1ace1b3 --- /dev/null +++ b/0001-switch-requirement-from-pykerberos-back-to-kerberos.patch @@ -0,0 +1,38 @@ +From ce277612b1e262a84a1a97e5084571b66b7dd573 Mon Sep 17 00:00:00 2001 +From: Dan Callaghan +Date: Thu, 11 Feb 2016 10:29:02 +1000 +Subject: [PATCH] switch requirement from pykerberos back to kerberos + +--- + requirements.txt | 2 +- + setup.py | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/requirements.txt b/requirements.txt +index c49add0..98fcbbc 100644 +--- a/requirements.txt ++++ b/requirements.txt +@@ -1,6 +1,6 @@ + requests>=1.1.0 + winkerberos >= 0.5.0; sys.platform == 'win32' +-pykerberos >= 1.1.8, < 2.0.0; sys.platform != 'win32' ++kerberos; sys.platform != 'win32' + cryptography>=1.3 + cryptography>=1.3; python_version!="3.3" + cryptography>=1.3, <2; python_version=="3.3" +diff --git a/setup.py b/setup.py +index 8381ac7..53dafc0 100755 +--- a/setup.py ++++ b/setup.py +@@ -54,7 +54,7 @@ def get_version(): + ], + extras_require={ + ':sys_platform=="win32"': ['winkerberos>=0.5.0'], +- ':sys_platform!="win32"': ['pykerberos>=1.1.8,<2.0.0'], ++ ':sys_platform!="win32"': ['kerberos'], + }, + test_suite='test_requests_kerberos', + tests_require=['mock'], +-- +2.13.6 + diff --git a/python-requests-kerberos.spec b/python-requests-kerberos.spec new file mode 100644 index 0000000..f2881f6 --- /dev/null +++ b/python-requests-kerberos.spec @@ -0,0 +1,78 @@ +%global _empty_manifest_terminate_build 0 +Name: python-requests-kerberos +Version: 0.12.0 +Release: 1 +Summary: A Kerberos authentication handler for python-requests +License: MIT +URL: https://github.com/requests/requests-kerberos +Source0: https://files.pythonhosted.org/packages/14/61/85737ebe1e65cd4bf023d9e4610df70851bd7638e003b81a44a9b901feae/requests-kerberos-0.12.0.tar.gz +Patch0000: 0001-switch-requirement-from-pykerberos-back-to-kerberos.patch +BuildArch: noarch + +Requires: python3-requests python3-cryptography + +%description +Requests is an HTTP library, written in Python, for human beings. This library +adds optional Kerberos/GSSAPI authentication support and supports mutual +authentication. + +%package -n python3-requests-kerberos +Summary: A Kerberos authentication handler for python-requests +Provides: python-requests-kerberos +BuildRequires: python3-devel python3-setuptools +%description -n python3-requests-kerberos +Requests is an HTTP library, written in Python, for human beings. This library +adds optional Kerberos/GSSAPI authentication support and supports mutual +authentication. + +%package help +Summary: Development documents and examples for requests-kerberos +Provides: python3-requests-kerberos-doc +%description help +Requests is an HTTP library, written in Python, for human beings. This library +adds optional Kerberos/GSSAPI authentication support and supports mutual +authentication. + +%prep +%autosetup -n requests-kerberos-0.12.0 -p1 + +%build +%py3_build + +%install +%py3_install +install -d -m755 %{buildroot}/%{_pkgdocdir} +if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi +if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi +if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi +if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi +pushd %{buildroot} +if [ -d usr/lib ]; then + find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/lib64 ]; then + find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/bin ]; then + find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/sbin ]; then + find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst +fi +touch doclist.lst +if [ -d usr/share/man ]; then + find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst +fi +popd +mv %{buildroot}/filelist.lst . +mv %{buildroot}/doclist.lst . + +%files -n python3-requests-kerberos -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Tue Aug 4 2020 wangxiao - 0.12.0-1 +- package init diff --git a/python-requests-kerberos.yaml b/python-requests-kerberos.yaml new file mode 100644 index 0000000..253ebee --- /dev/null +++ b/python-requests-kerberos.yaml @@ -0,0 +1,4 @@ +version_control: github +src_repo: requests-kerberos +tag_prefix: "^v" +seperator: "." diff --git a/requests-kerberos-0.12.0.tar.gz b/requests-kerberos-0.12.0.tar.gz new file mode 100644 index 0000000..26bd4f7 Binary files /dev/null and b/requests-kerberos-0.12.0.tar.gz differ