{"record":{"id":"1ac8923e00c99700","repo":"quarkusio/quarkus","slug":"no-identityproviders-were-registered-to-handle-aut","errorCode":null,"errorMessage":"No IdentityProviders were registered to handle AuthenticationRequest %s","messagePattern":"No IdentityProviders were registered to handle AuthenticationRequest (.+?)","errorType":"exception","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"extensions/security/runtime/src/main/java/io/quarkus/security/runtime/QuarkusIdentityProviderManagerImpl.java","lineNumber":107,"sourceCode":"                        }\n                    });\n        }\n        return authenticated;\n    }\n\n    /**\n     * Attempts to create an authenticated identity for the provided {@link AuthenticationRequest} in a blocking manner\n     * <p>\n     * If authentication succeeds the resulting identity will be augmented with any configured {@link SecurityIdentityAugmentor}\n     * instances that have been registered.\n     *\n     * @param request The authentication request\n     * @return The first identity provider that was registered with this type\n     */\n    public SecurityIdentity authenticateBlocking(AuthenticationRequest request) {\n        var providers = this.providers.get(request.getClass());\n        if (providers == null) {\n            throw new IllegalArgumentException(\n                    \"No IdentityProviders were registered to handle AuthenticationRequest \" + request);\n        }\n        return handleProviders(providers, request).await().indefinitely();\n    }\n\n    private Uni<SecurityIdentity> handleProviders(\n            List<IdentityProvider<? extends AuthenticationRequest>> providers, AuthenticationRequest request) {\n        return handleProvider(0, providers, request)\n                .onItem()\n                .transformToUni(new Function<SecurityIdentity, Uni<? extends SecurityIdentity>>() {\n                    @Override\n                    public Uni<? extends SecurityIdentity> apply(SecurityIdentity securityIdentity) {\n                        return handleIdentityFromProvider(0, securityIdentity, request.getAttributes());\n                    }\n                });\n    }\n\n    private Uni<SecurityIdentity> handleProvider(int pos, List<IdentityProvider<? extends AuthenticationRequest>> providers,","sourceCodeStart":89,"sourceCodeEnd":125,"githubUrl":"https://github.com/quarkusio/quarkus/blob/e1c734241f34c7919086ceb4c9262b4a58f6de44/extensions/security/runtime/src/main/java/io/quarkus/security/runtime/QuarkusIdentityProviderManagerImpl.java#L89-L125","documentation":"QuarkusIdentityProviderManagerImpl looks up registered IdentityProvider instances keyed by the AuthenticationRequest subclass. When no provider is registered for the concrete request class, authentication cannot proceed and an IllegalArgumentException is thrown. The provider registry is populated at build time by security extensions.","triggerScenarios":"Calling identityProviderManager.authenticateBlocking(request) (or the reactive variant) with an AuthenticationRequest type for which no IdentityProvider was registered — e.g. passing a custom request type or a request type from an extension that is not installed.","commonSituations":"Manually invoking the IdentityProviderManager in custom filters with a wrong request type; an extension providing authentication (e.g. OIDC, properties-based IdentityProvider) is missing from the app; tests constructing a manager without providers.","solutions":["Ensure the extension that owns the AuthenticationRequest type is present and configured (e.g. quarkus-oidc, or quarkus-elytron-security / quarkus-security with a registered IdentityProvider).","In custom code, authenticate with a supported request type or implement and register an IdentityProvider<YourRequestType> via a build step.","Verify with quarkus.security that the provider is registered; in tests, add the provider to the builder before build()."],"exampleFix":"// before\nSecurityIdentity identity = ipm.authenticateBlocking(new TokenAuthenticationRequest(token)); // no provider for this type\n// after\nSecurityIdentity identity = ipm.authenticateBlocking(new AuthenticationRequestImpl(username, password));\n// or register:\n// builder.addProvider(new MyCustomIdentityProvider());","handlingStrategy":"try-catch","validationCode":"// verify provider availability when possible\nboolean hasProvider = providersStream().anyMatch(p -> p.getRequestType().equals(request.getClass()));\nif (!hasProvider) throw new IllegalArgumentException(\"no provider for \" + request.getClass());","typeGuard":null,"tryCatchPattern":"try {\n    SecurityIdentity id = ipm.authenticateBlocking(request);\n} catch (IllegalArgumentException e) {\n    if (e.getMessage().startsWith(\"No IdentityProviders\")) {\n        // fall back / report unsupported auth mechanism\n    } else throw e;\n}","preventionTips":["Install the extension owning the AuthenticationRequest type","Register custom IdentityProviders at build time","Prefer CDI-injected manager over manual construction"],"tags":["quarkus","security","authentication","identity-provider"],"backgroundTag":"missing-identity-provider","analyzedSha":"e1c734241f34c7919086ceb4c9262b4a58f6de44","analyzedAt":"2026-09-05T17:01:29.979Z","contentChangedAt":"2026-09-05T17:01:29.979Z","schemaVersion":2},"datasetVersion":"2026-09-12T22:17:10.623Z"}