@Bean
        @ConditionalOnMissingBean(name = "webAuthnServer")
        @RefreshScope(proxyMode = ScopedProxyMode.DEFAULT)
        public WebAuthnServer webAuthnServer(
            final CasConfigurationProperties casProperties,
            @Qualifier(WebAuthnCredentialRepository.BEAN_NAME) final WebAuthnCredentialRepository webAuthnCredentialRepository,
            @Qualifier("webAuthnMetadataService") final AttestationTrustSource webAuthnMetadataService,
            @Qualifier(SessionManager.BEAN_NAME) final SessionManager webAuthnSessionManager) throws Exception {

            val webAuthn = casProperties.getAuthn().getMfa().getWebAuthn().getCore();
            val serverName = casProperties.getServer().getName();
            val defaultRelyingPartyId = RelyingPartyIdentity
                .builder()
                .id(StringUtils.defaultIfBlank(webAuthn.getRelyingPartyId(), new URI(serverName).toURL().getHost()))
                .name(StringUtils.defaultIfBlank(webAuthn.getRelyingPartyName(), "CAS"))
                .build();

            val origins = new LinkedHashSet<String>();
            origins.add(serverName);
            if (StringUtils.isNotBlank(webAuthn.getAllowedOrigins())) {
                origins.addAll(org.springframework.util.StringUtils.commaDelimitedListToSet(webAuthn.getAllowedOrigins()));
            }

            val conveyance = AttestationConveyancePreference.valueOf(webAuthn.getAttestationConveyancePreference().toUpperCase(Locale.ENGLISH));
            val appId = new AppId(StringUtils.defaultIfBlank(webAuthn.getApplicationId(), serverName));
            val relyingParty = RelyingParty.builder()
                .identity(defaultRelyingPartyId)
                .credentialRepository(webAuthnCredentialRepository)
                .origins(origins)
                .attestationConveyancePreference(conveyance)
                .attestationTrustSource(webAuthnMetadataService)
                .allowUntrustedAttestation(webAuthn.isAllowUntrustedAttestation())
                .validateSignatureCounter(webAuthn.isValidateSignatureCounter())
                .appId(appId)
                .build();
            return new WebAuthnServer(webAuthnCredentialRepository,
                newCache(WEBAUTHN_SERVER_CACHE_SIZE), newCache(WEBAUTHN_SERVER_CACHE_SIZE), relyingParty,
                webAuthnSessionManager, casProperties);
        }
This is {@link WebAuthnConfiguration}.

@author Misagh Moayyed
@since 6.1.0
support/cas-server-support-webauthn/src/main/java/org/apereo/cas/config/WebAuthnConfiguration.java