LocalExcelTool
はじめる

ハッシュ一括生成

SHA-1/256/384/512 を一度に生成。秘密鍵を入れると HMAC も出力。

ハッシュ一括生成とは

ハッシュ一括生成ツールは、SHA-1・SHA-256・SHA-384・SHA-512 をまとめて計算するツールです。秘密鍵(secret)を入力すると、RFC 2104 準拠の HMAC-SHA256 / HMAC-SHA512 も同時に出力します。Web Crypto API を使うため、計算はブラウザ内で完結し、入力はどこにも送信されません。

🔒 処理はすべてブラウザ内で完結し、データは送信されません。

このツールの前提

処理場所
このページのブラウザ内(JavaScript / Canvas)
アップロード
なし — ファイルは端末の外に出ません
オフライン
ページを開いた後は通信不要

Four digests in one pass over the same bytes

SHA-1, SHA-256, SHA-384 and SHA-512 are computed from the same UTF-8 input so the lengths can be compared side by side: 40, 64, 96 and 128 hex characters. Seeing all four together makes it obvious that these are different functions of different widths, not one hash at different quality settings.

A digest is not a ranking of security. SHA-384 and SHA-512 are not 'stronger than SHA-256' in a way that matters here; they are wider hash functions with different internal block sizes. Collision resistance is already far beyond practical attack at 256 bits, so the choice is driven by what the other side of the protocol accepts.

HMAC is a different construction, not a keyed hash

Supplying a secret switches the output to HMAC per RFC 2104: the key is padded or hashed to the block size, XORed with two constants, and the hash is applied twice. The result is not 'SHA-256 of the key plus the message' — that naive concatenation is length-extendable and insecure.

HMAC-SHA256 is what webhook signatures, API request signing and TOTP-based schemes use. Two things cause interop failures: the message encoding (hex versus raw bytes) and whether the comparison is constant-time. This page shows the hex digest for inspection; a verifier must compare in constant time to avoid leaking the expected value through timing.

Which to pick

SHA-256 for integrity and signatures, SHA-512 when a protocol specifies it, SHA-1 only to satisfy a legacy format that still demands it — git object names, for instance. SHA-1 collisions have been produced in public, so a SHA-1 digest is a change detector, not a security boundary.

If the goal is password storage, stop: none of these four are appropriate, keyed or not. Use Argon2id or bcrypt with a per-user salt and a cost setting high enough to be measurable. The reason is speed, and it is the whole reason those algorithms exist.

使い方

  1. 1.テキストを入力
  2. 2.HMAC が必要なら secret を入力
  3. 3.実行して全ハッシュをコピー

他の方法との比較

同じ変換をする方法は 3 つあります。ブラウザ内(このページ)、サーバー側の変換サービス、デスクトップアプリ。差がつくのは速度ではなく、ファイルがどこへ行くかと、無料でどこまでできるかです。

観点このツールサーバー側の変換サービス
ファイルの処理場所このページのブラウザ内ベンダーのサーバー(アップロード後)
アカウント不要多くの場合必要(無料枠の制限解除に登録を求める)
無料で扱えるサイズサイズ制限なし(回数制限もなし)数ファイル/時間、または 5〜10MB 程度で課金 wall
料金無料。Pro は月 $9(大きいファイルと AI 機能のみ)サブスクが一般的。おおむね月 $7〜15(2026 年 11 月時点)
オフライン一度開けば通信不要不可
20MB を処理し始めるまで待ち時間なし(アップロードが無い)アップロードが支配的(10Mbps 上りで約 16 秒)
保証できないこと出力は決定的です。他の実装と突き合わせて検証できます同じ(変換の原理は変わらない)

サーバー側のサービスが優れている点は明確にあります。巨大なファイル、チームでの共有、変換履歴の管理、スクリプトからの自動化。逆に「1 回だけ、手元のファイルを別形式にしたい」という今回の用途では、アップロードの待ち時間と登録の手間だけが増えます。

よくある質問

MD5 は出力される?

いいえ。Web Crypto が MD5 を提供しないため、このツールでは計算できません。衝突が容易に作れるため、セキュリティ用途では SHA-256 以上を推奨します。

HMAC の書式は?

RFC 2104 に従い、hash=SHA-256 の HMAC は HMAC-SHA256 と表記します。API 署名の検証にそのまま使えます。

この変換で失われるもの

エンコードとハッシュは Web Crypto API または純 JavaScript 実装で行います。出力は決定的で、同じ入力からは常に同じ結果になります。他のツールと突き合わせて検証できます。

関連ガイド

その他のエンコード / デコード