code: protected Set<Event> resolveSingleMultifactorProvider(final Optional<RequestContext> context, final RegisteredService service,
                                                            final Principal principal,
                                                            final Collection<MultifactorAuthenticationProvider> providers) {
          val globalPrincipalAttributeValueRegex = casProperties.getAuthn().getMfa().getGlobalPrincipalAttributeValueRegex();
          val provider = providers.iterator().next();
          LOGGER.trace("Found a single multifactor provider [{}] in the application context", provider);
          val attributeNames = commaDelimitedListToSet(casProperties.getAuthn().getMfa().getGlobalPrincipalAttributeNameTriggers());
          return multifactorAuthenticationProviderResolver.resolveEventViaPrincipalAttribute(principal, attributeNames, service, context, providers,
              input -> input != null && input.matches(globalPrincipalAttributeValueRegex));
      }
docs: Resolve single multifactor provider set.
  
  @param context   the context
  @param service   the service
  @param principal the principal
  @param providers the providers
  @return the set