redo how permissions are stored