Class DefaultReverseProxyAuthenticator
java.lang.Object
org.jenkinsci.plugins.reverse_proxy_auth.auth.DefaultReverseProxyAuthenticator
- All Implemented Interfaces:
ReverseProxyAuthenticator
,org.springframework.beans.factory.Aware
,org.springframework.beans.factory.InitializingBean
,org.springframework.context.MessageSourceAware
public class DefaultReverseProxyAuthenticator
extends Object
implements ReverseProxyAuthenticator, org.springframework.beans.factory.InitializingBean, org.springframework.context.MessageSourceAware
- Author:
- Wilder Rodrigues (wrodrigues@schubergphilis.com)
-
Field Summary
Modifier and TypeFieldDescriptionprotected org.springframework.context.support.MessageSourceAccessor
-
Constructor Summary
ConstructorDescriptionDefaultReverseProxyAuthenticator
(String username, Collection<? extends org.springframework.security.core.GrantedAuthority> authorities) -
Method Summary
Modifier and TypeMethodDescriptionvoid
authenticate
(String username, String password) Authenticates as a user and obtains additional user information from the directory.void
setMessageSource
(org.springframework.context.MessageSource messageSource)
-
Field Details
-
messages
protected org.springframework.context.support.MessageSourceAccessor messages
-
-
Constructor Details
-
DefaultReverseProxyAuthenticator
public DefaultReverseProxyAuthenticator(String username, @CheckForNull Collection<? extends org.springframework.security.core.GrantedAuthority> authorities)
-
-
Method Details
-
setMessageSource
public void setMessageSource(@NonNull org.springframework.context.MessageSource messageSource) - Specified by:
setMessageSource
in interfaceorg.springframework.context.MessageSourceAware
-
afterPropertiesSet
public void afterPropertiesSet()- Specified by:
afterPropertiesSet
in interfaceorg.springframework.beans.factory.InitializingBean
-
authenticate
public ReverseProxyUserDetails authenticate(String username, String password) throws DataAccessException Description copied from interface:ReverseProxyAuthenticator
Authenticates as a user and obtains additional user information from the directory.- Specified by:
authenticate
in interfaceReverseProxyAuthenticator
- Parameters:
username
- the user's login name (not their DN).password
- the user's password supplied at login.- Returns:
- the details of the successfully authenticated user.
- Throws:
DataAccessException
-