Security News
The Risks of Misguided Research in Supply Chain Security
Snyk's use of malicious npm packages for research raises ethical concerns, highlighting risks in public deployment, data exfiltration, and unauthorized testing.
@portkey/contracts
Advanced tools
![ES Version](https://img.shields.io/badge/ES-2020-yellow) ![Node Version](https://img.shields.io/badge/node-14.x-green) [![NPM Package Version][npm-image-version]][npm-url]
@portkey/contracts
npm install @portkey/contracts
yarn add @portkey/contracts
Script | Description |
---|---|
clean | Uses rm to remove dist/ |
build | Uses tsc to build package and dependent packages |
lint | Uses eslint to lint package |
lint:fix | Uses eslint to check and fix any warnings |
format | Uses prettier to format the code |
import { getContractBasic } from '@portkey/contracts'
// use ca contract
const contract = await getContractBasic({
chainType: 'aelf',
account: 'your account',
contractAddress: 'contractAddress',
caContractAddress: 'caContractAddress',
callType: 'ca',
caHash: 'caHash',
rpcUrl: 'rpcUrl',
});
// use base contract
const contract = await getContractBasic({
account: 'your account',
contractAddress: 'contractAddress',
chainType: 'aelf',
rpcUrl: 'rpcUrl',
})
// use portkey provider
import detectProvider from '@portkey/detect-provider';
// detect provider
const provider = await detectProvider();
// get chain provider
const chainProvider = await provider.getChain('AELF');
const contract = await getContractBasic({
chainProvider,
contractAddress: 'contractAddress',
});
// call view
contract.callViewMethod('your method', paramsOption);
// call send
contract.callSendMethod('your method', 'your address', paramsOption);
FAQs
![ES Version](https://img.shields.io/badge/ES-2020-yellow) ![Node Version](https://img.shields.io/badge/node-14.x-green) [![NPM Package Version][npm-image-version]][npm-url]
The npm package @portkey/contracts receives a total of 1,582 weekly downloads. As such, @portkey/contracts popularity was classified as popular.
We found that @portkey/contracts demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers 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
Snyk's use of malicious npm packages for research raises ethical concerns, highlighting risks in public deployment, data exfiltration, and unauthorized testing.
Research
Security News
Socket researchers found several malicious npm packages typosquatting Chalk and Chokidar, targeting Node.js developers with kill switches and data theft.
Security News
pnpm 10 blocks lifecycle scripts by default to improve security, addressing supply chain attack risks but sparking debate over compatibility and workflow changes.