JamesSingleton / hooks-arsenal

An arsenal of React Hooks... aka, a React Hooks library
MIT License
7 stars 3 forks source link

chore(deps): update dependency marked to 4.0.10 [security] #563

Open renovate[bot] opened 2 years ago

renovate[bot] commented 2 years ago

WhiteSource Renovate

This PR contains the following updates:

Package Change
marked 2.1.3 -> 4.0.10

GitHub Vulnerability Alerts

CVE-2022-21681

Impact

What kind of vulnerability is it?

Denial of service.

The regular expression inline.reflinkSearch may cause catastrophic backtracking against some strings. PoC is the following.

import * as marked from 'marked';

console.log(marked.parse(`[x]: x

\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](\\[\\](`));

Who is impacted?

Anyone who runs untrusted markdown through marked and does not use a worker with a time limit.

Patches

Has the problem been patched?

Yes

What versions should users upgrade to?

4.0.10

Workarounds

Is there a way for users to fix or remediate the vulnerability without upgrading?

Do not run untrusted markdown through marked or run marked on a worker thread and set a reasonable time limit to prevent draining resources.

References

Are there any links users can visit to find out more?

For more information

If you have any questions or comments about this advisory:

CVE-2022-21680

Impact

What kind of vulnerability is it?

Denial of service.

The regular expression block.def may cause catastrophic backtracking against some strings. PoC is the following.

import * as marked from "marked";

marked.parse(`[x]:${' '.repeat(1500)}x ${' '.repeat(1500)} x`);

Who is impacted?

Anyone who runs untrusted markdown through marked and does not use a worker with a time limit.

Patches

Has the problem been patched?

Yes

What versions should users upgrade to?

4.0.10

Workarounds

Is there a way for users to fix or remediate the vulnerability without upgrading?

Do not run untrusted markdown through marked or run marked on a worker thread and set a reasonable time limit to prevent draining resources.

References

Are there any links users can visit to find out more?

For more information

If you have any questions or comments about this advisory:


Configuration

πŸ“… Schedule: "" (UTC).

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

β™» Rebasing: Whenever PR is behind base branch, 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 WhiteSource Renovate. View repository job log here.

vercel[bot] commented 2 years ago

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

πŸ” Inspect: https://vercel.com/jamesrsingleton/hooks-arsenal/5XiF49M4yCtuz3zQksN96vm7UP7E
βœ… Preview: https://hooks-arsenal-git-renovate-npm-marked-vu-de7da6-jamesrsingleton.vercel.app

github-actions[bot] commented 2 years ago

This pull request is stale because it has been open 30 days with no activity. Remove no-pr-activity label or comment or this will be closed in 5 days.

renovate[bot] commented 2 years ago

⚠ Artifact update problem

Renovate failed to update an artifact related to this branch. You probably do not want to merge this PR as-is.

β™» Renovate will retry this branch, including artifacts, only when one of the following happens:

The artifact failure details are included below:

File name: package-lock.json
npm notice 
npm notice New minor version of npm available! 8.5.0 -> 8.6.0
npm notice Changelog: <https://github.com/npm/cli/releases/tag/v8.6.0>
npm notice Run `npm install -g npm@8.6.0` to update!
npm notice 
npm WARN ERESOLVE overriding peer dependency
npm WARN While resolving: airbnb-prop-types@2.16.0
npm WARN Found: react@17.0.2
npm WARN node_modules/react
npm WARN   dev react@"17.0.2" from the root project
npm WARN   6 more (@testing-library/react, ...)
npm WARN 
npm WARN Could not resolve dependency:
npm WARN peer react@"^0.14 || ^15.0.0 || ^16.0.0-alpha" from airbnb-prop-types@2.16.0
npm WARN node_modules/airbnb-prop-types
npm WARN   airbnb-prop-types@"^2.16.0" from enzyme-adapter-utils@1.14.0
npm WARN   node_modules/enzyme-adapter-utils
npm WARN 
npm WARN Conflicting peer dependency: react@16.14.0
npm WARN node_modules/react
npm WARN   peer react@"^0.14 || ^15.0.0 || ^16.0.0-alpha" from airbnb-prop-types@2.16.0
npm WARN   node_modules/airbnb-prop-types
npm WARN     airbnb-prop-types@"^2.16.0" from enzyme-adapter-utils@1.14.0
npm WARN     node_modules/enzyme-adapter-utils
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR! 
npm ERR! While resolving: amex-jest-preset-react@6.1.2
npm ERR! Found: react@17.0.2
npm ERR! node_modules/react
npm ERR!   dev react@"17.0.2" from the root project
npm ERR!   peer react@"*" from @testing-library/react@12.1.2
npm ERR!   node_modules/@testing-library/react
npm ERR!     dev @testing-library/react@"12.1.2" from the root project
npm ERR!   5 more (@testing-library/react-hooks, react-dom, ...)
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! peer react@"16.x" from amex-jest-preset-react@6.1.2
npm ERR! node_modules/amex-jest-preset-react
npm ERR!   dev amex-jest-preset-react@"6.1.2" from the root project
npm ERR! 
npm ERR! Conflicting peer dependency: react@16.14.0
npm ERR! node_modules/react
npm ERR!   peer react@"16.x" from amex-jest-preset-react@6.1.2
npm ERR!   node_modules/amex-jest-preset-react
npm ERR!     dev amex-jest-preset-react@"6.1.2" from the root project
npm ERR! 
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR! 
npm ERR! See /tmp/renovate-cache/others/npm/eresolve-report.txt for a full report.

npm ERR! A complete log of this run can be found in:
npm ERR!     /tmp/renovate-cache/others/npm/_logs/2022-04-01T00_39_32_398Z-debug-0.log