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

666 bloom, hashing and secp256k1 pure and secure functions. #784

Merged
merged 10 commits into from
Apr 11, 2024

Conversation

lucanicoladebiasi
Copy link
Contributor

@lucanicoladebiasi lucanicoladebiasi commented Apr 9, 2024

Description

The code at packages

  • packages/core/src/bloom
  • packages/core/src/hash,
  • packages/core/src/secp256k1
  • packages/core/tests/utils/hex

is pure (no nodejs dependencies) and secure (can be certified to be cryptographic secure).

The code avoid any conversion between Uint8Array, string and Buffer.

Code and tests still using Buffer and strings are reworked to minimize the number of files changed.

Type of change

Please delete options that are not relevant.

  • New feature (non-breaking change which adds functionality)
  • No documentation changes, but the examples are adapted to the work with what secp256k1 provides.

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

  • yarn test:unit
  • yarn test:solo
  • yarn test:examples

Test Configuration:

  • Node.js Version: v21.6.2
  • Yarn Version: v1.22.21

Checklist:

  • My code follows the coding standards of this project
  • I have performed a self-review of my code
  • I have commented on my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • New and existing integration tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules
  • I have not added any vulnerable dependencies to my code

@lucanicoladebiasi lucanicoladebiasi self-assigned this Apr 9, 2024
@lucanicoladebiasi lucanicoladebiasi requested a review from a team as a code owner April 9, 2024 09:55
@lucanicoladebiasi lucanicoladebiasi marked this pull request as draft April 9, 2024 11:01
Copy link

Test Coverage

Summary

Lines Statements Branches Functions
Coverage: 100%
100% (2994/2994) 100% (620/620) 100% (626/626)
Title Tests Skipped Failures Errors Time
core 443 0 💤 0 ❌ 0 🔥 59.216s ⏱️
network 266 0 💤 0 ❌ 0 🔥 1m 42s ⏱️
errors 48 0 💤 0 ❌ 0 🔥 13.976s ⏱️

@fabiorigam fabiorigam merged commit edabbd3 into main Apr 11, 2024
11 checks passed
@fabiorigam fabiorigam deleted the 666-bloom-hash-secp256k1-pure-and-secure branch April 11, 2024 09:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants