File tree Expand file tree Collapse file tree
webauthn-server-attestation/src/main/java/com/yubico/fido/metadata Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -18,6 +18,12 @@ Fixes:
1818
1919`webauthn-server-attestation`:
2020
21+ Changes:
22+
23+ * `FidoMetadataDownloader` builder method `.downloadBlob(URL)` now logs a
24+ warning if the given URL is not an HTTPS URL. Javadoc relaxed to not describe
25+ HTTPS as required since this was never enforced.
26+
2127New features:
2228
2329* Added `AuthenticatorStatus.RETIRED` and `Filters.notRetired()`.
Original file line number Diff line number Diff line change @@ -424,17 +424,24 @@ public Step5 useDefaultBlob() {
424424 }
425425
426426 /**
427- * Download the metadata BLOB from the given HTTPS <code>url</code>.
427+ * Download the metadata BLOB from the given HTTP or HTTPS <code>url</code>.
428428 *
429429 * <p>The BLOB will be downloaded if it does not exist in the cache, or if the <code>
430430 * nextUpdate</code> property of the cached BLOB is the current date or earlier.
431431 *
432432 * <p>If the BLOB is downloaded, it is also written to the cache {@link File} or {@link
433433 * Consumer} configured in the next step.
434434 *
435- * @param url the HTTP URL to download. It MUST use the <code>https:</code> scheme.
435+ * <p>It is RECOMMENDED to use a HTTPS URL for improved transport security. Most notably this
436+ * helps prevent attacks that could force the application to continue using a stale cached
437+ * BLOB even after the real MDS has a newer BLOB available.
438+ *
439+ * @param url the HTTP or HTTPS URL to download.
436440 */
437441 public Step5 downloadBlob (@ NonNull URL url ) {
442+ if (!"https" .equals (url .getProtocol ())) {
443+ log .warn ("FIDO MDS BLOB download URL is not a HTTPS URL: {}" , url );
444+ }
438445 return new Step5 (this , null , url );
439446 }
440447
You can’t perform that action at this time.
0 commit comments