Skip to content

Commit f00b469

Browse files
committed
Cover appidExclude extension in JavaDocs for RelyingParty.appid
1 parent de52b06 commit f00b469

File tree

1 file changed

+27
-9
lines changed

1 file changed

+27
-9
lines changed

webauthn-server-core/src/main/java/com/yubico/webauthn/RelyingParty.java

Lines changed: 27 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@
4242
import com.yubico.webauthn.data.PublicKeyCredentialParameters;
4343
import com.yubico.webauthn.data.PublicKeyCredentialRequestOptions;
4444
import com.yubico.webauthn.data.PublicKeyCredentialRequestOptions.PublicKeyCredentialRequestOptionsBuilder;
45+
import com.yubico.webauthn.data.RegistrationExtensionInputs;
4546
import com.yubico.webauthn.data.RelyingPartyIdentity;
4647
import com.yubico.webauthn.exception.AssertionFailedException;
4748
import com.yubico.webauthn.exception.InvalidSignatureCountException;
@@ -140,8 +141,7 @@ public class RelyingParty {
140141
@NonNull private final CredentialRepository credentialRepository;
141142

142143
/**
143-
* The extension input to set for the <code>appid</code> extension when initiating authentication
144-
* operations.
144+
* The extension input to set for the <code>appid</code> and <code>appidExclude</code> extensions.
145145
*
146146
* <p>You do not need this extension if you have not previously supported U2F. Its purpose is to
147147
* make already-registered U2F credentials forward-compatible with the WebAuthn API. It is not
@@ -154,13 +154,19 @@ public class RelyingParty {
154154
* <p>If this member is set, {@link #startAssertion(StartAssertionOptions) startAssertion} will
155155
* automatically set the <code>appid</code> extension input, and {@link
156156
* #finishAssertion(FinishAssertionOptions) finishAssertion} will adjust its verification logic to
157-
* also accept this AppID as an alternative to the RP ID.
157+
* also accept this AppID as an alternative to the RP ID. Likewise, {@link
158+
* #startRegistration(StartRegistrationOptions)} startRegistration} will automatically set the
159+
* <code>appidExclude</code> extension input.
158160
*
159161
* <p>By default, this is not set.
160162
*
161163
* @see AssertionExtensionInputs#getAppid()
164+
* @see RegistrationExtensionInputs#getAppidExclude()
162165
* @see <a href="https://www.w3.org/TR/2021/REC-webauthn-2-20210408/#sctn-appid-extension">§10.1.
163166
* FIDO AppID Extension (appid)</a>
167+
* @see <a
168+
* href="https://www.w3.org/TR/2021/REC-webauthn-2-20210408/#sctn-appid-exclude-extension">§10.2.
169+
* FIDO AppID Exclusion Extension (appidExclude)</a>
164170
*/
165171
@NonNull private final Optional<AppId> appId;
166172

@@ -563,8 +569,8 @@ public RelyingPartyBuilder credentialRepository(CredentialRepository credentialR
563569
}
564570

565571
/**
566-
* The extension input to set for the <code>appid</code> extension when initiating
567-
* authentication operations.
572+
* The extension input to set for the <code>appid</code> and <code>appidExclude</code>
573+
* extensions.
568574
*
569575
* <p>You do not need this extension if you have not previously supported U2F. Its purpose is to
570576
* make already-registered U2F credentials forward-compatible with the WebAuthn API. It is not
@@ -577,23 +583,29 @@ public RelyingPartyBuilder credentialRepository(CredentialRepository credentialR
577583
* <p>If this member is set, {@link #startAssertion(StartAssertionOptions) startAssertion} will
578584
* automatically set the <code>appid</code> extension input, and {@link
579585
* #finishAssertion(FinishAssertionOptions) finishAssertion} will adjust its verification logic
580-
* to also accept this AppID as an alternative to the RP ID.
586+
* to also accept this AppID as an alternative to the RP ID. Likewise, {@link
587+
* #startRegistration(StartRegistrationOptions)} startRegistration} will automatically set the
588+
* <code>appidExclude</code> extension input.
581589
*
582590
* <p>By default, this is not set.
583591
*
584592
* @see AssertionExtensionInputs#getAppid()
593+
* @see RegistrationExtensionInputs#getAppidExclude()
585594
* @see <a
586595
* href="https://www.w3.org/TR/2021/REC-webauthn-2-20210408/#sctn-appid-extension">§10.1.
587596
* FIDO AppID Extension (appid)</a>
597+
* @see <a
598+
* href="https://www.w3.org/TR/2021/REC-webauthn-2-20210408/#sctn-appid-exclude-extension">§10.2.
599+
* FIDO AppID Exclusion Extension (appidExclude)</a>
588600
*/
589601
public RelyingPartyBuilder appId(@NonNull Optional<AppId> appId) {
590602
this.appId = appId;
591603
return this;
592604
}
593605

594606
/**
595-
* The extension input to set for the <code>appid</code> extension when initiating
596-
* authentication operations.
607+
* The extension input to set for the <code>appid</code> and <code>appidExclude</code>
608+
* extensions.
597609
*
598610
* <p>You do not need this extension if you have not previously supported U2F. Its purpose is to
599611
* make already-registered U2F credentials forward-compatible with the WebAuthn API. It is not
@@ -606,14 +618,20 @@ public RelyingPartyBuilder appId(@NonNull Optional<AppId> appId) {
606618
* <p>If this member is set, {@link #startAssertion(StartAssertionOptions) startAssertion} will
607619
* automatically set the <code>appid</code> extension input, and {@link
608620
* #finishAssertion(FinishAssertionOptions) finishAssertion} will adjust its verification logic
609-
* to also accept this AppID as an alternative to the RP ID.
621+
* to also accept this AppID as an alternative to the RP ID. Likewise, {@link
622+
* #startRegistration(StartRegistrationOptions)} startRegistration} will automatically set the
623+
* <code>appidExclude</code> extension input.
610624
*
611625
* <p>By default, this is not set.
612626
*
613627
* @see AssertionExtensionInputs#getAppid()
628+
* @see RegistrationExtensionInputs#getAppidExclude()
614629
* @see <a
615630
* href="https://www.w3.org/TR/2021/REC-webauthn-2-20210408/#sctn-appid-extension">§10.1.
616631
* FIDO AppID Extension (appid)</a>
632+
* @see <a
633+
* href="https://www.w3.org/TR/2021/REC-webauthn-2-20210408/#sctn-appid-exclude-extension">§10.2.
634+
* FIDO AppID Exclusion Extension (appidExclude)</a>
617635
*/
618636
public RelyingPartyBuilder appId(@NonNull AppId appId) {
619637
return this.appId(Optional.of(appId));

0 commit comments

Comments
 (0)