adobe / aem-core-cif-components

A set of configurations and components to get you started with AEM Commerce development
Apache License 2.0
103 stars 80 forks source link

chore(deps): update dependency moment to 2.29.4 [security] - autoclosed #937

Closed renovate[bot] closed 1 year ago

renovate[bot] commented 2 years ago

Mend Renovate

This PR contains the following updates:

Package Change
moment 2.29.2 -> 2.29.4

⚠ Dependency Lookup Warnings ⚠

Warnings were logged while processing this repo. Please check the logs for more information.

GitHub Vulnerability Alerts

CVE-2022-31129

Impact

Patches

The problem is patched in 2.29.4, the patch can be applied to all affected versions with minimal tweaking.

Workarounds

In general, given the proliferation of ReDoS attacks, it makes sense to limit the length of the user input to something sane, like 200 characters or less. I haven't seen legitimate cases of date-time strings longer than that, so all moment users who do pass a user-originating string to constructor are encouraged to apply such a rudimentary filter, that would help with this but also most future ReDoS vulnerabilities.

References

There is an excellent writeup of the issue here: https://github.com/moment/moment/pull/6015#issuecomment-1152961973=

Details

The issue is rooted in the code that removes legacy comments (stuff inside parenthesis) from strings during rfc2822 parsing. moment("(".repeat(500000)) will take a few minutes to process, which is unacceptable.


Configuration

📅 Schedule: Branch creation - "" (UTC), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.



This PR has been generated by Mend Renovate. View repository job log here.

codecov[bot] commented 2 years ago

Codecov Report

Merging #937 (c357849) into master (dbe0f6d) will not change coverage. The diff coverage is n/a.

@@            Coverage Diff            @@
##             master     #937   +/-   ##
=========================================
  Coverage     89.15%   89.15%           
  Complexity     2212     2212           
=========================================
  Files           354      354           
  Lines          9987     9987           
  Branches       1438     1438           
=========================================
  Hits           8904     8904           
  Misses          787      787           
  Partials        296      296           
Flag Coverage Δ
integration 51.78% <ø> (ø)
jest 86.68% <ø> (ø)
karma 95.53% <ø> (ø)
unittests 87.43% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more