Closed Bug 1758509 (CVE-2022-24713) Opened 3 years ago Closed 3 years ago

Update regex crate in-tree to 1.5.5

Categories

(Core :: General, enhancement, P1)

enhancement

Tracking

()

RESOLVED FIXED
100 Branch
Tracking Status
firefox-esr91 99+ fixed
firefox98 --- wontfix
firefox99 + fixed
firefox100 + fixed

People

(Reporter: janerik, Assigned: janerik)

Details

(Keywords: csectype-dos, sec-low, Whiteboard: [adv-main99+][adv-esr91.8+])

Attachments

(2 files)

As per https://blog.rust-lang.org/2022/03/08/cve-2022-24713.html (CVE-2022-24713) the regex crate is vulnerable to DoS attacks as it didn't properly limit the complexity of expressions it parses.

This is fixed in 1.5.5.

I don't know where and how we use the crate in Gecko.

Cargo.toml in tree: https://searchfox.org/mozilla-central/rev/15f12b0c6c56b449304f6cb1f84ac4df84dc936a/third_party/rust/regex/Cargo.toml#16

Group: mozilla-employee-confidential → core-security-release
Keywords: csectype-dos
Keywords: sec-low
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 100 Branch

Not sure we really need to backport this if it's only a sec-low, but I kind of feel like we're going to see duplicate reports if we don't given the upstream CVE. This grafts cleanly to Beta and ESR, so IMO we might as well move forward with approval requests when you get a chance.

Should be a non-risky uplift, I agree.
For all I know we should not be vulnerable (at least a quick look through our code base didn't uncover anything), but better be safe than sorry.

Flags: needinfo?(jrediger)

Comment on attachment 9266858 [details]
Bug 1758509 - Update regex crate to 1.5.5 r?emilio,glandium

Beta/Release Uplift Approval Request

  • User impact if declined: The regex crate has a vulnerability, that can lead to a Denial of Service if exposed to malicious regular expressions.
    It's unlikely that we expose such a code path anywhere in the m-c codebase, but we didn't fully verify that this holds.
  • Is this code covered by automated tests?: No
  • Has the fix been verified in Nightly?: Yes
  • Needs manual test from QE?: No
  • If yes, steps to reproduce:
  • List of other uplifts needed: None
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): Patch version update of a Rust dependency. The regex crate is only used internally, if at all. Unlikely that we even expose the vulnerable code path to users anywhere.
  • String changes made/needed:

ESR Uplift Approval Request

  • If this is not a sec:{high,crit} bug, please state case for ESR consideration: CVE for a Rust dependency, unlikely to be hit in our code base. It applies cleanly for both Beta and ESR and thus might just avoid us getting more reports about it.
  • User impact if declined: The regex crate has a vulnerability, that can lead to a Denial of Service if exposed to malicious regular expressions.
    It's unlikely that we expose such a code path anywhere in the m-c codebase, but we didn't fully verify that this holds.
  • Fix Landed on Version: 100
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): Patch version update of a Rust dependency. The regex crate is only used internally, if at all. Unlikely that we even expose the vulnerable code path to users anywhere.
Attachment #9266858 - Flags: approval-mozilla-esr91?
Attachment #9266858 - Flags: approval-mozilla-beta?

Comment on attachment 9266858 [details]
Bug 1758509 - Update regex crate to 1.5.5 r?emilio,glandium

Approved for 99.0b3. Thanks.

Attachment #9266858 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
QA Whiteboard: [post-critsmash-triage]
Flags: qe-verify-

Comment on attachment 9266858 [details]
Bug 1758509 - Update regex crate to 1.5.5 r?emilio,glandium

Approved for 91.8esr.

Attachment #9266858 - Flags: approval-mozilla-esr91? → approval-mozilla-esr91+
Alias: CVE-2022-24713
QA Whiteboard: [post-critsmash-triage] → [post-critsmash-triage][adv-main99+]
QA Whiteboard: [post-critsmash-triage][adv-main99+] → [post-critsmash-triage]
Whiteboard: [adv-main99+]
Attached file advisory.txt
Whiteboard: [adv-main99+] → [adv-main99+][adv-esr91.8+]
Group: core-security-release
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: