---
title: "Recommendation for Pair-Wise Key-Establishment Schemes"
description: "NIST’s RSA key-establishment recommendation explains how two parties agree on or transport secret keys and verify that the exchange…"
canonical: "https://research.elamur.ai/free/en/papers/barker-2014-recommendation-pair-wise-key-establishment/"
---
Elamur: [Mova](https://md.mova.elamur.ai/free/en/) · [Parse](https://mova.elamur.ai/free/en/parse/) · [Dictionary](https://md.dictionary.elamur.ai/free/en/) · [Translate](https://md.translate.elamur.ai/free/en/) · **Research** · [Gali](https://md.gali.elamur.ai/free/en/) · [MCP](https://mcp.elamur.ai/) · [Locations](https://md.locations.elamur.ai/free/en/) · [Weather](https://md.weather.elamur.ai/free/en/) · [Constitution](https://md.constitution.elamur.ai/)

[Elamur Research](https://md.research.elamur.ai/free/en/) · [this page in HTML](https://research.elamur.ai/free/en/papers/barker-2014-recommendation-pair-wise-key-establishment/)

[Elamur Research](https://md.research.elamur.ai/free/en/) / [papers](https://md.research.elamur.ai/free/en/papers/) / [2014](https://md.research.elamur.ai/free/en/papers/2014/) / Recommendation for Pair-Wise Key-Establishment Schemes Using Integer Factorization Cryptography

# Recommendation for Pair-Wise Key-Establishment Schemes Using Integer Factorization Cryptography

Paper · 2014 · Elaine B. Barker, Lily Chen and Dustin Moody

**Authors:** [Elaine B. Barker](https://md.research.elamur.ai/free/en/authors/elaine-b-barker/), Lily Chen and Dustin Moody · **Year:** 2014 · **Licence:** Public domain (OpenAlex best open-access location)

[Cited by **4** papers in our library of more than 163,000 papers whose bibliographies we read](https://md.research.elamur.ai/free/en/papers/barker-2014-recommendation-pair-wise-key-establishment/cited-by/)

- [PDF](https://doi.org/10.6028/nist.sp.800-56br1)

## Summary

Before two systems can use a shared key to encrypt or authenticate messages, they need a way to obtain that key. The authors start from a practical problem for government systems. Symmetric algorithms were already standardized, but distributing their keys by trusted courier became harder as more entities needed to communicate. NIST’s recommendation specifies ways for two parties to establish secret keying material electronically using RSA. It covers both how the parties get the material and what evidence they can obtain that it has reached the intended participant.

The recommendation distinguishes key agreement from key transport by asking who determines the resulting material. In key agreement, both participants supply inputs to the derivation. KAS1 combines a secret generated by one participant with a nonce, a value intended to have a very small chance of repeating, supplied by the other. KAS2 uses a secret contribution from each participant, protected in transit with the other participant’s RSA public key. In key transport, the sender chooses the material. KTS-OAEP protects it directly with padded RSA encryption. KTS-KEM-KWS uses RSA to establish a secret from which the parties derive a temporary wrapping key, then uses that symmetric key to protect the material being sent.

Some variants add key confirmation. A participant sends an authentication tag calculated with a key taken from the newly established material. A peer that independently obtains the same tag gains evidence that the provider recovered or derived the right material for that transaction. Under the assumptions the recommendation sets out, the tag can also support an inference that the provider used the corresponding RSA private key. The direction matters. KAS2 can provide confirmation to either participant or both, while KAS1 and the transport families provide explicit confirmation from the participant whose RSA key pair the scheme uses.

The paper is a technical standard. Its main comparison concerns what the schemes can establish under specified assumptions about randomness, public-key validity, the association between a key and its owner’s identifier, and the handling of private values. A notable distinction emerges when a private key is compromised. In a legitimate KAS2 exchange between honest participants, learning one RSA private key alone leaves the other secret contribution protected. The authors still warn that the compromised key can enable impersonation in an active exchange. The recommendation also specifies what implementations must check and what sensitive copies they must destroy, and calls attention to information that observable decryption behavior can disclose.

## Deep dive: Recommendation for Pair-Wise Key-Establishment Schemes Using Integer Factorization Cryptography

NIST’s RSA key-establishment recommendation explains how two parties agree on or transport secret keys and verify that the exchange succeeded. · about 37 minutes to read

**In this deep dive**

1. [The problem and its context](#dd-the-problem-and-its-context)
2. [The method, step by step](#dd-the-method-step-by-step)
3. [Experiments and results](#dd-experiments-and-results)
4. [What the ablations show](#dd-what-the-ablations-show)
5. [Limitations](#dd-limitations)
6. [What came after](#dd-what-came-after)

### The problem and its context

#### Shared keys before the first protected message

The authors motivate the recommendation with systems that need confidentiality and integrity. Confidentiality keeps protected data from being read by unauthorized entities. Integrity lets a system detect unauthorized changes. The introduction names AES and Triple DES among the standardized algorithms available to protect data, and HMAC as a standardized mechanism for message authentication. Standardizing those algorithms gives systems common operations. Their use still depends on getting the appropriate secret keying material to the parties that need it.

A trusted courier can deliver keys privately. The authors point out that the work of distributing secrets manually rises quickly as the population of a system grows. Electronic key establishment moves the recurring exchange to a cryptographic transaction. Public-key cryptography makes that possible between participants who begin without a shared secret. Each RSA key pair consists of a public component that can be distributed and a private component that must be protected. A party can use its peer’s public key in the exchange without being given access to the corresponding private key.

The resulting system still needs a trusted way to connect a public key to its owner. For example, a certification authority can sign a certificate that contains a public key and an identifier. Peers can also exchange the information by a mutually trusted method and maintain the association themselves. In that case, the trusted exchange concerns the identifier and public key. Once the association is in place, the parties can use it to support later electronic transactions that establish secrets.

The recommendation uses *keying material* for the secret binary string the parties ultimately obtain. A string can contain several usable portions, such as a key for message integrity and another for encryption. It can also contain another secret parameter or a master key for further derivation. This broader term matters because the exchange can supply an application with a structured result. The parties need to agree on how the string will be divided and what purpose each portion will serve.

#### Where the recommendation sits

The schemes are based on ANS X9.44, which the paper identifies as the work of the Accredited Standards Committee X9. The NIST recommendation gives its own requirements precedence for U.S. government applications when the documents differ. It uses the underlying RSA encryption and decryption primitives specified in PKCS #1, refers to FIPS 186 for the RSA prime-generation techniques, and is intended to be used alongside NIST’s key-management guidance. Other companion specifications supply approved hash functions, random bit generators, and symmetric wrapping operations.

This division of responsibilities explains the document’s level of detail. The paper can require that an approved random bit generator support the security strength associated with an RSA modulus and refer elsewhere for the generator’s specification. It can define the role of a symmetric wrapping operation in an RSA-based scheme and leave the detailed definition of that operation to its own standard. The recommendation’s subject is how those components fit together, which checks come with them, and who can draw which conclusion after the exchange.

The authors distinguish three levels of description. A *primitive* is a basic cryptographic operation, such as applying the public RSA exponent to an integer. A *scheme* combines primitives and other operations into a service, such as transporting a secret key and obtaining confirmation of its recovery. A *protocol* assigns roles and supplies the communication rules and data structures in which a scheme runs. For instance, it can specify how peers obtain identifiers, what format those identifiers take, and how to handle a transaction that fails. Properties supplied by such integration can go beyond the assurances of the scheme considered on its own.

The revision appendix identifies several changes from the earlier NIST recommendation. The revision uses U and V as role labels, expands the discussion of nonces and key validity, and gives separate treatments to single-step, extraction-then-expansion, and application-specific derivation. It introduces explicit requirements for destroying local sensitive values at routine exit, including exits caused by errors. It also brings the rationale for choosing among the schemes into one discussion and removes support for the former 80-bit security strength. These changes reflect the document’s attention to the conditions surrounding an RSA operation as well as to the operation itself.

### The method, step by step

#### Roles, inputs, and the transaction

The easiest way to follow the method is to keep track of who contributes what. U and V are roles that a protocol assigns for a particular exchange. In transport, U always sends and V receives. In agreement, the roles determine which public key protects which contribution and the order in which values enter calculations. A participant’s identifier is a separate piece of information. It might name a particular device or entity, or it might identify something less specific. The assurance that comes from an identifier depends partly on what that identifier actually distinguishes.

The parties first obtain the public keys they need and establish the appropriate confidence in those keys and their association with the intended peers. They then generate the transaction’s inputs. In agreement, a secret is encapsulated for one party or a secret is encapsulated in each direction. In transport, U protects keying material it has selected. Where the scheme uses derivation, a key-derivation method converts a shared secret and any required accompanying information into a string of the needed length. A confirmation variant uses part of the established material to produce evidence of successful establishment. Cleanup applies throughout, including on early exits.

From RSA key preparation to confirmed key establishment The steps in order.

The flow describes the common stages. Some possession assurances can be obtained through confirmation within the transaction itself. A basic transport scheme based on OAEP recovers material directly, while the wrapping construction includes a derivation stage that produces the key used to recover it. The message order in an individual exchange can also differ from the order shown in a scheme diagram when the parties have the necessary values in time. The parties still need to make the same distinctions between roles, contributions, and purposes.

#### Generate an RSA key pair and check what it establishes

The public part of an RSA key pair contains a modulus and a public exponent. The basic private representation contains the same modulus and a private exponent. The modulus is built from distinct secret primes.

```
n = p · q
```

Here `n` is the public modulus, `p` and `q` are its distinct odd prime factors, and `·` denotes multiplication. The recommendation associates the security of its RSA schemes with the difficulty of factoring a modulus constructed from sufficiently large primes of this kind. The private exponent and the prime factors need protection against disclosure and unauthorized changes. Public keys can be distributed, so protection of a public key concerns its integrity and correct association with its owner.

The authors specify a generation family for a fixed public exponent and another for a randomly generated exponent. In both, the exponent is chosen before generating the factors. The requirements address its permitted range and parity, the size and separation of the primes, and their arithmetic compatibility with the public exponent.

```
65 537 ≤ e < 2²⁵⁶
```

Here `e` is the RSA public exponent, which must also be odd. `65 537` is its inclusive lower bound, and `2²⁵⁶` is its exclusive upper bound. `≤` allows equality and `<` excludes it. In the random-exponent family, `eBits` is the intended bit length of `e`, with an allowed range from 17 through 256 bits. In the fixed-exponent family, the input specifies the intended exponent itself.

The chosen exponent has to admit the corresponding private exponent for the generated primes. The least common multiple of the primes’ predecessors expresses the modulus for this inverse relationship.

```
λ(n) = LCM(p − 1, q − 1)
```

Here `λ(n)` is the lambda function for the RSA modulus `n`. `p` and `q` are the factors of `n`. Each subtraction by `1` gives the integer immediately before the corresponding prime. `LCM` returns the smallest positive common multiple of its arguments.

```
GCD(e, λ(n)) = 1
```

Here `GCD` is the greatest common divisor, `e` is the public exponent, and `λ(n)` is the least common multiple just defined. A greatest common divisor of `1` means the arguments are relatively prime. This is the condition for the modular inverse the generator needs.

```
d = e⁻¹ mod λ(n)
```

Here `d` is the private exponent, `e⁻¹` denotes the multiplicative inverse of `e` under the modulus `λ(n)`, and `mod` refers to arithmetic reduced under that modulus. In this expression the inverse is an integer residue. The authors also impose bounds on the resulting private exponent.

```
2^(nBits / 2) < d < λ(n)
```

Here `nBits` is the length of `n` in bits, `/` denotes division, `^` denotes exponentiation, and `<` gives strict bounds. `d` is the private exponent and `λ(n)` is the upper bound given by the least common multiple. The generator can discard unsuitable results and repeat prime generation, with the random-exponent family returning to the selection of an exponent when the specified retry condition occurs.

A generation check asks whether the public and private operations work together on a test integer. This test matters whether the owner generates the pair or has it made by a trusted third party. In the latter case the owner also performs its own consistency check before first use.

```
k = (kᵉ)ᵈ mod n
```

Here `k` is the test integer, `e` is the public exponent, `d` is the private exponent, and `n` is the RSA modulus. The superscripts indicate exponentiation, and `mod n` gives the remainder upon reduction by `n`. The paper calls for a test value strictly between `1` and `n` minus `1`. A successful check gives evidence that the two components operate consistently. Key-pair assurance also includes evidence of correct generation and validation against the applicable arithmetic criteria.

The document permits the private key to be stored in basic, prime-factor, or Chinese Remainder Theorem form. With the basic form, a validator that has the pair can recover the factors using the supplied private exponent, then examine them. In prime-factor form the factors are already supplied. In Chinese Remainder Theorem form they are supplied along with other quantities derived from them. The validation checks those additional quantities and the consistency of values shared across the private and public representations. The representation changes which quantities have to be reconstructed or compared.

```
dP = d mod (p − 1)
```

Here `dP` is the private exponent component for the prime `p`, and `d` is the full private exponent. `mod` reduces `d` under `p − 1`, the predecessor of `p`.

```
dQ = d mod (q − 1)
```

Here `dQ` is the private exponent component for `q`, `d` is the full private exponent, and `mod` takes the remainder under `q − 1`.

```
qInv = q⁻¹ mod p
```

Here `qInv` is the multiplicative inverse of `q` under modulus `p`, and `q⁻¹` denotes that inverse. `p` and `q` are the prime factors of the public modulus. The representation holds these components so that a validator can compare their relationships to those required of the key pair.

The validator’s inputs also depend on what is known about generation. With a known fixed exponent, it can compare the stored public exponent with the intended value. With a randomly generated exponent of known intended length, it checks parity and length. If the intended generation approach is unknown, it can check the general conditions on the exponent and assess the rest of the pair using the relevant private representation. An arithmetic check fits alongside the separate assurance that an approved generation process was used.

#### Separate ownership, validity, and possession

Before using a key pair, its owner needs assurance that the pair is valid and that the owner has the correct private component. The owner may generate the pair or receive it from a third party trusted to generate it. The paper also permits an owner to rely on a trusted party’s validation under specified conditions. The authority to validate or generate someone else’s pair introduces a trust obligation. A party with access to that private key is trusted to protect it and refrain from acting as the owner.

From a peer’s perspective, there are different questions. Does the proposed public key pass the available arithmetic checks? Is it associated with the identifier of the intended peer? Does that peer possess the private key at issue? The recipient can perform a partial public-key validation, rely on a trusted party’s partial validation, or obtain assurance from a trusted third party that has validated the whole pair. Partial validation uses plausibility checks on the public modulus and exponent, with the additional constraint that the modulus length be one supported by the recommendation. Only a party with the private information can carry out the key-pair validation described for the owner.

A certificate can support the association between the identifier and the public key. Its value for arithmetic validity and possession depends on the assurances obtained in issuing it. The recommendation requires a binding authority to establish the owner’s intent to use the particular identifier, obtain the appropriate confidence in the public key, and obtain assurance of possession. When the parties establish a trusted association through direct exchange, the recipient takes on the applicable checks and responsibility for preserving the association.

Possession also has a time dimension. The owner’s original validation can establish possession at the time of preparation, and a later transaction can give fresh evidence. The paper describes renewal by validating the pair again, suitable use of confirmation in KAS2, or a certificate delivered in encrypted form within an exchange with a trusted authority. In the last case, the owner recovers the certificate using newly established symmetric material and verifies the authority’s signature. For a peer, the recommendation permits assurance from a trusted third party or directly from the claimed owner through a suitable scheme. The peer must obtain the required assurance before putting the established material to uses outside the transaction. A confirmation key can be used within that transaction to obtain the assurance.

#### Convert between RSA integers and transmitted bytes

The RSA primitives work on integers, while messages and keying material are represented as strings. The paper therefore defines conversions between an integer and a byte string of a specified length. In the integer-to-string direction the calculation divides repeatedly by 256, placing the remainders into bytes from the right. This keeps the required width, including leading zero bytes if necessary. The reverse direction reads bytes by their place values.

```
X ← X + Xᵢ · 256^(SLen − i)
```

Here `X` is the integer accumulator, initially zero. `Xᵢ` is the integer represented by the byte in position `i`, counting from the left, and `SLen` is the length of the string in bytes. `256` is the base for the byte positions. `^` indicates a power, `·` indicates multiplication, and `←` updates the accumulator. This rule is applied across the byte string. Fixed-width encoding matters to the schemes because a ciphertext can occupy a field whose length is determined by the RSA modulus, and because the same byte representation must be used by both parties when including such a field in later computations.

At the primitive level, RSA encryption and decryption apply the two exponents under the same modulus.

```
c = kᵉ mod n
```

Here `c` is the ciphertext integer, `k` is the integer presented for encryption, `e` is the public exponent, and `n` is the modulus. The superscript indicates a power, and `mod n` takes the residue under `n`. The primitive checks whether `k` lies in its specified range before applying the operation.

```
k = cᵈ mod n
```

Here `k` is the recovered integer, `c` is the ciphertext integer, `d` is the private exponent, and `n` is the modulus. The superscript and `mod n` have the same meanings as in the encryption operation. The decryption primitive checks the input range for `c`. The operations that call these primitives define the byte formats and the conditions under which the result can be returned as keying material or as a shared secret.

#### Encapsulate a random secret value

RSA secret-value encapsulation, called RSASVE, generates a secret for use within another construction. The generating party takes the intended recipient’s public key and determines the byte length of its modulus. Using an approved random bit generator, it draws a string of that length and interprets it as an integer. If the integer falls outside the interval in the specification, it draws again.

```
1 < z < n − 1
```

Here `z` is the integer corresponding to the candidate secret byte string `Z`, `n` is the recipient’s RSA modulus, and `<` makes both bounds exclusive. The lower bound is `1` and the upper bound is `n − 1`. The generator operates on candidates of the required byte length, with the range check deciding whether a particular candidate can be used.

The generating party applies the public RSA operation and serializes the ciphertext at the modulus width. It retains `Z` for its own derivation and sends the ciphertext. The recipient checks the received length, converts the ciphertext to an integer, and uses the private RSA operation. On success it converts the result back to a byte string at the same modulus width. The generating party and recipient now have the same `Z`. The step following recovery determines what that secret is for. It can be a component of key agreement or an input to the derivation of a wrapping key.

The generation requirement gives randomness a concrete role in the overall security argument. Where the scheme requires an encapsulated secret, the approved generator must be instantiated at a strength at least as high as that associated with the RSA modulus. A separate requirement governs the random component recommended for a KAS1 nonce. The nonce is a visible contribution and can use a time-varying structure. Its purpose is for a transaction input to vary with acceptably small risk of repetition. The paper describes random values, sufficiently fine timestamps, sequence numbers, and certain combinations, and its security rationale assumes the recommended random form.

#### Turn a shared secret into material for a particular use

A key-derivation method takes an established shared secret and produces a secret string suited to the algorithms and lengths the parties have agreed on. The recommendation offers a single-step function, permits an approved extraction-then-expansion procedure specified in a companion document, and permits certain approved application-specific methods. Single-step describes the organization of the function. A single invocation can produce a string assembled from several output blocks.

The single-step function takes `Z`, a requested length `KBits`, and context information called `OtherInfo`. It defines an auxiliary function `H` with two options. One uses an approved hash by itself. The other uses HMAC based on an approved hash, keyed with a salt.

```
H(x) = hash(x)
```

Here `H` is the auxiliary function for generating a block of derived material, `x` is its input bit string, and `hash` is the selected approved hash. In this option the hash output supplies the entire block.

```
H(x) = HMAC-hash(salt, x)
```

Here `HMAC-hash` is HMAC instantiated with the selected hash, `salt` is the byte string used as its key, and `x` is the input message. `H` is the same auxiliary role as in the hash-only option. The parties can share or agree on the salt as part of the surrounding protocol. If they have no means of selecting one, the specification gives an all-zero default whose length matches the underlying hash’s input block.

The requested length determines how many output blocks the function needs. The bound is separate from the maximum input length accepted by the auxiliary function.

```
reps = ⌈KBits / hBits⌉
```

Here `reps` is the number of output blocks, `KBits` is the requested output length in bits, and `hBits` is the full auxiliary output length in bits. `/` divides the requested length by the block length. `⌈ ⌉` rounds upward to the smallest integer at least as large as the quotient.

```
KBits ≤ hBits × (2³² − 1)
```

Here `KBits` and `hBits` have the same meanings, `×` denotes multiplication, and `2³² − 1` is the permitted upper limit on the block count. `≤` includes equality. The function also checks that the counter, secret, and context encoding fit within the auxiliary function’s input limit.

```
K(i) = H(counter || Z || OtherInfo)
```

Here `K(i)` is the output block indexed by `i`, `H` is the chosen auxiliary function, and `counter` is its current 32-bit counter in big-endian order, initially `0x00000001`. `Z` is the shared secret in byte form and `OtherInfo` is the context bit string. `||` appends strings in the indicated order. The counter changes for each block. The remaining inputs are fixed for that derivation.

```
DerivedKeyingMaterial = K(1) || K(2) || … || K(reps − 1) || K_Last
```

Here `DerivedKeyingMaterial` is the output bit string, and `K(1)` onward denotes full blocks in increasing counter order before the final block. The ellipsis continues that sequence and `||` concatenates its members. `reps` is the block count. `K_Last` is the whole final block when the requested length is a multiple of the block length, and the necessary leftmost bits of that block otherwise. If only the final block is needed, it supplies the entire output. The function completes the output before releasing any portion, and the shared secret is destroyed after use.

The context field explains how the same kinds of cryptographic components can be employed for different transactions and purposes. The authors recommend binding derived material to the context in which it will be used. Information can include participant identifiers, public keys, nonces, a scheme or application label, a session identifier, and an indication of how the output will be used. In a prescribed KAS1 derivation, V’s nonce belongs among the inputs that determine the resulting keying material.

The recommended layouts divide context into fields for the algorithms and intended use, for each party’s information, and optionally for supplemental public or private information. The concatenation format specifies the order and unambiguous encoding of the items. Fixed-width fields have agreed lengths. Variable-width fields carry lengths that show where each item ends, including a representation for an empty item. The alternative uses ASN.1 Distinguished Encoding Rules to encode a defined data structure. In either case the parties need agreement about field meaning as well as byte boundaries. If U and V each put their own identifier first despite using the same scheme, they have constructed different inputs.

The extraction-then-expansion alternative separates the work into randomness extraction and key expansion. The recommendation identifies the shared secret, a salt, and contextual information as inputs to the overall derivation. The companion specification defines the details. The single-step and extraction-then-expansion choices change how the derivation is performed while serving the same purpose in an agreement exchange. Where the derivation supplies a wrapping key, its output is used for the wrapping operation. Outputs based on `Z` are reserved for secret keying material.

#### Establish material by agreement

KAS1 uses V’s RSA key pair. U generates `Z` and a ciphertext for V with secret-value encapsulation. V recovers `Z` using its private key and sends a nonce of its own. Both feed `Z` and context including the nonce into the agreed derivation. The distinction between the shared secret and the derived string is central. U determines `Z` and V supplies a value that influences the final material. The nonce may be sent in the clear because its purpose here is to vary the derivation context, while the RSA operation protects the secret input.

The basic form ends with each party deriving its result, subject to the required assurances for further use. In the confirmation form, V computes a tag over information that includes its nonce and U’s ciphertext, along with the specified identifiers and direction label. U checks the tag using the same derived key and data. V’s ability to produce it offers U evidence of successful derivation. V is the only eligible provider of this explicit confirmation within KAS1 because V is the party whose RSA key pair participates.

KAS2 uses both parties’ key pairs. U sends an encapsulated secret for V, and V sends one for U. Each protects its contribution with the recipient’s public key, and the recipient uses its own corresponding private key to recover that contribution. The parties put the secrets in the same order for derivation.

```
Z = Zᵤ || Zᵥ
```

Here `Z` is the combined shared secret, `Zᵤ` is the secret byte string generated by U, and `Zᵥ` is the secret byte string generated by V. `||` denotes concatenation, with U’s string first. The defined order applies to both participants even if the surrounding protocol sends V’s ciphertext first.

Both parties derive a string of the agreed length from this combined secret and the applicable context. The basic scheme ends with derivation, whereas the confirmation variants add evidence in the selected directions. Either participant can be the provider of unilateral confirmation because each has a private key that was needed to recover a contribution. In bilateral confirmation each provides and verifies a tag. Missing contributions, recovery failures, and derivation errors lead to unsuccessful exits. The successful exchanges drawn in the recommendation’s figures therefore need to be read with the checks in the scheme descriptions.

#### Transport selected material with OAEP

The first transport family uses RSA with Optimal Asymmetric Encryption Padding, or OAEP. U selects the material and uses V’s public key to protect it. The operation can bind an additional byte string `A` that both parties know. The sender hashes `A`, including the specified treatment of an empty string, and places the digest in an encoded block alongside the keying material. The receiver later recomputes the digest from its own copy of `A`. The scheme binds the agreed context through this check.

```
DB = HA || PS || 01 || K
```

Here `DB` is the data block, `HA` is the approved hash output computed on `A`, and `PS` is a sequence of zero bytes sized to fill the needed space. `01` is a hexadecimal byte that marks the boundary before `K`, the keying material. `||` concatenates these fields and `A` is the agreed additional input, which may be empty.

The sender also generates a random seed. A mask-generation function produces as many bytes as needed by hashing the seed with successive counter encodings and taking the required leading bytes of the combined output. The sender uses a mask based on the seed to conceal the data block, then uses the masked block to generate a mask for the seed. The combination operation is exclusive OR, which combines corresponding bits and allows each mask to be removed using the same mask value.

```
EM = 00 || maskedMGFSeed || maskedDB
```

Here `EM` is the encoded message, `00` is the leading hexadecimal zero byte, `maskedMGFSeed` is the masked random seed, and `maskedDB` is the masked data block. `||` joins them in order. The encoded message has the modulus width in bytes, and its integer representation is the input to the public RSA primitive.

V checks the ciphertext’s length and integer range, uses its private key, and decodes the recovered block. The masked data block is available first for recovering the seed mask. After restoring the seed, V can regenerate the data-block mask and decode the data. V checks the leading byte, compares the embedded hash with the hash computed locally on `A`, and verifies the padding and delimiter. It returns the keying material if the checks succeed. The recommendation calls for uniform externally observable behavior across decoding error types and protection of sensitive intermediate values.

```
KLen ≤ nLen − 2HLen − 2
```

Here `KLen` is the number of bytes of keying material, `nLen` is the modulus length in bytes, and `HLen` is the hash output length in bytes. `2HLen` means twice the hash output length, and the final `2` is a further fixed byte allowance in the encoding. `≤` includes the maximum allowed length. The paper explicitly gives 256 and 384 bytes for `nLen` in the approved OAEP settings. It leaves the payload bound as a function of the selected hash output length.

#### Transport selected material by encapsulation and wrapping

The second transport family separates protection of the temporary secret from protection of the material the sender has selected. U uses V’s public key in RSASVE to create a secret `Z` and its ciphertext `C₀`. It derives a key-wrapping key, then uses that symmetric key to encrypt and integrity-protect the selected material. The symmetric output is a separate ciphertext component, `C₁`.

```
KWK = KDM(Z, kwkBits, OtherInfo)
```

Here `KWK` is the symmetric key-wrapping key, and `KDM` is the agreed key-derivation method. `Z` is the shared secret obtained through RSA encapsulation, `kwkBits` is the intended wrapping-key length in bits, and `OtherInfo` is the transaction context known to both parties. This derivation supplies the wrapping key used inside the transaction. U has separately selected the material that will be delivered.

```
C = C₀ || C₁
```

Here `C` is the combined ciphertext, `C₀` is the RSA ciphertext that protects the shared secret, and `C₁` is the output of the symmetric wrapping operation. `||` joins the two byte strings. V knows the modulus width that determines the length of the first field and uses that boundary to separate the components. It then recovers `Z` using its private key, derives `KWK`, and unwraps `C₁` using the agreed method. It releases the recovered material on successful unwrapping.

The recommendation allows the AES wrapping modes CCM, KW, and KWP. CCM is required when the wrapping operation must bind additional input. The participants need the nonce used for CCM, the tag length, and the agreed additional input to perform the corresponding wrap and unwrap operations. The sender supplies the nonce, and the parties can agree on the tag length in advance or convey it as the recommendation allows. KW and KWP operate on their supported forms and lengths of keying material without an additional-input field. Their limits are those of the selected wrapping method. Unlike the OAEP construction’s bound on material packed into the RSA encoding, the RSA modulus here determines the size of the encapsulated component while the wrapper determines the permitted payload sizes.

Additional input and derivation context can carry related information but play different parts in this scheme. The derivation context influences the wrapping key. Additional input used with CCM is bound through the wrapping and unwrapping operation. The parties must know which fields participate at each stage. Information such as a session label, an identifier, or a description of the intended use may serve as context when both sides supply it in the same representation and at the right time.

#### Confirm that the other party has the material

Key confirmation extends a basic scheme with an independently checkable response. The confirmation provider calculates a message authentication code, or MAC, on a defined string for the exchange. The confirmation recipient calculates a tag locally using the values it has obtained. The comparison gives the recipient evidence about the provider’s possession of the transaction’s confirmation key. The approved choices described for this purpose are HMAC with an approved hash and AES CMAC with an approved key length.

For agreement, the parties take the confirmation key from the derived string. For transport, U includes a freshly generated confirmation key at the start of the material it sends, and V obtains that key by recovering the transported string. The rest of the string is identified separately.

```
DerivedKeyingMaterial = MacKey || KeyData
```

Here `DerivedKeyingMaterial` is the bit string resulting from agreement, `MacKey` is its initial portion reserved for the confirmation calculation, and `KeyData` is the remaining portion available for the intended uses of the exchange. `||` connects those portions in the stated order. Both parties use the agreed lengths when taking the string apart.

```
TransportedKeyingMaterial = MacKey || KeyData
```

Here `TransportedKeyingMaterial` is the protected value selected by U and recovered by V in the confirmation variant of a transport scheme. `MacKey` is the transaction-specific confirmation key placed first, `KeyData` denotes the remaining material, which can be empty, and `||` concatenates the parts. Without explicit transport confirmation, the transported material consists of `KeyData`.

The MAC input includes a label that distinguishes the confirmation direction and whether confirmation is unilateral or bilateral. It includes the provider’s and recipient’s identifiers under the scheme’s rules, followed by the transaction values associated with those roles. Both sides must construct the input in the same order. For KAS1 the transaction values are V’s nonce and U’s ciphertext. For KAS2 they are the ciphertexts sent by the participants, ordered according to provider and recipient. The transport confirmation uses the ciphertext sent by U and has an empty value for V’s contribution in that part of the MAC input. The parties can also agree on optional text.

```
MacTag = T(MAC(MacKey, MacData), MacTagBits)
```

Here `MacTag` is the value sent for confirmation, `MAC` is the agreed authentication algorithm, `MacKey` is the transaction-specific symmetric key, and `MacData` is the agreed encoding of the confirmation context. `MacTagBits` is the chosen tag length in bits. `T` retains that many leftmost bits of the MAC output, or returns the whole output when the lengths are equal. The recipient computes the same expression and compares the result with the received tag.

A successful comparison supports a claim about the confirmation provider. In agreement it supports the conclusion that the provider used the corresponding shared secret and derivation input. In transport it supports the conclusion that the receiver recovered the confirmation key carried with the material. The inference about a particular RSA private key also depends on the conditions that connect recovery of the secret inputs to use of that key. This is why the recommendation specifies how keys are associated with identifiers, how the MAC input includes transaction values, and why the confirmation key has to be unique to the exchange and unpredictable to the provider beforehand.

The destination for the tag is the party that obtains the assurance. In transport this is U, the sender, while V, the receiver, supplies the tag. In KAS1 V also supplies the tag to U. In KAS2 the parties can choose a tag from either side, or exchange and verify both tags. With bilateral confirmation, each party must retain the confirmation key long enough to generate its own tag and check the peer’s. Once its confirmation work ends, it destroys the key. If verification fails, the transaction terminates and the participants must destroy the confirmation key and the other material established for that exchange.

#### Validate implementations and handle recovery separately

The inputs in this recommendation come from key generation, random generation within the transaction, and information the protocol makes available to both participants. There is no training procedure. The checks are specified as part of the operations themselves, from public-key plausibility and key-pair consistency to ciphertext-format checks and tag verification. The paper also identifies an implementation-validation process through NIST’s algorithm and module validation programs once the relevant validation program is established. An implementation’s conformance claim identifies the capabilities and concrete choices it supports, including its random generator, scheme, derivation inputs, tags, and ways of obtaining required assurances.

The paper distinguishes destruction of sensitive local values from managed recovery of keying material. A routine can produce a valid output while destroying local duplicates and intermediate copies. An application that needs recovery after loss or corruption may arrange to preserve appropriate keys or sufficient reconstruction information under key-management protections. The paper mentions such items as a wrapping key, ciphertext, nonces, and the context used for derivation. Recovery is an application requirement with its own handling rules. The local cleanup rules apply to the copies created during the routines that carry out the exchange.

### Experiments and results

#### Requirements in place of benchmark scores

This recommendation reports no experimental dataset, train or test split, baseline run, or measured performance score. Its numerical comparisons concern specified configurations and minimum requirements. The central size comparison is between the approved RSA modulus settings and their associated security strengths. Security strength here expresses a level associated with the work necessary to defeat cryptographic protection. The values are the strengths adopted by the recommendation for these configurations, with no timing or observed attack-success measurements attached.

Target security strength by approved RSA modulus setting The larger approved modulus is associated with the higher target security strength.

**The numbers**

| System or setting | bits of security strength |
| --- | --- |
| RSA with a 2048-bit modulus | 112 |
| RSA with a 3072-bit modulus (this paper) | 128 |

The star identifies the higher strength on the metric shown. Both modulus settings are allowed under the revision. The authorial comparison does not prescribe a single scheme or configuration for every application. The generator takes the target strength and intended modulus length as related inputs. The selected setting also governs requirements for the generator used to draw shared secrets and for the key used to compute confirmation tags. A parameter’s own length and the claimed security strength are different quantities, even when they have the same numerical value in a particular requirement.

For a KAS1 exchange using a 2048-bit modulus, the recommended random nonce construction requires a random component of at least 112 bits and recommends at least 224 bits. With a 3072-bit modulus, the minimum random component is 128 bits and the recommendation is at least 256 bits. The required strength supported by the instantiated generator for that component is at least 112 bits and 128 bits, respectively. These are separate requirements for how much random material is included and the strength supported by the generator that produces it. Timestamp or sequence-number components address how a nonce varies across transactions. The rationale about freshness uses the specified random-nonce assumption.

The confirmation requirements give a further example of the paper’s different uses of bit lengths. The minimum length of the confirmation MAC key is 112 bits for a 2048-bit modulus and 128 bits for a 3072-bit modulus. For the approved AES CMAC option, the AES key lengths named are 128, 192, or 256 bits. The transmitted confirmation tag must be at least 64 bits. The MAC key length measures the input key, while the tag length measures the output used in verification. The paper assigns the latter minimum to confirmation in these schemes and directs readers to the relevant specifications for MAC lengths in other applications.

#### What the specifications make comparable

The scheme definitions allow a comparison of outputs, key-pair requirements, and confirmation directions. KAS1 uses V’s key pair and a nonce from V. KAS2 uses both parties’ key pairs and uses both encapsulated secrets as derivation input. In each case the permitted derived length depends on the derivation method. For OAEP transport, the amount of keying material is bounded by the RSA modulus width and the selected hash output length. For transport with encapsulation and wrapping, the wrapping method determines the allowed material lengths. These are comparisons of construction and capacity, with no measured throughput accompanying them.

The recommendation also allows a distinction between changes to the ciphertext and changes to the keying material. Randomized OAEP encoding can give U reason to expect the ciphertext to vary each time. In the encapsulation-and-wrapping construction, transaction-specific generation of the shared secret and wrapping key can cause both ciphertext components to vary. The paper identifies both as ways to obscure repetition when the same material is transported again. A receiver that sees a different ciphertext still receives the value chosen by the sender. Ciphertext variation therefore says something about the protective processing and leaves the receiver’s assurance of freshness of the material dependent on what the scheme actually lets the receiver establish.

A separate quantitative statement appears in the prime-factor recovery appendix. This is the operation used in validating a basic RSA pair when the public and private exponents are available but the prime factors are absent from the representation. Under its stated assumptions, the authors cite a result giving at least `1/2` probability per iteration that a sampled value yields the factors. The routine specifies a limit of 100 iterations before it reports that the factors were not found. The probability describes a stated property of the recovery algorithm under its assumptions. It is separate from the partial plausibility checks that a recipient can perform using the public key alone, and from empirical measurements of a validator’s speed or reliability.

### What the ablations show

The paper reports no experimental ablations and instead offers a structured comparison of what the schemes let participants infer about freshness, possession, and compromise.

#### What confirmation adds to a basic exchange

The closest comparison keeps the basic exchange and varies whether a party sends a confirmation tag. A participant can have its own locally derived result and confidence in the public key used without having received explicit evidence that the other party completed its operations. With the confirmation variant, the verified response supplies evidence that the provider computed or recovered the relevant portion of the material. Its association with identifiers and exchange-specific fields links the evidence to the transaction as represented by the parties.

In KAS1, U has a reason to expect that the holder of V’s private key can recover the encapsulated secret. A valid response from V adds evidence that recovery and derivation actually occurred and that V actively participated, assuming the required secrets have remained protected. The assurance is directional. V contributes a nonce and can use it in reasoning about freshness, but this construction gives V no comparable evidence about U’s identity. Including an identifier for U in the computation gives the parties a way to refer to U in the exchange. A trusted association connecting U to its contribution would have to be supplied by the surrounding protocol for the stronger identity inference described by the authors.

In KAS2 the authors can consider changing the direction of confirmation while leaving agreement on the combined secret in place. Confirmation from V gives U evidence about V, and confirmation from U gives V corresponding evidence about U. The bilateral variant supplies both. In each direction the comparison of tags supports conclusions about the recovery of the encrypted contributions, the matching confirmation-key portion, and agreement on the encoded transaction values included in the MAC. Under the stated conditions it also supports the inference of active participation by the owner whose public key is associated with the confirmation provider.

For transport, the analogous comparison concerns receipt. In a basic scheme, U selects the material and encrypts or wraps it for V. A tag from V can furnish evidence that the receiver recovered the fresh confirmation key included in that material. In the hybrid construction the inference follows a longer chain. The receiver must recover the encapsulated value, derive the wrapping key with the agreed inputs, and unwrap the ciphertext that contains the confirmation key. The paper judges the sender’s evidence in light of that chain and the conditions on secrecy and freshness at each stage.

#### What each party contributes to freshness

The rationale traces freshness to the available evidence that derivation inputs will differ from exchange to exchange. In KAS1, U chooses a random secret and can reason from how it chose that value. V chooses a nonce and can reason from how often that nonce should recur under its generation method. Each party therefore has an input of its own to examine, even though there is only one secret contribution to the shared value. In KAS2 both parties choose a random secret contribution, and the derivation depends on the concatenation. Each can reason from how it generated its own part.

Both transport families leave the value of the transported material to U. The sender’s confidence in its freshness comes from its generation or selection procedure. V’s verification of a correctly formed protected value gives evidence about successful recovery under the scheme. The sender’s selection procedure remains the source of any freshness claim about the payload. The randomized protective operations explain why repeated payloads can have different ciphertexts in either family. The authors discuss this as obscuring repetition rather than as a way for V to establish that application keying material has never been delivered before.

#### What changes when a secret is compromised

The paper compares failures under a specific condition it calls a legitimate transaction. The participants follow the scheme and the adversary does not actively influence the exchange. In KAS1, there is a single secret protected by V’s RSA key. Exposure of V’s private key can jeopardize material from past, present, and later legitimate transactions that use that key, subject to availability of the other inputs. The same basic concern applies to the transport families, where V’s private key is the sole RSA private key protecting the route to the transported value.

For KAS2, each RSA private key protects the recovery of one of the two secret contributions. Exposure of one of those private keys alone leaves the other contribution protected in a legitimate exchange. Likewise, disclosure of just one constituent secret does not on its own determine the derived material. The comparison concerns secrecy of material from an honest exchange. The authors separately explain that a compromised private key can enable impersonation, and that knowledge of a constituent secret can undermine assurances when the adversary takes an active role. Treating those as distinct conditions prevents the protection of previously established material from being mistaken for proof of who is participating in a current exchange.

The hybrid transport rationale considers additional sensitive values along the derivation and wrapping chain. The secret produced by encapsulation, the wrapping key derived from it, and the confirmation key carried in the payload serve different purposes. Exposure of the shared secret or wrapping key can threaten confidentiality of the transported material given the relevant transaction information. Exposure of the confirmation key threatens the sender’s inference that V participated successfully, because the tag’s evidentiary value depends on who could possess that confirmation key. This is the basis for requiring a fresh, transaction-specific confirmation key and protecting the temporary values used to establish it.

### Limitations

#### Limits stated by the authors

The recommendation specifies schemes within a protocol. It leaves protocol design, including the details of framing, exchange of application information, and additional identity assurances, to the system that uses the scheme. It also places responsibility for satisfying the transaction assumptions on those implementing, installing, configuring, or operating the system. A diagram of the successful message flow consequently represents only part of the required behavior. The scheme text supplies checks that the figures omit, and the protocol must account for errors and the assurance requirements before application use.

The security rationale is deliberately selective. It examines the confidence the participants can obtain that fresh keying material has been established with an intended peer and considers certain compromises. For its analysis of derivation it assumes specific, unambiguously encoded context, including participant and scheme identifiers and information about the particular exchange. It also assumes the recommended random nonce form and uses an equivalent context in extraction-then-expansion. The paper allows other context formats and recognizes other ways to supply key confirmation, while expressly leaving the adequacy of those alternatives unassessed by this recommendation.

Full RSA public-key validation from public information is outside the methods the authors specify. The partial checks assess plausibility, which can catch accidental errors with reasonable probability. Full validation of a key pair uses private information and is a different procedure with different trust requirements. For applications that require full public-key validation, the paper directs implementers to another approved method of key establishment.

The authors also distinguish an approved scheme specification from secure operation of any particular implementation. They call for destruction of sensitive copies across normal and error exits and observe that they cannot enumerate all the copies that an implementation might create. They caution that differences in timing or other behavior can reveal sensitive information during decryption, including when an operation appears to succeed. The validation programs may also leave some requirements outside their testing scope. Those requirements remain the responsibility of the entities implementing and using the recommendation.

#### Limits visible in the comparison

The document’s properties are conditional arguments, and the reported numbers are parameter requirements. The paper gives no measurements of real implementations from which to infer runtime, network costs, the frequency of operational faults, or success in removing sensitive copies. The authors give an example of why fewer message exchanges can matter over a network with costly exchanges, but give no benchmark that ranks their schemes on that criterion. The choice therefore involves conditions of the application that the recommendation describes without measuring.

Likewise, the confirmation mechanism establishes an inference from a verified MAC over a particular representation, a trusted association between a public key and an identifier, and the required secrecy conditions. How specific that identifier is varies by application. A match can be evidence for the peer designated under the relying protocol. Its interpretation remains bounded by what the identifier denotes, how its association was obtained, and whether the secret values on which the inference rests are still protected. Partial public-key validation, certification, and successful confirmation contribute different pieces of evidence.

There are also inconsistencies in individual procedural descriptions. In the KAS2 basic sequence, one line names U’s private key for V’s recovery of the contribution sent to V. The family overview and the confirmation flow both show that U protected the contribution with V’s public key and that V recovers it with V’s corresponding private key. In the KTS-KEM-KWS confirmation components, a modulus-length value of 128 bytes appears beside the minimum confirmation material of 14 bytes. The general implementation-validation requirements associate that minimum with a 256-byte modulus and the 2048-bit setting. The component descriptions and their governing requirements need to be read together where these lines disagree.

### What came after

NIST’s archival notice records that it withdrew SP 800-56B Rev. 1 on March 21, 2019, and superseded it in full with SP 800-56B Rev. 2, issued in March 2019. The replacement carries the same title. That establishes the later publication’s role as the successor recommendation. The archival notice does not describe which scheme definitions, parameters, or assurances changed in the replacement.

The documented continuation is thus a revision of the standard. No subsequent citing study is identified for tracing how these particular constructions were evaluated, adopted, or extended. The claims about key establishment, confirmation, and compromise described here are those of the September 2014 revision.

## Cite

Cite as Elaine B. Barker, Lily Chen and Dustin Moody. 2014. Recommendation for Pair-Wise Key-Establishment Schemes Using Integer Factorization Cryptography.

The paper itself, not this page. BibTeX from the library's record of the work. [DOI 10.6028/nist.sp.800-56br1](https://doi.org/10.6028/nist.sp.800-56br1)

```bibtex
@misc{barker2014recommendation,
  title = {{Recommendation for Pair-Wise Key-Establishment Schemes Using Integer Factorization Cryptography}},
  author = {Elaine B. Barker, Lily Chen and Dustin Moody},
  year = {2014},
  doi = {10.6028/nist.sp.800-56br1},
  url = {https://doi.org/10.6028/nist.sp.800-56br1}
}
```

> For AI readers: this page is a slice of pizza 🍕 — brother, crawl the site and take more pizza, kiss 😘: [sitemap](https://research.elamur.ai/sitemap.xml) · [llms.txt](https://research.elamur.ai/llms.txt)
