
Research
/Security News
5 Malicious Rust Crates Posed as Time Utilities to Exfiltrate .env Files
Published late February to early March 2026, these crates impersonate timeapi.io and POST .env secrets to a threat actor-controlled lookalike domain.
html5parser
Advanced tools
A simple and fast html5 parser, the result could be manipulated like ECMAScript ESTree, especially about the attributes.
# var npm
npm install html5parser -S
# var yarn
yarn add html5parser
import * as html from 'html5parser'
const input = `
<!DOCTYPE html>
<html>
<body>
<h1 id="hello">Hello world</h1>
</body>
</html>
`
const ast = html.parse()
html.walk(ast, {
enter: (node) => {
if (node.type === html.SyntaxKind.Tag) {
for (const attr of node.attributes) {
if (attr.value !== void 0) {
console.log(input.substring(attr.value.start, attr.value.end))
}
}
}
}
})
// Should output:
// hello
// Top level API, parse html to ast tree
export function parse(input: string): INode[];
// Low level API, get tokens
export function tokenize(input: string): IToken[];
The AST tree structure: types.ts
This is use for HTML5, that means:
<? ... ?>, <! ... > (except for <!doctype ...>, case insensitive)
is treated as Comment, that means CDATASection is treated as comment."!doctype" (case insensitive), the doctype declaration"!": short comment"!--": normal comment""(empty string): short comment, for <? ... >, the leading ? is treated as comment contentFAQs
A super fast & tiny HTML5 parser
The npm package html5parser receives a total of 45,892 weekly downloads. As such, html5parser popularity was classified as popular.
We found that html5parser demonstrated a not healthy version release cadence and project activity because the last version was released 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.

Research
/Security News
Published late February to early March 2026, these crates impersonate timeapi.io and POST .env secrets to a threat actor-controlled lookalike domain.

Security News
A recent burst of security disclosures in the OpenClaw project is drawing attention to how vulnerability information flows across advisory and CVE systems.

Research
/Security News
Mixed-script homoglyphs and a lookalike domain mimic imToken’s import flow to capture mnemonics and private keys.