summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris McDonough <chrism@agendaless.com>2009-05-06 05:25:53 +0000
committerChris McDonough <chrism@agendaless.com>2009-05-06 05:25:53 +0000
commit39cbad11badcb2e31df39da18cbe2c57a27281ac (patch)
tree15ee5a87102680461b5e56fc79b6fc78a325f06a
parent226b49247817931b5f932980538c74dd8835491e (diff)
downloadpyramid-39cbad11badcb2e31df39da18cbe2c57a27281ac.tar.gz
pyramid-39cbad11badcb2e31df39da18cbe2c57a27281ac.tar.bz2
pyramid-39cbad11badcb2e31df39da18cbe2c57a27281ac.zip
Thinko.
-rw-r--r--repoze/bfg/security.py1
-rw-r--r--repoze/bfg/tests/test_security.py2
2 files changed, 2 insertions, 1 deletions
diff --git a/repoze/bfg/security.py b/repoze/bfg/security.py
index bfc43d752..4b28811cc 100644
--- a/repoze/bfg/security.py
+++ b/repoze/bfg/security.py
@@ -260,6 +260,7 @@ class InheritingACLSecurityPolicy(object):
# clear the entire allowed set, as we've hit a
# deny of Everyone ala (Deny, Everyone, ALL)
allowed = set()
+ break
elif ace_principal in allowed:
allowed.remove(ace_principal)
diff --git a/repoze/bfg/tests/test_security.py b/repoze/bfg/tests/test_security.py
index 20ec1d4db..03a466e7c 100644
--- a/repoze/bfg/tests/test_security.py
+++ b/repoze/bfg/tests/test_security.py
@@ -356,7 +356,7 @@ class TestInheritingACLSecurityPolicy(unittest.TestCase):
policy = self._makeOne(lambda *arg: None)
result = sorted(
policy.principals_allowed_by_permission(context, 'read'))
- self.assertEqual(result, ['chrism', 'other'])
+ self.assertEqual(result, ['chrism'])
def test_principals_allowed_by_permission(self):
from repoze.bfg.security import Allow