Class SecondFactorOnlyCredentialLabeller
java.lang.Object
net.shibboleth.idp.plugin.authn.webauthn.admin.impl.SecondFactorOnlyCredentialLabeller
- All Implemented Interfaces:
BiFunction<EnhancedCredentialRecord,ProfileRequestContext, List<String>>
@ThreadSafe
public class SecondFactorOnlyCredentialLabeller
extends Object
implements BiFunction<EnhancedCredentialRecord,ProfileRequestContext,List<String>>
A credential labeller function that labels credentials as 'SecondFactor' if the authenticator that created the
credential should only be used as a second factor, and not sole factor of authentication.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final StringThe default label to use for second factor only credentials.private StringThe label to use for second factor only credentials.private final org.slf4j.LoggerClass logger.private Set<com.yubico.fido.metadata.AAGUID>A set of authenticators that should only be used for second factor authentication, based on their AAGUID. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionapply(EnhancedCredentialRecord cred, ProfileRequestContext prc) voidSet the label to use for second factor only credentials.voidsetSecondFactorOnlyAuthenticators(Set<String> allowed) Set the authenticators that should only be used for second factor authentication based on their AAGUID.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.function.BiFunction
andThen
-
Field Details
-
DEFAULT_LABEL
The default label to use for second factor only credentials.- See Also:
-
log
@Nonnull private final org.slf4j.Logger logClass logger. -
secondFactorOnlyAuthenticators
@Nonnull @NotLive @Unmodifiable private Set<com.yubico.fido.metadata.AAGUID> secondFactorOnlyAuthenticatorsA set of authenticators that should only be used for second factor authentication, based on their AAGUID. -
label
The label to use for second factor only credentials.
-
-
Constructor Details
-
SecondFactorOnlyCredentialLabeller
public SecondFactorOnlyCredentialLabeller()Constructor.
-
-
Method Details
-
setSecondFactorOnlyAuthenticators
Set the authenticators that should only be used for second factor authentication based on their AAGUID.- Parameters:
allowed- The second factor authenticators to set.
-
setLabel
Set the label to use for second factor only credentials.- Parameters:
labelIn- The label to set.
-
apply
public List<String> apply(@Nullable EnhancedCredentialRecord cred, @Nullable ProfileRequestContext prc) - Specified by:
applyin interfaceBiFunction<EnhancedCredentialRecord,ProfileRequestContext, List<String>>
-