[JENKINS-14843] Allow extensions to determine whether it is appropriate for specific security realms