in src/main/java/org/apache/sling/auth/oauth_client/impl/OidcAuthenticationHandler.java [148:175]
public OidcAuthenticationHandler(@Reference(policyOption = ReferencePolicyOption.GREEDY) @NotNull SlingRepository repository,
@NotNull BundleContext bundleContext, @Reference List<ClientConnection> connections,
@Reference OAuthStateManager stateManager,
Config config,
@Reference(cardinality = ReferenceCardinality.OPTIONAL, policyOption = ReferencePolicyOption.GREEDY) LoginCookieManager loginCookieManager,
@Reference(policyOption = ReferencePolicyOption.GREEDY) UserInfoProcessor userInfoProcessor
) {
this.repository = repository;
this.connections = connections.stream()
.collect(Collectors.toMap( ClientConnection::name, Function.identity()));
this.stateManager = stateManager;
this.idp = config.idp();
this.callbackUri = config.callbackUri();
this.defaultRedirect = config.defaultRedirect();
this.loginCookieManager = loginCookieManager;
this.defaultConnectionName = config.defaultConnectionName();
this.userInfoProcessor = userInfoProcessor;
this.userInfoEnabled = config.userInfoEnabled();
logger.debug("activate: registering ExternalIdentityProvider");
bundleContext.registerService(
new String[]{ExternalIdentityProvider.class.getName(), CredentialsSupport.class.getName()}, new OidcIdentityProvider(idp),
null);
logger.info("OidcAuthenticationHandler successfully activated");
}