Skip to content

Commit 44799d0

Browse files
committed
Fix incorrect javadoc on AssertionResult.signatureCounterValid
1 parent 0ba2f92 commit 44799d0

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

NEWS

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55
- CVE-2020-10672
66
- CVE-2020-10969
77
- CVE-2020-11620
8+
- Fixed incorrect JavaDoc on AssertionResult.isSignatureCounterValid(): it will
9+
also return true if both counters are zero.
810

911

1012
== Version 1.6.2 ==

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

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,13 @@ public class AssertionResult {
9191
private final long signatureCount;
9292

9393
/**
94-
* <code>true</code> if and only if the {@link AuthenticatorData#getSignatureCounter() signature counter value}
95-
* in the assertion was strictly greater than {@link RegisteredCredential#getSignatureCount() the stored one}.
94+
* <code>true</code> if and only if at least one of the following is true:
95+
* <ul>
96+
* <li>The {@link AuthenticatorData#getSignatureCounter() signature counter value} in the assertion was strictly
97+
* greater than {@link RegisteredCredential#getSignatureCount() the stored one}.</li>
98+
* <li>The {@link AuthenticatorData#getSignatureCounter() signature counter value} in the assertion and
99+
* {@link RegisteredCredential#getSignatureCount() the stored one} were both zero.</li>
100+
* </ul>
96101
*
97102
* @see <a href="https://www.w3.org/TR/2019/PR-webauthn-20190117/#sec-authenticator-data">§6.1. Authenticator
98103
* Data</a>

0 commit comments

Comments
 (0)