Skip to content

Commit 9edc343

Browse files
committed
gradle spotlessApply
Fixes formatting issues since commit 5d4c251.
1 parent a92b426 commit 9edc343

File tree

3 files changed

+24
-8
lines changed

3 files changed

+24
-8
lines changed

webauthn-server-core/src/main/java/com/yubico/webauthn/data/ByteArray.java

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -109,22 +109,30 @@ public int size() {
109109
return this.bytes.length;
110110
}
111111

112-
/** @return a copy of the raw byte contents. */
112+
/**
113+
* @return a copy of the raw byte contents.
114+
*/
113115
public byte[] getBytes() {
114116
return BinaryUtil.copy(bytes);
115117
}
116118

117-
/** @return the content bytes encoded as classic Base64 data. */
119+
/**
120+
* @return the content bytes encoded as classic Base64 data.
121+
*/
118122
public String getBase64() {
119123
return BASE64_ENCODER.encodeToString(bytes);
120124
}
121125

122-
/** @return the content bytes encoded as Base64Url data, without padding. */
126+
/**
127+
* @return the content bytes encoded as Base64Url data, without padding.
128+
*/
123129
public String getBase64Url() {
124130
return base64url;
125131
}
126132

127-
/** @return the content bytes encoded as hexadecimal data. */
133+
/**
134+
* @return the content bytes encoded as hexadecimal data.
135+
*/
128136
@ToString.Include
129137
public String getHex() {
130138
return BinaryUtil.toHex(bytes);

webauthn-server-demo/src/main/java/demo/webauthn/SessionManager.java

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,18 @@ private static <K, V> Cache<K, V> newCache() {
2323
.build();
2424
}
2525

26-
/** @return Create a new session for the given user, or return the existing one. */
26+
/**
27+
* @return Create a new session for the given user, or return the existing one.
28+
*/
2729
public ByteArray createSession(@NonNull ByteArray userHandle) throws ExecutionException {
2830
ByteArray sessionId = usersToSessionIds.get(userHandle, () -> generateRandom(32));
2931
sessionIdsToUsers.put(sessionId, userHandle);
3032
return sessionId;
3133
}
3234

33-
/** @return the user handle of the given session, if any. */
35+
/**
36+
* @return the user handle of the given session, if any.
37+
*/
3438
public Optional<ByteArray> getSession(@NonNull ByteArray token) {
3539
return Optional.ofNullable(sessionIdsToUsers.getIfPresent(token));
3640
}

yubico-util/src/main/java/com/yubico/internal/util/BinaryUtil.java

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,12 +37,16 @@ public static byte[] copy(byte[] bytes) {
3737
return Arrays.copyOf(bytes, bytes.length);
3838
}
3939

40-
/** @param bytes Bytes to encode */
40+
/**
41+
* @param bytes Bytes to encode
42+
*/
4143
public static String toHex(byte[] bytes) {
4244
return BaseEncoding.base16().encode(bytes).toLowerCase();
4345
}
4446

45-
/** @param hex String of hexadecimal digits to decode as bytes. */
47+
/**
48+
* @param hex String of hexadecimal digits to decode as bytes.
49+
*/
4650
public static byte[] fromHex(String hex) {
4751
return BaseEncoding.base16().decode(hex.toUpperCase());
4852
}

0 commit comments

Comments
 (0)