Skip to content

chore: use keccak256 from ethereum-cryptography #28170

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

legobeat
Copy link
Contributor

@legobeat legobeat commented Oct 30, 2024

Description

  • chore: use keccak256 from ethereum-cryptography

Legacy ethereum-util is deprecated and uses a simialrly legacy version of keccak. This replaces usage with ethereum-cryptography (@noble/hashes).

Open in GitHub Codespaces

Related issues

Blocked by

Blocking

Manual testing steps

Screenshots/Recordings

Before

After

Pre-merge author checklist

Pre-merge reviewer checklist

  • I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed).
  • I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.

Copy link
Contributor

CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes.

@legobeat legobeat added dependencies Pull requests that update a dependency file team-security labels Oct 30, 2024
@legobeat legobeat added the type-tech-debt Technical debt label Oct 30, 2024
@legobeat legobeat force-pushed the deps-ethereumjs-util-keccak branch from 344f094 to 663b589 Compare October 30, 2024 04:05
@legobeat legobeat force-pushed the deps-ethereumjs-util-keccak branch 2 times, most recently from 89b2759 to 1f4eeb0 Compare October 30, 2024 05:02
@legobeat legobeat marked this pull request as ready for review October 30, 2024 05:03
@legobeat legobeat requested review from a team as code owners October 30, 2024 05:03
@legobeat legobeat force-pushed the deps-ethereumjs-util-keccak branch from 1f4eeb0 to 89db810 Compare October 30, 2024 05:27
@legobeat legobeat force-pushed the deps-ethereumjs-util-keccak branch 15 times, most recently from bd1ca09 to 508f025 Compare November 6, 2024 08:40
@legobeat legobeat force-pushed the deps-ethereumjs-util-keccak branch 2 times, most recently from 7621574 to 374ccbf Compare November 9, 2024 10:02
@legobeat legobeat force-pushed the deps-ethereumjs-util-keccak branch 2 times, most recently from 04d97e2 to e9b5bea Compare November 23, 2024 08:45
github-merge-queue bot pushed a commit that referenced this pull request Nov 26, 2024
## **Description**
- remove redundant resolutions entries
  - `ethereumjs-util` v5 is no longer present
- fix: use `BN` from bn.js (v5) instead of `ethereumjs-util` (deprecated
version)

[![Open in GitHub
Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/MetaMask/metamask-extension/pull/28146?quickstart=1)

## **Related issues**

#### Blocking
- #28169
  - #28171
  - #28170

## **Manual testing steps**

## **Screenshots/Recordings**

### **Before**

### **After**

## **Pre-merge author checklist**

- [x] I've followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask
Extension Coding
Standards](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/CODING_GUIDELINES.md).
- [x] I've completed the PR template to the best of my ability
- [x] I’ve included tests if applicable
- [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [x] I’ve applied the right labels on the PR (see [labeling
guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)).
Not required for external contributors.

## **Pre-merge reviewer checklist**

- [ ] I've manually tested the PR (e.g. pull and build branch, run the
app, test code being changed).
- [ ] I confirm that this PR addresses all acceptance criteria described
in the ticket it closes and includes the necessary testing evidence such
as recordings and or screenshots.
@legobeat legobeat force-pushed the deps-ethereumjs-util-keccak branch 2 times, most recently from ab339f5 to fd1bfc8 Compare December 14, 2024 01:35
@legobeat legobeat force-pushed the deps-ethereumjs-util-keccak branch 8 times, most recently from 479897b to e3a89c6 Compare December 22, 2024 03:22
@legobeat legobeat marked this pull request as draft December 23, 2024 22:27
@legobeat legobeat force-pushed the deps-ethereumjs-util-keccak branch from e3a89c6 to ce17b12 Compare December 23, 2024 22:27
@legobeat legobeat marked this pull request as ready for review December 23, 2024 22:45
@legobeat legobeat force-pushed the deps-ethereumjs-util-keccak branch from e815f24 to 31ad53c Compare January 9, 2025 22:19
@legobeat legobeat requested a review from a team as a code owner January 9, 2025 22:19
@legobeat legobeat force-pushed the deps-ethereumjs-util-keccak branch 2 times, most recently from d9acb20 to faa4608 Compare January 9, 2025 22:50
@legobeat legobeat force-pushed the deps-ethereumjs-util-keccak branch from faa4608 to 87ef2cf Compare January 9, 2025 23:03
@NicolasMassart NicolasMassart assigned legobeat and unassigned legobeat Mar 7, 2025
Copy link
Member

@leotm leotm left a comment

Choose a reason for hiding this comment

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

policy changes look OK RE

  • ethereum-cryptography
  • ethereum-cryptography>@noble/curves
  • ethereum-cryptography>@noble/curves>@noble/hashes

pending conflicts to resolve

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 external-contributor team-security type-tech-debt Technical debt
Projects
Status: Needs dev review
Development

Successfully merging this pull request may close these issues.

3 participants