HMAC生成器
使用SHA-1、SHA-256、SHA-384或SHA-512生成HMAC签名。
如何使用本工具
- 1
Pick a hash algorithm from the dropdown: SHA-1, SHA-256, SHA-384, or SHA-512.
- 2
Type or paste your shared secret key into the key field.
- 3
Type or paste the message you want to authenticate into the message box.
- 4
Click Generate to compute the HMAC; the lowercase hex digest appears below.
什么是HMAC生成器?
HMAC(Hash-based Message Authentication Code,基于哈希的消息认证码)使用共享的密钥来验证消息的完整性和真实性。它是webhook签名、API请求签名(AWS Signature V4、Stripe的webhook)以及JWT的HS256/HS384/HS512算法的基础。
常见使用场景
Verify an incoming webhook by recomputing the HMAC of the raw request body with your endpoint's signing secret and comparing it to the provider's signature header.
Check a Stripe webhook locally: HMAC-SHA256 the timestamped payload with your whsec_ secret to confirm your verification logic before deploying.
Debug a mismatched signature by pasting the exact bytes your server and client each signed to see which side is wrong.
Generate a quick integrity tag for a config file or message so a teammate with the same key can confirm it was not altered in transit.
Teach or learn how HMAC differs from a bare hash by toggling algorithms and watching the digest length change.
Sanity-check a single HMAC step of a larger signing scheme (such as one round of the AWS SigV4 key-derivation chain) during development.
常见问题
HMAC和哈希是一回事吗?▼
相关工具
密码哈希生成器(PBKDF2)
使用PBKDF2-SHA256在你的浏览器中生成安全的密码哈希。比MD5或简单SHA更强,工作因子可调。
AES-256加密
使用AES-256-GCM加密和解密文本。密钥通过PBKDF2-SHA256从你的口令派生而来。
2FA二维码生成器
为Google Authenticator、Authy、1Password及其他2FA应用生成TOTP二维码。
密码强度检测器
根据字符集大小和常见密码列表检测你密码的熵值。完全离线运行。
凯撒密码编码与解码工具
使用凯撒密码对文本进行编码或解码:按固定位移替换字母。
ROT13编码与解码工具
使用ROT13对文本进行编码或解码:一种位移13位、且自身互逆的凯撒密码。