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

@keystonehq/base-eth-keyring

Package Overview
Dependencies
Maintainers
2
Versions
63
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@keystonehq/base-eth-keyring - npm Package Compare versions

Comparing version 0.4.1-alpha.2 to 0.4.1-alpha.3

34

dist/base-eth-keyring.cjs.development.js

@@ -12,2 +12,3 @@ 'use strict';

var uuid = require('uuid');
var rlp = _interopDefault(require('rlp'));

@@ -385,21 +386,18 @@ const keyringType = "QR Hardware Wallet Device";

this.accounts = this.accounts.filter(a => a.toLowerCase() !== address.toLowerCase());
} // tx is an instance of the ethereumjs-transaction class.
}
async signTransaction(address, tx$1) {
const dataType = tx$1.type === 0 ? bcUrRegistryEth.DataType.transaction : bcUrRegistryEth.DataType.typedTransaction;
let messageToSign;
static serializeTx(tx) {
// need use EIP-155
// @ts-ignore
tx.v = new ethereumjsUtil.BN(tx.common.chainId()); // @ts-ignore
if (tx$1.type === 0) {
messageToSign = rlp.encode(tx$1.getMessageToSign(false));
} else {
messageToSign = tx$1.getMessageToSign(false);
}
tx.r = new ethereumjsUtil.BN(0); // @ts-ignore
tx.s = new ethereumjsUtil.BN(0);
return tx.serialize();
}
async signTransaction(address, tx$1) {
const hdPath = await this._pathFromAddress(address);
const chainId = tx$1.common.chainId();
const requestId = uuid.v4();
const ethSignRequest = bcUrRegistryEth.EthSignRequest.constructETHRequest(BaseKeyring.serializeTx(tx$1), bcUrRegistryEth.DataType.transaction, hdPath, this.xfp, requestId, chainId);
const ethSignRequest = bcUrRegistryEth.EthSignRequest.constructETHRequest(messageToSign, dataType, hdPath, this.xfp, requestId, chainId);
const {

@@ -410,10 +408,4 @@ r,

} = await this.requestSignature(requestId, ethSignRequest, "Scan with your Keystone", 'After your Keystone has signed the transaction, click on "Scan Keystone" to receive the signature');
const txJson = tx$1.toJSON();
return tx.Transaction.fromTxData({
to: txJson["to"],
gasLimit: txJson["gasLimit"],
gasPrice: txJson["gasPrice"],
data: txJson["data"],
nonce: txJson["nonce"],
value: txJson["value"],
return tx.TransactionFactory.fromTxData({ ...tx$1.toJSON(),
type: tx$1.type,
r,

@@ -420,0 +412,0 @@ s,

@@ -1,2 +0,2 @@

"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,t,i,r=(e=require("hdkey"))&&"object"==typeof e&&"default"in e?e.default:e,s=require("ethereumjs-util"),n=require("@ethereumjs/tx"),a=require("@keystonehq/bc-ur-registry-eth"),o=require("uuid");!function(e){e.hd="hd",e.pubkey="pubkey"}(t||(t={})),function(e){e.standard="account.standard",e.ledger_live="account.ledger_live",e.ledger_legacy="account.ledger_legacy"}(i||(i={}));class h{constructor(e){this.version=1,this.getInteraction=()=>{throw new Error("KeystoneError#invalid_extends: method getInteraction not implemented, please extend BaseKeyring by overwriting this method.")},this.type="QR Hardware Wallet Device",this.requestSignature=async(e,t,i,r)=>{const s=await this.getInteraction().requestSignature(t,i,r),n=s.getRequestId(),a=s.getSignature();if(n&&o.stringify(n)!==e)throw new Error("KeystoneError#invalid_data: read signature error: mismatched requestId");return{r:a.slice(0,32),s:a.slice(32,64),v:a.slice(64)}},this.__readCryptoHDKey=e=>{var t,r;const s="m/"+e.getOrigin().getPath(),n=null==(t=e.getOrigin().getSourceFingerprint())?void 0:t.toString("hex"),a=(null==(r=e.getChildren())?void 0:r.getPath())||"0/*",o=e.getName();if(e.getNote()===i.standard?this.keyringAccount=i.standard:e.getNote()===i.ledger_legacy&&(this.keyringAccount=i.ledger_legacy),!n)throw new Error("KeystoneError#invalid_data: invalid crypto-hdkey, cannot get source fingerprint");const h=e.getBip32Key();this.xfp=n,this.xpub=h,this.hdPath=s,this.childrenPath=a,void 0!==o&&""!==o&&(this.name=o),this.initialized=!0},this.__readCryptoAccount=e=>{var t,r;const n=null==(t=e.getMasterFingerprint())?void 0:t.toString("hex");if(!n)throw new Error("KeystoneError#invalid_data: invalid crypto-account, cannot get master fingerprint");this.xfp=n,this.initialized=!0;let a=!1;const o=e.getOutputDescriptors();if(!o||0===o.length)throw new Error("KeystoneError#invalid_data: invalid crypto-account, no crypto output found");if(o.length%5!=0)throw new Error("KeystoneError#invalid_data: only support 5x pubkey accounts for now");return null==(r=e.getOutputDescriptors())||r.forEach(e=>{try{const t=e.getHDKey();if(t){const e=t.getKey(),r="M/"+t.getOrigin().getPath(),n="0x"+s.publicToAddress(e,!0).toString("hex");this.name=t.getName(),t.getNote()===i.ledger_live&&(this.keyringAccount=i.ledger_live),void 0===this.paths[s.toChecksumAddress(n)]&&(a=!0),this.paths[s.toChecksumAddress(n)]=r}}catch(e){throw new Error("KeystoneError#invalid_data: "+e)}}),a},this.getName=()=>this.name,this.setAccountToUnlock=e=>{this.unlockedAccount=parseInt(e,10)},this.__getNormalPage=async e=>{this.page+=e,this.page<=0&&(this.page=1);const t=(this.page-1)*this.perPage,i=t+this.perPage,r=[];for(let e=t;e<i;e++){const t=await this.__addressFromIndex("m",e);r.push({address:t,balance:null,index:e}),this.indexes[s.toChecksumAddress(t)]=e}return r},this.__getLedgerLivePage=async e=>{const t=(this.page+e-1)*this.perPage,i=t+this.perPage,r=[];for(let e=t;e<i;e++){const t=await this.__addressFromIndex("m",e);r.push({address:t,balance:null,index:e})}return this.page+=e,r},this.__addressFromIndex=async(e,i)=>{if(this.keyringMode===t.hd){this.checkKeyring(),this.hdk||(this.hdk=r.fromExtendedKey(this.xpub));const t=this.childrenPath.replace("*",String(i)).replace(/\*/g,"0"),n=this.hdk.derive(`${e}/${t}`),a="0x"+s.publicToAddress(n.publicKey,!0).toString("hex");return s.toChecksumAddress(a)}{const e=Object.keys(this.paths)[i];if(e)return s.toChecksumAddress(e);throw new Error("KeystoneError#pubkey_account.no_expected_account")}},this.page=0,this.perPage=5,this.accounts=[],this.currentAccount=0,this.unlockedAccount=0,this.name="QR Hardware",this.keyringMode=t.hd,this.keyringAccount=i.standard,this.initialized=!1,this.xfp="",this.xpub="",this.hdPath="",this.childrenPath="0/*",this.indexes={},this.paths={},this.deserialize(e)}async readKeyring(){const e=await this.getInteraction().readCryptoHDKeyOrCryptoAccount();this.syncKeyring(e)}syncKeyring(e){e.getRegistryType().getType()===a.extend.RegistryTypes.CRYPTO_HDKEY.getType()?(this.keyringMode=t.hd,this.__readCryptoHDKey(e)):(this.keyringMode=t.pubkey,this.__readCryptoAccount(e))}checkKeyring(){if(!this.xfp||!this.xpub||!this.hdPath)throw new Error("KeystoneError#invalid_keyring: keyring not fulfilled, please call function `readKeyring` firstly")}serialize(){return Promise.resolve({initialized:this.initialized,accounts:this.accounts,currentAccount:this.currentAccount,page:this.page,perPage:this.perPage,keyringAccount:this.keyringAccount,keyringMode:this.keyringMode,name:this.name,version:this.version,xfp:this.xfp,xpub:this.xpub,hdPath:this.hdPath,childrenPath:this.childrenPath,indexes:this.indexes,paths:this.paths})}deserialize(e){e&&(this.accounts=e.accounts,this.currentAccount=e.currentAccount,this.page=e.page,this.perPage=e.perPage,this.name=e.name,this.initialized=e.initialized,this.keyringMode=e.keyringMode||t.hd,this.keyringAccount=e.keyringAccount||i.standard,this.xfp=e.xfp,this.xpub=e.xpub,this.hdPath=e.hdPath,this.indexes=e.indexes,this.paths=e.paths,this.childrenPath=e.childrenPath||"0/*")}setCurrentAccount(e){this.currentAccount=e}getCurrentAccount(){return this.currentAccount}getCurrentAddress(){return this.accounts[this.currentAccount]}async addAccounts(e=1){const t=this.unlockedAccount,i=t+e,r=[];for(let e=t;e<i;e++){const t=await this.__addressFromIndex("m",e);r.push(t),this.page=0,this.unlockedAccount++}return this.accounts=this.accounts.concat(r),this.accounts}getFirstPage(){return this.page=0,this.__getPage(1)}getNextPage(){return this.__getPage(1)}getPreviousPage(){return this.__getPage(-1)}async __getPage(e){return this.initialized||await this.readKeyring(),this.keyringMode===t.hd?this.__getNormalPage(e):this.__getLedgerLivePage(e)}getAccounts(){return Promise.resolve(this.accounts)}removeAccount(e){if(!this.accounts.map(e=>e.toLowerCase()).includes(e.toLowerCase()))throw new Error(`Address ${e} not found in this keyring`);this.accounts=this.accounts.filter(t=>t.toLowerCase()!==e.toLowerCase())}static serializeTx(e){return e.v=new s.BN(e.common.chainId()),e.r=new s.BN(0),e.s=new s.BN(0),e.serialize()}async signTransaction(e,t){const i=await this._pathFromAddress(e),r=t.common.chainId(),s=o.v4(),c=a.EthSignRequest.constructETHRequest(h.serializeTx(t),a.DataType.transaction,i,this.xfp,s,r),{r:d,s:u,v:g}=await this.requestSignature(s,c,"Scan with your Keystone",'After your Keystone has signed the transaction, click on "Scan Keystone" to receive the signature'),l=t.toJSON();return n.Transaction.fromTxData({to:l.to,gasLimit:l.gasLimit,gasPrice:l.gasPrice,data:l.data,nonce:l.nonce,value:l.value,r:d,s:u,v:g},{common:t.common})}signMessage(e,t){return this.signPersonalMessage(e,t)}async signPersonalMessage(e,t){const i=s.stripHexPrefix(t),r=await this._pathFromAddress(e),n=o.v4(),h=a.EthSignRequest.constructETHRequest(Buffer.from(i,"hex"),a.DataType.personalMessage,r,this.xfp,n,void 0,e),{r:c,s:d,v:u}=await this.requestSignature(n,h,"Scan with your Keystone",'After your Keystone has signed this message, click on "Scan Keystone" to receive the signature');return"0x"+Buffer.concat([c,d,u]).toString("hex")}async signTypedData(e,t){const i=await this._pathFromAddress(e),r=o.v4(),s=a.EthSignRequest.constructETHRequest(Buffer.from(JSON.stringify(t),"utf-8"),a.DataType.typedData,i,this.xfp,r,void 0,e),{r:n,s:h,v:c}=await this.requestSignature(r,s,"Scan with your Keystone",'After your Keystone has signed this data, click on "Scan Keystone" to receive the signature');return"0x"+Buffer.concat([n,h,c]).toString("hex")}async _pathFromAddress(e){if(this.keyringMode===t.hd){const t=s.toChecksumAddress(e);let i=this.indexes[t];if(void 0===i)for(let e=0;e<1e3;e++)if(t===await this.__addressFromIndex("m",e)){i=e;break}if(void 0===i)throw new Error("Unknown address");return`${this.hdPath}/${this.childrenPath.replace("*",i.toString()).replace(/\*/g,"0")}`}{const t=s.toChecksumAddress(e),i=this.paths[t];if(void 0===i)throw new Error("Unknown address");return i}}}h.type="QR Hardware Wallet Device",exports.BaseKeyring=h;
"use strict";function e(e){return e&&"object"==typeof e&&"default"in e?e.default:e}Object.defineProperty(exports,"__esModule",{value:!0});var t,r,i=e(require("hdkey")),s=require("ethereumjs-util"),n=require("@ethereumjs/tx"),a=require("@keystonehq/bc-ur-registry-eth"),o=require("uuid"),h=e(require("rlp"));!function(e){e.hd="hd",e.pubkey="pubkey"}(t||(t={})),function(e){e.standard="account.standard",e.ledger_live="account.ledger_live",e.ledger_legacy="account.ledger_legacy"}(r||(r={}));class c{constructor(e){this.version=1,this.getInteraction=()=>{throw new Error("KeystoneError#invalid_extends: method getInteraction not implemented, please extend BaseKeyring by overwriting this method.")},this.type="QR Hardware Wallet Device",this.requestSignature=async(e,t,r,i)=>{const s=await this.getInteraction().requestSignature(t,r,i),n=s.getRequestId(),a=s.getSignature();if(n&&o.stringify(n)!==e)throw new Error("KeystoneError#invalid_data: read signature error: mismatched requestId");return{r:a.slice(0,32),s:a.slice(32,64),v:a.slice(64)}},this.__readCryptoHDKey=e=>{var t,i;const s="m/"+e.getOrigin().getPath(),n=null==(t=e.getOrigin().getSourceFingerprint())?void 0:t.toString("hex"),a=(null==(i=e.getChildren())?void 0:i.getPath())||"0/*",o=e.getName();if(e.getNote()===r.standard?this.keyringAccount=r.standard:e.getNote()===r.ledger_legacy&&(this.keyringAccount=r.ledger_legacy),!n)throw new Error("KeystoneError#invalid_data: invalid crypto-hdkey, cannot get source fingerprint");const h=e.getBip32Key();this.xfp=n,this.xpub=h,this.hdPath=s,this.childrenPath=a,void 0!==o&&""!==o&&(this.name=o),this.initialized=!0},this.__readCryptoAccount=e=>{var t,i;const n=null==(t=e.getMasterFingerprint())?void 0:t.toString("hex");if(!n)throw new Error("KeystoneError#invalid_data: invalid crypto-account, cannot get master fingerprint");this.xfp=n,this.initialized=!0;let a=!1;const o=e.getOutputDescriptors();if(!o||0===o.length)throw new Error("KeystoneError#invalid_data: invalid crypto-account, no crypto output found");if(o.length%5!=0)throw new Error("KeystoneError#invalid_data: only support 5x pubkey accounts for now");return null==(i=e.getOutputDescriptors())||i.forEach(e=>{try{const t=e.getHDKey();if(t){const e=t.getKey(),i="M/"+t.getOrigin().getPath(),n="0x"+s.publicToAddress(e,!0).toString("hex");this.name=t.getName(),t.getNote()===r.ledger_live&&(this.keyringAccount=r.ledger_live),void 0===this.paths[s.toChecksumAddress(n)]&&(a=!0),this.paths[s.toChecksumAddress(n)]=i}}catch(e){throw new Error("KeystoneError#invalid_data: "+e)}}),a},this.getName=()=>this.name,this.setAccountToUnlock=e=>{this.unlockedAccount=parseInt(e,10)},this.__getNormalPage=async e=>{this.page+=e,this.page<=0&&(this.page=1);const t=(this.page-1)*this.perPage,r=t+this.perPage,i=[];for(let e=t;e<r;e++){const t=await this.__addressFromIndex("m",e);i.push({address:t,balance:null,index:e}),this.indexes[s.toChecksumAddress(t)]=e}return i},this.__getLedgerLivePage=async e=>{const t=(this.page+e-1)*this.perPage,r=t+this.perPage,i=[];for(let e=t;e<r;e++){const t=await this.__addressFromIndex("m",e);i.push({address:t,balance:null,index:e})}return this.page+=e,i},this.__addressFromIndex=async(e,r)=>{if(this.keyringMode===t.hd){this.checkKeyring(),this.hdk||(this.hdk=i.fromExtendedKey(this.xpub));const t=this.childrenPath.replace("*",String(r)).replace(/\*/g,"0"),n=this.hdk.derive(`${e}/${t}`),a="0x"+s.publicToAddress(n.publicKey,!0).toString("hex");return s.toChecksumAddress(a)}{const e=Object.keys(this.paths)[r];if(e)return s.toChecksumAddress(e);throw new Error("KeystoneError#pubkey_account.no_expected_account")}},this.page=0,this.perPage=5,this.accounts=[],this.currentAccount=0,this.unlockedAccount=0,this.name="QR Hardware",this.keyringMode=t.hd,this.keyringAccount=r.standard,this.initialized=!1,this.xfp="",this.xpub="",this.hdPath="",this.childrenPath="0/*",this.indexes={},this.paths={},this.deserialize(e)}async readKeyring(){const e=await this.getInteraction().readCryptoHDKeyOrCryptoAccount();this.syncKeyring(e)}syncKeyring(e){e.getRegistryType().getType()===a.extend.RegistryTypes.CRYPTO_HDKEY.getType()?(this.keyringMode=t.hd,this.__readCryptoHDKey(e)):(this.keyringMode=t.pubkey,this.__readCryptoAccount(e))}checkKeyring(){if(!this.xfp||!this.xpub||!this.hdPath)throw new Error("KeystoneError#invalid_keyring: keyring not fulfilled, please call function `readKeyring` firstly")}serialize(){return Promise.resolve({initialized:this.initialized,accounts:this.accounts,currentAccount:this.currentAccount,page:this.page,perPage:this.perPage,keyringAccount:this.keyringAccount,keyringMode:this.keyringMode,name:this.name,version:this.version,xfp:this.xfp,xpub:this.xpub,hdPath:this.hdPath,childrenPath:this.childrenPath,indexes:this.indexes,paths:this.paths})}deserialize(e){e&&(this.accounts=e.accounts,this.currentAccount=e.currentAccount,this.page=e.page,this.perPage=e.perPage,this.name=e.name,this.initialized=e.initialized,this.keyringMode=e.keyringMode||t.hd,this.keyringAccount=e.keyringAccount||r.standard,this.xfp=e.xfp,this.xpub=e.xpub,this.hdPath=e.hdPath,this.indexes=e.indexes,this.paths=e.paths,this.childrenPath=e.childrenPath||"0/*")}setCurrentAccount(e){this.currentAccount=e}getCurrentAccount(){return this.currentAccount}getCurrentAddress(){return this.accounts[this.currentAccount]}async addAccounts(e=1){const t=this.unlockedAccount,r=t+e,i=[];for(let e=t;e<r;e++){const t=await this.__addressFromIndex("m",e);i.push(t),this.page=0,this.unlockedAccount++}return this.accounts=this.accounts.concat(i),this.accounts}getFirstPage(){return this.page=0,this.__getPage(1)}getNextPage(){return this.__getPage(1)}getPreviousPage(){return this.__getPage(-1)}async __getPage(e){return this.initialized||await this.readKeyring(),this.keyringMode===t.hd?this.__getNormalPage(e):this.__getLedgerLivePage(e)}getAccounts(){return Promise.resolve(this.accounts)}removeAccount(e){if(!this.accounts.map(e=>e.toLowerCase()).includes(e.toLowerCase()))throw new Error(`Address ${e} not found in this keyring`);this.accounts=this.accounts.filter(t=>t.toLowerCase()!==e.toLowerCase())}async signTransaction(e,t){const r=0===t.type?a.DataType.transaction:a.DataType.typedTransaction;let i;i=0===t.type?h.encode(t.getMessageToSign(!1)):t.getMessageToSign(!1);const s=await this._pathFromAddress(e),c=t.common.chainId(),d=o.v4(),u=a.EthSignRequest.constructETHRequest(i,r,s,this.xfp,d,c),{r:g,s:y,v:p}=await this.requestSignature(d,u,"Scan with your Keystone",'After your Keystone has signed the transaction, click on "Scan Keystone" to receive the signature');return n.TransactionFactory.fromTxData({...t.toJSON(),type:t.type,r:g,s:y,v:p},{common:t.common})}signMessage(e,t){return this.signPersonalMessage(e,t)}async signPersonalMessage(e,t){const r=s.stripHexPrefix(t),i=await this._pathFromAddress(e),n=o.v4(),h=a.EthSignRequest.constructETHRequest(Buffer.from(r,"hex"),a.DataType.personalMessage,i,this.xfp,n,void 0,e),{r:c,s:d,v:u}=await this.requestSignature(n,h,"Scan with your Keystone",'After your Keystone has signed this message, click on "Scan Keystone" to receive the signature');return"0x"+Buffer.concat([c,d,u]).toString("hex")}async signTypedData(e,t){const r=await this._pathFromAddress(e),i=o.v4(),s=a.EthSignRequest.constructETHRequest(Buffer.from(JSON.stringify(t),"utf-8"),a.DataType.typedData,r,this.xfp,i,void 0,e),{r:n,s:h,v:c}=await this.requestSignature(i,s,"Scan with your Keystone",'After your Keystone has signed this data, click on "Scan Keystone" to receive the signature');return"0x"+Buffer.concat([n,h,c]).toString("hex")}async _pathFromAddress(e){if(this.keyringMode===t.hd){const t=s.toChecksumAddress(e);let r=this.indexes[t];if(void 0===r)for(let e=0;e<1e3;e++)if(t===await this.__addressFromIndex("m",e)){r=e;break}if(void 0===r)throw new Error("Unknown address");return`${this.hdPath}/${this.childrenPath.replace("*",r.toString()).replace(/\*/g,"0")}`}{const t=s.toChecksumAddress(e),r=this.paths[t];if(void 0===r)throw new Error("Unknown address");return r}}}c.type="QR Hardware Wallet Device",exports.BaseKeyring=c;
//# sourceMappingURL=base-eth-keyring.cjs.production.min.js.map
import HDKey from 'hdkey';
import { publicToAddress, toChecksumAddress, BN, stripHexPrefix } from 'ethereumjs-util';
import { Transaction } from '@ethereumjs/tx';
import { publicToAddress, toChecksumAddress, stripHexPrefix } from 'ethereumjs-util';
import { TransactionFactory } from '@ethereumjs/tx';
import { extend, EthSignRequest, DataType } from '@keystonehq/bc-ur-registry-eth';
import { stringify, v4 } from 'uuid';
import rlp from 'rlp';

@@ -378,21 +379,18 @@ const keyringType = "QR Hardware Wallet Device";

this.accounts = this.accounts.filter(a => a.toLowerCase() !== address.toLowerCase());
} // tx is an instance of the ethereumjs-transaction class.
}
async signTransaction(address, tx) {
const dataType = tx.type === 0 ? DataType.transaction : DataType.typedTransaction;
let messageToSign;
static serializeTx(tx) {
// need use EIP-155
// @ts-ignore
tx.v = new BN(tx.common.chainId()); // @ts-ignore
if (tx.type === 0) {
messageToSign = rlp.encode(tx.getMessageToSign(false));
} else {
messageToSign = tx.getMessageToSign(false);
}
tx.r = new BN(0); // @ts-ignore
tx.s = new BN(0);
return tx.serialize();
}
async signTransaction(address, tx) {
const hdPath = await this._pathFromAddress(address);
const chainId = tx.common.chainId();
const requestId = v4();
const ethSignRequest = EthSignRequest.constructETHRequest(BaseKeyring.serializeTx(tx), DataType.transaction, hdPath, this.xfp, requestId, chainId);
const ethSignRequest = EthSignRequest.constructETHRequest(messageToSign, dataType, hdPath, this.xfp, requestId, chainId);
const {

@@ -403,10 +401,4 @@ r,

} = await this.requestSignature(requestId, ethSignRequest, "Scan with your Keystone", 'After your Keystone has signed the transaction, click on "Scan Keystone" to receive the signature');
const txJson = tx.toJSON();
return Transaction.fromTxData({
to: txJson["to"],
gasLimit: txJson["gasLimit"],
gasPrice: txJson["gasPrice"],
data: txJson["data"],
nonce: txJson["nonce"],
value: txJson["value"],
return TransactionFactory.fromTxData({ ...tx.toJSON(),
type: tx.type,
r,

@@ -413,0 +405,0 @@ s,

/// <reference types="node" />
import { Transaction } from "@ethereumjs/tx";
import { TypedTransaction } from "@ethereumjs/tx";
import { CryptoHDKey, EthSignRequest, CryptoAccount } from "@keystonehq/bc-ur-registry-eth";

@@ -84,4 +84,3 @@ import { InteractionProvider } from "./InteractionProvider";

removeAccount(address: string): void;
private static serializeTx;
signTransaction(address: string, tx: Transaction): Promise<Transaction>;
signTransaction(address: string, tx: TypedTransaction): Promise<TypedTransaction>;
signMessage(withAccount: string, data: string): Promise<string>;

@@ -88,0 +87,0 @@ signPersonalMessage(withAccount: string, messageHex: string): Promise<string>;

{
"name": "@keystonehq/base-eth-keyring",
"version": "0.4.1-alpha.2",
"version": "0.4.1-alpha.3",
"description": "base eth keyring",

@@ -29,6 +29,7 @@ "author": "aaronisme <aarondongchen@gmail.com>",

"dependencies": {
"@ethereumjs/tx": "3.0.0",
"@ethereumjs/tx": "3.5.1",
"@keystonehq/bc-ur-registry-eth": "^0.9.1-alpha.2",
"ethereumjs-util": "^7.0.8",
"hdkey": "^2.0.1",
"rlp": "^3.0.0",
"uuid": "^8.3.2"

@@ -45,3 +46,3 @@ },

},
"gitHead": "d834a5413218c10fb5f021d691188135f4a4ba17"
"gitHead": "341aa52a660f1079e039ff383ff103c7e0792451"
}

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