New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

xchaos

Package Overview
Dependencies
Maintainers
1
Versions
50
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

xchaos

High-speed stream cipher with WebAssembly

latest
npmnpm
Version
1.0.48
Version published
Maintainers
1
Created
Source

XChaOS (Pure JS)

XChaOS is a fast, modern ARX stream cipher implemented in Wasm. It uses a 1024-bit internal state and produces 128-byte blocks with high performance and simplicity.

Features

  • 256-bit key / 128-bit nonce
  • Wasm compiled
  • Secure ARX-based operations (Add-Rotate-XOR)
  • ChaCha-inspired design with dynamic rotations and lane shuffles

Usage

import { encrypt, decrypt, keystream } from 'xchaos';

const key = Buffer.alloc(32, 1); // 256-bit
const nonce = Buffer.alloc(16, 2); // 128-bit
const message = Buffer.from("Secret");

const encrypted = encrypt(key, nonce, message);
const decrypted = decrypt(key, nonce, encrypted);

console.log(decrypted.toString()); // "Secret"

Installation

npm install xchaos

Keywords

xchaos

FAQs

Package last updated on 11 May 2025

Did you know?

Socket

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.

Install

Related posts