Commit c6fcf3e8 authored by Maurits van Rees's avatar Maurits van Rees

Explicitly require Manager role for `AltDatabaseManager`.

If you use experimental.publishtraverse and try to call manage_pack,
it warns that the object (the manage_pack function) has no roles.
In strict mode it will fail.
This is an indication that the function *might* be available for anonymous users.
That is not the case here, but being strict seems good.
parent d8693682
...@@ -8,6 +8,7 @@ http://docs.zope.org/zope2/ ...@@ -8,6 +8,7 @@ http://docs.zope.org/zope2/
2.13.27 (unreleased) 2.13.27 (unreleased)
-------------------- --------------------
- Explicitly require Manager role for ``AltDatabaseManager``. [maurits]
2.13.26 (2017-02-20) 2.13.26 (2017-02-20)
......
...@@ -482,6 +482,7 @@ class ApplicationManager(Folder,CacheManager): ...@@ -482,6 +482,7 @@ class ApplicationManager(Folder,CacheManager):
class AltDatabaseManager(DatabaseManager, CacheManager): class AltDatabaseManager(DatabaseManager, CacheManager):
""" Database management DBTab-style """ Database management DBTab-style
""" """
__roles__ = ('Manager', )
db_name = ApplicationManager.db_name.im_func db_name = ApplicationManager.db_name.im_func
db_size = ApplicationManager.db_size.im_func db_size = ApplicationManager.db_size.im_func
manage_pack = ApplicationManager.manage_pack.im_func manage_pack = ApplicationManager.manage_pack.im_func
......
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