
Security News
Nx npm Packages Compromised in Supply Chain Attack Weaponizing AI CLI Tools
Malicious Nx npm versions stole secrets and wallet info using AI CLI tools; Socket’s AI scanner detected the supply chain attack and flagged the malware.
gimli-crypto
Advanced tools
Gimli cryptographic pseudorandom permutation and sponge-based hash function
"Gimli is a 384-bit permutation designed to achieve high security with high performance across a broad range of platforms."
This is a JavaScript implementation of the permutation and a sponge-based hash function (XOF).
npm install gimli-crypto
But it's really small, maybe just copy and paste?
var gimli = require('gimli-crypto').gimli;
var state = new Uint8Array(48);
// state is 000000....0000
gimli(state);
// state is c4d867....302e
var hash = require('gimli-crypto').hash;
// 32-byte digest of [1,2,3,4,5,6] calculated in two steps.
var digest = hash()
.write(new Uint8Array([1,2,3]))
.write(new Uint8Array([4,5,6]))
.read();
// 111-byte digest of [1,2,3]
var longDigest = new Uint8Array(111);
var data = new Uint8Array([1,2,3]);
hash().write(data).read(longDigest);
// XORing with output of XOF
var key = new Uint8Array([1,2,3]);
var text = new Uint8Array([4,5,6]);
hash().write(key).read(text, true);
// outputs Uint8Array [ 81, 10, 158 ]
FAQs
Gimli cryptographic pseudorandom permutation and sponge-based hash function
The npm package gimli-crypto receives a total of 0 weekly downloads. As such, gimli-crypto popularity was classified as not popular.
We found that gimli-crypto 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.
Security News
Malicious Nx npm versions stole secrets and wallet info using AI CLI tools; Socket’s AI scanner detected the supply chain attack and flagged the malware.
Security News
CISA’s 2025 draft SBOM guidance adds new fields like hashes, licenses, and tool metadata to make software inventories more actionable.
Security News
A clarification on our recent research investigating 60 malicious Ruby gems.