
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
node-weakauras-parser
Advanced tools
Native module for Node.js that does deserialization/serialization of WeakAuras' strings
npm install node-weakauras-parser
# or
yarn add node-weakauras-parser
The package is pre-built for the following environments (Haswell is used as the target arch for x86_64 builds):
| OS | Node >=12 |
|---|---|
| Linux glibc (x86_64) | ✔️ |
| Linux glibc (aarch64) | ✔️ |
| Linux musl-libc (x86_64) | ✔️ |
| macOS (x86_64) | ✔️ |
| macOS (aarch64) | ✔️ |
| Windows (x86_64) | ✔️ |
If you use something else, you will need Rust and zlib in order to build from source code.
If you are using a x86_64 CPU and getting SIGILL, your CPU does not support some of the instructions that Haswell does. To fix that, you will have to build from source code.
Non-blocking version:
const parser = require('node-weakauras-parser');
(async function() {
const source = { test: 1 };
const encoded = await parser.encode(source);
const decoded = await parser.decode(encoded);
console.log(JSON.stringify(source) === JSON.stringify(decoded));
}());
Blocking version (slightly faster, but blocks the event loop):
const parser = require('node-weakauras-parser');
const source = { test: 1 };
const encoded = parser.encodeSync(source);
const decoded = parser.decodeSync(encoded);
console.log(JSON.stringify(source) === JSON.stringify(decoded));
Both decode() and decodeSync() accept an optional argument to configure the memory usage limit for decompression (in bytes). Default value is 8 MBs. You can pass +Infinity to disable it.
Both encode and encodeSync() accept an optional argument to specify the encoding version. See the definition of FormatVersion in index.d.ts.
SavedVariables.lua, so it shouldn't be an issue with WA strings.encode() now uses a new serialization algorithm adopted by WA in v2.18.encode() and decode() in v2 still spent majority of their time on the main thread, thus blocking the event loop. This is no longer the case but infinite numbers are no longer supported;encode() and decode() are now non-blocking;encodeSync() and decodeSync().The source code is licensed under the MIT License. However, it depends on GPL-licensed code, so the whole distribution is licensed under GPLv2.
FAQs
Native module for Node.js that does deserialization/serialization of WeakAuras' strings
We found that node-weakauras-parser demonstrated a healthy version release cadence and project activity because the last version was released less than 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.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.