Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ox

Package Overview
Dependencies
Maintainers
0
Versions
237
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ox - npm Package Compare versions

Comparing version 0.0.0-canary-20241118200512 to 0.0.0-canary-20241123141635

_cjs/core/internal/entropy.js

7

_cjs/core/P256.js

@@ -13,2 +13,3 @@ "use strict";

const PublicKey = require("./PublicKey.js");
const Entropy = require("./internal/entropy.js");
exports.noble = p256_1.secp256r1;

@@ -39,3 +40,7 @@ function getPublicKey(options) {

const { hash, payload, privateKey } = options;
const { r, s, recovery } = p256_1.secp256r1.sign(payload instanceof Uint8Array ? payload : Bytes.fromHex(payload), privateKey instanceof Uint8Array ? privateKey : Bytes.fromHex(privateKey), ...(hash ? [{ prehash: true, lowS: true }] : []));
const { r, s, recovery } = p256_1.secp256r1.sign(payload instanceof Uint8Array ? payload : Bytes.fromHex(payload), privateKey instanceof Uint8Array ? privateKey : Bytes.fromHex(privateKey), {
extraEntropy: Entropy.extraEntropy,
lowS: true,
...(hash ? { prehash: true } : {}),
});
return {

@@ -42,0 +47,0 @@ r,

@@ -15,2 +15,3 @@ "use strict";

const PublicKey = require("./PublicKey.js");
const Entropy = require("./internal/entropy.js");
exports.noble = secp256k1_1.secp256k1;

@@ -41,3 +42,7 @@ function getPublicKey(options) {

const { hash, payload, privateKey } = options;
const { r, s, recovery } = secp256k1_1.secp256k1.sign(Bytes.from(payload), Bytes.from(privateKey), ...(hash ? [{ prehash: true, lowS: true }] : []));
const { r, s, recovery } = secp256k1_1.secp256k1.sign(Bytes.from(payload), Bytes.from(privateKey), {
extraEntropy: Entropy.extraEntropy,
lowS: true,
...(hash ? { prehash: true } : {}),
});
return {

@@ -44,0 +49,0 @@ r,

2

_cjs/version.js
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.version = void 0;
exports.version = '0.0.0-canary-20241118200512';
exports.version = '0.0.0-canary-20241123141635';
//# sourceMappingURL=version.js.map

@@ -5,2 +5,3 @@ import { secp256r1 } from '@noble/curves/p256';

import * as PublicKey from './PublicKey.js';
import * as Entropy from './internal/entropy.js';
/** Re-export of noble/curves P256 utilities. */

@@ -92,3 +93,7 @@ export const noble = secp256r1;

const { hash, payload, privateKey } = options;
const { r, s, recovery } = secp256r1.sign(payload instanceof Uint8Array ? payload : Bytes.fromHex(payload), privateKey instanceof Uint8Array ? privateKey : Bytes.fromHex(privateKey), ...(hash ? [{ prehash: true, lowS: true }] : []));
const { r, s, recovery } = secp256r1.sign(payload instanceof Uint8Array ? payload : Bytes.fromHex(payload), privateKey instanceof Uint8Array ? privateKey : Bytes.fromHex(privateKey), {
extraEntropy: Entropy.extraEntropy,
lowS: true,
...(hash ? { prehash: true } : {}),
});
return {

@@ -95,0 +100,0 @@ r,

@@ -6,2 +6,3 @@ import { secp256k1 } from '@noble/curves/secp256k1';

import * as PublicKey from './PublicKey.js';
import * as Entropy from './internal/entropy.js';
/** Re-export of noble/curves secp256k1 utilities. */

@@ -111,3 +112,7 @@ export const noble = secp256k1;

const { hash, payload, privateKey } = options;
const { r, s, recovery } = secp256k1.sign(Bytes.from(payload), Bytes.from(privateKey), ...(hash ? [{ prehash: true, lowS: true }] : []));
const { r, s, recovery } = secp256k1.sign(Bytes.from(payload), Bytes.from(privateKey), {
extraEntropy: Entropy.extraEntropy,
lowS: true,
...(hash ? { prehash: true } : {}),
});
return {

@@ -114,0 +119,0 @@ r,

/** @internal */
export const version = '0.0.0-canary-20241118200512';
export const version = '0.0.0-canary-20241123141635';
//# sourceMappingURL=version.js.map

@@ -10,17 +10,3 @@ import * as Address from './Address.js';

export declare const noble: Readonly<{
create: (hash: import("@noble/curves/abstract/utils.js").CHash) => import(
/**
* Computes the secp256k1 ECDSA public key from a provided private key.
*
* @example
* ```ts twoslash
* import { Secp256k1 } from 'ox'
*
* const publicKey = Secp256k1.getPublicKey({ privateKey: '0x...' })
* ```
*
* @param options - The options to compute the public key.
* @returns The computed public key.
*/
"@noble/curves/abstract/weierstrass.js").CurveFn;
create: (hash: import("@noble/curves/abstract/utils.js").CHash) => import("@noble/curves/abstract/weierstrass.js").CurveFn;
CURVE: ReturnType<(curve: import("@noble/curves/abstract/weierstrass.js").CurveType) => Readonly<{

@@ -27,0 +13,0 @@ readonly nBitLength: number;

/** @internal */
export declare const version = "0.0.0-canary-20241118200512";
export declare const version = "0.0.0-canary-20241123141635";
//# sourceMappingURL=version.d.ts.map
# ox
## 0.0.0-canary-20241118200512
## 0.0.0-canary-20241123141635
### Patch Changes
- [`9ad0d2c`](https://github.com/wevm/ox/commit/9ad0d2c9777b5c6a8c1cd64ad8742f9c05706606) Thanks [@jxom](https://github.com/jxom)! - Added non-deterministic signature generation.
## 0.2.2
### Patch Changes
- [`4f40358`](https://github.com/wevm/ox/commit/4f4035826313dce974b7c7fa64ba4ea20d1f7f61) Thanks [@jxom](https://github.com/jxom)! - Tweaked `RpcResponse` and `Provider` errors to have optional parameters.

@@ -8,0 +14,0 @@

@@ -7,2 +7,3 @@ import { secp256r1 } from '@noble/curves/p256'

import type * as Signature from './Signature.js'
import * as Entropy from './internal/entropy.js'

@@ -154,3 +155,7 @@ /** Re-export of noble/curves P256 utilities. */

privateKey instanceof Uint8Array ? privateKey : Bytes.fromHex(privateKey),
...(hash ? [{ prehash: true, lowS: true }] : []),
{
extraEntropy: Entropy.extraEntropy,
lowS: true,
...(hash ? { prehash: true } : {}),
},
)

@@ -157,0 +162,0 @@ return {

@@ -8,2 +8,3 @@ import { secp256k1 } from '@noble/curves/secp256k1'

import type * as Signature from './Signature.js'
import * as Entropy from './internal/entropy.js'
import type { OneOf } from './internal/types.js'

@@ -195,3 +196,7 @@

Bytes.from(privateKey),
...(hash ? [{ prehash: true, lowS: true }] : []),
{
extraEntropy: Entropy.extraEntropy,
lowS: true,
...(hash ? { prehash: true } : {}),
},
)

@@ -198,0 +203,0 @@ return {

{
"name": "ox",
"description": "Ethereum Standard Library",
"version": "0.0.0-canary-20241118200512",
"version": "0.0.0-canary-20241123141635",
"main": "./_cjs/index.js",

@@ -6,0 +6,0 @@ "module": "./_esm/index.js",

/** @internal */
export const version = '0.0.0-canary-20241118200512'
export const version = '0.0.0-canary-20241123141635'

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc