TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Show HN: Pw-punch – sub-2KB JWT/password crypto – Edge-native, 0 deps

1 点作者 idtpanic大约 1 个月前
I needed a lightweight crypto lib for JWTs and password hashing that works without Node. So I built `pw-punch`, a 4KB WebCrypto-only toolkit — no deps, no config.<p>It works great on Cloudflare &#x2F; Deno &#x2F; Bun. Would love to hear what you think.<p>I&#x27;ve been working on a tiny crypto utility that requires *no dependencies*, *no Node.js*, and works purely on the WebCrypto API — ideal for edge runtimes like *Cloudflare Workers*, *Deno*, *Vercel*, or *Bun*.<p>Features: - Password hashing using PBKDF2 + random salt - JWT-style token signing (HMAC-SHA256 &#x2F; SHA512) - Token verification with claim checks (exp, iat, nbf, iss, sub, aud) - `kid` support (key rotation) - ~4KB gzipped, 0 config, 0 install<p>I built it because I needed something that just works on the edge with *zero install bloat*. Would love to hear your thoughts or feedback.

1 comment

idtpanic大约 1 个月前
npm: <a href="https:&#x2F;&#x2F;www.npmjs.com&#x2F;package&#x2F;pw-punch" rel="nofollow">https:&#x2F;&#x2F;www.npmjs.com&#x2F;package&#x2F;pw-punch</a>