目次

NIST SP 800-107 Rev. 1 日本語訳

英語タイトル : Recommendation for Applications Using Approved Hash Algorithms
日本語タイトル : 承認済みハッシュアルゴリズムを使用するアプリケーションに関する推奨事項
公開日 : 2012-08-24
原文URL : https://csrc.nist.gov/pubs/sp/800/107/r1/final
翻訳編集 : 自動生成(有志による非公式の日本語訳), 原文取得日 : 2026-10-01, 訳文 : 277 / 277 ブロック

[要約] SP 800-107 Rev. 1 は、FIPS 180-4 で規定される承認済みハッシュ関数を用いる暗号アプリケーションについて、必要または望ましいセキュリティ強度を実現するための指針を示す勧告です。承認済みハッシュアルゴリズムの一覧と、デジタル署名、HMAC、ハッシュベース鍵導出関数、乱数生成などでのハッシュ関数の使用、切り詰められたハッシュ値を扱い、付録で第二原像耐性強度を示します。ハッシュ関数は任意の長さのメッセージから固定長のメッセージダイジェストを計算するもので、情報セキュリティの多くの用途で使われることを踏まえた指針です。

NIST Special Publication 800-107

NIST特別刊行物 800-107

Revision 1

改訂第1版

Recommendation for Applications Using Approved Hash Algorithms

承認済みハッシュアルゴリズムを使用するアプリケーションに関する推奨事項

Quynh Dang

Quynh Dang

Computer Security Division Information Technology Laboratory

コンピュータセキュリティ部門 情報技術研究所

C O M P U T E R S E C U R I T Y

コンピュータセキュリティ

August 2012

2012年8月

図表
[U.S. Department of Commerce seal — not reproduced on this unofficial site]

[米国商務省の紋章。公的な標章のため、この非公式サイトには掲載していません。原本 PDF を参照してください。]

U.S. Department of Commerce Rebecca M. Blank, Acting Secretary

米国商務省 Rebecca M. Blank(長官代行)

National Institute of Standards and Technology

米国国立標準技術研究所

Patrick Gallagher, Under Secretary of Commerce for Standards and Technology and Director

Patrick Gallagher(商務省標準技術担当次官兼所長)

Abstract

概要

Hash functions that compute a fixed-length message digest from arbitrary length messages are widely used for many purposes in information security. This document provides security guidelines for achieving the required or desired security strengths when using cryptographic applications that employ the approved hash functions specified in Federal Information Processing Standard (FIPS) 180-4. These include functions such as digital signatures, Keyed-hash Message Authentication Codes (HMACs) and Hash-based Key Derivation Functions (Hash-based KDFs).

任意の長さのメッセージから固定長のメッセージダイジェストを計算するハッシュ関数は、情報セキュリティの多くの用途で広く使用されています。本書は、連邦情報処理標準(FIPS)180-4で規定される承認済みハッシュ関数を用いる暗号アプリケーションにおいて、要求される、または望ましいセキュリティ強度を実現するためのセキュリティ指針を示します。対象には、デジタル署名、鍵付きハッシュメッセージ認証コード(HMAC)、ハッシュベース鍵導出関数(ハッシュベースKDF)などが含まれます。

KEY WORDS: digital signatures, hash algorithm, hash function, hash-based key derivation algorithms, hash value, HMAC, message digest, randomized hashing, random number generation, SHA, truncated hash values.

キーワード:デジタル署名、ハッシュアルゴリズム、ハッシュ関数、ハッシュベース鍵導出アルゴリズム、ハッシュ値、HMAC、メッセージダイジェスト、ランダム化ハッシュ、乱数生成、SHA、切り詰められたハッシュ値。

Acknowledgements

謝辞

The author, Quynh Dang of the National Institute of Standards and Technology (NIST) gratefully appreciates the contributions and comments from Elaine Barker, William E. Burr, Shu-jen Chang, Lily Chen, Donna F. Dodson, Morris Dworkin, John Kelsey, Ray Perlner, W. Timothy Polk and Andrew Regenscheid. The author also appreciates comments from Daniel Brown, Hugo Krawczyk, Praveen Gauravaram and Richard Davis during the development of this Recommendation.

著者である米国国立標準技術研究所(NIST)のQuynh Dangは、Elaine Barker、William E. Burr、Shu-jen Chang、Lily Chen、Donna F. Dodson、Morris Dworkin、John Kelsey、Ray Perlner、W. Timothy Polk、Andrew Regenscheidから寄せられた貢献とコメントに深く感謝します。また著者は、本推奨事項の策定中にDaniel Brown、Hugo Krawczyk、Praveen Gauravaram、Richard Davisから寄せられたコメントにも感謝します。

Table of Contents

目次

Recommendation for Applications Using Approved Hash Algorithms

承認済みハッシュアルゴリズムを使用するアプリケーションに関する推奨事項

1 Introduction

1 はじめに

A hash algorithm is used to map a message of arbitrary length to a fixed-length message digest. Federal Information Processing Standard (FIPS) 180-4, the Secure Hash Standard (SHS) [FIPS 180-4], specifies seven approved hash algorithms: SHA-1, SHA-224, SHA-256, SHA-384, SHA-512, SHA-512/224 and SHA-512/256.

ハッシュアルゴリズムは、任意の長さのメッセージを固定長のメッセージダイジェストに対応付けるために使用されます。連邦情報処理標準(FIPS)180-4「セキュアハッシュ標準(SHS)」[FIPS 180-4]は、承認済みハッシュアルゴリズムとして、SHA-1、SHA-224、SHA-256、SHA-384、SHA-512、SHA-512/224、SHA-512/256の7種類を規定しています。

This Recommendation provides security guidelines for supporting the required or desired security strengths of several cryptographic applications that employ the approved hash functions specified in FIPS 180-4, such as digital signature applications specified in FIPS 186-3 [FIPS 186-3], Keyed-hash Message Authentication Codes (HMACs) specified in FIPS 198-1 [FIPS 198-1] and Hash-based Key Derivation Functions specified in SP 800-56A [SP 800-56A] and SP 800-56B [SP 800-56B]. While the use of hash functions in HMAC-based key derivation functions is specified in SP 800-56C [SP 800-56C] and SP 800-108 [SP 800-108], these documents sufficiently address the security aspects of their use, so discussions of SP 800-56C and SP 800-108 are not included herein.

本推奨事項は、FIPS 180-4で規定される承認済みハッシュ関数を使用する複数の暗号アプリケーションについて、要求される、または望ましいセキュリティ強度を確保するためのセキュリティ指針を示します。そのようなアプリケーションには、FIPS 186-3 [FIPS 186-3]で規定されるデジタル署名アプリケーション、FIPS 198-1 [FIPS 198-1]で規定される鍵付きハッシュメッセージ認証コード(HMAC)、SP 800-56A [SP 800-56A]およびSP 800-56B [SP 800-56B]で規定されるハッシュベース鍵導出関数などがあります。HMACベースの鍵導出関数におけるハッシュ関数の使用はSP 800-56C [SP 800-56C]およびSP 800-108 [SP 800-108]で規定されていますが、これらの文書がその使用のセキュリティ面を十分に扱っているため、本書ではSP 800-56CおよびSP 800-108について論じない。

2 Authority

2 権限

This Recommendation has been developed by the National Institute of Standards and Technology (NIST) in furtherance of its statutory responsibilities under the Federal Information Security Management Act (FISMA) of 2002, Public Law 107-347.

本推奨事項は、2002年連邦情報セキュリティマネジメント法(FISMA、Public Law 107-347)に基づく法定責務を果たすため、米国国立標準技術研究所(NIST)が策定しました。

NIST is responsible for developing standards and guidelines, including minimum requirements, for providing adequate information security for all agency operations and assets, but such standards and guidelines shall not apply to national security systems. This recommendation is consistent with the requirements of the Office of Management and Budget (OMB) Circular A-130, Section 8b(3), Securing Agency Information Systems, as analyzed in A-130, Appendix IV: Analysis of Key Sections. Supplemental information is provided in A-130, Appendix III.

NISTは、各機関のすべての業務と資産に適切な情報セキュリティを提供するための標準および指針(最低要件を含む)を策定する責任を負います。ただし、これらの標準および指針は国家安全保障システムには適用されません。本推奨事項は、行政管理予算局(OMB)通達A-130第8b(3)節「Securing Agency Information Systems」の要件(A-130付録IV「Analysis of Key Sections」で分析されているもの)と整合しています。補足情報はA-130付録IIIに示されています。

This Recommendation has been prepared for use by Federal agencies. It may be used by non-governmental organizations on a voluntary basis and is not subject to copyright (attribution would be appreciated by NIST).

本推奨事項は連邦機関での使用を目的として作成されました。非政府組織も任意で使用でき、著作権の対象ではありません(NISTは出典の明記を歓迎します)。

Nothing in this Recommendation should be taken to contradict standards and guidelines made mandatory and binding on Federal agencies by the Secretary of Commerce under statutory authority. Nor should this Recommendation be interpreted as altering or superseding the existing authorities of the Secretary of Commerce, Director of the OMB, or any other federal official.

本推奨事項のいかなる記述も、法定権限に基づいて商務長官が連邦機関に義務付けた標準および指針と矛盾するものと解釈してはなりません。また、本推奨事項は、商務長官、OMB長官、その他の連邦政府職員が有する既存の権限を変更または置き換えるものと解釈してはなりません。

Conformance testing for implementations of this Recommendation will be conducted within the framework of the Cryptographic Algorithm Validation Program (CAVP) and the Cryptographic Module Validation Program (CMVP). The requirements of this Recommendation are indicated by the word “shall”. Some of these requirements may be out-of-scope for CAVP and CMVP validation testing, and thus are the responsibility of entities using, implementing, installing, or configuring applications that incorporate this Recommendation.

本推奨事項を実装したものの適合性試験は、暗号アルゴリズム検証プログラム(CAVP)および暗号モジュール検証プログラム(CMVP)の枠組みで実施されます。本推奨事項の要件はshallという語で示されます。これらの要件の一部はCAVPおよびCMVPの検証試験の対象外となる場合があり、その場合は、本推奨事項を組み込むアプリケーションを使用、実装、設置または構成する主体が責任を負います。

3 Glossary of Terms, Acronyms and Mathematical Symbols

3 用語、頭字語および数学記号の用語集

3.1 Terms and Definitions

3.1 用語と定義

Adversary

攻撃者

An entity that is not authorized to access or modify information, or who works to defeat any protections afforded the information.

情報へのアクセスまたは情報の変更を許可されていない主体、あるいは情報に施された保護を破ろうとする主体。

Algorithm

アルゴリズム

A clearly specified mathematical process for computation; a set of rules that, if followed, will give a prescribed result.

計算のために明確に定められた数学的手順、すなわち、従えば所定の結果が得られる一連の規則。

Approved

承認済み

FIPS-approved and/or NIST-recommended. An algorithm or technique that is either 1) specified in a FIPS or NIST Recommendation, 2) adopted in a FIPS or NIST Recommendation or 3) specified in a list of NIST-approved security functions.

FIPSで承認されたもの、および/またはNISTが推奨するもの。アルゴリズムまたは技法が、1) FIPSまたはNIST推奨事項で規定されている、2) FIPSまたはNIST推奨事項に採用されている、または3) NIST承認済みセキュリティ機能の一覧に記載されていることをいいます。

Approved hash algorithms

承認済みハッシュアルゴリズム

Hash algorithms specified in FIPS 180-4.

FIPS 180-4で規定されるハッシュアルゴリズム。

Bit string

ビット列

An ordered sequence of 0 and 1 bits. In this Recommendation, the leftmost bit is the most significant bit of the string. The rightmost bit is the least significant bit of the string.

0と1を順序付けて並べた列。本推奨事項では、左端のビットを列の最上位ビット、右端のビットを最下位ビットとします。

Bits of security

セキュリティビット数

See security strength.

「セキュリティ強度」を参照してください。

Block cipher

ブロック暗号

An invertible symmetric-key cryptographic algorithm that operates on fixed-length blocks of input using a secret key and an unvarying transformation algorithm. The resulting output block is the same length as the input block.

秘密鍵と変化しない変換アルゴリズムを用い、固定長の入力ブロックを処理する、可逆な共通鍵暗号アルゴリズム。出力ブロックは入力ブロックと同じ長さです。

Collision

衝突

An event in which two different messages have the same message digest.

異なる2つのメッセージから同じメッセージダイジェストが得られる事象。

Collision resistance

衝突耐性

An expected property of a hash function whereby it is computationally infeasible to find a collision, See “Collision”.

ハッシュ関数に期待される性質であり、衝突を見つけることが計算上実行不可能であることをいいます。「衝突」を参照してください。

Digital signature

デジタル署名

The result of applying two cryptographic functions (a hash function, followed by a digital signature function; see FIPS 186-3 for details). When the functions are properly implemented, the digital signature provides origin authentication, data integrity protection and signatory non-repudiation.

2つの暗号関数(ハッシュ関数に続いてデジタル署名関数)を適用した結果です。詳細はFIPS 186-3を参照してください。これらの関数が適切に実装されている場合、デジタル署名は発信元認証、データ完全性保護、および署名者の否認防止を実現します。

Hash algorithm

ハッシュアルゴリズム

See hash function. “Hash algorithm” and “hash function” are used interchangeably in this Recommendation.

「ハッシュ関数」を参照してください。本推奨事項では「ハッシュアルゴリズム」と「ハッシュ関数」を同じ意味で使用します。

Hash function

ハッシュ関数

A function that maps a bit string of arbitrary length to a fixed-length bit string. The function is expected to have the following three properties:

任意の長さのビット列を固定長のビット列に対応付ける関数。次の3つの性質を備えることが期待されます。

1.Collision resistance (see Collision resistance),

1.衝突耐性(「衝突耐性」を参照)

2.Preimage resistance (see Preimage resistance) and

2.原像耐性(「原像耐性」を参照)、および

3.Second preimage resistance (see Second preimage resistance).

3.第二原像耐性(「第二原像耐性」を参照してください)。

Approved hash functions are specified in [FIPS 180-4].

承認済みハッシュ関数は[FIPS 180-4]で規定されます。

Hash output

ハッシュ出力

See “message digest”.

「メッセージダイジェスト」を参照してください。

Hash value

ハッシュ値

See “message digest”.

「メッセージダイジェスト」を参照してください。

鍵

A parameter used with a cryptographic algorithm that determines its operation in such a way that an entity with knowledge of the key can reproduce or reverse the operation, while an entity without knowledge of the key cannot. Examples applicable to this Recommendation include:

暗号アルゴリズムとともに使用され、その動作を決定するパラメータ。鍵を知る主体は処理を再現または逆転できますが、鍵を知らない主体にはそれができません。本推奨事項に関係する例を次に示します。

1.The computation of a keyed-hash message authentication code.

1.鍵付きハッシュメッセージ認証コードの計算。

2.The verification of a keyed-hash message authentication code.

2.鍵付きハッシュメッセージ認証コードの検証。

3.The generation of a digital signature on a message.

3.メッセージに対するデジタル署名の生成。

4.The verification of a digital signature.

4.デジタル署名の検証。

Key Derivation Key

鍵導出鍵

A key used as an input to a key derivation function to derive other keys.

別の鍵を導出するために、鍵導出関数への入力として使用する鍵。

Keying Material

鍵素材

A bit string, such that any non-overlapping segments of the string with the required lengths can be used as symmetric cryptographic keys and secret parameters, such as initialization vectors.

必要な長さを持つ、互いに重複しない任意の部分列を、共通鍵暗号鍵として、および初期化ベクトルなどの秘密パラメータとして使用できるビット列。

L-bit Hash Function: A hash function for which the length of the output is L bits.

Lビットハッシュ関数:出力長がLビットのハッシュ関数。

MAC algorithm: An algorithm that computes a MAC from a message and a key.

MACアルゴリズム:メッセージと鍵からMACを計算するアルゴリズム。

Message digest

メッセージダイジェスト

The result of applying a hash function to a message. Also known as a “hash value” or “hash output”.

メッセージにハッシュ関数を適用した結果。ハッシュ値またはハッシュ出力とも呼ばれます。

Preimage

原像

A message X that produces a given message digest when it is processed by a hash function.

ハッシュ関数で処理したとき、所与のメッセージダイジェストを生成するメッセージX。

Preimage resistance

原像耐性

An expected property of a hash function such that, given a randomly chosen message digest, message_digest, it is computationally infeasible to find a preimage of the message_digest, See “Preimage”.

ハッシュ関数に期待される性質であり、ランダムに選ばれたメッセージダイジェストmessage_digestが与えられたとき、それに対応する原像を見つけることが計算上実行不可能であることをいいます。「原像」を参照してください。

Random bit

ランダムビット

A bit for which an attacker has exactly a 50% probability of success of guessing the value of the bit as either a zero or one. It is also called an unbiased bit.

攻撃者がその値を0または1のいずれかと推測して成功する確率が正確に50%であるビット。偏りのないビットとも呼ばれます。

Random bit generator

ランダムビット生成器

A device or algorithm that can produce a sequence of bits that appear to be both statistically independent and unbiased.

統計的に独立で偏りのないように見えるビット列を生成できる装置またはアルゴリズム。

Randomized hashing: A process by which the input to a hash function is randomized before being processed by the hash function.

ランダム化ハッシュ:ハッシュ関数で処理する前に、その入力をランダム化する処理。

Random number: A value in a set of numbers that has an equal probability of being selected from the total population of possibilities and, in that sense, is unpredictable. A random number is an instance of an unbiased random variable, that is, the output produced by a uniformly distributed random process. Random numbers may, e.g., be obtained by converting suitable stings of random bits (see [SP 800-90A], Appendix B.5 for details).

乱数:数の集合に含まれる値であって、取り得る値の全体の中から等しい確率で選択され、その意味で予測不可能なもの。乱数は偏りのない確率変数の実現値、すなわち一様分布するランダムな過程が生成する出力です。乱数は、例えば、適切なランダムビット列を変換することによって得ることができます(詳細は[SP 800-90A]の付録B.5を参照してください)。

Second preimage

第二原像

A message X’, that is different from a given message X, such that its message digest is the same as the known message digest of X.

所与のメッセージXとは異なるメッセージX’であり、そのメッセージダイジェストが、Xの既知のメッセージダイジェストと同じであるもの。

Second preimage resistance

第二原像耐性

An expected property of a hash function whereby it is computationally infeasible to find a second preimage of a known message digest, See “Second preimage”.

ハッシュ関数に期待される性質であり、既知のメッセージダイジェストから第二原像を見つけることが計算上実行不可能であることをいいます。「第二原像」を参照してください。

Secret keying material: The binary data that is used to form secret keys, such as AES encryption or HMAC keys.

シークレット鍵素材:AES暗号鍵やHMAC鍵など、秘密鍵を形成するために使用される二進データ。

Security strength (Also “bits of security”): A number associated with the amount of work (that is, the number of operations) that is required to break a cryptographic algorithm or system. If \(2^N\) execution operations of the algorithm (or system) are required to break the cryptographic algorithm, then the security strength is \(N\) bits.

セキュリティ強度(「セキュリティビット数」ともいう):暗号アルゴリズムまたはシステムを破るために必要な作業量(すなわち演算回数)に関連付けられる数値です。暗号アルゴリズムを破るために、そのアルゴリズム(またはシステム)の実行演算が\(2^N\)回必要である場合、セキュリティ強度は\(N\)ビットです。

Shall: Used to indicate a requirement of this Recommendation.

Shall:本推奨事項の要件を示すために用いる語。

Shared secret

共有シークレット

A secret value that has been computed using a key agreement algorithm and is used as input to a key derivation function.

鍵合意アルゴリズムを用いて計算され、鍵導出関数への入力として使用される秘密の値。

3.2 Acronyms

3.2 頭字語

FIPS

Federal Information Processing Standard

連邦情報処理標準

SHA

Secure Hash Algorithm

セキュアハッシュアルゴリズム

KDF

Key Derivation Function

鍵導出関数

MAC

Message Authentication Code

メッセージ認証コード

HMAC

Keyed-hash Message Authentication Code

鍵付きハッシュメッセージ認証コード

RBG

Random Bit Generator

ランダムビット生成器

3.3 Symbols

3.3 記号

K

HMAC key.

HMAC鍵。

L

Length in bits of the full message digest from a hash function.

ハッシュ関数による完全なメッセージダイジェストのビット長。

\(\mathit{MacTag}\)Transmitted full or truncated HMAC output.
\(\min(x, y)\)The minimum of \(x\) and \(y\). For example, if \(x < y\), then \(\min(x, y) = x\).
\(\lambda\)The length in bits of a \(\mathit{MacTag}\), or the length in bits of a truncated message digest (used, for example, by a digital signature algorithm).
\(\mathit{MacTag}\)送信される完全なHMAC出力または切り詰められたHMAC出力。
\(\min(x, y)\)\(x\)と\(y\)の最小値。例えば、\(x < y\)ならば\(\min(x, y) = x\)。
\(\lambda\)\(\mathit{MacTag}\)のビット長、または(例えばデジタル署名アルゴリズムで使用される)切り詰められたメッセージダイジェストのビット長。

4 Approved Hash Algorithms

4 承認済みハッシュアルゴリズム

Currently, there are seven approved hash algorithms specified in FIPS 180-4: SHA-1, SHA-224, SHA-256, SHA-384 SHA-512, SHA-512/224 and SHA-512/256. These hash algorithms produce outputs of 160, 224, 256, 384, 512, 224 and 256 bits, respectively. The output of a hash algorithm is commonly known as a message digest, a hash value or a hash output.

現在、FIPS 180-4で規定される承認済みハッシュアルゴリズムは7種類あります。SHA-1、SHA-224、SHA-256、SHA-384、SHA-512、SHA-512/224、SHA-512/256です。これらのハッシュアルゴリズムの出力長は、それぞれ160、224、256、384、512、224、256ビットです。ハッシュアルゴリズムの出力は一般に、メッセージダイジェスト、ハッシュ値、またはハッシュ出力と呼ばれます。

4.1 Hash Function Properties

4.1 ハッシュ関数の特性

An approved hash function1 is expected to have the following three properties:

承認済みハッシュ関数1は、次の3つの性質を備えることが期待されます。

1. Collision resistance: It is computationally infeasible to find two different inputs to the hash function that have the same hash value. That is, if \(\mathit{hash}\) is a hash function, it is computationally infeasible to find two different inputs \(x\) and \(x'\) for which \(\mathit{hash}(x) = \mathit{hash}(x')\). Collision resistance is measured by the amount of work that would be needed to find a collision for a hash function with high probability. If the amount of work is \(2^N\), then the collision resistance is \(N\) bits. The expected collision-resistance strength of a hash function is half the length of the hash value produced by that hash function, i.e., for an \(L\)-bit hash function, the expected security strength for collision resistance is \(L/2\) bits. For example, SHA-256 produces a (full-length) hash value of 256 bits; SHA-256 provides an expected collision resistance of 128 bits (see Table 1 in Section 4.2).

1. 衝突耐性:同じハッシュ値となる、ハッシュ関数への異なる2つの入力を見つけることが計算上実行不可能であること。つまり、\(\mathit{hash}\)がハッシュ関数ならば、異なる2つの入力\(x\)と\(x'\)であって\(\mathit{hash}(x) = \mathit{hash}(x')\)となるものを見つけることが計算上実行不可能です。衝突耐性は、ハッシュ関数の衝突を高い確率で見つけるのに必要な作業量で測られます。必要な作業量が\(2^N\)なら、衝突耐性は\(N\)ビットです。ハッシュ関数の期待衝突耐性強度は、そのハッシュ関数が生成するハッシュ値の長さの半分です。すなわち、\(L\)ビットハッシュ関数の場合、衝突耐性の期待セキュリティ強度は\(L/2\)ビットとなります。例えば、SHA-256は256ビットの(全長)ハッシュ値を生成し、128ビットの期待衝突耐性を提供します(4.2節の表1を参照)。

1 The terms “hash function” and “hash algorithm” are used interchangeably, depending on the context of the discussions throughout this Recommendation.
1 本推奨事項では、議論の文脈に応じて「ハッシュ関数」と「ハッシュアルゴリズム」を同じ意味で使用します。

2. Preimage resistance2: Given a randomly chosen hash value, \(\mathit{hash\_value}\), it is computationally infeasible to find an \(x\) so that \(\mathit{hash}(x) = \mathit{hash\_value}\). This property is also called the one-way property. Preimage resistance is measured by the amount of work that would be needed to have a high probability of finding a preimage for a hash function. If the amount of work is \(2^N\), then the preimage resistance is \(N\) bits. The expected preimage-resistance strength of a hash function is the length of the hash value produced by that hash function, i.e., for an \(L\)-bit hash function, the expected security strength for preimage resistance is \(L\) bits. For example, SHA-256 produces a (full-length) hash value of 256 bits; SHA-256 provides an expected preimage resistance of 256 bits (see Table 1 in Section 4.2).

2. 原像耐性2:ランダムに選ばれたハッシュ値\(\mathit{hash\_value}\)が与えられたとき、\(x\)であって\(\mathit{hash}(x) = \mathit{hash\_value}\)となるものを見つけることが計算上実行不可能であること。この性質は一方向性とも呼ばれます。原像耐性は、ハッシュ関数の原像を高い確率で見つけるのに必要な作業量で測られます。必要な作業量が\(2^N\)なら、原像耐性は\(N\)ビットです。ハッシュ関数の期待原像耐性強度は、そのハッシュ関数が生成するハッシュ値の長さに等しい。すなわち、\(L\)ビットハッシュ関数の場合、原像耐性の期待セキュリティ強度は\(L\)ビットとなります。例えば、SHA-256は256ビットの(全長)ハッシュ値を生成し、256ビットの期待原像耐性を提供します(4.2節の表1を参照)。

3. Second preimage resistance: It is computationally infeasible to find a second input that has the same hash value as any other specified input. That is, given an input \(x\), it is computationally infeasible to find a second input \(x'\) that is different from \(x\), such that \(\mathit{hash}(x) = \mathit{hash}(x')\). Second preimage resistance is measured by the amount of work that would be needed to have a high probability of finding a second preimage for a hash function. If the amount of work is \(2^N\), then the second preimage resistance is \(N\) bits. In general, the expected second preimage strength of a hash function is the length of the hash value produced by that hash function, i.e., for an \(L\)-bit hash function, the expected security strength for second preimage resistance is \(L\) bits. For example, SHA-256 produces a (full-length) hash value of 256 bits; SHA-256 provides an expected second preimage resistance of 256 bits (see Table 1 in Section 4.2). However, for some hash functions, the second preimage resistance strength also depends on the message length processed by the hash function. More details can be found in Appendix A.

3. 第二原像耐性:指定された任意の入力と同じハッシュ値を持つ第二の入力を見つけることが計算上実行不可能であること。つまり、入力\(x\)が与えられたとき、第二の入力\(x'\)であって、\(x\)とは異なり、\(\mathit{hash}(x) = \mathit{hash}(x')\)となるものを見つけることが計算上実行不可能です。第二原像耐性は、ハッシュ関数の第二原像を高い確率で見つけるのに必要な作業量で測られます。必要な作業量が\(2^N\)なら、第二原像耐性は\(N\)ビットです。一般に、ハッシュ関数の期待第二原像耐性強度は、そのハッシュ関数が生成するハッシュ値の長さに等しい。すなわち、\(L\)ビットハッシュ関数の場合、第二原像耐性の期待セキュリティ強度は\(L\)ビットとなります。例えば、SHA-256は256ビットの(全長)ハッシュ値を生成し、256ビットの期待第二原像耐性を提供します(4.2節の表1を参照)。ただし、一部のハッシュ関数では、第二原像耐性強度はハッシュ関数が処理するメッセージの長さにも依存します。詳細は付録Aを参照してください。

The security strength of a hash function is determined by its collision resistance strength, preimage resistance strength or second preimage resistance strength, depending on the property(ies) that the cryptographic application needs from the hash function. If an application requires more than one property from the hash function, then the weakest property is the security strength of the hash function for that application. For instance, the security strength of a hash function for digital signatures is defined as its collision resistance strength, because digital signatures require both collision resistance and second preimage resistance from the hash function, and the collision resistance strength of the hash function (L/2) is less than its second preimage resistance strength (i.e., L). A hash function that is not suitable for one application might be suitable for other cryptographic applications that do not require the same security properties. SHA-1 is not suitable for general-purpose digital signature applications (as specified in FIPS 186-3) that require 112 bits of security. In the case of digital signatures, SHA-1 does not provide the 112 bits of collision resistance (see Table 1 in Section 4.2) needed to achieve the security strength. On the other hand, SHA-1 does provide the 112 bits of preimage resistance that is needed to achieve the 112-bit security strength for HMAC. The security strengths of the approved hash functions for different applications can be found in SP 800-57, Part 1 [SP 800-57].

ハッシュ関数のセキュリティ強度は、暗号アプリケーションがハッシュ関数に求める性質に応じて、衝突耐性強度、原像耐性強度、または第二原像耐性強度で決まります。アプリケーションが複数の性質を必要とする場合、そのハッシュ関数のセキュリティ強度は最も弱い性質によって決まります。例えば、デジタル署名では、ハッシュ関数に衝突耐性と第二原像耐性の両方が必要ですが、衝突耐性強度(L/2)は第二原像耐性強度(L)より低いため、デジタル署名に用いるハッシュ関数のセキュリティ強度は衝突耐性強度として定義されます。ある用途に適さないハッシュ関数でも、同じセキュリティ特性を必要としない別の暗号用途には適する場合があります。SHA-1は、112ビットのセキュリティを必要とする汎用デジタル署名アプリケーション(FIPS 186-3で規定)には適しません。デジタル署名では、必要なセキュリティ強度を満たすために必要な112ビットの衝突耐性をSHA-1は提供しません(4.2節の表1を参照してください)。一方、SHA-1はHMACで112ビットのセキュリティ強度を実現するために必要な112ビットの原像耐性を提供します。用途別の承認済みハッシュ関数のセキュリティ強度は、SP 800-57第1部[SP 800-57]を参照してください。

2 There are slightly different definitions of preimage resistance of hash functions in the literature.
2 文献には、ハッシュ関数の原像耐性について若干異なる定義があります。

4.2 Strengths of the Approved Hash Algorithms

4.2 承認済みハッシュアルゴリズムの強度

Table 1 provides a summary of the security strengths for the hash function security properties (discussed in the previous section) of the approved hash functions.

表1に、前節で説明したハッシュ関数のセキュリティ特性について、承認済みハッシュ関数のセキュリティ強度をまとめます。

Table 1: Strengths of the Security Properties of the Approved Hash Algorithms

表1:承認済みハッシュアルゴリズムのセキュリティ特性の強度

SHA-1SHA-224SHA-256SHA-384SHA-512SHA-512/224SHA-512/256
Collision Resistance Strength in bits< 80112128192256112128
Preimage Resistance Strength in bits160224256384512224256
Second Preimage Resistance Strength in bits105-160201-224201-256384394-512224256
原本PDFの抜粋画像原本 PDF p.11 の画像抜粋
SHA-1SHA-224SHA-256SHA-384SHA-512SHA-512/224SHA-512/256
衝突耐性強度(ビット)< 80112128192256112128
原像耐性強度(ビット)160224256384512224256
第二原像耐性強度(ビット)105-160201-224201-256384394-512224256

As mentioned in Section 4.1, the expected collision resistance strength of any approved hash function is, in general, half the length of its hash value. This is currently believed to be true for all the approved hash functions except SHA-1. The latest cryptanalytic results for SHA-1 [SHA1 Attack] indicate that it may have a collision resistance strength that is considerably less than its expected strength of 80 bits. The expected preimage resistance strengths of the approved hash functions are provided in the above table. At the time that this Recommendation was written, there had been no known short cuts for finding preimages of the hash values generated by the approved hash algorithms. Except for SHA-384, SHA-512/224 and SHA-512/256, the second preimage resistance strengths of the approved hash functions depend not only on the functions themselves, but also on the sizes of the messages that the hash functions process [Second Preimage Attack]. In Table 1, the low end of each range applies to the situation where the length of the message input to the hash function is the maximum length allowed by the hash function, while the high end of the range applies to the situation where the message input length is relatively small. Information on determining the actual second preimage resistance strengths of the approved hash functions for different message lengths is provided in Appendix A. In the case of SHA-384, SHA-512/224 or SHA-512/256, the second preimage resistance strength does not depend on the message length; details can be found in Appendix A. Note that the preimage resistance and the second preimage resistance strengths are greater than the collision resistance strength for each of the approved hash algorithms specified in FIPS 180-4.

4.1節で述べたように、一般に、承認済みハッシュ関数の期待衝突耐性強度はハッシュ値長の半分です。SHA-1を除くすべての承認済みハッシュ関数で、現時点ではこれが当てはまると考えられています。SHA-1に関する最新の暗号解析結果[SHA1 Attack]は、その衝突耐性強度が期待強度である80ビットを大幅に下回る可能性を示しています。承認済みハッシュ関数の期待原像耐性強度は上記の表に示されています。本推奨事項の執筆時点では、承認済みハッシュアルゴリズムが生成するハッシュ値の原像を見つけるための近道は知られていませんでした。SHA-384、SHA-512/224、SHA-512/256を除き、承認済みハッシュ関数の第二原像耐性強度は、関数自体だけでなく、ハッシュ関数が処理するメッセージの大きさにも依存します[Second Preimage Attack]。表1の各範囲の下限は、ハッシュ関数へのメッセージ入力長がそのハッシュ関数で許される最大長である場合に適用され、上限はメッセージ入力長が比較的小さい場合に適用されます。異なるメッセージ長に対する承認済みハッシュ関数の実際の第二原像耐性強度の算定に関する情報は付録Aに示します。SHA-384、SHA-512/224、SHA-512/256の場合、第二原像耐性強度はメッセージ長に依存しません。詳細は付録Aを参照してください。なお、FIPS 180-4で規定される承認済みハッシュアルゴリズムのいずれについても、原像耐性強度と第二原像耐性強度は衝突耐性強度を上回ります。

5 Hash function Usage

5 ハッシュ関数の使用

5.1 Truncated Message Digest

5.1 切り詰められたメッセージダイジェスト

Some applications may require a value that is shorter than the (full-length) message digest provided by an approved hash function as specified in FIPS 180-4. In such cases, it may be appropriate to use a subset of the bits produced by the hash function as the (shortened) message digest. Let the (shortened) message digest be called a truncated message digest, and let λ be its desired length in bits. A truncated message digest may be used if the following requirements are met:

一部のアプリケーションでは、FIPS 180-4に規定される承認済みハッシュ関数が出力する(全長の)メッセージダイジェストより短い値が必要となる場合があります。そのような場合、ハッシュ関数が生成するビットの一部を(短縮された)メッセージダイジェストとして使用するのが適切なことがあります。この(短縮された)メッセージダイジェストを「切り詰められたメッセージダイジェスト」と呼び、その所望のビット長をλとします。切り詰められたメッセージダイジェストは、次の要件を満たす場合に使用してもよいです。

1.The length of the output block of the approved hash function to be used shall be greater than λ (i.e., L > λ).

1.使用する承認済みハッシュ関数の出力ブロックの長さはλより大きくなければなりません(すなわち、L > λ)。

2.The λ left-most bits of the full-length message digest shall be selected as the truncated message digest.

2.2. 全長メッセージダイジェストの左端からλビットを、切り詰められたメッセージダイジェストとして選択しなければなりません。

For example, if a truncated message digest of 96 bits is desired, the SHA-256 hash function could be used (e.g., because it is available to the application, and provides an output larger than 96 bits). The leftmost 96 bits of the 256-bit message digest generated by SHA-256 are selected as the truncated message digest, and the rightmost 160 bits of the message digest are discarded.

例えば、96ビットの切り詰められたメッセージダイジェストが必要な場合、SHA-256ハッシュ関数を使用できます(例えば、アプリケーションで利用可能であり、96ビットを超える出力を提供するため)。SHA-256が生成する256ビットのメッセージダイジェストの左端96ビットを切り詰められたメッセージダイジェストとして選択し、右端の160ビットを破棄します。

3. If collision resistance is required, \(\lambda\) shall be at least twice the required collision resistance strength \(s\) (in bits) for the truncated message digest (i.e., \(\lambda \ge 2s\)).

3. 衝突耐性が必要な場合、\(\lambda\)は、切り詰められたメッセージダイジェストに必要な衝突耐性強度\(s\)(ビット単位)の少なくとも2倍でなければなりません(すなわち、\(\lambda \ge 2s\))。

These specifications for truncating the output of a cryptographic hash function promote application interoperability in situations where the use of shortened message digests is appropriate (and permissible), as determined by implementers and application developers acting in conformance with NIST Standards and Recommendations. Truncating the message digest can impact the security of an application. By truncating a message digest, the expected collision resistance strength is reduced from L/2 to λ/2 (in bits). For the example in item 2 above, even though SHA-256 provides 128 bits of collision resistance, the collision resistance provided by the 96-bit truncated message digest is half the length of the truncated message digest, which is 48 bits, in this case.

暗号ハッシュ関数の出力を切り詰めるこれらの仕様は、NIST標準および推奨事項に従う実装者とアプリケーション開発者が適切かつ許容できると判断した場合に、短縮されたメッセージダイジェストを使用する状況で、アプリケーション間の相互運用性を促進します。メッセージダイジェストの切り詰めは、アプリケーションのセキュリティに影響することがあります。切り詰めると、期待衝突耐性強度はL/2からλ/2(ビット単位)へ低下します。上記の項目2の例では、SHA-256自体は128ビットの衝突耐性を提供しますが、96ビットに切り詰めたメッセージダイジェストの衝突耐性は、その長さの半分、すなわち48ビットとなります。

The truncated message digest of λ bits provides an expected preimage resistance of λ bits, not L bits, regardless of the hash function used. The expected second preimage resistance strength of a message digest truncated to λ bits sometimes depends on the length of the message. This dependence is determined as specified in Appendix A. Note that there are situations for which the expected second preimage resistance strength does not depend on the message length. For example, a 130-bit truncated message digest generated using SHA-256 has an expected second preimage strength of 130 bits, rather than a value in the range specified in Table 1 above for SHA-256. Truncating the message digest can have other impacts, as well. For example, applications that use a truncated message digest risk attacks based on confusion between different parties about the specific amount of truncation used, as well as the specific hash function that was used to produce the truncated message digest. Any application using a truncated message digest is responsible for ensuring that the truncation amount and the hash function used are known to all parties, with no chance of ambiguity.

λビットに切り詰めたメッセージダイジェストが提供する期待原像耐性は、使用するハッシュ関数にかかわらずLビットではなくλビットです。λビットに切り詰めたメッセージダイジェストの期待第二原像耐性強度は、メッセージ長に依存することがあります。この依存関係は付録Aの規定に従って決まります。期待第二原像耐性強度がメッセージ長に依存しない場合もあります。例えば、SHA-256で生成した130ビットの切り詰められたメッセージダイジェストの期待第二原像耐性強度は130ビットであり、表1に示したSHA-256の範囲内の値ではありません。メッセージダイジェストの切り詰めには、ほかの影響もあります。例えば、切り詰められたメッセージダイジェストを使うアプリケーションでは、切り詰め量や生成に用いたハッシュ関数について当事者間に混乱が生じることで、攻撃の危険が生じます。切り詰められたメッセージダイジェストを使用するアプリケーションは、曖昧さが生じないよう、切り詰め量と使用したハッシュ関数をすべての当事者が把握できるようにする責任を負います。

5.2 Digital Signatures

5.2 デジタル署名

A hash function is used to map a message of any eligible length (see FIPS 180-4) to a fixed-length message digest. In a digital signature generation process, this message digest is then signed by a signing operation, such as an RSA private key operation, to produce a digital signature. The resulting digital signature is used to verify who signed the message and whether or not the message was altered (either deliberately or accidentally) after it was signed. When two different messages have the same message digest (i.e., a collision is found), then a digital signature of one message could be used as a digital signature for the other message. If this happens, then a verified digital signature does not guarantee the authenticity of the signed message, because either one of the two messages could be considered valid. Therefore, a hash function used for digital signatures requires collision resistance. The approved hash functions are considered to provide the collision resistance strengths as specified in Table 1 of Section 4.2. For digital signature applications, the security strength of a hash function without any preprocessing is generally its collision resistance strength. When appropriate processing is applied to the data before the hash value is computed, the security strength may be more than the collision resistance strength (see Section 5.2.3). Without any preprocessing of the message input to the hash function, the security strength of any digital signature that is generated using an algorithm specified in FIPS 186-3 is the minimum of the collision resistance strength of the hash algorithm and the security strength provided by the signing algorithm. More information on security strengths can be found in SP 800-57, Part 1. For instance, if a digital signature that is generated by one of the approved digital signature algorithms with SHA-1 as the hash function and key sizes specified in FIPS 186-33, then the security strength of this digital signature is less than 80 bits (see Table 1 in Section 4.2); i.e., the strength of the digital signature process is determined by the strength of SHA-1, rather than the strength of the key, in this case. Therefore, SHA-1 shall not be used in any new digital signature applications that require at least 80 bits of security strength. Furthermore, SHA-1 shall not be used for the generation of digital signatures after the end of 2013 (see SP 800-131A [SP 800-131A] for information about the required key lengths for digital signature applications). More information on the security strengths of digital signature applications using the approved hash algorithms and the recommended lifetimes of cryptographic algorithm usage can be found in SP 800-57, Part 1. There are several ways to use hash functions with digital signature algorithms as described below.

ハッシュ関数は、FIPS 180-4で認められる長さのメッセージを固定長のメッセージダイジェストに対応付けるために使用されます。デジタル署名の生成では、このメッセージダイジェストに署名操作(RSA秘密鍵操作など)を適用し、デジタル署名を生成します。生成されたデジタル署名は、誰がメッセージに署名したか、また署名後にメッセージが(意図的または偶発的に)変更されたかどうかを検証するために使われます。異なる2つのメッセージが同じメッセージダイジェストを持つ(すなわち衝突が見つかる)場合、一方のメッセージのデジタル署名を他方のメッセージの署名として使用できてしまいます。この場合、どちらのメッセージも有効とみなされ得るため、署名を検証できても、署名されたメッセージの真正性は保証されません。したがって、デジタル署名に用いるハッシュ関数には衝突耐性が必要です。承認済みハッシュ関数は、4.2節の表1に示す衝突耐性強度を提供するとみなされています。デジタル署名アプリケーションでは、前処理を一切行わない場合のハッシュ関数のセキュリティ強度は、一般にその衝突耐性強度です。ハッシュ値の計算前にデータへ適切な処理を適用する場合、セキュリティ強度は衝突耐性強度を上回ることがあります(5.2.3節を参照してください)。ハッシュ関数へのメッセージ入力を前処理しない場合、FIPS 186-3で規定されるアルゴリズムで生成されるデジタル署名のセキュリティ強度は、ハッシュアルゴリズムの衝突耐性強度と署名アルゴリズムのセキュリティ強度の小さい方となります。セキュリティ強度の詳細はSP 800-57第1部を参照してください。例えば、承認済みデジタル署名アルゴリズムのいずれかを使い、ハッシュ関数としてSHA-1を用い、FIPS 186-3で規定された鍵長³で生成したデジタル署名のセキュリティ強度は80ビット未満です(4.2節の表1を参照してください)。この場合、署名プロセスの強度は鍵の強度ではなくSHA-1の強度で決まります。したがって、少なくとも80ビットのセキュリティ強度を必要とする新たなデジタル署名アプリケーションでSHA-1を使用してはなりません。さらに、2013年末以降、デジタル署名の生成にSHA-1を使用してはなりません(デジタル署名アプリケーションで必要な鍵長についてはSP 800-131A [SP 800-131A]を参照してください)。承認済みハッシュアルゴリズムを用いるデジタル署名アプリケーションのセキュリティ強度と、暗号アルゴリズムの推奨使用期間については、SP 800-57第1部を参照してください。以下に、デジタル署名アルゴリズムでハッシュ関数を使用する複数の方法を示します。

5.2.1 Full-length Message Digests

5.2.1 全長メッセージダイジェスト

When the untruncated output of an approved hash function (as specified in FIPS 180-4) is used by an approved digital signature algorithm (as specified in FIPS 186-3), the resulting full-length message digests can support security strengths up to those given in Table 1 of Section 4.2 (for collision resistance).

FIPS 180-4に規定される承認済みハッシュ関数の切り詰めていない出力を、FIPS 186-3に規定される承認済みデジタル署名アルゴリズムで使用する場合、得られる全長メッセージダイジェストは、4.2節の表1に(衝突耐性について)示される値までのセキュリティ強度を支えることができます。

5.2.2 Truncated Message Digests

5.2.2 切り詰められたメッセージダイジェスト

In some specific situations, truncated message digests are used in generating digital signatures. (Details about these situations, including the lengths required for the truncated hash values, can be found in FIPS 186-3.) In such cases, the security strength that can be supported by a hash function depends on the length of these truncated values, as well as the particular hash function that is used. As noted in Section 5.1, when the outputs of an approved \(L\)-bit hash function are truncated to \(\lambda\) bits (where \(\lambda < L\)), the collision resistance strength supported by the truncated message digests is reduced to \(\lambda/2\) bits. Therefore, in addition to the requirements/restrictions imposed by FIPS 186-3, the value of \(\lambda\) shall be at least twice the desired security strength (in bits) required for the digital signature. For example, if a security strength of 112 bits is required for digital signatures, a (truncated) message digest of (at least) 224 bits must be used. If required/desired, any approved hash functions except SHA-1 could be employed to generate (truncated) message digests of exactly 224 bits in length. (For SHA-224 and SHA-512/224, the hash function's output would not require truncation.) It is recommended that the hash function chosen should minimize the number of truncation operations required to achieve the required/desired length for the hash value. For the 224-bit example above, SHA-512/224 should be chosen over SHA-384 and SHA-512/256. All three hash functions employ one (internal) truncation operation to produce their output, but SHA-384 and SHA-512/256 would each require an additional (external) truncation operation to pare their output down to the desired length of 224 bits.

特定の状況では、デジタル署名の生成に切り詰められたメッセージダイジェストを使用します(必要な切り詰めハッシュ値の長さを含む状況の詳細はFIPS 186-3を参照)。この場合、ハッシュ関数が支えられるセキュリティ強度は、切り詰められた値の長さと使用するハッシュ関数の両方に依存します。5.1節で述べたとおり、承認済み\(L\)ビットハッシュ関数の出力を\(\lambda\)ビットに切り詰める場合(\(\lambda < L\))、切り詰められたメッセージダイジェストが支える衝突耐性強度は\(\lambda/2\)ビットに低下します。したがって、FIPS 186-3が課す要件および制限に加えて、\(\lambda\)の値はデジタル署名に必要な目標セキュリティ強度(ビット単位)の少なくとも2倍でなければなりません。例えば、デジタル署名に112ビットのセキュリティ強度が必要なら、少なくとも224ビットの(切り詰められた)メッセージダイジェストを使用しなければなりません。必要または望ましい場合、SHA-1を除く任意の承認済みハッシュ関数を使って、正確に224ビット長の(切り詰められた)メッセージダイジェストを生成できます(SHA-224およびSHA-512/224では、ハッシュ関数の出力を切り詰める必要はない)。必要または望ましいハッシュ値長を得るために必要な切り詰め操作の回数が最小となるハッシュ関数を選ぶことが推奨されます。上記の224ビットの例では、SHA-384やSHA-512/256よりSHA-512/224を選ぶべきです。3つのハッシュ関数はいずれも出力を生成するために内部切り詰めを1回行いますが、SHA-384とSHA-512/256では、出力を目標の224ビットにするため、さらに外部切り詰めを行う必要があります。

3 Key sizes that provide at least 112 bits of strength are provided.
3 112ビット以上の強度を提供する鍵長が規定されています。

5.2.3 Randomized Hashing for Digital Signatures

5.2.3 デジタル署名のためのランダム化ハッシュ

As described in Section 5.2, the overall security strength of a digital signature is limited by the collision resistance strength of the hash function. However, when using the randomized hashing technique specified in SP 800-106 [SP 800-106], a randomized hash function may support a higher level of security with respect to a particular potential vulnerability, offering enhanced protection to a message signer against a collision attack by a malicious message preparer who formulates the message to be signed, but does not actually sign the message. In such an attack, the malicious message preparer would endeavor to find two messages that hash to the same value. Once the message signer had generated a signature for one of the messages, the malicious preparer could accuse the signer of having signed the other message instead. In situations where one party is asked to sign messages prepared by another party, the level of protection (in bits) that is provided to the message signer against a collision attack by using randomized hashing is determined by the minimum of the following three quantities:

5.2節で説明したように、デジタル署名全体のセキュリティ強度はハッシュ関数の衝突耐性強度によって制限されます。ただし、SP 800-106 [SP 800-106]で規定されるランダム化ハッシュ技法を用いると、特定の潜在的な脆弱性に対するセキュリティ強度を高められる場合があります。実際には署名せず、署名対象のメッセージを作成する悪意あるメッセージ作成者が衝突攻撃を行う場合に、ランダム化ハッシュ関数は署名者をより強く保護できます。この攻撃では、悪意ある作成者は同じ値にハッシュされる2つのメッセージを見つけようとします。署名者が一方のメッセージに署名した後、作成者は、署名者がもう一方のメッセージに署名したと主張できます。ある当事者が別の当事者の用意したメッセージへの署名を求められる状況で、ランダム化ハッシュによる衝突攻撃への署名者の保護レベル(ビット単位)は、次の3つの値の最小値で決まります。

•The second preimage resistance strength (in bits) of the hash function.

•1. ハッシュ関数の第二原像耐性強度(ビット単位)。

•The security strength (in bits) of the random bit generator (RBG) employed by the signer to produce bit strings used to randomize messages, or, the collision resistance strength (in bits) of the hash function – whichever is larger.

•2. 署名者がメッセージをランダム化するビット列の生成に用いるランダムビット生成器(RBG)のセキュリティ強度(ビット単位)、またはハッシュ関数の衝突耐性強度(ビット単位)のうち、大きい方。

•The sum of the collision resistance strength (in bits) of the hash function and the smaller of these two quantities: (1) The length (in bits) of bit strings used to randomize messages (denoted rv in SP 800-106), and (2) The length (in bits) of the RBG output used to generate rv (as specified in Section 3.3 of SP 800-106).

•3. ハッシュ関数の衝突耐性強度(ビット単位)と、次の2つの値の小さい方との合計:(1) メッセージのランダム化に使うビット列の長さ(ビット単位、SP 800-106ではrvと表記)、(2) rvの生成に使うRBG出力の長さ(ビット単位、SP 800-106第3.3節で規定)。

When randomized hashing is used, the RBG (see Section 5.5 below for more information) employed to produce the bit strings used to randomize messages shall support a security strength that is equal to or greater than the security strength of the signing algorithm. See SP 800-57, Part 1, for information about security strengths of different signing algorithms. The randomization process itself shall conform to the specifications of SP 800-106 for digital signature applications supporting at least 112 bits of security. Under these conditions, SHA-1-based randomized hashing could provide 112 bits of security strength against a collision attack by a malicious message preparer, even though the unrandomized SHA-1 function has a collision resistance strength that is less than 80 bits. It is important to note what the use of randomized hashing for digital signatures does and does not provide:

ランダム化ハッシュを使用する場合、メッセージのランダム化に用いるビット列を生成するRBG(詳細は後述の5.5節を参照)は、署名アルゴリズムのセキュリティ強度以上のセキュリティ強度を支えなければなりません。各種署名アルゴリズムのセキュリティ強度についてはSP 800-57第1部を参照してください。ランダム化処理自体は、112ビット以上のセキュリティを支えるデジタル署名アプリケーションについて、SP 800-106の仕様に適合しなければなりません。この条件下では、ランダム化していないSHA-1関数の衝突耐性強度が80ビット未満でも、SHA-1ベースのランダム化ハッシュは、悪意あるメッセージ作成者による衝突攻撃に対して112ビットのセキュリティ強度を提供できます。デジタル署名にランダム化ハッシュを使うことで得られるものと得られないものを理解しておくことが重要です。

1.1) Randomized hashing can offer a message signer additional protection by reducing the likelihood that a message preparer can find multiple messages that yield the same hash value during the digital signature generation process – even if it is practical to find collisions for the unrandomized hash function.

1.1) ランダム化ハッシュは、ランダム化していないハッシュ関数で衝突を実際に見つけられる場合でも、デジタル署名生成中にメッセージ作成者が同じハッシュ値になる複数のメッセージを見つける可能性を下げ、署名者を追加的に保護できます。

2.2) Randomized hashing does not offer the message preparer or the signature verifiers any additional protection from a misbehaving signer (who may, for example, generate one signature that can be associated with either of two chosen messages after finding randomized versions of those messages that hash to the same value).

2.2) ランダム化ハッシュは、不正な署名者(例えば、選択した2つのメッセージについて同じ値にハッシュされるランダム化版を見つけた後、その2つのメッセージのどちらにも対応付けられる1つの署名を生成し得る署名者)から、メッセージ作成者や署名検証者を追加的に保護するものではありません。

3.Randomized hashing does not improve the assurance of origin authenticity, data integrity, and/or signatory non-repudiation provided by the digital signature to signature verifiers (i.e., relying parties).

3.ランダム化ハッシュは、デジタル署名が署名検証者(すなわち依拠当事者)に提供する発信元真正性、データ完全性、および/または署名者の否認防止に関する保証を高めるものではありません。

5.3 Keyed-Hash Message Authentication Codes (HMAC)

5.3 鍵付きハッシュメッセージ認証コード(HMAC)

5.3.1 Description

5.3.1 説明

Message authentication codes (MACs) provide data authentication and integrity protection. Two types of algorithms for computing a MAC have been approved: 1) MAC algorithms that are based on approved block cipher algorithms (more information can be found in [SPs 800-38B, C and D]) and 2) MAC algorithms that are based on hash functions, called HMAC algorithms, that are specified in FIPS 198-1. This section discusses the use of HMAC. An output from an HMAC algorithm is called an HMAC output. The HMAC output is either used in its entirety, or is truncated (see Section 5.3.3) when it is transmitted for subsequent verification. The transmitted value is called a MacTag. The HMAC algorithm requires the use of a secret key that is shared between the entity that generates the HMAC output (e.g., a message sender), and the entity (or entities) that need to verify the transmitted MacTag (message receiver(s)). The HMAC output is generated from a secret key and the string of “text” to be MACed (e.g., a message to be sent) using the HMAC algorithm. The MacTag is provided to the MacTag verifier, along with the “text” that was MACed (e.g., the sender transmits both the MacTag and the message to the intended receiver). The verifier computes an HMAC output on the received “text” using the same key and HMAC algorithm that were (purportedly) used to generate the received MacTag, generates a (new) MacTag (either a full or truncated HMAC output), and then compares the verifier-generated MacTag with the received MacTag. If the two values match, the “text” has been correctly received and the verifier is assured that the entity that generated the MacTag is a member of the community of users that share the key. The security strength provided by the HMAC algorithm depends on the security strength of the HMAC key, the underlying hash algorithm and the length of the MacTag.

メッセージ認証コード(MAC)は、データの認証と完全性保護を提供します。MACの計算には、承認済みブロック暗号アルゴリズムに基づくMACアルゴリズム(詳細は[SP 800-38B、C、D]を参照)と、ハッシュ関数に基づくMACアルゴリズムの2種類が承認されています。後者はHMACアルゴリズムと呼ばれ、FIPS 198-1で規定されます。本節ではHMACの使用について説明します。HMACアルゴリズムの出力をHMAC出力と呼びます。後続の検証のために送信するとき、HMAC出力は全体を使用するか、切り詰めます(5.3.3節を参照してください)。送信される値をMacTagと呼びます。HMACアルゴリズムでは、HMAC出力を生成する主体(例えばメッセージ送信者)と、送信されたMacTagを検証する必要がある主体(複数の場合もある、すなわちメッセージ受信者)との間で秘密鍵を共有する必要があります。HMACアルゴリズムを使い、秘密鍵とMAC対象の「テキスト」列(例えば送信するメッセージ)からHMAC出力を生成します。MacTagは、MAC対象の「テキスト」とともに検証者へ渡されます(例えば、送信者はMacTagとメッセージを意図した受信者へ送信します)。検証者は、受信した「テキスト」に対し、受信したMacTagの生成に使われた(とされる)ものと同じ鍵とHMACアルゴリズムでHMAC出力を計算し、新しいMacTag(HMAC出力の全体または切り詰めた値)を生成して、検証者が生成したMacTagと受信したMacTagを比較します。2つの値が一致すれば、「テキスト」は正しく受信されており、検証者はMacTagを生成した主体が鍵を共有する利用者群の一員であると確信できます。HMACアルゴリズムが提供するセキュリティ強度は、HMAC鍵のセキュリティ強度、基礎となるハッシュアルゴリズム、およびMacTagの長さに依存します。

5.3.2 The HMAC Key

5.3.2 HMAC鍵

The security strength of the HMAC algorithm depends, in part, on the security strength of the HMAC key, K. An HMAC key shall have a security strength that meets or exceeds the security strength required to protect the data over which the HMAC is computed.

HMACアルゴリズムのセキュリティ強度は、HMAC鍵Kのセキュリティ強度にも依存します。HMAC鍵は、HMACを計算する対象データの保護に必要なセキュリティ強度以上でなければなりません。

The HMAC key shall be kept secret. When the secrecy of the HMAC key, K, is not preserved, an adversary that knows K, may impersonate any of the users that share that key in order to generate MacTags that seem to be authentic (i.e., MacTags that can be verified and are subsequently presumed to be authentic). HMAC keys shall be generated as specified in SP 800-133 [SP 800-133].

HMAC鍵は秘密に保たなければなりません。HMAC鍵Kの秘匿性が保たれない場合、Kを知る攻撃者は、その鍵を共有する利用者になりすまし、真正に見える(すなわち検証でき、その後真正とみなされる)MacTagを生成できます。HMAC鍵はSP 800-133 [SP 800-133]に従って生成しなければなりません。

5.3.3 Truncation of HMAC Output

5.3.3 HMAC出力の切り詰め

When an application truncates the HMAC output to generate a MacTag to a desired length, λ, the λ left-most bits of the HMAC output shall be used as the MacTag. However, the output length, λ, shall be no less than 32 bits. For example, a low bandwidth channel or a desired high efficiency computation application such as audio or video casting application might use 32-bit MacTags.

アプリケーションがHMAC出力を切り詰めて、所望の長さλのMacTagを生成する場合、HMAC出力の左端からλビットをMacTagとして使用しなければなりません。ただし、出力長λは32ビット以上でなければなりません。例えば、低帯域幅のチャネルや、音声・動画配信のように計算効率を高めたいアプリケーションでは、32ビットのMacTagを使うことがあります。

5.3.4 Security Effect of the HMAC Key

5.3.4 HMAC鍵がセキュリティに及ぼす影響

Let \(C\) denote the bit length of the internal hash value that is denoted \(H\) in FIPS 180-4. (This \(H\) is often called the “chaining value” in descriptions of Merkle–Damgård-style hash functions.) Note that \(C\) is not (necessarily) equal to \(L\), the bit length of the hash function’s output (see, for example, SHA-384 or SHA-512/\(t\) for any \(t < 512\), for which \(L < 512 = C\)). In all currently approved hash functions, \(L \le C\) (with \(L = C\) for SHA-1, SHA-256, and SHA-512). The effective security strength4 of the HMAC key is the minimum of the security strength of \(K\) and the value of \(2C\). That is, \(\text{security strength} = \min(\text{security strength of } K, 2C)\). For example, if the security strength of \(K\) is 128 bits, and SHA-1 is used, then the effective security strength of the HMAC key is 128 bits, since for SHA-1, \(2C = 320\). Note that, in this example, even if the security strength of \(K\) is greater than 320 bits, the effective security strength of the key is limited to 320 bits (the value of \(2C\) for SHA-1). In general, there is no benefit in generating \(K\) with more than \(2C\) bits of security. In particular, it is not sensible to generate \(K\) with a bit length that exceeds the input block size of the approved \(L\)-bit hash function employed in the HMAC construction. Such a \(K\) is hashed, and the resulting \(L\)-bit value is used instead. Returning to the SHA-1 example, suppose that the key \(K\) has a bit length greater than 512 (the input block size for SHA-1). Instead of using \(K\) directly, HMAC replaces \(K\) by its 160-bit SHA-1 hash value, and so the effective security strength of that choice of \(K\) is no more than 160 bits.

\(C\)を、FIPS 180-4で\(H\)と表記される内部ハッシュ値のビット長とします(この\(H\)は、Merkle–Damgård型ハッシュ関数の説明で「連鎖値」と呼ばれることが多い)。\(C\)は、ハッシュ関数の出力ビット長\(L\)と必ずしも等しくありません(例えばSHA-384や、SHA-512/\(t\)で\(t < 512\)であるものでは、\(L < 512 = C\))。現在承認されているすべてのハッシュ関数では\(L \le C\)です(SHA-1、SHA-256、SHA-512では\(L = C\))。HMAC鍵の実効セキュリティ強度4は、\(K\)のセキュリティ強度と\(2C\)の値の小さい方です。すなわち、\(\text{セキュリティ強度} = \min(K \text{ のセキュリティ強度}, 2C)\)となります。例えば、\(K\)のセキュリティ強度が128ビットでSHA-1を使用する場合、HMAC鍵の実効セキュリティ強度は128ビットです。SHA-1では\(2C = 320\)だからです。この例では、\(K\)のセキュリティ強度が320ビットを超えても、鍵の実効セキュリティ強度は320ビット(SHA-1の\(2C\)の値)に制限されます。一般に、\(K\)を\(2C\)ビットを超えるセキュリティで生成しても利点はありません。特に、\(K\)を、HMAC構成で用いる承認済み\(L\)ビットハッシュ関数の入力ブロック長を超えるビット長で生成するのは適切ではありません。そのような\(K\)はハッシュされ、代わりに得られた\(L\)ビット値が使用されます。SHA-1の例に戻り、鍵\(K\)のビット長が512(SHA-1の入力ブロック長)を超えるとします。\(K\)をそのまま使うのではなく、HMACは\(K\)を160ビットのSHA-1ハッシュ値に置き換えるため、その\(K\)の選択による実効セキュリティ強度は160ビット以下となります。

4 As described in [BCK1], the success of a collision attack on any approved HMAC algorithm in FIPS 198-1 that uses SHA-1 would require the collection of at least \(2^{80}\) pairs of chosen plaintexts and their corresponding HMAC values. This is an impractical task. So, the collision attack is not considered in this document. In this Recommendation, the strength of the HMAC key is considered to be the amount of work required for an attacker who performs a brute-force attack to discover the HMAC key \(K\) or the first hash values (\(H\)s) from hashing the two strings: \((K0 \oplus \mathit{opad})\) and \((K0 \oplus \mathit{ipad})\) separately in the HMAC construction (see FIPS 198-1) in order to generate authentic \(\mathit{MacTags}\) at any time.

4 [BCK1]の説明によると、FIPS 198-1で規定される承認済みHMACアルゴリズムのうちSHA-1を使用するものへの衝突攻撃を成功させるには、選択平文と対応するHMAC値の組を少なくとも\(2^{80}\)組集める必要があります。これは実行不可能な作業であるため、本書では衝突攻撃を考慮しません。本推奨事項では、HMAC鍵の強度を、攻撃者が真正な\(\mathit{MacTags}\)をいつでも生成するために、ブルートフォース攻撃を行って、HMAC鍵\(K\)、またはHMAC構成(FIPS 198-1を参照)で\((K0 \oplus \mathit{opad})\)と\((K0 \oplus \mathit{ipad})\)という2つの文字列を個別にハッシュして得られる最初のハッシュ値(\(H\))を特定するために必要な作業量とみなします。

5.3.5 Security of the HMAC Values

5.3.5 HMAC値のセキュリティ

The successful verification of a \(\mathit{MacTag}\) does not completely guarantee that the accompanying text is authentic; there is a slight chance that an adversary with no knowledge of the HMAC key, \(K\), can present a \((\mathit{MacTag}, \mathit{text})\) pair that will pass the verification procedure. From the perspective of an adversary that does not know the HMAC key \(K\) (i.e., the adversary is not among the community of users that share the key), the assurance of authenticity provided by a \(\mathit{MacTag}\) depends on its length and on the number of failed \(\mathit{MacTag}\) verifications allowed by a system for each value of the HMAC key. Let \(2^t\) be the number of failed \(\mathit{MacTag}\) verifications allowed by a system for each value of the HMAC key. The \(\mathit{MacTag}\) length, \(\lambda\), and the value of \(t\) need to be chosen to avoid an unacceptable probability of falsely accepting forged data. The likelihood of accepting forged data as authentic is \((1/2)^{(\lambda - t)}\). For example, if \(\lambda\) is 32, and a system allows \(2^{12}\) failed \(\mathit{MacTag}\) verifications for any given value of the HMAC key, then the likelihood of accepting forged data is \((1/2)^{20}\). In order to increase assurance of authenticity, either \(\lambda\) would need to be increased, or the number of allowed failed \(\mathit{MacTag}\) verifications for each value of the HMAC key would need to be decreased. To avoid having an unacceptable probability of falsely accepting forged data at any time, the value of the HMAC key must be changed to a new value before the number of failed \(\mathit{MacTag}\) authentications reaches the maximum allowed number (\(2^t\)). For the example above, with \(\lambda = 32\) and \(t = 20\), the HMAC key must be changed before the number of failed \(\mathit{MacTag}\) verifications reaches \(2^{12}\). The table below provides the likelihoods of accepting forged data for different \(\mathit{MacTag}\) lengths and allowed numbers of MAC verifications using a given value of the HMAC key. This table is intended to assist the implementers of HMAC applications in security-sensitive systems to assess the security risk associated with using \(\mathit{MacTags}\).

\(\mathit{MacTag}\)の検証に成功しても、付随するテキストが真正であることは完全には保証されません。HMAC鍵\(K\)を知らない攻撃者であっても、検証手順を通過する\((\mathit{MacTag}, \mathit{text})\)の組を提示できる可能性がわずかにあります。HMAC鍵\(K\)を知らない攻撃者(すなわち、鍵を共有する利用者群に属さない攻撃者)から見た場合、\(\mathit{MacTag}\)による真正性の保証は、その長さと、HMAC鍵の各値に対してシステムが許容する\(\mathit{MacTag}\)検証の失敗回数に依存します。\(2^t\)を、HMAC鍵の各値に対してシステムが許容する\(\mathit{MacTag}\)検証の失敗回数とします。\(\mathit{MacTag}\)の長さ\(\lambda\)と\(t\)の値は、偽造データを誤って受け入れる確率が許容できない水準にならないよう選ぶ必要があります。偽造データを真正として受け入れる確率は\((1/2)^{(\lambda - t)}\)です。例えば、\(\lambda\)が32で、システムが\(2^{12}\)回の\(\mathit{MacTag}\)検証の失敗をHMAC鍵の任意の値に対して許容する場合、偽造データを受け入れる確率は\((1/2)^{20}\)です。真正性の保証を高めるには、\(\lambda\)を大きくするか、\(\mathit{MacTag}\)検証の許容失敗回数をHMAC鍵の各値について減らす必要があります。どの時点においても、偽造データを誤って受け入れる確率が許容できない水準にならないようにするには、HMAC鍵の値を、\(\mathit{MacTag}\)認証の失敗回数が最大許容数(\(2^t\))に達する前に新しい値へ変更しなければなりません。上記の例で\(\lambda = 32\)、\(t = 20\)の場合、\(\mathit{MacTag}\)検証の失敗回数が\(2^{12}\)に達する前にHMAC鍵を変更しなければなりません。次の表は、異なる\(\mathit{MacTag}\)長と、HMAC鍵の所与の値を用いたMAC検証の許容回数について、偽造データを受け入れる確率を示します。この表は、セキュリティが重要なシステムでHMACアプリケーションを実装する者が、\(\mathit{MacTags}\)の使用に伴うセキュリティリスクを評価するのを助けるためのものです。

\(\lambda\)Number of Failed Verifications Allowed (\(2^t\)):
\(2^{20}\)\(2^{30}\)\(2^{35}\)
40\(2^{-20}\)\(2^{-10}\)\(2^{-5}\)
64\(2^{-44}\)\(2^{-34}\)\(2^{-29}\)
96\(2^{-76}\)\(2^{-66}\)\(2^{-61}\)
\(\lambda\)許容する検証失敗回数(\(2^t\)):
\(2^{20}\)\(2^{30}\)\(2^{35}\)
40\(2^{-20}\)\(2^{-10}\)\(2^{-5}\)
64\(2^{-44}\)\(2^{-34}\)\(2^{-29}\)
96\(2^{-76}\)\(2^{-66}\)\(2^{-61}\)

Table 2: Risks/Likelihoods of Accepting Forged Data

表2:偽造データを受け入れるリスク/確率

Each \(2^{-x}\) entry displayed in Table 2 is the probability of accepting forged data given the indicated choices for the \(\mathit{MacTag}\) length and the number of failed \(\mathit{MacTag}\) verifications allowed for a fixed value of the HMAC key. If the probability is not acceptable for the system, the HMAC key shall be changed to a new value before the number of failed MAC verifications reaches \(2^t\). A commonly acceptable length for the \(\mathit{MacTag}\) is 64 bits; \(\mathit{MacTags}\) with lengths shorter than 64 bits are discouraged.

表2に示す各\(2^{-x}\)の値は、示された\(\mathit{MacTag}\)長と、HMAC鍵の値を固定した場合に許容される\(\mathit{MacTag}\)検証の失敗回数に対して、偽造データを受け入れる確率です。その確率がシステムにとって許容できない場合、MAC検証失敗回数が\(2^t\)に達する前にHMAC鍵を新しい値に変更しなければなりません。一般に許容可能な\(\mathit{MacTag}\)の長さは64ビットであり、\(\mathit{MacTags}\)で長さが64ビット未満のものは推奨されません。

5.4 Hash-based Key Derivation Functions

5.4 ハッシュベース鍵導出関数

Hash functions can be used as building blocks in key derivation functions (KDFs) (e.g., as specified in SP 800-56A, SP 800-56B, SP 800-56C and SP 800-108). The KDFs specified in future versions of SPs 800-56A and B are expected to use the hash functions either directly or indirectly in an HMAC construction. The method specified in SP 800-56C is an additional approved method for key derivation purposes in SPs 800-56A and B. The key derivation functions in SP 800-56A, B and C are used to generate (i.e., derive) secret keying material from a shared secret computed during a key agreement transaction between communicating parties. The hash-based KDFs specified in SP 800-108 use an HMAC construction and can be used either: (1) to derive keying material from an existing key, or (2) as a key-expansion step in the key derivation method specified in SP 800-56C. In addition to the KDFs in SPs 800-56A, B and C, and in SP 800-108, there are several other allowed application-specific KDFs described in SP 800-135 [SP 800-135]. These application-specific KDFs are approved for use in their own protocols with specific conditions; see SP 800-135 for detailed information.

ハッシュ関数は鍵導出関数(KDF)の構成要素として使用できます(例えばSP 800-56A、SP 800-56B、SP 800-56C、SP 800-108に規定)。SP 800-56AおよびBの将来版で規定されるKDFは、ハッシュ関数を直接、またはHMAC構成を介して間接的に使用すると見込まれます。SP 800-56Cで規定される方式は、SP 800-56AおよびBで鍵を導出するために承認された追加方式です。SP 800-56A、B、Cの鍵導出関数は、通信当事者間の鍵合意トランザクションで計算された共有シークレットからシークレット鍵素材を生成(すなわち導出)します。SP 800-108のハッシュベースKDFはHMAC構成を使用し、(1)既存鍵から鍵素材を導出する方法、または(2)SP 800-56Cの鍵導出方式における鍵拡張段階として使用できます。SP 800-56A、B、CおよびSP 800-108のKDFに加えて、SP 800-135 [SP 800-135]には、用途固有の許可されたKDFがいくつか記載されています。これらの用途固有KDFは、所定の条件のもと、それぞれのプロトコルで使用することが承認されています。詳細はSP 800-135を参照してください。

5.4.1 Using a Hash Function Directly for Key Derivation

5.4.1 鍵導出におけるハッシュ関数の直接使用

This section discusses and provides security requirements for the KDFs in SP 800-56A and B that use the hash function directly as their building block (i.e., in the concatenation and ASN.1 KDFs). The KDFs derive the keying material from a shared secret computed during the key agreement transaction and other input attributes. The security strength that can be provided by a derived key depends on the security strength of the asymmetric keys used to generate the shared secret, the preimage strength of the hash function used in the KDF and the length of the derived key. Therefore, if a derived key is intended to provide s bits of security strength, then each of the following shall be equal to or greater than s:

本節では、ハッシュ関数を構成要素として直接使用するSP 800-56AおよびBのKDF(すなわち連結KDFおよびASN.1 KDF)について説明し、セキュリティ要件を示します。これらのKDFは、鍵合意トランザクション中に計算した共有シークレットとその他の入力属性から鍵素材を導出します。導出鍵が提供できるセキュリティ強度は、共有シークレットの生成に使用した非対称鍵のセキュリティ強度、KDFで使用するハッシュ関数の原像耐性、および導出鍵の長さに依存します。したがって、導出鍵にsビットのセキュリティ強度を持たせる場合、以下の各項目はs以上でなければなりません。

•The security strength supported by the asymmetric keys,

•非対称鍵が支えるセキュリティ強度。

•The preimage strength of the hash function, and

•ハッシュ関数の原像耐性。

•The length of the derived key in bits.

•導出鍵のビット長。

5.4.2 Using HMAC for Key Derivation During a Key Agreement Transaction

5.4.2 鍵合意トランザクション中の鍵導出におけるHMACの使用

This section discusses and provides security requirements for the key derivation methods in SP 800-56A, B and C that use the hash function in an HMAC construction. The KDFs specified in SPs 800-56A and B derive keys in a single step, and are being revised to allow the use of HMAC with an approved hash function for key derivation. SP 800-56C specifies a two-step key derivation procedure in which HMAC can be used during the key derivation process.

本節では、ハッシュ関数をHMAC構成で使用するSP 800-56A、B、Cの鍵導出方式について説明し、セキュリティ要件を示します。SP 800-56AおよびBで規定されるKDFは1段階で鍵を導出するものであり、鍵導出に承認済みハッシュ関数を用いるHMACの使用を認めるよう改訂が進められています。SP 800-56Cは、鍵導出の過程でHMACを使用できる2段階の鍵導出手順を規定します。

5.4.2.1 Using HMAC in the Single-Step Key Derivation Process

5.4.2.1 1段階鍵導出プロセスにおけるHMACの使用

SP 800-56A and B specify single-step key derivation functions using HMAC in the concatenation and ASN.1 forms. The security strength that can be provided by a derived key depends on the security strength of the asymmetric keys used to generate the shared secret, the preimage strength of the hash function used in the HMAC construction in the KDF and the length of the derived key. Note that in this case, the key used for HMAC is a salt, which can be a publicly known value, a secret value, or a combination of both. Therefore, if a derived key is intended to provide s bits of security strength, then each of the following shall be equal to or greater than s:

SP 800-56AおよびBは、HMACを用いる連結形式およびASN.1形式の1段階鍵導出関数を規定します。導出鍵が提供できるセキュリティ強度は、共有シークレットの生成に使用した非対称鍵のセキュリティ強度、KDFのHMAC構成で使用するハッシュ関数の原像耐性、および導出鍵の長さに依存します。なお、この場合、HMACに使用する鍵はソルトであり、公開値、秘密値、またはその両方の組み合わせでよいです。したがって、導出鍵にsビットのセキュリティ強度を持たせる場合、以下の各項目はs以上でなければなりません。

•The security strength provided by the asymmetric keys,

•非対称鍵が提供するセキュリティ強度。

•The preimage strength of the hash function used in the HMAC construction, and

•HMAC構成で使用するハッシュ関数の原像耐性。

•The length of the derived key in bits.

•導出鍵のビット長。

5.4.2.2 Using HMAC in the Two-Step Key Derivation Process

5.4.2.2 2段階鍵導出プロセスにおけるHMACの使用

SP 800-56C specifies a two-step key derivation procedure, which is also known as an “extraction-then-expansion” procedure. This procedure is included by reference in SPs 800-56A and B. The extraction-then-expansion procedure in SP 800-56C is comprised of two separate steps: randomness-extraction and key-expansion, both of which can be implemented using an HMAC construction; when this construction is used, the same hash function is used for the randomness extraction and key expansion steps. The security strength that can be provided by a key derived using the two-step procedure depends on the security strength of the asymmetric keys used to generate the shared secret, the preimage strength of the hash function used in each HMAC construction and the length of the derived key. In the randomness extraction step, the key used for HMAC is a salt, which can be a publicly known value, a secret value, or a combination of both; the result of this step is a key derivation key. In the key expansion step, the key used for HMAC is the entire key derivation key that was output from the randomness extraction step, e.g., if SHA-1 is used during the randomness extraction step, then the output is 160 bits in length, and is used as the key derivation key for the key expansion step. When this two-step procedure is used, if a derived key is intended to provide s bits of security strength, then each of the following shall be equal to or greater than s:

SP 800-56Cは「抽出後拡張」手順とも呼ばれる2段階の鍵導出手順を規定します。この手順はSP 800-56AおよびBに参照により含まれます。SP 800-56Cの抽出後拡張手順は、ランダム性抽出と鍵拡張という2つの独立した段階から成り、どちらもHMAC構成で実装できます。この構成を用いる場合、ランダム性抽出段階と鍵拡張段階では同じハッシュ関数を使用します。2段階手順で導出される鍵が提供できるセキュリティ強度は、共有シークレットの生成に使用した非対称鍵のセキュリティ強度、各HMAC構成で使用するハッシュ関数の原像耐性、および導出鍵の長さに依存します。ランダム性抽出段階でHMACに使用する鍵はソルトであり、公開値、秘密値、またはその両方の組み合わせでよいです。この段階の結果は鍵導出鍵です。鍵拡張段階でHMACに使用する鍵は、ランダム性抽出段階から出力された鍵導出鍵全体です。例えば、ランダム性抽出段階でSHA-1を使用すると、出力は160ビット長となり、鍵拡張段階の鍵導出鍵として使用されます。この2段階手順を用いる場合、導出鍵にsビットのセキュリティ強度を持たせるのであれば、以下の各項目はs以上でなければなりません。

•The security strength provided by the asymmetric keys,

•非対称鍵が提供するセキュリティ強度。

•The preimage strength of the hash function used in the HMAC construction of each step of the procedure, and

•手順の各段階でHMAC構成に使用するハッシュ関数の原像耐性。

•The length of the derived key in bits.

•導出鍵のビット長。

5.4.3 Using HMAC for Key Derivation from a Pre-shared Key

5.4.3 事前共有鍵からの鍵導出におけるHMACの使用

This section discusses and provides security requirements for the KDFs in SP 800-108 that are used to derive keying material from a pre-shared (i.e., existing) key, called a key-derivation key. HMAC can be used with an approved hash function to derive keying material. The security strength of a derived key depends on the security strength provided by the key-derivation key, the hash function used in the HMAC construction and the length of the derived key. If a derived key is intended to provide s bits of security strength, then each of the following shall be equal to or greater than s:

本節では、事前共有(すなわち既存の)鍵から鍵素材を導出するために用いるSP 800-108のKDFについて説明し、セキュリティ要件を示します。この鍵は鍵導出鍵と呼ばれます。承認済みハッシュ関数とともにHMACを用いて、鍵素材を導出できます。導出鍵のセキュリティ強度は、鍵導出鍵が提供するセキュリティ強度、HMAC構成で使用するハッシュ関数、および導出鍵の長さに依存します。導出鍵にsビットのセキュリティ強度を持たせる場合、以下の各項目はs以上でなければなりません。

•The security strength provided by the key-derivation key,

•鍵導出鍵が提供するセキュリティ強度。

•The preimage strength of the hash function used in the HMAC construction, and

•HMAC構成で使用するハッシュ関数の原像耐性。

•The length of the derived key in bits.

•導出鍵のビット長。

5.5 Random Number (Bit) Generation

5.5 乱数(ビット)生成

A random bit generator (RBG) is used to produce random bits. These bits may be used directly or may be converted to a random number (integer). Approved RBGs that use deterministic algorithms5, along with methods for converting a bit string to an integer can be found in SP 800-90A. Other approved random number generators were either specified or approved by reference in FIPS 186-2 [FIPS 186-2]; however, their use is limited (see SP 800-131A [SP 800-131A]). RBGs may be constructed using hash functions. The hash function used by the RBG shall be selected so that the RBG can provide a security strength that meets or exceeds the minimum security strength required for the random bits that it generates. See SP 800-57, Part 1, for the security strength that can be provided for each approved hash function for random number generation.

ランダムビット生成器(RBG)はランダムビットを生成するために用いられます。これらのビットはそのまま使用することも、乱数(整数)に変換して使用することもできます。決定論的アルゴリズム5を用いる承認済みRBGと、ビット列を整数に変換する方法はSP 800-90Aに記載されています。その他の承認済み乱数生成器はFIPS 186-2 [FIPS 186-2]で規定または参照により承認されましたが、その使用は制限されています(SP 800-131A [SP 800-131A]を参照してください)。ハッシュ関数を使ってRBGを構成できます。RBGが使用するハッシュ関数は、生成するランダムビットに必要な最小セキュリティ強度以上をRBGが提供できるよう選択しなければなりません。乱数生成で承認済みハッシュ関数ごとに提供可能なセキュリティ強度については、SP 800-57第1部を参照してください。

6 References

6 参考文献

[SP 800-38B]

[SP 800-38B]

NIST Special Publication (SP) 800-38B, Recommendation for Block Cipher Modes of Operation: The CMAC Mode for Authentication, May 2005.

NIST特別刊行物(SP)800-38B「ブロック暗号の利用モードに関する推奨事項:認証のためのCMACモード」、2005年5月。

[SP 800-38C]

[SP 800-38C]

NIST Special Publication (SP) 800-38C, Recommendation for Block Cipher Modes of Operation: the CCM Mode for Authentication and Confidentiality, July 2007.

NIST特別刊行物(SP)800-38C「ブロック暗号の利用モードに関する推奨事項:認証と機密性のためのCCMモード」、2007年7月。

[SP 800-38D]

[SP 800-38D]

NIST Special Publication (SP) 800-38D, Recommendation for Block Cipher Modes of Operation: Galois/Counter Mode (GCM) and GMAC, November 2007.

NIST特別刊行物(SP)800-38D「ブロック暗号の利用モードに関する推奨事項:Galois/Counter Mode(GCM)およびGMAC」、2007年11月。

[SP 800-56A]

[SP 800-56A]

NIST Special Publication (SP) 800-56A, Recommendation for Pair-Wise Key Establishment Schemes Using Discrete Logarithm Cryptography, March 2007.

NIST特別刊行物(SP)800-56A「離散対数暗号を用いるペア単位鍵確立方式に関する推奨事項」、2007年3月。

5 Commonly known as deterministic random bit generators or pseudorandom number generators.
5 一般に、決定論的ランダムビット生成器または疑似乱数生成器と呼ばれます。

[SP 800-56B]

[SP 800-56B]

NIST Special Publication (SP) 800-56B, Recommendation for Pair-Wise Key Establishment Using Integer Factorization Cryptography, August 2009.

NIST特別刊行物(SP)800-56B「整数因数分解暗号を用いるペア単位鍵確立に関する推奨事項」、2009年8月。

[SP 800-56C]

[SP 800-56C]

NIST Special Publication (SP) 800-56C, Recommendation for Key Derivation through Extraction-then-Expansion, November 2011.

NIST特別刊行物(SP)800-56C『抽出後拡張による鍵導出の推奨事項』、2011年11月。

[SP 800-57]

[SP 800-57]

NIST Special Publication (SP) 800-57, Part 1, Recommendation for Key Management: General, (Revision 3) July 2012.

NIST特別刊行物(SP)800-57第1部『鍵管理に関する推奨事項:一般事項』改訂第3版、2012年7月。

[SP 800-90A]

[SP 800-90A]

NIST Special Publication (SP) 800-90A, Recommendation for Random Number Generation Using Deterministic Random Bit Generators, January 2012.

NIST特別刊行物(SP)800-90A『決定論的ランダムビット生成器を用いる乱数生成に関する推奨事項』、2012年1月。

[SP 800-106]

[SP 800-106]

NIST Special Publication (SP) 800-106, Randomized Hashing for Digital Signatures, February 2009.

NIST特別刊行物(SP)800-106『デジタル署名のためのランダム化ハッシュ』、2009年2月。

[SP 800-108]

[SP 800-108]

NIST Special Publication (SP) 800-108, Recommendation for Key Derivation Using Pseudorandom Functions, November 2008.

NIST特別刊行物(SP)800-108『疑似ランダム関数を用いた鍵導出に関する推奨事項』、2008年11月。

[SP 800-131A]

[SP 800-131A]

E. Barker and A. Roginsky, “Transitions: Recommendation for Transitioning the Use of Cryptographic Algorithms and Key Lengths”, NIST Special Publication 800-131A, January 2011.

E. Barker、A. Roginsky『移行:暗号アルゴリズムと鍵長の使用の移行に関する推奨事項』、NIST特別刊行物800-131A、2011年1月。

[SP 800-133]

[SP 800-133]

NIST 800-133 Recommendation for Cryptographic Key Generation, (Draft), August 2011.

NIST 800-133『暗号鍵生成に関する推奨事項』(ドラフト)、2011年8月。

[SP 800-135]

[SP 800-135]

NIST Special Publication (SP) 800-135, Recommendation for Existing Application-Specific Key Derivation Functions, Revision 1, December 2011.

NIST特別刊行物(SP)800-135『既存の用途固有鍵導出関数に関する推奨事項』改訂第1版、2011年12月。

[FIPS 180-4]

[FIPS 180-4]

Federal Information Processing Standard 180-4, Secure Hash Standard (SHS), March 2012.

連邦情報処理標準(FIPS)180-4『セキュアハッシュ標準(SHS)』、2012年3月。

[FIPS 186-2]

[FIPS 186-2]

Federal Information Processing Standard 186-2, Digital Signature Standard (DSS), January 2000.

連邦情報処理標準(FIPS)186-2『デジタル署名標準(DSS)』、2000年1月。

[FIPS 186-3]

[FIPS 186-3]

Federal Information Processing Standard 186-3, Digital Signature Standard (DSS), June 2009.

連邦情報処理標準(FIPS)186-3『デジタル署名標準(DSS)』、2009年6月。

[FIPS 198-1]

[FIPS 198-1]

Federal Information Processing Standard 198-1, The Keyed-Hash Message Authentication Code (HMAC), July 2008.

連邦情報処理標準(FIPS)198-1『鍵付きハッシュメッセージ認証コード(HMAC)』、2008年7月。

[SHA1 Attack]

[SHA1 Attack]

Wang X., Yin Y., and Yu H., Finding Collisions in the Full SHA-1, The 25th Annual International Cryptology Conference, Santa Barbara, California, USA, August 2005.

Wang X.、Yin Y.、Yu H.「フルSHA-1における衝突の発見」第25回年次国際暗号学会議、米国カリフォルニア州サンタバーバラ、2005年8月。

[Second Preimage Attack]

[Second Preimage Attack]

Kelsey J. and Schneier B., Second Preimages on n-bit hash functions for Much Less than 2n Work, Lecture Notes in Computer Science, Vol. 3494, Springer, 2005, ISBN-10 3-540-25910-4.

Kelsey J.、Schneier B.「nビットハッシュ関数において2nよりはるかに少ない計算量で第二原像を求める方法」Lecture Notes in Computer Science、第3494巻、Springer、2005年、ISBN-10 3-540-25910-4。

[BCK1]

M. Bellare, R. Canetti, and H. Krawczyk, Keyed Hash Functions for Message Authentication, Proceedings of Crypto'96, LNCS 1109, pp. 1-15. (http://www.research.ibm.com/security/keyed-md5.html)

M. Bellare、R. Canetti、H. Krawczyk『メッセージ認証のための鍵付きハッシュ関数』、Crypto’96予稿集、LNCS 1109、1–15頁。(http://www.research.ibm.com/security/keyed-md5.html)

Appendix A : Actual Second Preimage Resistance Strengths of Approved Hash functions

付録A:承認済みハッシュ関数の実際の第二原像耐性強度

In an application, if the size of the messages is small, then the second preimage resistance strengths of the hash functions are practically the same as their preimage resistance strengths described in Section 4.2. The actual second preimage resistance strength for SHA-1, SHA -224, SHA-256 and SHA-512 is approximately \((L - M)\), where \(L\) is the output block size of the hash function, and the message is \(2^M\) input blocks in length. For example, if a message that is \(2^{33}\) bits in length (i.e., a gigabyte long) is hashed by SHA-256 (whose input block size is \(2^9\) bits), the second preimage resistance strength is \((L - M) = (256 - 24) = 232\) bits (where \(L = 256\), and \(M = \log_2(2^{33}/2^9) = (33 - 9) = 24\)). That is, the amount of work required to find a second preimage is \(2^{232}\).

アプリケーションでメッセージのサイズが小さい場合、ハッシュ関数の第二原像耐性強度は、4.2節で説明した原像耐性強度と実質的に同じです。SHA-1、SHA -224、SHA-256およびSHA-512の実際の第二原像耐性強度は、おおよそ\((L - M)\)です。ここで\(L\)はハッシュ関数の出力ブロックサイズであり、メッセージの長さは\(2^M\)個の入力ブロックです。例えば、長さ\(2^{33}\)ビット(すなわち1ギガバイト)のメッセージをSHA-256(入力ブロックサイズは\(2^9\)ビット)でハッシュする場合、第二原像耐性強度は\((L - M) = (256 - 24) = 232\)ビットとなります(ここで\(L = 256\)、\(M = \log_2(2^{33}/2^9) = (33 - 9) = 24\))。つまり、第二原像を見つけるのに必要な作業量は\(2^{232}\)です。

In an application, if the size of the messages is small, then the second preimage resistance strengths of the hash functions are practically the same as their preimage resistance strengths described in Section 4.2.

アプリケーションで使用するメッセージのサイズが小さい場合、ハッシュ関数の第二原像耐性強度は、4.2節で説明した原像耐性強度と実質的に同じです。

The actual second preimage resistance strength for SHA-1, SHA -224, SHA-256 and SHA-512 is approximately (L – M), where L is the output block size of the hash function, and the message is \(2^{M}\) input blocks in length.

SHA-1、SHA-224、SHA-256およびSHA-512の実際の第二原像耐性強度は、約(L – M)です。ここで、Lはハッシュ関数の出力ブロックサイズであり、メッセージの長さは入力ブロック\(2^{M}\)個分です。

For example, if a message that is \(2^{33}\) bits in length (i.e., a gigabyte long) is hashed by SHA-256 (whose input block size is \(2^{9}\) bits), the second preimage resistance strength is (L – M) = (256 – 24) = 232 bits (where L = 256, and M = \(\log_{2}(2^{33}/2^{9})\) = (33 – 9) = 24). That is, the amount of work required to find a second preimage is \(2^{232}\).

例えば、長さが\(2^{33}\)ビット(すなわち1ギガバイト)のメッセージを、入力ブロックサイズが\(2^{9}\)ビットのSHA-256でハッシュ化すると、第二原像耐性強度は(L – M)=(256 – 24)= 232ビットとなる(ここで、L = 256、M = \(\log_{2}(2^{33}/2^{9})\) =(33 – 9)= 24)。すなわち、第二原像を見つけるために必要な計算量は\(2^{232}\)です。

It is important to note that the amount of work is based on the number of compression function executions (compressing single message blocks), not on the number of hash function executions (hashing messages of more than one block in length).

この計算量は、ハッシュ関数の実行回数(複数ブロック長のメッセージのハッシュ化回数)ではなく、圧縮関数の実行回数(単一のメッセージブロックの圧縮回数)に基づくことに注意が必要です。

The actual second preimage resistance strength of SHA-1, SHA -224, SHA-256 and SHA-512 varies, depending on the maximum size of the messages in the application using the hash function.

SHA-1、SHA-224、SHA-256およびSHA-512の実際の第二原像耐性強度は、そのハッシュ関数を使用するアプリケーションにおけるメッセージの最大サイズに応じて変化します。

The second preimage resistance of SHA-384, SHA-512/224 or SHA-512/256 does not depend on the message length because the attack described in [Second Preimage Attack] would actually require more work than a brute-force approach, which will break the second preimage resistance of SHA-384, SHA-512/224 or SHA-512/256 with work of 384, 224, or 256 bits, respectively.

SHA-384、SHA-512/224またはSHA-512/256の第二原像耐性は、メッセージ長に依存しません。[Second Preimage Attack]で説明されている攻撃は、実際には総当たり法よりも多くの計算量を必要とするためです。総当たり法では、それぞれ384ビット、224ビット、256ビットの計算量で、SHA-384、SHA-512/224またはSHA-512/256の第二原像耐性を破ることができます。

For any truncated message digest of λ bits, the actual second preimage resistance strength of SHA-1, SHA-224, SHA-256, and SHA-512 is the minimum of (L – M) and λ, where λ ≤ 160 for SHA-1, λ ≤ 224 for SHA-224, λ ≤ 256 for SHA-256, and λ ≤ 512 for SHA-512.

λビットに切り詰めた任意のメッセージダイジェストについて、SHA-1、SHA-224、SHA-256およびSHA-512の実際の第二原像耐性強度は、(L – M)とλの小さい方です。ここで、SHA-1ではλ ≤ 160、SHA-224ではλ ≤ 224、SHA-256ではλ ≤ 256、SHA-512ではλ ≤ 512です。

The actual second preimage resistance strengths of SHA-384, SHA-512/224 and SHA-512/256 is λ (where λ ≤ 384 for SHA-384, λ ≤ 224 for SHA-512/224, and λ ≤ 256 for SHA-512/256).

SHA-384、SHA-512/224およびSHA-512/256の実際の第二原像耐性強度はλです(ここで、SHA-384ではλ ≤ 384、SHA-512/224ではλ ≤ 224、SHA-512/256ではλ ≤ 256)。

Appendix B : Document Changes

付録B:文書の変更点

The original version of this document was published in February 2009. The main technical additions to this revision are: 1) Adding and addressing the security properties of SHA-512/224 and SHA-512/256. 2) Expanding the discussion of the security of HMAC values in Section 5.3, 3) Revising Section 5.2, especially sub-section 5.2.3 : Randomized Hashing for Digital Signatures, and 4) Section 5.4: Hash-based Key Derivation Function was rewritten to incorporate the “extraction-then-expansion” key derivation procedure specified in SP 800-56C and to discuss different approved hash-based key derivation functions.

この文書の初版は2009年2月に発行されました。この改訂における主な技術的追加事項は次のとおりです。1)SHA-512/224およびSHA-512/256のセキュリティ特性を追加して説明しました。2)5.3節のHMAC値のセキュリティに関する説明を拡充しました。3)5.2節、特に小節5.2.3「デジタル署名のためのランダム化ハッシュ」を改訂しました。4)5.4節「ハッシュベース鍵導出関数」を書き直し、SP 800-56Cで規定された「抽出後拡張」鍵導出手順を取り入れ、承認済みの各種ハッシュベース鍵導出関数について説明しました。