Commit 1294a57f authored by Vincent Pelletier's avatar Vincent Pelletier Committed by Kazuhiko Shiozaki

Products.ERP5.ERP5Site: Add a method to disable AuthorisationExtractor

parent 0402e6b0
......@@ -619,6 +619,16 @@ class ERP5Site(ResponseHeaderGenerator, FolderMixIn, PortalObjectBase, CacheCook
AutorisationExtractorBeforeTraverseHook.handle,
)
security.declareProtected(Permissions.ManagePortal, 'disableAuthorisationExtractor')
def disableAuthorisationExtractor(self):
"""
Disable AutorisationExtractorBeforeTraverseHook.
"""
BeforeTraverse.unregisterBeforeTraverse(
self,
AutorisationExtractorBeforeTraverseHook.handle,
)
security.declareProtected(Permissions.ManagePortal, 'isAuthorisationExtractorEnabled')
def isAuthorisationExtractorEnabled(self):
"""
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment