Skip to content

Commit 5388273

Browse files
fix(webauthn): drop large_blob_key from public Assertion model
Per review on #198: keep the per-credential largeBlobKey only on the CTAP-level Ctap2GetAssertionResponse. Surfacing it on the public Assertion struct gives callers a foot-gun to forward straight to the RP, which is exactly the disclosure this PR is meant to prevent. The follow-up authenticatorLargeBlobs PR (#206) can read the key directly off the CTAP response.
1 parent bdb1328 commit 5388273

2 files changed

Lines changed: 0 additions & 7 deletions

File tree

libwebauthn/src/ops/webauthn/get_assertion.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -405,7 +405,6 @@ pub struct Assertion {
405405
pub user: Option<Ctap2PublicKeyCredentialUserEntity>,
406406
pub credentials_count: Option<u32>,
407407
pub user_selected: Option<bool>,
408-
pub large_blob_key: Option<Vec<u8>>,
409408
pub unsigned_extensions_output: Option<GetAssertionResponseUnsignedExtensions>,
410409
pub enterprise_attestation: Option<bool>,
411410
pub attestation_statement: Option<Ctap2AttestationStatement>,
@@ -815,7 +814,6 @@ mod tests {
815814
user: None,
816815
credentials_count: None,
817816
user_selected: None,
818-
large_blob_key: None,
819817
unsigned_extensions_output: None,
820818
enterprise_attestation: None,
821819
attestation_statement: None,

libwebauthn/src/proto/ctap2/model/get_assertion.rs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -493,7 +493,6 @@ impl Ctap2GetAssertionResponse {
493493
user: self.user,
494494
credentials_count: self.credentials_count,
495495
user_selected: self.user_selected,
496-
large_blob_key: self.large_blob_key.map(ByteBuf::into_vec),
497496
unsigned_extensions_output,
498497
enterprise_attestation: self.enterprise_attestation,
499498
attestation_statement: self.attestation_statement,
@@ -680,9 +679,5 @@ mod tests {
680679
.expect("largeBlob extension output present");
681680

682681
assert!(large_blob.blob.is_none());
683-
assert_eq!(
684-
assertion.large_blob_key.as_deref(),
685-
Some(&device_returned_key[..])
686-
);
687682
}
688683
}

0 commit comments

Comments
 (0)