[python-velruse] Apply patch introducing a new extension point to the openid provider.
Ralph Bean
ralph at fedoraproject.org
Thu Oct 17 17:39:35 UTC 2013
commit 7ab1794b6dfe7b5f1c1dd1157fef8d43efeb6aa4
Author: Ralph Bean <rbean at redhat.com>
Date: Thu Oct 17 13:39:29 2013 -0400
Apply patch introducing a new extension point to the openid provider.
python-velruse-extract-extra-data.patch | 38 +++++++++++++++++++++++++++++++
python-velruse.spec | 8 +++++-
2 files changed, 45 insertions(+), 1 deletions(-)
---
diff --git a/python-velruse-extract-extra-data.patch b/python-velruse-extract-extra-data.patch
new file mode 100644
index 0000000..305dc74
--- /dev/null
+++ b/python-velruse-extract-extra-data.patch
@@ -0,0 +1,38 @@
+From ff3066dae721da3253ba5cba6e957ee37cf12942 Mon Sep 17 00:00:00 2001
+From: Patrick Uiterwijk <puiterwijk at redhat.com>
+Date: Thu, 17 Oct 2013 16:12:02 +0200
+Subject: [PATCH] Make it possible to extract extra data from the
+ OpenIDResponse object
+
+---
+ velruse/providers/openid.py | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+diff --git a/velruse/providers/openid.py b/velruse/providers/openid.py
+index ae35bfa..5c01329 100644
+--- a/velruse/providers/openid.py
++++ b/velruse/providers/openid.py
+@@ -253,6 +253,7 @@ def callback(self, request):
+ sreg_resp=sreg.SRegResponse.fromSuccessResponse(info),
+ ax_resp=ax.FetchResponse.fromSuccessResponse(info)
+ )
++ self._extract_extra_data(info, user_data)
+ # Did we get any OAuth info?
+ oauth = info.extensionResponse(
+ 'http://specs.openid.net/extensions/oauth/1.0', False
+@@ -273,6 +274,12 @@ def callback(self, request):
+ else:
+ raise ThirdPartyFailure("OpenID failed.")
+
++ def _extract_extra_data(self, info, user_data):
++ """
++ This function does nothing, but can be used in subclasses
++ to extract extra information from the OpenIDResponse object
++ """
++
+
+ class AttribAccess(object):
+ """Uniform attribute accessor for Simple Reg and Attribute Exchange
+--
+1.8.4
+
diff --git a/python-velruse.spec b/python-velruse.spec
index f8d5e8c..4fddd30 100644
--- a/python-velruse.spec
+++ b/python-velruse.spec
@@ -2,13 +2,15 @@
Name: python-%{modname}
Version: 1.0.3
-Release: 5%{?dist}
+Release: 6%{?dist}
Summary: Simplify third-party authentication for web applications
Group: Development/Libraries
License: MIT
URL: http://pypi.python.org/pypi/%{modname}
Source0: http://pypi.python.org/packages/source/v/%{modname}/%{modname}-%{version}.tar.gz
+# https://github.com/bbangert/velruse/pull/134
+Patch0: python-velruse-extract-extra-data.patch
BuildArch: noarch
@@ -70,6 +72,7 @@ language.
%prep
%setup -q -n %{modname}-%{version}
+%patch0 -p1
# Remove bundle egg info in case it exists
rm -rf %{modname}.egg-info
@@ -89,6 +92,9 @@ rm -rf %{modname}.egg-info
%{python_sitelib}/%{modname}-%{version}*
%changelog
+* Thu Oct 17 2013 Ralph Bean <rbean at redhat.com> - 1.0.3-6
+- Apply patch introducing an new extension point
+
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1.0.3-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
More information about the scm-commits
mailing list