@Override
    public boolean shouldProceedWithMultifactorProviderSelection(final RequestContext requestContext) {
        val authentication = WebUtils.getAuthentication(requestContext);
        val request = WebUtils.getHttpServletRequestFromExternalWebflowContext(requestContext);
        val response = WebUtils.getHttpServletResponseFromExternalWebflowContext(requestContext);
        val principal = authentication.getPrincipal().getId();

        LOGGER.trace("Retrieving trusted authentication records for [{}]", principal);
        val results = mfaTrustEngine.get(principal);
        
        val fingerprint = deviceFingerprintStrategy.determineFingerprint(authentication, request, response);
        LOGGER.trace("Checking trusted authentication records for [{}] that matches [{}]", principal, fingerprint);

        val trustedDevices = results.stream().filter(entry -> entry.getDeviceFingerprint().equals(fingerprint)).toList();
        if (trustedDevices.isEmpty()) {
            LOGGER.debug("No trusted authentication records could be found for [{}] to match the current device fingerprint", principal);
            return true;
        }
        val provider = requestContext.getCurrentEvent().getAttributes()
            .get(MultifactorAuthenticationProvider.class.getName(), MultifactorAuthenticationProvider.class);
        val matchingDevice = trustedDevices
            .stream()
            .filter(device -> StringUtils.isNotBlank(device.getMultifactorAuthenticationProvider()))
            .filter(device -> provider.matches(device.getMultifactorAuthenticationProvider()))
            .findFirst();
        if (matchingDevice.isPresent()) {
            val mfaProvider = MultifactorAuthenticationUtils.getMultifactorAuthenticationProviderById(
                matchingDevice.get().getMultifactorAuthenticationProvider(), requestContext.getActiveFlow().getApplicationContext());
            requestContext.getFlashScope().put("mfaProvider", mfaProvider.orElseThrow());
            return false;
        }
        return true;
    }
This is {@link MultifactorAuthenticationTrustProviderSelectionCriteria}.

@author Misagh Moayyed
@since 7.0.0
support/cas-server-support-trusted-mfa-core/src/main/java/org/apereo/cas/trusted/web/flow/MultifactorAuthenticationTrustProviderSelectionCriteria.java