You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@allura.apache.org by ke...@apache.org on 2017/07/18 17:08:15 UTC

allura git commit: Skips antispam decoding on plaintext fields

Repository: allura
Updated Branches:
  refs/heads/master 97f59a158 -> cc9b8663c


Skips antispam decoding on plaintext fields


Project: http://git-wip-us.apache.org/repos/asf/allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/allura/commit/cc9b8663
Tree: http://git-wip-us.apache.org/repos/asf/allura/tree/cc9b8663
Diff: http://git-wip-us.apache.org/repos/asf/allura/diff/cc9b8663

Branch: refs/heads/master
Commit: cc9b8663c452a4377ddb14824265bf5a872aac47
Parents: 97f59a1
Author: Kenton Taylor <kt...@slashdotmedia.com>
Authored: Tue Jul 18 17:08:06 2017 +0000
Committer: Kenton Taylor <kt...@slashdotmedia.com>
Committed: Tue Jul 18 17:08:06 2017 +0000

----------------------------------------------------------------------
 Allura/allura/lib/utils.py                | 6 +++++-
 Allura/allura/lib/widgets/auth_widgets.py | 2 +-
 2 files changed, 6 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/allura/blob/cc9b8663/Allura/allura/lib/utils.py
----------------------------------------------------------------------
diff --git a/Allura/allura/lib/utils.py b/Allura/allura/lib/utils.py
index d9f7ced..3fa269e 100644
--- a/Allura/allura/lib/utils.py
+++ b/Allura/allura/lib/utils.py
@@ -370,7 +370,11 @@ class AntiSpam(object):
                 if obj.spinner != expected_spinner:
                     raise ValueError('Bad spinner value')
                 for k in new_params.keys():
-                    new_params[obj.dec(k)] = new_params.pop(k)
+                    try:
+                        new_params[obj.dec(k)] = new_params[k]
+                        new_params.pop(k)
+                    except:
+                        pass
                 for fldno in range(obj.num_honey):
                     value = new_params.pop('honey%s' % fldno)
                     if value:

http://git-wip-us.apache.org/repos/asf/allura/blob/cc9b8663/Allura/allura/lib/widgets/auth_widgets.py
----------------------------------------------------------------------
diff --git a/Allura/allura/lib/widgets/auth_widgets.py b/Allura/allura/lib/widgets/auth_widgets.py
index 7bac270..e25c029 100644
--- a/Allura/allura/lib/widgets/auth_widgets.py
+++ b/Allura/allura/lib/widgets/auth_widgets.py
@@ -42,7 +42,7 @@ class LoginForm(ForgeForm):
             }),
             ew.PasswordField(name=g.antispam.enc('password'), label='Password'),
             ew.Checkbox(
-                name='rememberme',
+                name=g.antispam.enc('rememberme'),
                 label='Remember Me',
                 attrs={'style': 'margin-left: 162px;'}),
             ew.HiddenField(name='return_to'),