
Security News
curl Shuts Down Bug Bounty Program After Flood of AI Slop Reports
A surge of AI-generated vulnerability reports has pushed open source maintainers to rethink bug bounties and tighten security disclosure processes.
@coolwallet/evm
Advanced tools
Typescript library with support for the integration of EVM compatible chain for third party application, include the functionalities of generation of addresses and signed transactions.
npm install @coolwallet/evm
import EVM from '@coolwallet/evm';
import { crypto } from '@coolwallet/core';
import { createTransport } from '@coolwallet/transport-web-ble';
// Select the chain
const chainId = 137; // Polygon Mainnet
const evm = new EVM(chainId);
const transport = await createTransport();
const { privateKey: appPrivateKey } = crypto.key.generateKeyPair();
const appId = 'appId that had been registered by wallet';
const addressIndex = 0;
const address = await evm.getAddress(transport, appPrivateKey, appId, addressIndex);
const transaction = {
nonce: '0x21d',
gasPrice: '0x59682f00',
gasLimit: '0x5208',
to: '0x81bb32e4A7e4d0500d11A52F3a5F60c9A6Ef126C',
value: '0x5af3107a4000',
data: '0x00',
};
const signTxData = {
transport,
appPrivateKey,
appId,
transaction,
addressIndex,
};
const normalTx = await evm.signTransaction(signTxData);
const signTxData = {
transport,
appPrivateKey,
appId,
transaction,
addressIndex,
};
const erc20Transaction = {
nonce: '0x85',
gasPrice: '0x23a427985a',
gasLimit: '0x72c2',
to: '0xe41d2489571d322189246dafa5ebde1f4699f498',
value: '0x0',
data: '0x00',
option: {
symbol: 'USDT',
unit: '6',
},
};
const erc20SignTxData = {
transport,
appPrivateKey,
appId,
transaction: erc20Transaction,
addressIndex,
};
const erc20Tx = await evm.signERC20Transaction(erc20SignTxData);
The address generated is compatible to BIP44 with account and change set to 0, which means calling getAddress with addressIndex = i will get the address of folllowing BIP44 path:
m/44'/60'/0'/0/{i}
In the design of current hardware, we only support path m/44'/60'/0'/0/{i} for speed optimization. This might change in the future and we will then open a more general interface to deal with custom path.
async getAddress(
transport: types.Transport,
appPrivateKey: string,
appId: string,
addressIndex: number
): Promise<string>
| Arg | Description | Type | Required |
|---|---|---|---|
| transport | Object to communicate with CoolWallet device | Transport | True |
| appPrivateKey | Private key for the connected application | string | True |
| appId | ID for the connected application | string | True |
| addressIndex | The from address index in BIP44 derivation | number | True |
Sign Ethereum Transaction. If the transaction has non-empty data field, the card will display SMART instead of transfering amount.
async signTransaction(signTxData: types.signTx): Promise<string>
| Arg | Description | Type | Required |
|---|---|---|---|
| transport | Object to communicate with CoolWallet device | Transport | True |
| appPrivateKey | Private key for the connected application | string | True |
| appId | ID for the connected application | string | True |
| transaction | Essential information/property for Ethereum Transaction | Transaction | True |
| addressIndex | The from address index in BIP44 derivation | number | True |
| publicKey | Public key of the from address | string | True |
Perform ethereum personal_sign.
async signMessage(signMsgData: types.signMsg): Promise<string>
| Arg | Description | Type | Required |
|---|---|---|---|
| transport | Object to communicate with CoolWallet device | Transport | True |
| appPrivateKey | Private key for the connected application | string | True |
| appId | ID for the connected application | string | True |
| message | Message to sign | string | True |
| addressIndex | The from address index in BIP44 derivation | number | True |
Perform ethereum sign_typed_data.
async signTypedData(typedData: types.signTyped): Promise<string>
| Arg | Description | Type | Required |
|---|---|---|---|
| transport | Object to communicate with CoolWallet device | Transport | True |
| appPrivateKey | Private key for the connected application | string | True |
| appId | ID for the connected application | string | True |
| typedData | Typed structured data to be signed | any | True |
| addressIndex | The from address index in BIP44 derivation | number | True |
mkdir src/chain/newsrc/chain/newtoken.ts:export const TOKENS = {};
index.ts:import { TOKENS } from './token';
import { ChainProps } from '../types';
class NewChain extends ChainProps {
id = NewChainId as number;
symbol = 'NewChainSymbol';
signature = '';
tokens = TOKENS;
}
export default new NewChain();
NewChain from src/chain/index.tsexport { default as NEW } from './new';
NewChain to tools/chain to generate encoded data which should be signed.console.log('New Chain Information', CHAIN.NEW.toHexChainInfo());
FAQs
Coolwallet EVMOS sdk
The npm package @coolwallet/evm receives a total of 72 weekly downloads. As such, @coolwallet/evm popularity was classified as not popular.
We found that @coolwallet/evm demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
A surge of AI-generated vulnerability reports has pushed open source maintainers to rethink bug bounties and tighten security disclosure processes.

Product
Scan results now load faster and remain consistent over time, with stable URLs and on-demand rescans for fresh security data.

Product
Socket's new Alert Details page is designed to surface more context, with a clearer layout, reachability dependency chains, and structured review.