# Uses of Class
net.shibboleth.idp.authn.context.UsernamePasswordContext

Packages that use UsernamePasswordContext
Package
Description
net.shibboleth.idp.authn
APIs related to the authentication of a subject.
net.shibboleth.idp.authn.context
Context classes for managing authentication-related state.
net.shibboleth.idp.authn.impl
Implementation of various authentication actions.

## Uses of UsernamePasswordContext in net.shibboleth.idp.authn

Fields in net.shibboleth.idp.authn with type parameters of type UsernamePasswordContext
Modifier and Type
Field
Description
`private Function<ProfileRequestContext,UsernamePasswordContext>`
AbstractUsernamePasswordCredentialValidator.`usernamePasswordContextLookupStrategy`
Lookup strategy for UP context.
Methods in net.shibboleth.idp.authn with parameters of type UsernamePasswordContext
Modifier and Type
Method
Description
`protected abstract Subject`
AbstractUsernamePasswordCredentialValidator.`doValidate(ProfileRequestContext profileRequestContext, AuthenticationContext authenticationContext, UsernamePasswordContext usernamePasswordContext, CredentialValidator.WarningHandler warningHandler, CredentialValidator.ErrorHandler errorHandler)`
Override method for subclasses to use to perform the actual validation.
`protected Subject`
AbstractUsernamePasswordCredentialValidator.`populateSubject(Subject subject, UsernamePasswordContext usernamePasswordContext)`
Decorate the subject with "standard" content from the validation and clean up as instructed.
Method parameters in net.shibboleth.idp.authn with type arguments of type UsernamePasswordContext
Modifier and Type
Method
Description
`void`
AbstractUsernamePasswordCredentialValidator.`setUsernamePasswordContextLookupStrategy(Function<ProfileRequestContext,UsernamePasswordContext> strategy)`
Set the lookup strategy to locate the `UsernamePasswordContext`.

## Uses of UsernamePasswordContext in net.shibboleth.idp.authn.context

Methods in net.shibboleth.idp.authn.context that return UsernamePasswordContext
Modifier and Type
Method
Description
`UsernamePasswordContext`
UsernamePasswordContext.`setPassword(String pass)`
Sets the password associated with the username.
`UsernamePasswordContext`
UsernamePasswordContext.`setTransformedUsername(String name)`
Sets the transformed username.
`UsernamePasswordContext`
UsernamePasswordContext.`setUsername(String name)`
Sets the username and resets the transformed version to be identical.

## Uses of UsernamePasswordContext in net.shibboleth.idp.authn.impl

Fields in net.shibboleth.idp.authn.impl declared as UsernamePasswordContext
Modifier and Type
Field
Description
`private final UsernamePasswordContext`
JAASCredentialValidator.SimpleCallbackHandler.`context`
Context for call.
`private final UsernamePasswordContext`
KerberosCredentialValidator.SimpleCallbackHandler.`context`
Context for call.
`private UsernamePasswordContext`
PrePopulateUsername.`usernameContext`
Context to operate on.
Fields in net.shibboleth.idp.authn.impl with type parameters of type UsernamePasswordContext
Modifier and Type
Field
Description
`private Function<ProfileRequestContext,UsernamePasswordContext>`
ExtractUsernamePasswordFromBasicAuth.`contextCreationStrategy`
Creation strategy for UsernamePasswordContext.
`private Function<ProfileRequestContext,UsernamePasswordContext>`
PrePopulateUsername.`usernamePasswordContextCreationStrategy`
Strategy used to create/locate the `UsernamePasswordContext` to operate on.
Methods in net.shibboleth.idp.authn.impl with parameters of type UsernamePasswordContext
Modifier and Type
Method
Description
`private boolean`
HTPasswdCredentialValidator.`authenticate(UsernamePasswordContext usernamePasswordContext, String storedPassword)`
Compare input password to stored value.
`private Subject`
JAASCredentialValidator.`authenticate(String loginConfigName, UsernamePasswordContext usernamePasswordContext)`
Create a JAAS configuration and attempt a login with it.
`protected Subject`
HTPasswdCredentialValidator.`doValidate(ProfileRequestContext profileRequestContext, AuthenticationContext authenticationContext, UsernamePasswordContext usernamePasswordContext, CredentialValidator.WarningHandler warningHandler, CredentialValidator.ErrorHandler errorHandler)`
Override method for subclasses to use to perform the actual validation.
`protected Subject`
JAASCredentialValidator.`doValidate(ProfileRequestContext profileRequestContext, AuthenticationContext authenticationContext, UsernamePasswordContext usernamePasswordContext, CredentialValidator.WarningHandler warningHandler, CredentialValidator.ErrorHandler errorHandler)`
Override method for subclasses to use to perform the actual validation.
`protected Subject`
KerberosCredentialValidator.`doValidate(ProfileRequestContext profileRequestContext, AuthenticationContext authenticationContext, UsernamePasswordContext usernamePasswordContext, CredentialValidator.WarningHandler warningHandler, CredentialValidator.ErrorHandler errorHandler)`
Override method for subclasses to use to perform the actual validation.
`protected Subject`
LDAPCredentialValidator.`doValidate(ProfileRequestContext profileRequestContext, AuthenticationContext authenticationContext, UsernamePasswordContext usernamePasswordContext, CredentialValidator.WarningHandler warningHandler, CredentialValidator.ErrorHandler errorHandler)`
Override method for subclasses to use to perform the actual validation.
`protected Subject`
JAASCredentialValidator.`populateSubject(Subject subject, Subject derivedSubject, UsernamePasswordContext usernamePasswordContext)`
Finish decorating the result.
`protected Subject`
KerberosCredentialValidator.`populateSubject(Subject subject, UsernamePasswordContext usernamePasswordContext)`
Decorate the subject with "standard" content from the validation and clean up as instructed.
`protected Subject`
LDAPCredentialValidator.`populateSubject(UsernamePasswordContext usernamePasswordContext, AuthenticationResponse ldapResponse)`
Builds a new `Subject` populated with the necessary data.
Method parameters in net.shibboleth.idp.authn.impl with type arguments of type UsernamePasswordContext
Modifier and Type
Method
Description
`void`
ExtractUsernamePasswordFromBasicAuth.`setUsernamePasswordContextCreationStrategy(Function<ProfileRequestContext,UsernamePasswordContext> strategy)`
Sets the creation strategy for the `UsernamePasswordContext`.
`void`
PrePopulateUsername.`setUsernamePasswordContextCreationStrategy(Function<ProfileRequestContext,UsernamePasswordContext> strategy)`
Set the strategy used to create/locate the `UsernamePasswordContext` to operate on.
Constructors in net.shibboleth.idp.authn.impl with parameters of type UsernamePasswordContext
Modifier
Constructor
Description
``
`SimpleCallbackHandler(UsernamePasswordContext usernamePasswordContext)`
Constructor.
``
`SimpleCallbackHandler(UsernamePasswordContext usernamePasswordContext)`
Constructor.