Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Security] Bump jquery from 3.4.1 to 3.5.0 #1666

Closed

Conversation

dependabot-preview[bot]
Copy link

@dependabot-preview dependabot-preview bot commented Apr 29, 2020

⚠️ Dependabot Preview has been deactivated ⚠️

This pull request was created by Dependabot Preview, and you've upgraded to Dependabot. This means it won't respond to dependabot commands nor will it be automatically closed if a new version is found.

If you close this pull request, Dependabot will re-create it the next time it checks for updates and everything will work as expected.


Bumps jquery from 3.4.1 to 3.5.0. This update includes security fixes.

Vulnerabilities fixed

Sourced from The GitHub Security Advisory Database.

Potential XSS vulnerability in jQuery

Impact

Passing HTML from untrusted sources - even after sanitizing it - to one of jQuery's DOM manipulation methods (i.e. .html(), .append(), and others) may execute untrusted code.

Patches

This problem is patched in jQuery 3.5.0.

Workarounds

To workaround the issue without upgrading, adding the following to your code:

jQuery.htmlPrefilter = function( html ) {
	return html;
};

You need to use at least jQuery 1.12/2.2 or newer to be able to apply this workaround.

References

https://blog.jquery.com/2020/04/10/jquery-3-5-0-released/ https://jquery.com/upgrade-guide/3.5/

... (truncated)

Affected versions: >= 1.2 < 3.5.0

Sourced from The GitHub Security Advisory Database.

Potential XSS vulnerability in jQuery In jQuery versions greater than or equal to 1.0.3 and before 3.5.0, passing HTML containing elements from untrusted sources - even after sanitizing it - to one of jQuery's DOM manipulation methods (i.e. .html(), .append(), and others) may execute untrusted code.

This problem is patched in jQuery 3.5.0.

Affected versions: >= 1.0.3 < 3.5.0

Commits
  • 7a0a850 3.5.0
  • 8570a08 Release: Update AUTHORS.txt
  • da3dd85 Ajax: Do not execute scripts for unsuccessful HTTP responses
  • 065143c Ajax: Overwrite s.contentType with content-type header value, if any
  • 1a4f10d Tests: Blacklist one focusin test in IE
  • 9e15d6b Event: Use only one focusin/out handler per matching window & document
  • 966a709 Manipulation: Skip the select wrapper for <option> outside of IE 9
  • 1d61fd9 Manipulation: Make jQuery.htmlPrefilter an identity function
  • 04bf577 Selector: Update Sizzle from 2.3.4 to 2.3.5
  • 7506c9c Build: Resolve Travis config warnings
  • Additional commits viewable in compare view
Maintainer changes

This version was pushed to npm by mgol, a new releaser for jquery since your current version.


Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
  • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
  • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
  • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
  • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language
  • @dependabot badge me will comment on this PR with code to add a "Dependabot enabled" badge to your readme

Additionally, you can set the following in your Dependabot dashboard:

  • Update frequency (including time of day and day of week)
  • Pull request limits (per update run and/or open at any time)
  • Automerge options (never/patch/minor, and dev/runtime dependencies)
  • Out-of-range updates (receive only lockfile updates, if desired)
  • Security updates (receive only security updates, if desired)

@dependabot-preview dependabot-preview bot added dependencies Pull requests that update a dependency file security Pull requests that address a security vulnerability labels Apr 29, 2020
@dependabot-preview dependabot-preview bot force-pushed the dependabot/npm_and_yarn/jquery-3.5.0 branch 3 times, most recently from 4f122e8 to 0526e40 Compare July 5, 2020 22:13
@gitpod-io
Copy link

gitpod-io bot commented Jul 5, 2020

@dependabot-preview dependabot-preview bot force-pushed the dependabot/npm_and_yarn/jquery-3.5.0 branch 3 times, most recently from 56af406 to cd48647 Compare July 7, 2020 04:22
@codecov
Copy link

codecov bot commented Jul 7, 2020

Codecov Report

Merging #1666 (4655d4b) into main (853e719) will decrease coverage by 1.51%.
The diff coverage is 52.96%.

❗ Current head 4655d4b differs from pull request most recent head 53aa8b9. Consider uploading reports for the commit 53aa8b9 to get more accurate results
Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1666      +/-   ##
==========================================
- Coverage   66.67%   65.16%   -1.52%     
==========================================
  Files         130      137       +7     
  Lines        2686     2862     +176     
  Branches      433      462      +29     
==========================================
+ Hits         1791     1865      +74     
- Misses        895      997     +102     
Impacted Files Coverage Δ
src/Modules.js 100.00% <ø> (ø)
src/modules/EdgeDetect/Module.js 100.00% <ø> (ø)
src/modules/WebglDistort/Module.js 2.29% <0.00%> (ø)
src/modules/ColorHalftone/Module.js 3.63% <3.63%> (ø)
src/modules/Shadow/Module.js 44.30% <44.30%> (ø)
src/modules/Mask/Module.js 87.87% <87.87%> (ø)
src/modules/Overlay/Module.js 93.18% <94.11%> (-1.69%) ⬇️
src/modules/ColorHalftone/index.js 100.00% <100.00%> (ø)
src/modules/Colorbar/Module.js 100.00% <100.00%> (ø)
src/modules/Crop/Module.js 88.88% <100.00%> (ø)
... and 12 more

@dependabot-preview dependabot-preview bot force-pushed the dependabot/npm_and_yarn/jquery-3.5.0 branch 6 times, most recently from a0e2cb9 to 8173d54 Compare July 12, 2020 20:15
@jywarren
Copy link
Member

OK, seeing:

(node:8331) UnhandledPromiseRejectionWarning: Error: Protocol error (Runtime.callFunctionOn): Target closed.
    at Promise (/home/travis/build/publiclab/image-sequencer/node_modules/puppeteer/lib/Connection.js:183:56)
    at new Promise (<anonymous>)
    at CDPSession.send (/home/travis/build/publiclab/image-sequencer/node_modules/puppeteer/lib/Connection.js:182:12)
    at ExecutionContext._evaluateInternal (/home/travis/build/publiclab/image-sequencer/node_modules/puppeteer/lib/ExecutionContext.js:107:44)
    at ExecutionContext.evaluate (/home/travis/build/publiclab/image-sequencer/node_modules/puppeteer/lib/ExecutionContext.js:48:23)
    at ExecutionContext.<anonymous> (/home/travis/build/publiclab/image-sequencer/node_modules/puppeteer/lib/helper.js:112:23)
    at ElementHandle._scrollIntoViewIfNeeded (/home/travis/build/publiclab/image-sequencer/node_modules/puppeteer/lib/JSHandle.js:163:49)
    at ElementHandle.click (/home/travis/build/publiclab/image-sequencer/node_modules/puppeteer/lib/JSHandle.js:264:16)
    at ElementHandle.<anonymous> (/home/travis/build/publiclab/image-sequencer/node_modules/puppeteer/lib/helper.js:112:23)
    at DOMWorld.click (/home/travis/build/publiclab/image-sequencer/node_modules/puppeteer/lib/DOMWorld.js:367:18)
  -- ASYNC --

and

  ● Clear and Delete Steps › Resize Module is added
    TypeError: e.hasOwnProperty is not a function
      at m.getOptions (file:/home/travis/build/publiclab/image-sequencer/node_modules/bootstrap/dist/js/bootstrap.min.js:6:23482)

I'm going to try restarting, but not sure what's going on here...

@jywarren
Copy link
Member

This is a pretty big breaking change so 3.5.0 didn't apparently respect semantic versioning:

Potential XSS vulnerability in jQuery

Impact

Passing HTML from untrusted sources - even after sanitizing it - to one of jQuery's DOM manipulation methods (i.e. .html(), .append(), and others) may execute untrusted code.

Patches

This problem is patched in jQuery 3.5.0.

Workarounds

To workaround the issue without upgrading, adding the following to your code:

jQuery.htmlPrefilter = function( html ) {
	return html;
};

You need to use at least jQuery 1.12/2.2 or newer to be able to apply this workaround.

References

https://blog.jquery.com/2020/04/10/jquery-3-5-0-released/ https://jquery.com/upgrade-guide/3.5/

... (truncated)

Affected versions: >= 1.2 < 3.5.0

@dependabot-preview dependabot-preview bot force-pushed the dependabot/npm_and_yarn/jquery-3.5.0 branch 5 times, most recently from d2aab02 to e46b0c5 Compare August 5, 2020 23:33
@dependabot-preview dependabot-preview bot force-pushed the dependabot/npm_and_yarn/jquery-3.5.0 branch from e46b0c5 to 267b5fc Compare September 21, 2020 21:53
@dependabot-preview dependabot-preview bot force-pushed the dependabot/npm_and_yarn/jquery-3.5.0 branch from 267b5fc to fe56be0 Compare October 6, 2020 15:57
@jywarren
Copy link
Member

jywarren commented Oct 6, 2020

Hmm, a variety of issues like these, that don't seem related to the jQuery change but could be?

  ● Clear and Delete Steps › Resize Module is added
    TypeError: e.hasOwnProperty is not a function
      at m.getOptions (file:/home/travis/build/publiclab/image-sequencer/node_modules/bootstrap/dist/js/bootstrap.min.js:6:23482)
      at m.init (file:/home/travis/build/publiclab/image-sequencer/node_modules/bootstrap/dist/js/bootstrap.min.js:6:22370)
      at new m (file:/home/travis/build/publiclab/image-sequencer/node_modules/bootstrap/dist/js/bootstrap.min.js:6:21893)
      at HTMLAnchorElement.<anonymous> (file:/home/travis/build/publiclab/image-sequencer/node_modules/bootstrap/dist/js/bootstrap.min.js:6:30920)
      at Function.each (file:/home/travis/build/publiclab/image-sequencer/node_modules/jquery/dist/jquery.min.js:2:2976)
      at S.fn.init.each (file:/home/travis/build/publiclab/image-sequencer/node_modules/jquery/dist/jquery.min.js:2:1454)
      at S.fn.init.i [as tooltip] (file:/home/travis/build/publiclab/image-sequencer/node_modules/bootstrap/dist/js/bootstrap.min.js:6:30789)
      at HTMLDocument.<anonymous> (file:/home/travis/build/publiclab/image-sequencer/dist/image-sequencer-ui.js:912:36)
      at e (file:/home/travis/build/publiclab/image-sequencer/node_modules/jquery/dist/jquery.min.js:2:30005)
      at t (file:/home/travis/build/publiclab/image-sequencer/node_modules/jquery/dist/jquery.min.js:2:30307)
      at Suite.describe (test/ui-2/test/clear_and_delete_step.test.js:13:3)
  ● Clear and Delete Steps › Brightness Module is added
    expect(received).toBe(expected) // Object.is equality
    Expected: 3
    Received: 2
      25 |     await page.click('[data-value=\'brightness\']');
      26 |     const Length2 = await page.evaluate(() => document.querySelectorAll('.step').length);
    > 27 |     expect(Length2).toBe(3);
         |                     ^
      28 |   }, timeout);
      29 | 
      30 |   test('Contrast Module is added', async () => {
      at Object.test (test/ui-2/test/clear_and_delete_step.test.js:27:21)

@dependabot-preview dependabot-preview bot force-pushed the dependabot/npm_and_yarn/jquery-3.5.0 branch 4 times, most recently from 77a7e9e to 9934e26 Compare October 14, 2020 23:06
@dependabot-preview dependabot-preview bot force-pushed the dependabot/npm_and_yarn/jquery-3.5.0 branch 3 times, most recently from 1151d4a to 33905d3 Compare March 24, 2021 22:47
@dependabot-preview dependabot-preview bot force-pushed the dependabot/npm_and_yarn/jquery-3.5.0 branch 6 times, most recently from 1d0f2d1 to 4770d20 Compare March 31, 2021 17:44
@dependabot-preview dependabot-preview bot force-pushed the dependabot/npm_and_yarn/jquery-3.5.0 branch 6 times, most recently from d6d624e to fa655cf Compare April 15, 2021 21:05
@dependabot-preview dependabot-preview bot force-pushed the dependabot/npm_and_yarn/jquery-3.5.0 branch 5 times, most recently from 69977ba to dccf475 Compare April 30, 2021 13:47
@gitpod-io
Copy link

gitpod-io bot commented Apr 30, 2021

@dependabot-preview dependabot-preview bot force-pushed the dependabot/npm_and_yarn/jquery-3.5.0 branch from dccf475 to ddd439c Compare May 6, 2021 21:00
@dependabot-preview dependabot-preview bot force-pushed the dependabot/npm_and_yarn/jquery-3.5.0 branch 2 times, most recently from 4531b02 to 37eeb7c Compare May 18, 2021 20:01
Bumps [jquery](https://github.com/jquery/jquery) from 3.4.1 to 3.5.0. **This update includes security fixes.**
- [Release notes](https://github.com/jquery/jquery/releases)
- [Commits](jquery/jquery@3.4.1...3.5.0)

Signed-off-by: dependabot-preview[bot] <[email protected]>
@dependabot-preview dependabot-preview bot force-pushed the dependabot/npm_and_yarn/jquery-3.5.0 branch from 37eeb7c to 53aa8b9 Compare May 18, 2021 20:22
@harshkhandeparkar
Copy link
Member

Superseeded by #1890

@dependabot-preview
Copy link
Author

OK, I won't notify you again about this release, but will get in touch when a new version is available.

If you change your mind, just re-open this PR and I'll resolve any conflicts on it.

@dependabot-preview dependabot-preview bot deleted the dependabot/npm_and_yarn/jquery-3.5.0 branch July 27, 2021 20:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file security Pull requests that address a security vulnerability
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants