From 42bcd9c28c8afbb84fa715c584d612159dafbb7c Mon Sep 17 00:00:00 2001 From: Alexander Kryklia Date: Mon, 2 Sep 2013 11:45:22 +0300 Subject: [PATCH] updated comment --- common/lib/xmodule/xmodule/lti_module.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/common/lib/xmodule/xmodule/lti_module.py b/common/lib/xmodule/xmodule/lti_module.py index 865bf4c89b..9b3f5fbf72 100644 --- a/common/lib/xmodule/xmodule/lti_module.py +++ b/common/lib/xmodule/xmodule/lti_module.py @@ -1,5 +1,7 @@ """ Module that allows to insert LTI tools to page. +Module uses current 0.14.2 version of requests (oauth part). +Please update code when upgrading requests. """ import logging @@ -80,9 +82,9 @@ class LTIModule(LTIFields, XModule): # 0.14.2 (current) version of requests oauth library encodes signature, # with 'Content-Type': 'application/x-www-form-urlencoded' - # so '='' becomes '%3D', but server waits for unencoded signature. - # Decode signature back: - # may be it may be encoded by browser again... check + # so '='' becomes '%3D'. + # We send form via browser, so browser will encode it again, + # So we need to decode signature back: params[u'oauth_signature'] = urllib.unquote(params[u'oauth_signature']).decode('utf8') return params