Class RecoveryModeAwareApplicationService
java.lang.Object
com.atlassian.crowd.manager.application.ApplicationServiceGeneric
com.atlassian.crowd.manager.recovery.RecoveryModeAwareApplicationService
- All Implemented Interfaces:
ApplicationService
An extension of
ApplicationServiceGeneric that supports recovery mode. When recovery mode is activated,
an extra directory as provided by the RecoveryModeService will
be prepended to the list of directories for any application.- Since:
- 2.7.2
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.atlassian.crowd.manager.application.ApplicationService
ApplicationService.MembershipsIterable -
Constructor Summary
ConstructorsConstructorDescriptionRecoveryModeAwareApplicationService(DirectoryManager directoryManager, SearchStrategyFactory searchStrategyFactory, PermissionManager permissionManager, com.atlassian.event.api.EventPublisher eventPublisher, EventStore eventStore, WebhookRegistry webhookRegistry, AvatarProvider avatarProvider, ApplicationFactory applicationFactory, RecoveryModeService recoveryModeService, AuthenticationOrderOptimizer authenticationOrderOptimizer, AccessFilterFactory accessFilterFactory, CrowdDarkFeatureManager crowdDarkFeatureManager) -
Method Summary
Modifier and TypeMethodDescriptiongetActiveDirectories(Application application) Given anapplication, retrieve all active directories associated with it.booleanisUserAuthorised(Application application, User user) Returnstrueif the user is permitted to attempt authentication with the application.booleanisUserAuthorised(Application application, String username) Returnstrueif the user is permitted to attempt authentication with the application.Methods inherited from class com.atlassian.crowd.manager.application.ApplicationServiceGeneric
addAllUsers, addGroup, addGroupToGroup, addUser, addUser, addUserToGroup, authenticateUser, authenticateUser, createPagedGroupSearcher, createPagedUserSearcher, expireAllPasswords, findGroupByName, findGroupWithAttributesByName, findRemoteUserByName, findUserByKey, findUserByName, findUserWithAttributesByKey, findUserWithAttributesByName, findWebhookById, getCapabilitiesForNewUsers, getCurrentEventToken, getMemberships, getNewEvents, getUserAvatar, getUserAvatarLink, isGroupDirectGroupMember, isGroupNestedGroupMember, isUserDirectGroupMember, isUserNestedGroupMember, registerWebhook, removeGroup, removeGroupAttributes, removeGroupFromGroup, removeUser, removeUserAttributes, removeUserFromGroup, renameUser, searchDirectGroupRelationships, searchGroups, searchNestedGroupRelationships, searchUsers, setUserStatusLocally, storeGroupAttributes, storeUserAttributes, unregisterWebhook, updateGroup, updateUser, updateUserCredential, userAuthenticated, validateUpdateUser
-
Constructor Details
-
RecoveryModeAwareApplicationService
public RecoveryModeAwareApplicationService(DirectoryManager directoryManager, SearchStrategyFactory searchStrategyFactory, PermissionManager permissionManager, com.atlassian.event.api.EventPublisher eventPublisher, EventStore eventStore, WebhookRegistry webhookRegistry, AvatarProvider avatarProvider, ApplicationFactory applicationFactory, RecoveryModeService recoveryModeService, AuthenticationOrderOptimizer authenticationOrderOptimizer, AccessFilterFactory accessFilterFactory, CrowdDarkFeatureManager crowdDarkFeatureManager)
-
-
Method Details
-
getActiveDirectories
Description copied from class:ApplicationServiceGenericGiven anapplication, retrieve all active directories associated with it.- Overrides:
getActiveDirectoriesin classApplicationServiceGeneric- Parameters:
application- application to query- Returns:
- list of active directories associated with
application
-
isUserAuthorised
Description copied from interface:ApplicationServiceReturnstrueif the user is permitted to attempt authentication with the application. If the user could not be found, thenfalseis returned.For a user to have access to an application:
- the Application must be active.
- and either:
- the User is stored in a directory which is associated to the Application and the "allow all to authenticate" flag is true.
- the User is a member of a Group that is allowed to authenticate with the Application and both the User and Group are from the same RemoteDirectory.
- Specified by:
isUserAuthorisedin interfaceApplicationService- Overrides:
isUserAuthorisedin classApplicationServiceGeneric- Parameters:
application- application user is authenticating againstusername- username- Returns:
true</tt> if the user is permitted to attempt authentication with the application, otherwise <tt>false. If the user could not be found,falsewill be returned.
-
isUserAuthorised
Description copied from interface:ApplicationServiceReturnstrueif the user is permitted to attempt authentication with the application. If the user could not be found, thenfalseis returned.For a user to have access to an application:
- the Application must be active.
- and either:
- the User is stored in a directory which is associated to the Application and the "allow all to authenticate" flag is true.
- the User is a member of a Group that is allowed to authenticate with the Application and both the User and Group are from the same RemoteDirectory.
- Specified by:
isUserAuthorisedin interfaceApplicationService- Overrides:
isUserAuthorisedin classApplicationServiceGeneric- Parameters:
application- application user is authenticating againstuser- the user that will be checked- Returns:
true</tt> if the user is permitted to attempt authentication with the application, otherwise <tt>false. If the user could not be found,falsewill be returned.
-