Class RestAuthenticationContextImpl
java.lang.Object
com.atlassian.bamboo.plugins.rest.security.RestAuthenticationContextImpl
- All Implemented Interfaces:
RestAuthenticationContext
A SAL implementation of authentication context to retrieve the principal and authentication status.
This is result of REST v2 migration, which didn't offer a replacement for the old
com.atlassian.plugins.rest.common.security.AuthenticationContext.
- Since:
- 10.0
-
Constructor Summary
ConstructorDescriptionRestAuthenticationContextImpl
(com.atlassian.sal.api.user.UserManager userManager) -
Method Summary
-
Constructor Details
-
RestAuthenticationContextImpl
@Inject public RestAuthenticationContextImpl(com.atlassian.sal.api.user.UserManager userManager)
-
-
Method Details
-
getPrincipal
- Specified by:
getPrincipal
in interfaceRestAuthenticationContext
- Returns:
- the authenticated principal,
null
if none is authenticated.
-
isAuthenticated
public boolean isAuthenticated()- Specified by:
isAuthenticated
in interfaceRestAuthenticationContext
- Returns:
true
if the principal is authenticated,false
otherwise.
-