Search in sources :

Example 1 with AnyOfAuthzModule

use of org.forgerock.openam.core.rest.session.AnyOfAuthzModule in project OpenAM by OpenRock.

the class CoreRestGuiceModule method getSessionResourceAuthzModule.

@Provides
@Inject
public AnyOfAuthzModule getSessionResourceAuthzModule(SSOTokenManager ssoTokenManager, PrivilegeAuthzModule privilegeAuthzModule, AdminOnlyAuthzModule adminOnlyAuthzModule) {
    SessionResourceAuthzModule sessionResourceAuthzModule = new SessionResourceAuthzModule(ssoTokenManager);
    List<CrestAuthorizationModule> authzList = new ArrayList<>(3);
    authzList.add(adminOnlyAuthzModule);
    authzList.add(privilegeAuthzModule);
    authzList.add(sessionResourceAuthzModule);
    return new AnyOfAuthzModule(authzList);
}
Also used : SessionResourceAuthzModule(org.forgerock.openam.core.rest.session.SessionResourceAuthzModule) ArrayList(java.util.ArrayList) AnyOfAuthzModule(org.forgerock.openam.core.rest.session.AnyOfAuthzModule) CrestAuthorizationModule(org.forgerock.authz.filter.crest.api.CrestAuthorizationModule) Inject(javax.inject.Inject) Provides(com.google.inject.Provides)

Aggregations

Provides (com.google.inject.Provides)1 ArrayList (java.util.ArrayList)1 Inject (javax.inject.Inject)1 CrestAuthorizationModule (org.forgerock.authz.filter.crest.api.CrestAuthorizationModule)1 AnyOfAuthzModule (org.forgerock.openam.core.rest.session.AnyOfAuthzModule)1 SessionResourceAuthzModule (org.forgerock.openam.core.rest.session.SessionResourceAuthzModule)1