summaryrefslogtreecommitdiffstats
path: root/dom/webauthn/WebAuthnResult.cpp
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-15 03:35:49 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-15 03:35:49 +0000
commitd8bbc7858622b6d9c278469aab701ca0b609cddf (patch)
treeeff41dc61d9f714852212739e6b3738b82a2af87 /dom/webauthn/WebAuthnResult.cpp
parentReleasing progress-linux version 125.0.3-1~progress7.99u1. (diff)
downloadfirefox-d8bbc7858622b6d9c278469aab701ca0b609cddf.tar.xz
firefox-d8bbc7858622b6d9c278469aab701ca0b609cddf.zip
Merging upstream version 126.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'dom/webauthn/WebAuthnResult.cpp')
-rw-r--r--dom/webauthn/WebAuthnResult.cpp22
1 files changed, 21 insertions, 1 deletions
diff --git a/dom/webauthn/WebAuthnResult.cpp b/dom/webauthn/WebAuthnResult.cpp
index 268dd62f20..6fd446ffa0 100644
--- a/dom/webauthn/WebAuthnResult.cpp
+++ b/dom/webauthn/WebAuthnResult.cpp
@@ -102,7 +102,27 @@ WebAuthnRegisterResult::GetAuthenticatorAttachment(
return NS_ERROR_NOT_AVAILABLE;
}
-nsresult WebAuthnRegisterResult::Anonymize() {
+NS_IMETHODIMP
+WebAuthnRegisterResult::HasIdentifyingAttestation(
+ bool* aHasIdentifyingAttestation) {
+ // Assume the attestation statement is identifying in case the constructor or
+ // the getter below fail.
+ bool isIdentifying = true;
+
+ nsCOMPtr<nsIWebAuthnAttObj> attObj;
+ nsresult rv = authrs_webauthn_att_obj_constructor(mAttestationObject,
+ /* anonymize */ false,
+ getter_AddRefs(attObj));
+ if (NS_SUCCEEDED(rv)) {
+ Unused << attObj->IsIdentifying(&isIdentifying);
+ }
+
+ *aHasIdentifyingAttestation = isIdentifying;
+ return NS_OK;
+}
+
+NS_IMETHODIMP
+WebAuthnRegisterResult::Anonymize() {
// The anonymize flag in the nsIWebAuthnAttObj constructor causes the
// attestation statement to be removed during deserialization. It also
// causes the AAGUID to be zeroed out. If we can't deserialize the