Skip to content

Conversation

@rekmarks
Copy link
Member

@rekmarks rekmarks commented Nov 3, 2023

Migrate Node from v16 (EOL) to v18 and migrate Webpack from v4 to v5.

To test, build using yarn start or yarn build and check that the output in dist/ is as expected (no change from main).

Set minimum Node.js version to v18 and migrate
Webpack from v4 to v5.
}
}
},
"packageManager": "yarn@1.22.19"
Copy link
Member Author

Choose a reason for hiding this comment

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

This is to ensure that correct Yarn version is used for people with Yarn >=2 installed. Can be changed when we migrate this to Yarn 3/4.

"ethereumjs-util": "^5.1.1",
"ethers": "^5.0.32",
"gh-pages": "^3.1.0",
"node-polyfill-webpack-plugin": "^2.0.1",
Copy link
Member Author

Choose a reason for hiding this comment

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

Webpack 4 had Node polyfills by default. For Webpack 5 you need to do it via a plugin.

@socket-security
Copy link

New, updated, and removed dependencies detected. Learn more about Socket for GitHub ↗︎

Packages Version New capabilities Transitives Size Publisher
node-polyfill-webpack-plugin 2.0.1 shell +64 9.14 MB richienb
webpack-cli 3.3.12...5.1.4 None +35/-243 6.62 MB evilebottnawi
clean-webpack-plugin 3.0.0...4.0.0 None +17/-215 5.92 MB johnagan
webpack-dev-server 3.11.2...4.15.1 network +68/-274 9.95 MB evilebottnawi
copy-webpack-plugin 6.0.2...11.0.0 None +28/-227 6.56 MB evilebottnawi

🚮 Removed packages: webpack@4.43.0

@socket-security
Copy link

🚨 Potential security issues detected. Learn more about Socket for GitHub ↗︎

To accept the risk, merge this PR and you will not be notified again.

Issue Package Version Note Source
Deprecated memfs 3.6.0
  • Reason: this will be v4
Network access webpack-dev-server 4.15.1
Network access bonjour-service 1.1.1
New author tty-browserify 0.0.1
New author browserify-sign 4.2.2
Unstable ownership browserify-sign 4.2.2
New author assert 2.1.0
New author hasown 2.0.0
Unstable ownership hasown 2.0.0
New author for-each 0.3.3
No README launch-editor 2.6.1
Shell access launch-editor 2.6.1
Shell access update-browserslist-db 1.0.13
Unpublished package define-properties 1.2.1
  • Version: 1/2/2001, 12:00:00 AM

Next steps

What is a deprecated package?

The maintainer of the package marked it as deprecated. This could indicate that a single version should not be used, or that the package is no longer maintained and any new vulnerabilities will not be fixed.

Research the state of the package and determine if there are non-deprecated versions that can be used, or if it should be replaced with a new, supported solution.

What is network access?

This module accesses the network.

Packages should remove all network access that is functionally unnecessary. Consumers should audit network access to ensure legitimate use.

What is new author?

A new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.

Scrutinize new collaborator additions to packages because they now have the ability to publish code into your dependency tree. Packages should avoid frequent or unnecessary additions or changes to publishing rights.

What is unstable ownership?

A new collaborator has begun publishing package versions. Package stability and security risk may be elevated.

Try to reduce the amount of authors you depend on to reduce the risk to malicious actors gaining access to your supply chain. Packages should remove inactive collaborators with publishing rights from packages on npm.

Why are READMEs important?

Package does not have a README. This may indicate a failed publish or a low quality package.

Add a README to to the package and publish a new version.

What is shell access?

This module accesses the system shell. Accessing the system shell increases the risk of executing arbitrary code.

Packages should avoid accessing the shell which can reduce portability, and make it easier for malicious shell access to be introduced.

What are unpublished packages?

Package version was not found on the registry. It may exist on a different registry and need to be configured to pull from that registry.

Packages can be removed from the registry by manually un-publishing, a security issue removal, or may simply never have been published to the registry. Reliance on these packages will cause problem when they are not found.

Take a deeper look at the dependency

Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support [AT] socket [DOT] dev.

Remove the package

If you happen to install a dependency that Socket reports as Known Malware you should immediately remove it and select a different dependency. For other alert types, you may may wish to investigate alternative packages or consider if there are other ways to mitigate the specific risk posed by the dependency.

Mark a package as acceptable risk

To ignore an alert, reply with a comment starting with @SocketSecurity ignore followed by a space separated list of package-name@version specifiers. e.g. @SocketSecurity ignore foo@1.0.0 bar@* or ignore all packages with @SocketSecurity ignore-all

  • @SocketSecurity ignore launch-editor@2.6.1
  • @SocketSecurity ignore tty-browserify@0.0.1
  • @SocketSecurity ignore browserify-sign@4.2.2
  • @SocketSecurity ignore assert@2.1.0
  • @SocketSecurity ignore hasown@2.0.0
  • @SocketSecurity ignore for-each@0.3.3
  • @SocketSecurity ignore memfs@3.6.0
  • @SocketSecurity ignore update-browserslist-db@1.0.13
  • @SocketSecurity ignore define-properties@1.2.1
  • @SocketSecurity ignore webpack-dev-server@4.15.1
  • @SocketSecurity ignore bonjour-service@1.1.1

@rekmarks
Copy link
Member Author

rekmarks commented Nov 3, 2023

Closing in favor of #264.

@rekmarks rekmarks closed this Nov 3, 2023
@rekmarks rekmarks deleted the webpack-5 branch November 3, 2023 17:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants