Package net.shibboleth.idp.plugin.authn.webauthn.admin

# Class CredentialCreationOptionsParameters.Builder

java.lang.Object
net.shibboleth.idp.plugin.authn.webauthn.admin.CredentialCreationOptionsParameters.Builder

All Implemented Interfaces:
  `CredentialCreationOptionsParameters.IAttestationConveyancePreferenceStage`, `CredentialCreationOptionsParameters.IBuildStage`, `CredentialCreationOptionsParameters.IChallengeStage`, `CredentialCreationOptionsParameters.IDisplayNameStage`, `CredentialCreationOptionsParameters.IExcludeCredentialsStage`, `CredentialCreationOptionsParameters.INameStage`, `CredentialCreationOptionsParameters.IResidentKeyRequirementStage`, `CredentialCreationOptionsParameters.IUserHandleStage`, `CredentialCreationOptionsParameters.IUserVerificationRequirementStage`

Enclosing class:
  CredentialCreationOptionsParameters

public static final class CredentialCreationOptionsParameters.Builder extends Object implements CredentialCreationOptionsParameters.IUserVerificationRequirementStage, CredentialCreationOptionsParameters.IChallengeStage, CredentialCreationOptionsParameters.IExcludeCredentialsStage, CredentialCreationOptionsParameters.INameStage, CredentialCreationOptionsParameters.IDisplayNameStage, CredentialCreationOptionsParameters.IResidentKeyRequirementStage, CredentialCreationOptionsParameters.IUserHandleStage, CredentialCreationOptionsParameters.IAttestationConveyancePreferenceStage, CredentialCreationOptionsParameters.IBuildStage
Builder class.

## Field Summary

Fields
Modifier and Type
Field
Description
`private com.yubico.webauthn.data.AttestationConveyancePreference`
`attestationConveyancePreference`
The Attestation conveyance preference.
`private com.yubico.webauthn.data.AuthenticatorAttachment`
`authenticatorAttachment`
The AuthenticatorAttachment requirement.
`private byte[]`
`challenge`
The challenge sent to the authenticator in registration ceremonies.
`private String`
`displayName`
The user.displayName supplied to the authenticator during registration.
`private boolean`
`enableCredProperties`
Enable the credential properties extenions.
`private Set<com.yubico.webauthn.data.PublicKeyCredentialDescriptor>`
`excludeCredentials`
Credentials that have already been registered with the IdP.
`private String`
`name`
The user.name.
`private com.yubico.webauthn.data.ResidentKeyRequirement`
`residentKeyRequirement`
The requirement on registering a ResidentKey.
`private byte[]`
`userId`
The userhandle supplied to the authenticator during registration.
`private com.yubico.webauthn.data.UserVerificationRequirement`
`userVerificationRequirement`
Does the authentication/registration require user verification.

## Constructor Summary

Constructors
Modifier
Constructor
Description
`private`
`Builder()`
Constructor.

## Method Summary

Modifier and Type
Method
Description
`CredentialCreationOptionsParameters`
`build()`
Build the options.
`CredentialCreationOptionsParameters.IBuildStage`
`withAttestationConveyancePreference(com.yubico.webauthn.data.AttestationConveyancePreference preference)`
The attestation conveyance preference.
`CredentialCreationOptionsParameters.IBuildStage`
`withAuthenticatorAttachment(com.yubico.webauthn.data.AuthenticatorAttachment attachment)`
The AuthenticatorAttachment requirement.
`CredentialCreationOptionsParameters.IExcludeCredentialsStage`
`withChallenge(byte[] challengeIn)`
The challenge sent to the authenticator in registration ceremonies.
`CredentialCreationOptionsParameters.IBuildStage`
`withCredentialPropertiesExt(boolean credProps)`
Is the credential properties extension enabled?
`CredentialCreationOptionsParameters.IResidentKeyRequirementStage`
`withDisplayName(String dispName)`
The user.displayName supplied to the authenticator during registration.
`CredentialCreationOptionsParameters.INameStage`
`withExcludeCredentials(Set<com.yubico.webauthn.data.PublicKeyCredentialDescriptor> exclude)`
Credentials that have already been registered with the IdP.
`CredentialCreationOptionsParameters.IDisplayNameStage`
`withName(String uname)`
The user.name of the user identity.
`CredentialCreationOptionsParameters.IUserHandleStage`
`withResidentKeyRequirement(com.yubico.webauthn.data.ResidentKeyRequirement residentKeyReq)`
The requirement on registering a ResidentKey.
`CredentialCreationOptionsParameters.IAttestationConveyancePreferenceStage`
`withUserId(byte[] id)`
The user.id supplied to the authenticator during registration.
`CredentialCreationOptionsParameters.IChallengeStage`
`withUserVerificationRequirement(com.yubico.webauthn.data.UserVerificationRequirement uvRequirement)`
Does the authentication/registration require user verification.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### userVerificationRequirement

private com.yubico.webauthn.data.UserVerificationRequirement userVerificationRequirement
Does the authentication/registration require user verification.

### challenge

private byte[] challenge
The challenge sent to the authenticator in registration ceremonies.

### excludeCredentials

private Set<com.yubico.webauthn.data.PublicKeyCredentialDescriptor> excludeCredentials
Credentials that have already been registered with the IdP.

### name

private String name
The user.name.

### residentKeyRequirement

private com.yubico.webauthn.data.ResidentKeyRequirement residentKeyRequirement
The requirement on registering a ResidentKey. Also know as a discoverable credential.

### userId

private byte[] userId
The userhandle supplied to the authenticator during registration. As generated by the IdP.

### authenticatorAttachment

private com.yubico.webauthn.data.AuthenticatorAttachment authenticatorAttachment
The AuthenticatorAttachment requirement. `null` would represent either possibility.

### attestationConveyancePreference

private com.yubico.webauthn.data.AttestationConveyancePreference attestationConveyancePreference
The Attestation conveyance preference.

### displayName

private String displayName
The user.displayName supplied to the authenticator during registration. A human-palatable name for the user account, intended only for display

### enableCredProperties

private boolean enableCredProperties
Enable the credential properties extenions. For example, to report discoverable credentials i.e. 'passkeys'.

## Constructor Details

### Builder

private Builder()
Constructor.

## Method Details

### withUserVerificationRequirement

public CredentialCreationOptionsParameters.IChallengeStage withUserVerificationRequirement(@Nonnull com.yubico.webauthn.data.UserVerificationRequirement uvRequirement)
Description copied from interface: `CredentialCreationOptionsParameters.IUserVerificationRequirementStage`
Does the authentication/registration require user verification.

Specified by:
  `withUserVerificationRequirement` in interface `CredentialCreationOptionsParameters.IUserVerificationRequirementStage`
Parameters:
  `uvRequirement` - the requirement
Returns:
  the next stage

### withChallenge

public CredentialCreationOptionsParameters.IExcludeCredentialsStage withChallenge(@Nonnull byte[] challengeIn)
Description copied from interface: `CredentialCreationOptionsParameters.IChallengeStage`
The challenge sent to the authenticator in registration ceremonies.

Specified by:
  `withChallenge` in interface `CredentialCreationOptionsParameters.IChallengeStage`
Parameters:
  `challengeIn` - the challenge
Returns:
  the next stage

### withExcludeCredentials

public CredentialCreationOptionsParameters.INameStage withExcludeCredentials(@Nonnull Set<com.yubico.webauthn.data.PublicKeyCredentialDescriptor> exclude)
Description copied from interface: `CredentialCreationOptionsParameters.IExcludeCredentialsStage`
Credentials that have already been registered with the IdP.

Specified by:
  `withExcludeCredentials` in interface `CredentialCreationOptionsParameters.IExcludeCredentialsStage`
Parameters:
  `exclude` - the credentials to exclude
Returns:
  the next stage

### withName

public CredentialCreationOptionsParameters.IDisplayNameStage withName(@Nonnull String uname)
Description copied from interface: `CredentialCreationOptionsParameters.INameStage`
The user.name of the user identity.

Specified by:
  `withName` in interface `CredentialCreationOptionsParameters.INameStage`
Parameters:
  `uname` - the user.name
Returns:
  the next stage

### withDisplayName

public CredentialCreationOptionsParameters.IResidentKeyRequirementStage withDisplayName(@Nonnull String dispName)
Description copied from interface: `CredentialCreationOptionsParameters.IDisplayNameStage`
The user.displayName supplied to the authenticator during registration. A human-palatable name for the user account, intended only for display

Specified by:
  `withDisplayName` in interface `CredentialCreationOptionsParameters.IDisplayNameStage`
Parameters:
  `dispName` - the display name
Returns:
  the next stage

### withResidentKeyRequirement

public CredentialCreationOptionsParameters.IUserHandleStage withResidentKeyRequirement(@Nonnull com.yubico.webauthn.data.ResidentKeyRequirement residentKeyReq)
Description copied from interface: `CredentialCreationOptionsParameters.IResidentKeyRequirementStage`
The requirement on registering a ResidentKey. Also know as a discoverable credential.

Specified by:
  `withResidentKeyRequirement` in interface `CredentialCreationOptionsParameters.IResidentKeyRequirementStage`
Parameters:
  `residentKeyReq` - the requirement
Returns:
  the next stage

### withUserId

public CredentialCreationOptionsParameters.IAttestationConveyancePreferenceStage withUserId(@Nonnull byte[] id)
Description copied from interface: `CredentialCreationOptionsParameters.IUserHandleStage`
The user.id supplied to the authenticator during registration. As generated by the IdP.

Specified by:
  `withUserId` in interface `CredentialCreationOptionsParameters.IUserHandleStage`
Parameters:
  `id` - the user.id
Returns:
  the next stage

### withAttestationConveyancePreference

public CredentialCreationOptionsParameters.IBuildStage withAttestationConveyancePreference(@Nonnull com.yubico.webauthn.data.AttestationConveyancePreference preference)
Description copied from interface: `CredentialCreationOptionsParameters.IAttestationConveyancePreferenceStage`
The attestation conveyance preference.

Specified by:
  `withAttestationConveyancePreference` in interface `CredentialCreationOptionsParameters.IAttestationConveyancePreferenceStage`
Parameters:
  `preference` - the preference
Returns:
  the next stage

### withCredentialPropertiesExt

public CredentialCreationOptionsParameters.IBuildStage withCredentialPropertiesExt(boolean credProps)
Description copied from interface: `CredentialCreationOptionsParameters.IBuildStage`
Is the credential properties extension enabled?

Specified by:
  `withCredentialPropertiesExt` in interface `CredentialCreationOptionsParameters.IBuildStage`
Parameters:
  `credProps` - the flag
Returns:
  the next stage

### withAuthenticatorAttachment

public CredentialCreationOptionsParameters.IBuildStage withAuthenticatorAttachment(@Nullable com.yubico.webauthn.data.AuthenticatorAttachment attachment)
Description copied from interface: `CredentialCreationOptionsParameters.IBuildStage`
The AuthenticatorAttachment requirement. `null` would represent either possibility.

Specified by:
  `withAuthenticatorAttachment` in interface `CredentialCreationOptionsParameters.IBuildStage`
Parameters:
  `attachment` - the attachment
Returns:
  the next stage

### build

public CredentialCreationOptionsParameters build()
Description copied from interface: `CredentialCreationOptionsParameters.IBuildStage`
Build the options.

Specified by:
  `build` in interface `CredentialCreationOptionsParameters.IBuildStage`
Returns:
  the options