mirror of
https://github.com/evennia/evennia.git
synced 2026-04-07 00:45:22 +02:00
OBS: You'll need to resync/rebuild your database!
- This implements an updated, clearer and more robust access system. The policy is now to lock that which is not explicitly left open. - Permission strings -> Lock strings. Separating permissions and locks makes more sense security-wise - No more permissiongroup table; permissions instead use a simple tuple PERMISSIONS_HIERARCHY to define an access hierarchy - Cleaner lock-definition syntax, all based on function calls. - New objects/players/channels get a default security policy during creation (set through typeclass) As part of rebuilding and testing the new lock/permission system I got into testing and debugging several other systems, fixing some outstanding issues: - @reload now fully updates the database asynchronously. No need to reboot server when changing cmdsets - Dozens of new test suites added for about 30 commands so far - Help for channels made more clever and informative.
This commit is contained in:
parent
c2030c2c0c
commit
08b3de9e5e
49 changed files with 1714 additions and 1877 deletions
|
|
@ -47,7 +47,6 @@ from django.utils.encoding import smart_str
|
|||
from src.server.sessionhandler import SESSIONS
|
||||
from src.players import manager
|
||||
from src.typeclasses.models import Attribute, TypedObject
|
||||
from src.permissions import permissions
|
||||
from src.utils import logger
|
||||
|
||||
#------------------------------------------------------------
|
||||
|
|
@ -105,7 +104,6 @@ class PlayerDB(TypedObject):
|
|||
|
||||
"""
|
||||
|
||||
|
||||
#
|
||||
# PlayerDB Database model setup
|
||||
#
|
||||
|
|
@ -237,16 +235,6 @@ class PlayerDB(TypedObject):
|
|||
return self.user.is_superuser
|
||||
is_superuser = property(is_superuser_get)
|
||||
|
||||
def set_perm(self, perm):
|
||||
"Shortcuts to set permissions, replacing old ones"
|
||||
return permissions.set_perm(self, perm)
|
||||
def add_perm(self, perm):
|
||||
"Add permissions to the old ones"
|
||||
return permissions.add_perm(self, perm)
|
||||
def del_perm(self, perm):
|
||||
"Delete permission from old ones"
|
||||
return permissions.del_perm(self, perm)
|
||||
|
||||
#
|
||||
# PlayerDB class access methods
|
||||
#
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue