
Research
Malicious npm Packages Impersonate Flashbots SDKs, Targeting Ethereum Wallet Credentials
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
@tonconnect/protocol
Advanced tools
ℹ️ If you want to integrate TonConnect to your dApp, you should use [@tonconnect/sdk](https://www.npmjs.com/package/@tonconnect/sdk)
ℹ️ If you want to integrate TonConnect to your dApp, you should use @tonconnect/sdk
Package contains protocol requests, responses and event models and encoding, decoding functions.
You can use it to integrate TonConnect to your wallet app (written with TypeScript).
npm i @tonconnect/protocol
import { AppRequest, RpcMethod, WalletResponse } from '@tonconnect/protocol';
function myWalletAppRequestsHandler<T extends RpcMethod>(request: AppRequest<T>): Promise<WalletResponse<T>> {
// handle request, ask the user for a confirmation and return WalletResponse
}
import { SessionCrypto, WalletMessage, Base64, hexToByteArray } from '@tonconnect/protocol';
function encodeIncommingHTTPBridgeRequest(encryptedMessage: string, from: string): WalletMessage {
const sessionCrypto = new SessionCrypto(yourStoredSessionReypair);
const decryptedMessage =
sessionCrypto.decrypt(
Base64.decode(bridgeIncomingMessage.message).toUint8Array(),
hexToByteArray(bridgeIncomingMessage.from)
);
return JSON.parse(decryptedMessage);
}
FAQs
ℹ️ If you want to integrate TonConnect to your dApp, you should use [@tonconnect/sdk](https://www.npmjs.com/package/@tonconnect/sdk)
The npm package @tonconnect/protocol receives a total of 40,515 weekly downloads. As such, @tonconnect/protocol popularity was classified as popular.
We found that @tonconnect/protocol demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 4 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.
Research
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.
Security News
Following last week’s supply chain attack, Nx published findings on the GitHub Actions exploit and moved npm publishing to Trusted Publishers.