
Security News
PHP Foundation Says Chainguard Broke Security Embargo Ahead of Emergency Patches
The PHP Foundation says Chainguard broke a security embargo ahead of critical RCE patches, as leaks disrupted the coordinated release.
@cratestack/cbor-web
Advanced tools
wasm-bindgen CBOR codec for browser CrateStack RPC clients. Async one-time WASM init, synchronous encode/decode after — backed by the same Rust CborCodec the server and Rust client already use.
A wasm-bindgen build of cratestack-codec-cbor's CborCodec for browser
CrateStack RPC clients — the browser half of @cratestack/cbor-node's
epic (#285). Same Rust encode/decode logic the server and Rust client
already use, reachable from browser JavaScript with no CBOR reimplemented
in TypeScript.
npm install @cratestack/cbor-web
createCborCodec() performs the one-time WASM module instantiation and
resolves to a plain object satisfying CratestackRpcCodec from
@cratestack/ts-types. Every encode/decode call on the returned
object is synchronous — the async cost is paid once, not per call:
import { createCborCodec } from "@cratestack/cbor-web";
const codec = await createCborCodec();
const bytes = codec.encode({ hello: "world" });
const value = codec.decode(bytes);
import { createCborCodec } from "@cratestack/cbor-web";
import { createClient } from "./generated/client.js";
const client = createClient({
baseUrl: "https://api.example.com",
codec: await createCborCodec(),
});
Malformed CBOR input on decode, or a value encode can't represent,
throws a catchable JS Error — never a WASM trap that would poison the
module for subsequent calls (see crates/cratestack-cbor-wasm/src/wasm.rs
for why that distinction matters).
Ships a wasm-pack --target web build: the .wasm asset is resolved via
new URL('cratestack_cbor_wasm_bg.wasm', import.meta.url), which Vite,
webpack 5, and Next.js all handle as a static asset without extra config.
Verified against examples/embedded-browser-vite.
@cratestack/cbor-node — the Node/native counterpart (napi-rs).crates/cratestack-cbor-wasm — the wasm-bindgen crate this package wraps.crates/cratestack-codec-cbor — the underlying, unchanged Rust codec.MIT
FAQs
wasm-bindgen CBOR codec for browser CrateStack RPC clients. Async one-time WASM init, synchronous encode/decode after — backed by the same Rust CborCodec the server and Rust client already use.
We found that @cratestack/cbor-web 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.

Security News
The PHP Foundation says Chainguard broke a security embargo ahead of critical RCE patches, as leaks disrupted the coordinated release.

Security News
PHP releases emergency patches for two critical RCE vulnerabilities as agencies urge organizations to take unpatched sites offline.

Threat Research
/Security News
A supply chain attack compromised LiteLLM 1.107.0 on PyPI and Docker, spreading malware that steals cloud credentials, developer secrets, and AI provider keys.