
Research
Namastex.ai npm Packages Hit with TeamPCP-Style CanisterWorm Malware
Malicious Namastex.ai npm packages appear to replicate TeamPCP-style Canister Worm tradecraft, including exfiltration and self-propagation.
This is a library that converts between XML and JavaScript objects. The conversion is not necessarily lossless but it is very convenient.
| master | development |
|---|---|
The code is all contained within the x2js.js file, so you can include it directly
via a script tag. It will create window.X2JS, which is a constructor that can be
used to create instances of the converter, providing an optional configuration object.
In a Node app, require("x2js") will give you the constructor that you can use the same way.
Loading via AMD-capable loaders (e.g. require.js) is also supported and works equivalently.
The xmldom package is a dependency but it is only used under Node, as in browsers the browser DOM is used.
var x2js = new X2JS();
var document = x2js.xml2js(xml);
console.log(document.MyRootElement.ElementX[1].toString());
var xml = x2js.js2xml(document);
console.log(xml);
See the type definitions within x2js.d.ts for information about what configuration options you can pass.
A set of QUnit test cases are part of the project and act as the primary usage examples.
Run karma start --single run to test with Chrome, Firefox and IE.
Run node_modules\.bin\qunit-cli all_tests.js to test with the Node runtime.
Run npm test to execute both sets of tests.
Travis CI uses npm travistest to run tests using Firefox via Karma and Node.
Contributions are welcome! To ensure speedy merges, please:
We want to have a comitizen friendly formatted commit messages. This leads to more readable messages that are easy to follow when looking through the project history. But also, we use the git commit messages to generate the change log.
The commit message must respect this format that includes a type, a scope and a subject:
<type>(<scope>): <subject>
The header is mandatory and the scope of the header is optional.
Any line of the commit message cannot be longer 100 characters! This allows the message to be easier to read on GitHub as well as in various git tools.
Must be one of the following:
src or test filesThe scope could be anything specifying place of the commit change. For example
DejaDatePicker, DejaMonacoEditor, etc.
The subject contains succinct description of the change:
Breaking Changes should start with the word BREAKING CHANGE: with a space or two newlines.
The rest of the commit message is then used for this.
FAQs
Transforms between XML string and JavaScript object trees.
The npm package x2js receives a total of 44,212 weekly downloads. As such, x2js popularity was classified as popular.
We found that x2js demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 8 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
Malicious Namastex.ai npm packages appear to replicate TeamPCP-style Canister Worm tradecraft, including exfiltration and self-propagation.

Product
Explore exportable charts for vulnerabilities, dependencies, and usage with Reports, Socket’s new extensible reporting framework.

Product
Socket for Jira lets teams turn alerts into Jira tickets with manual creation, automated ticketing rules, and two-way sync.