Skip to content

Bug 2087250 - Mark scanned Firefox Accounts pairing links as opened in a custom tab - #450

Closed
corentinbect wants to merge 1 commit into
mozilla-firefox:autolandfrom
corentinbect:bug2087250
Closed

corentinbect wants to merge 1 commit into
mozilla-firefox:autolandfrom
corentinbect:bug2087250

Conversation

@corentinbect

@corentinbect corentinbect commented Nov 16, 2026 •

Copy link
Copy Markdown

The Firefox Accounts /pair page can't tell if it is shown in a custom tab so it can't adjust its wording accordingly.

Add an embed=customtab query parameter to the URL.


Lando: link
Bugzilla: bug 2087250

⚠️ This pull request has 2 warnings.
🚫 This pull request has 1 blocker.

@lando-web
lando-web Bot requested a review from a team November 16, 2026 15:29
@mozilla-code-review

Copy link
Copy Markdown

No new issues detected. This pull request is 🆗

1 similar comment
@mozilla-code-review

Copy link
Copy Markdown

No new issues detected. This pull request is 🆗

@mozilla-code-review

Copy link
Copy Markdown

No new issues detected. This pull request is 🆗

1 similar comment
@mozilla-code-review

Copy link
Copy Markdown

No new issues detected. This pull request is 🆗

@lando-web
lando-web Bot requested a review from a team November 17, 2026 09:11

@rocketsroger rocketsroger left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Couple of questions, but none blocking. Thanks!

@lando-web
lando-web Bot requested a review from a team November 18, 2026 14:33

@mozilla-code-review mozilla-code-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 build or test issues have been found in this revision.

5 error lines from the log
/builds/worker/checkouts/gecko/dom/base/CycleCollectorUnlinkTester.h:22:1: error: final class 'CycleCollectorUnlinkTester' uses NS_DECL_CYCLE_COLLECTING_ISUPPORTS; use NS_DECL_CYCLE_COLLECTING_ISUPPORTS_FINAL instead
'mach build -v' did not run successfully. Please check log for errors.
Running post_fatal callback...
Exiting -1
[taskcluster:error] exit status 255
5 error lines from the log
/builds/worker/checkouts/gecko/dom/base/CycleCollectorUnlinkTester.h:22:1: error: final class 'CycleCollectorUnlinkTester' uses NS_DECL_CYCLE_COLLECTING_ISUPPORTS; use NS_DECL_CYCLE_COLLECTING_ISUPPORTS_FINAL instead
'mach build -v' did not run successfully. Please check log for errors.
Running post_fatal callback...
Exiting -1
[taskcluster:error] exit status 255

@mozilla-code-review mozilla-code-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 build or test issues have been found in this revision.

5 error lines from the log
/builds/worker/checkouts/gecko/dom/base/CycleCollectorUnlinkTester.h:22:1: error: final class 'CycleCollectorUnlinkTester' uses NS_DECL_CYCLE_COLLECTING_ISUPPORTS; use NS_DECL_CYCLE_COLLECTING_ISUPPORTS_FINAL instead
'mach build -v' did not run successfully. Please check log for errors.
Running post_fatal callback...
Exiting -1
[taskcluster:error] exit status 255
5 error lines from the log
/builds/worker/checkouts/gecko/dom/base/CycleCollectorUnlinkTester.h:22:1: error: final class 'CycleCollectorUnlinkTester' uses NS_DECL_CYCLE_COLLECTING_ISUPPORTS; use NS_DECL_CYCLE_COLLECTING_ISUPPORTS_FINAL instead
'mach build -v' did not run successfully. Please check log for errors.
Running post_fatal callback...
Exiting -1
[taskcluster:error] exit status 255

@mozilla-code-review
mozilla-code-review Bot dismissed stale reviews from themself November 18, 2026 16:09

This review is now deprecated.

@mozilla-code-review mozilla-code-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

8 issues have been found in this revision.

8 issues are located outside of the files touched by the patch:

  • memory/replace/dmd/DMD.h:85 Error: Use of undeclared identifier 'MOZ_ASSERT' [clang-tidy: clang-diagnostic-error]
  • xpcom/string/nsReadableUtils.h:422 Error: No member named 'EnsureUtf16ValiditySpan' in namespace 'mozilla'; did you mean 'EnsureUTF16Validity'? [clang-tidy: clang-diagnostic-error]
  • xpcom/string/nsReadableUtils.h:422 Error: Non-const lvalue reference to type 'nsAString' (aka 'nsTSubstring<char16_t>') cannot bind to a temporary of type 'Span<element_type, dynamic_extent>' (aka 'Span<char16_t, dynamic_extent>') [clang-tidy: clang-diagnostic-error]
  • xpcom/string/nsReadableUtils.h:411 Error: No member named 'Utf16ValidUpTo' in namespace 'mozilla' [clang-tidy: clang-diagnostic-error]
  • xpcom/string/nsTSubstring.h:22 Error: "Using XPCOM strings is limited to code linked into libxul." [clang-tidy: clang-diagnostic-error]
  • Cargo.lock Error: Crate depends on a vulnerable version of zip.

Advisory:
AES entries returned without checking their authentication code when the data ends early or is empty
Package: zip
ID: RUSTSEC-2026-0545
CVSS: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:N
Report date: 2026-10-22
For WinZip AES (AE-1 and AE-2) entries, the 10-byte HMAC authentication code was read and checked only after the reader had consumed exactly the entry's declared compressed size. If the archive ended before that size was reached, the read returned end-of-stream and the truncated plaintext was accepted without the check. The authentication code of an entry with no encrypted data was never checked.

AES-CTR ciphertext can be changed bit by bit without the password, and AE-2 entries carry no CRC-32, so an attacker who can modify an archive can alter the decrypted contents of such an entry without any error being reported.

This affects reading AES-encrypted entries with a password (for example ZipArchive::by_name_decrypt) with the aes-crypto feature.

The fix returns an error when the data ends before the declared size, and checks the authentication code of empty entries.
URL: zip-rs/zip2@ec265db
Patched versions: [
">=9.0.0"
]
Unaffected versions: [
"<0.6.0"
]
Advisory metadata: {
"aliases": [
"CVE-2026-115906",
"GHSA-8hxf-qr8p-62x4"
],
"related": [],
"collection": "crates",
"categories": [
"crypto-failure"
],
"keywords": [
"aes",
"hmac",
"authentication"
],
"informational": null,
"references": [],
"source": null,
"withdrawn": null,
"license": "CC0-1.0"
}

Package info: {
"name": "zip",
"version": "2.4.2",
"source": null,
"checksum": null,
"dependencies": [
{
"name": "arbitrary",
"version": "1.4.1",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "crc32fast",
"version": "1.4.2",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "crossbeam-utils",
"version": "0.8.21",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "displaydoc",
"version": "0.2.4",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "flate2",
"version": "1.1.4",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "indexmap",
"version": "2.14.1",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "memchr",
"version": "2.7.4",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "thiserror",
"version": "2.0.12",
"source": "registry+https://github.com/rust-lang/crates.io-index"
}
],
"replace": null
} [cargo-audit: source-test-mozlint-cargo-audit]

  • Cargo.lock Error: Crate depends on a vulnerable version of zip.

Advisory:
ZipStreamReader extracts entries under local-header names that can differ from the central directory
Package: zip
ID: RUSTSEC-2026-0548
Report date: 2026-10-17
A ZIP archive names each entry twice: in the local file header in front of the entry's data, and in the central directory at the end of the archive. ZipArchive lists and opens entries by their central-directory names. ZipStreamReader::visit and ZipStreamReader::extract, like read_zipfile_from_stream, read the local headers in order and use the local-header names without comparing them with the central directory.

An archive can therefore show one set of file names to code that inspects it with ZipArchive and write files under other names when it is extracted with ZipStreamReader. If an application checks an archive one way and extracts it the other way, an attacker can get files written or overwritten inside the destination directory that the check never saw.

The fix adds an opt-in check. ZipStreamReader::enforce_header_consistency(true) compares each local header with its central-directory entry (name, sizes, CRC-32, compression method, flags and modification time) and fails extraction on a mismatch; ZipReadOptions::enforce_header_consistency(true) and ZipArchive::validate_header_consistency() do the same for ZipArchive. The check is off by default, so upgrading alone does not change what ZipStreamReader::new(...) extracts: applications that extract untrusted archives with ZipStreamReader need to turn it on.
URL: zip-rs/zip2@8068ab4
Patched versions: [
">=9.0.5"
]
Advisory metadata: {
"aliases": [
"CVE-2026-115905",
"GHSA-m665-v7pm-7grj"
],
"related": [],
"collection": "crates",
"categories": [
"privilege-escalation"
],
"keywords": [
"parser-differential",
"local-file-header",
"central-directory"
],
"informational": null,
"references": [],
"source": null,
"withdrawn": null,
"license": "CC0-1.0"
}

Package info: {
"name": "zip",
"version": "2.4.2",
"source": null,
"checksum": null,
"dependencies": [
{
"name": "arbitrary",
"version": "1.4.1",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "crc32fast",
"version": "1.4.2",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "crossbeam-utils",
"version": "0.8.21",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "displaydoc",
"version": "0.2.4",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "flate2",
"version": "1.1.4",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "indexmap",
"version": "2.14.1",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "memchr",
"version": "2.7.4",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "thiserror",
"version": "2.0.12",
"source": "registry+https://github.com/rust-lang/crates.io-index"
}
],
"replace": null
} [cargo-audit: source-test-mozlint-cargo-audit]

  • third_party/node/pnpm-lock.yaml Error: Depends on a vulnerable version of picomatch.

Advisory:
picomatch vulnerable to ReDoS through single-branch repeated extglobs
Package: picomatch
ID: GHSA-fc5q-39xc-vjpf
Severity: high
CWE: CWE-1333
URL: GHSA-fc5q-39xc-vjpf

Installed versions: 2.3.2
Vulnerable versions: <=4.0.7
Patched versions: >=4.0.8
Dependency paths:
.>sass>chokidar>anymatch>picomatch
.>sass>chokidar>readdirp>picomatch [pnpm-audit: source-test-mozlint-pnpm-audit]

@mozilla-code-review
mozilla-code-review Bot dismissed their stale review November 18, 2026 16:10

This review is now deprecated.

@mozilla-code-review mozilla-code-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

8 issues have been found in this revision.

8 issues are located outside of the files touched by the patch:

  • memory/replace/dmd/DMD.h:85 Error: Use of undeclared identifier 'MOZ_ASSERT' [clang-tidy: clang-diagnostic-error]
  • xpcom/string/nsReadableUtils.h:422 Error: No member named 'EnsureUtf16ValiditySpan' in namespace 'mozilla'; did you mean 'EnsureUTF16Validity'? [clang-tidy: clang-diagnostic-error]
  • xpcom/string/nsReadableUtils.h:422 Error: Non-const lvalue reference to type 'nsAString' (aka 'nsTSubstring<char16_t>') cannot bind to a temporary of type 'Span<element_type, dynamic_extent>' (aka 'Span<char16_t, dynamic_extent>') [clang-tidy: clang-diagnostic-error]
  • xpcom/string/nsReadableUtils.h:411 Error: No member named 'Utf16ValidUpTo' in namespace 'mozilla' [clang-tidy: clang-diagnostic-error]
  • xpcom/string/nsTSubstring.h:22 Error: "Using XPCOM strings is limited to code linked into libxul." [clang-tidy: clang-diagnostic-error]
  • Cargo.lock Error: Crate depends on a vulnerable version of zip.

Advisory:
AES entries returned without checking their authentication code when the data ends early or is empty
Package: zip
ID: RUSTSEC-2026-0545
CVSS: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:N
Report date: 2026-10-22
For WinZip AES (AE-1 and AE-2) entries, the 10-byte HMAC authentication code was read and checked only after the reader had consumed exactly the entry's declared compressed size. If the archive ended before that size was reached, the read returned end-of-stream and the truncated plaintext was accepted without the check. The authentication code of an entry with no encrypted data was never checked.

AES-CTR ciphertext can be changed bit by bit without the password, and AE-2 entries carry no CRC-32, so an attacker who can modify an archive can alter the decrypted contents of such an entry without any error being reported.

This affects reading AES-encrypted entries with a password (for example ZipArchive::by_name_decrypt) with the aes-crypto feature.

The fix returns an error when the data ends before the declared size, and checks the authentication code of empty entries.
URL: zip-rs/zip2@ec265db
Patched versions: [
">=9.0.0"
]
Unaffected versions: [
"<0.6.0"
]
Advisory metadata: {
"aliases": [
"CVE-2026-115906",
"GHSA-8hxf-qr8p-62x4"
],
"related": [],
"collection": "crates",
"categories": [
"crypto-failure"
],
"keywords": [
"aes",
"hmac",
"authentication"
],
"informational": null,
"references": [],
"source": null,
"withdrawn": null,
"license": "CC0-1.0"
}

Package info: {
"name": "zip",
"version": "2.4.2",
"source": null,
"checksum": null,
"dependencies": [
{
"name": "arbitrary",
"version": "1.4.1",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "crc32fast",
"version": "1.4.2",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "crossbeam-utils",
"version": "0.8.21",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "displaydoc",
"version": "0.2.4",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "flate2",
"version": "1.1.4",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "indexmap",
"version": "2.14.1",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "memchr",
"version": "2.7.4",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "thiserror",
"version": "2.0.12",
"source": "registry+https://github.com/rust-lang/crates.io-index"
}
],
"replace": null
} [cargo-audit: source-test-mozlint-cargo-audit]

  • Cargo.lock Error: Crate depends on a vulnerable version of zip.

Advisory:
ZipStreamReader extracts entries under local-header names that can differ from the central directory
Package: zip
ID: RUSTSEC-2026-0548
Report date: 2026-10-17
A ZIP archive names each entry twice: in the local file header in front of the entry's data, and in the central directory at the end of the archive. ZipArchive lists and opens entries by their central-directory names. ZipStreamReader::visit and ZipStreamReader::extract, like read_zipfile_from_stream, read the local headers in order and use the local-header names without comparing them with the central directory.

An archive can therefore show one set of file names to code that inspects it with ZipArchive and write files under other names when it is extracted with ZipStreamReader. If an application checks an archive one way and extracts it the other way, an attacker can get files written or overwritten inside the destination directory that the check never saw.

The fix adds an opt-in check. ZipStreamReader::enforce_header_consistency(true) compares each local header with its central-directory entry (name, sizes, CRC-32, compression method, flags and modification time) and fails extraction on a mismatch; ZipReadOptions::enforce_header_consistency(true) and ZipArchive::validate_header_consistency() do the same for ZipArchive. The check is off by default, so upgrading alone does not change what ZipStreamReader::new(...) extracts: applications that extract untrusted archives with ZipStreamReader need to turn it on.
URL: zip-rs/zip2@8068ab4
Patched versions: [
">=9.0.5"
]
Advisory metadata: {
"aliases": [
"CVE-2026-115905",
"GHSA-m665-v7pm-7grj"
],
"related": [],
"collection": "crates",
"categories": [
"privilege-escalation"
],
"keywords": [
"parser-differential",
"local-file-header",
"central-directory"
],
"informational": null,
"references": [],
"source": null,
"withdrawn": null,
"license": "CC0-1.0"
}

Package info: {
"name": "zip",
"version": "2.4.2",
"source": null,
"checksum": null,
"dependencies": [
{
"name": "arbitrary",
"version": "1.4.1",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "crc32fast",
"version": "1.4.2",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "crossbeam-utils",
"version": "0.8.21",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "displaydoc",
"version": "0.2.4",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "flate2",
"version": "1.1.4",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "indexmap",
"version": "2.14.1",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "memchr",
"version": "2.7.4",
"source": "registry+https://github.com/rust-lang/crates.io-index"
},
{
"name": "thiserror",
"version": "2.0.12",
"source": "registry+https://github.com/rust-lang/crates.io-index"
}
],
"replace": null
} [cargo-audit: source-test-mozlint-cargo-audit]

  • third_party/node/pnpm-lock.yaml Error: Depends on a vulnerable version of picomatch.

Advisory:
picomatch vulnerable to ReDoS through single-branch repeated extglobs
Package: picomatch
ID: GHSA-fc5q-39xc-vjpf
Severity: high
CWE: CWE-1333
URL: GHSA-fc5q-39xc-vjpf

Installed versions: 2.3.2
Vulnerable versions: <=4.0.7
Patched versions: >=4.0.8
Dependency paths:
.>sass>chokidar>anymatch>picomatch
.>sass>chokidar>readdirp>picomatch [pnpm-audit: source-test-mozlint-pnpm-audit]

…n a custom tab

The Firefox Accounts `/pair` page can't tell if it is shown in a custom tab so it can't adjust its wording accordingly.

Add an `embed=customtab` query parameter to the URL.
@mozilla-code-review
mozilla-code-review Bot dismissed their stale review November 19, 2026 09:49

This review is now deprecated.

@mozilla-code-review

Copy link
Copy Markdown

Previous issues have been fixed. This pull request is 🆗

@mozilla-code-review

Copy link
Copy Markdown

No new issues detected. This pull request is 🆗

lando-worker Bot pushed a commit that referenced this pull request Nov 19, 2026
…n a custom tab r=gela,roger

The Firefox Accounts `/pair` page can't tell if it is shown in a custom tab so it can't adjust its wording accordingly.

Add an `embed=customtab` query parameter to the URL.

Pull request: #450
@lando-worker

lando-worker Bot commented Nov 19, 2026

Copy link
Copy Markdown

Pull request closed by commit d3a5198

@lando-worker lando-worker Bot closed this Nov 19, 2026
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this pull request Nov 21, 2026
…n a custom tab r=gela,roger

The Firefox Accounts `/pair` page can't tell if it is shown in a custom tab so it can't adjust its wording accordingly.

Add an `embed=customtab` query parameter to the URL.

Pull request: mozilla-firefox/firefox#450

UltraBlame original commit: 3dca47cfd2137066cfcf2a625fc57a10ad38fafa
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this pull request Nov 21, 2026
…n a custom tab r=gela,roger

The Firefox Accounts `/pair` page can't tell if it is shown in a custom tab so it can't adjust its wording accordingly.

Add an `embed=customtab` query parameter to the URL.

Pull request: mozilla-firefox/firefox#450

UltraBlame original commit: 3dca47cfd2137066cfcf2a625fc57a10ad38fafa
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this pull request Nov 21, 2026
…n a custom tab r=gela,roger

The Firefox Accounts `/pair` page can't tell if it is shown in a custom tab so it can't adjust its wording accordingly.

Add an `embed=customtab` query parameter to the URL.

Pull request: mozilla-firefox/firefox#450

UltraBlame original commit: 3dca47cfd2137066cfcf2a625fc57a10ad38fafa
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants