update permission checking