performance improvement for with_instance_security scope