Autopatch to migrate to new permission system