
Research
/Security News
Weaponizing Discord for Command and Control Across npm, PyPI, and RubyGems.org
Socket researchers uncover how threat actors weaponize Discord across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.
@ton-community/tlb-parser
Advanced tools
npm install @ton-community/tlb-parser
Create a file with TLB scheme according to the documentation. This is an example of such a file (call it example.tlb
):
t$_ x:# y:(uint 5) = A;
Then do:
npx tlb-parser example.tlb
Or you can use the tool from inside JS or TS code.
import { ast, NodeVisitor, ASTRootBase } from "@ton-community/tlb-parser";
class TestVisitor extends NodeVisitor {
public visited: { [key: string]: number };
constructor() {
super();
this.visited = {};
}
override genericVisit(node: nodes.ASTRootBase): void {
if (this.visited[node.constructor.name] === undefined) {
this.visited[node.constructor.name] = 0;
}
this.visited[node.constructor.name] += 1;
return super.genericVisit(node);
}
}
const scheme = `
t$_ x:# y:(uint 5) = A;
`;
const tree = ast(scheme);
const visitor = new TestVisitor();
visitor.visit(tree);
console.log(
util.inspect(
visitor.visited,
{showHidden: false, depth: null, colors: true},
),
);
console.log(
util.inspect(
tree,
{showHidden: false, depth: null, colors: true},
),
);
[0.1.5] - 2025-08-25
FAQs
Parse TLB syntax into TypeScript objects
The npm package @ton-community/tlb-parser receives a total of 1,054 weekly downloads. As such, @ton-community/tlb-parser popularity was classified as popular.
We found that @ton-community/tlb-parser demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 6 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
/Security News
Socket researchers uncover how threat actors weaponize Discord across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.
Security News
Socket now integrates with Bun 1.3’s Security Scanner API to block risky packages at install time and enforce your organization’s policies in local dev and CI.
Research
The Socket Threat Research Team is tracking weekly intrusions into the npm registry that follow a repeatable adversarial playbook used by North Korean state-sponsored actors.