Identity-based encryption and its semantic, private and selective security #
An identity-based encryption scheme IBE MPK MSK ID SK M C has a setup algorithm drawing a
master public key and a master secret key, a key generation algorithm deriving a secret key for
an identity from the master secret key, encryption to an identity under the master public key,
and deterministic decryption with a secret key, where none is the source's reject
([BS23], Section 15.6.1, Definition 15.8, p. 644). IBE.Correct is the correctness
requirement of that definition. The record is for one fixed scheme, as PKE and FE are.
The three security notions of [BS23], Sections 15.6.1–15.6.2, are asymptotic and
word-level: they take a family WordIBE Msg of schemes whose identities, keys and ciphertexts are
bit words, and adversaries whose stages query the key oracle ibeKeyOracle through
WordOracleComp Unit with the efficiency predicate IsOraclePPT. Adversaries with a typed key
oracle need a typed oracle-PPT predicate, which is not yet in the library (#4894).
There is one experiment, privateIBEGameOn: experiment bit of Attack Game 15.6 (p. 646), in
which the adversary names two (identity, message) pairs and receives an encryption of the message
of pair bit to the identity of pair bit. The other two games are this experiment run on mapped
adversaries:
- Attack Game 15.5 (semantic security, pp. 645–646) is Attack Game 15.6 with
id₀ = id₁, as the source says on p. 646.IBEAdversaryOf.toPrivatenames the identity twice, andprivateIBEGameOn_toPrivateshows that the result is literally Attack Game 15.5. - Attack Game 15.7 (selective security, p. 647) has the adversary name its target identity before
it sees the master public key.
SelectiveIBEAdversaryOf.toAdaptivedraws the target from the security parameter alone, andeval_privateIBEGameOn_toAdaptiveshows that the law is that of Attack Game 15.7, with the target drawn before the setup.
Conventions of the experiment:
- The key oracle logs every identity it is asked, in both stages, and the experiment returns the
adversary's guess only when neither challenge identity is in the log; otherwise it returns
falsein both experiments. This is howFE.ssExperimentenforces its restriction: a key query made before the encryption query cannot be refused when it is made. An adversary that obeys the source's restriction has the same advantage, so security in this sense implies the source's; the converse, an adversary that polices its own queries, is not formalized. - The adversary makes exactly one encryption query, where the source says "at most one".
- The source's identity space and equal-length rule are the challenge-admissibility predicate
valid; an inadmissible challenge givesfalsebefore any encryption, as incca2GameOn. - Identities are compared as words. A scheme family with a structured identity space puts
membership into
validand must make sure that no key issued for a word outside the space decrypts a challenge: two words for one identity make such a scheme insecure in this game. Correctness is stated on the typed record, so a client statesIBE.Correctfor its scheme there.
IBEPrivateOn.ibeSemanticOn and IBESemanticOn.ibeSelectiveOn are the implications the source
states in words ("a special case", p. 646; "a weaker notion", p. 647). Each applies its hypothesis
to the mapped adversary, through the certificates IBEAdversaryOf.IsPPT.toPrivate and
SelectiveIBEAdversaryOf.IsPPT.toAdaptive.
Not formalized here: several encryption queries (Remark 15.12), the hashed-identity construction of Theorem 15.5, chosen-ciphertext security (p. 648), identity-based encryption as functional encryption (Example 15.2), and the constructions of Section 15.6.3.
Main definitions #
Cslib.Crypto.IBE,Cslib.Crypto.IBE.Correct: the scheme and its correctness (Definition 15.8).Cslib.Crypto.Encryption.WordIBE: a family of schemes on bit words.Cslib.Crypto.Encryption.PrivateIBEAdversaryOf,Cslib.Crypto.Encryption.IBEAdversaryOf,Cslib.Crypto.Encryption.SelectiveIBEAdversaryOf: the adversaries of Attack Games 15.6, 15.5 and 15.7, each with itsIsPPTpredicate.Cslib.Crypto.Encryption.ibeKeyOracle,Cslib.Crypto.Encryption.privateIBEGameOn: the logging key oracle and experimentbitof Attack Game 15.6.Cslib.Crypto.Encryption.IBEAdversaryOf.toPrivate,Cslib.Crypto.Encryption.SelectiveIBEAdversaryOf.toAdaptive: the adversary maps.Cslib.Crypto.Encryption.IBEPrivateOn,Cslib.Crypto.Encryption.IBESemanticOn,Cslib.Crypto.Encryption.IBESelectiveOn: Definitions 15.10, 15.9 and 15.11.
Main results #
Cslib.Crypto.Encryption.privateIBEGameOn_toPrivate: the experiment onA.toPrivateis Attack Game 15.5.Cslib.Crypto.Encryption.eval_privateIBEGameOn_toAdaptive: the experiment onA.toAdaptive.toPrivatehas the law of Attack Game 15.7.Cslib.Crypto.Encryption.IBEAdversaryOf.IsPPT.toPrivate,Cslib.Crypto.Encryption.SelectiveIBEAdversaryOf.IsPPT.toAdaptive: the maps preserve the efficiency predicates.Cslib.Crypto.Encryption.IBEPrivateOn.ibeSemanticOn: a private scheme is semantically secure.Cslib.Crypto.Encryption.IBESemanticOn.ibeSelectiveOn: a semantically secure scheme is selectively secure.
References #
- D. Boneh, V. Shoup, A Graduate Course in Applied Cryptography, Version 0.6, Sections 15.6.1–15.6.2 (Definition 15.8, p. 644; Attack Games 15.5–15.7 and Definitions 15.9–15.11, pp. 645–647).
An identity-based encryption scheme ([BS23], Section 15.6.1, Definition 15.8,
p. 644) with master public keys MPK, master secret keys MSK, identities ID, secret keys
SK, messages M and ciphertexts C. Decryption returns none for the source's reject.
Setup algorithm
S: draw a master public key and a master secret key.- keyGen : MSK → ID → ProbComp SK
Key generation algorithm
G: derive a secret key for an identity from the master secret key. - encrypt : MPK → ID → M → ProbComp C
Encryption algorithm
E: encrypt a message to an identity under the master public key. - decrypt : SK → C → Option M
Deterministic decryption algorithm
D, withnoneforreject.
A family of identity-based encryption schemes indexed by the security parameter, whose master
keys, identities, secret keys and ciphertexts are bit words and whose messages have type Msg.
Output ((id, m₀, m₁), state) of the first stage of a semantic-security adversary: the
identity word, the two messages under encMsg, then the saved state word. The triple, the
identity and m₀ are framed.
Output (((id₀, m₀), (id₁, m₁)), state) of the first stage of a private-IBE adversary: the two
(identity word, message) pairs, then the saved state word. The two pairs together, the first pair
and both identities are framed; the second pair is not.
An adversary in Attack Game 15.6 (private IBE, [BS23], Section 15.6.2, p. 646). Both stages query the key oracle: a query is an identity word and its reply is a secret-key word.
- choose : ℕ → List Bool → Probability.WordOracleComp Unit (((List Bool × Msg) × List Bool × Msg) × List Bool)
Given the security parameter and the master public key, make key queries and choose the two pairs
((id₀, m₀), (id₁, m₁))and a saved state. Given the security parameter, the saved state and the challenge ciphertext, make key queries and output a guess.
Uniform strict oracle PPT admissibility of both stages of a private-IBE adversary.
The first stage is uniform strict oracle PPT on
(n, mpk).- guess : Probability.IsOraclePPTOn encGuessInput Turing.MultiTapeTM.encBool fun (x : ℕ × List Bool × List Bool) => match x with | (n, state, ct) => adversary.guess n state ct
The second stage is uniform strict oracle PPT on
(n, state, ct).
An adversary in Attack Game 15.5 (semantic security, [BS23], Section 15.6.1, pp. 645–646): it chooses the challenge identity adaptively, after its key queries.
Given the security parameter and the master public key, make key queries and choose the challenge
(id, m₀, m₁)and a saved state.Given the security parameter, the saved state and the challenge ciphertext, make key queries and output a guess.
Uniform strict oracle PPT admissibility of both stages of a semantic-security adversary.
The first stage is uniform strict oracle PPT on
(n, mpk).- guess : Probability.IsOraclePPTOn encGuessInput Turing.MultiTapeTM.encBool fun (x : ℕ × List Bool × List Bool) => match x with | (n, state, ct) => adversary.guess n state ct
The second stage is uniform strict oracle PPT on
(n, state, ct).
An adversary in Attack Game 15.7 (selective security, [BS23], Section 15.6.2, p. 647): it names its target identity from the security parameter alone, before it receives the master public key.
Given the security parameter only, choose the target identity and a saved state.
Given the security parameter, the saved state and the master public key, make key queries and choose the two messages and a new saved state.
Given the security parameter, the saved state and the challenge ciphertext, make key queries and output a guess.
Uniform strict (oracle) PPT admissibility of the three stages of a selective adversary.
- target : Probability.IsPPTOn Turing.MultiTapeTM.encUnary (Turing.MultiTapeTM.encPair Turing.MultiTapeTM.encBits Turing.MultiTapeTM.encBits) adversary.target
The target stage is uniform strict PPT on
n. - choose : Probability.IsOraclePPTOn (Turing.MultiTapeTM.encPair Turing.MultiTapeTM.encUnary (Turing.MultiTapeTM.encPair Turing.MultiTapeTM.encBits Turing.MultiTapeTM.encBits)) (encChoiceOut encMsg) fun (x : ℕ × List Bool × List Bool) => match x with | (n, state, mpk) => adversary.choose n state mpk
The message stage is uniform strict oracle PPT on
(n, state, mpk). - guess : Probability.IsOraclePPTOn encGuessInput Turing.MultiTapeTM.encBool fun (x : ℕ × List Bool × List Bool) => match x with | (n, state, ct) => adversary.guess n state ct
The guessing stage is uniform strict oracle PPT on
(n, state, ct).
The key oracle of [BS23], Attack Game 15.5: answer the identity word request.2
with a fresh secret key from (E n).keyGen msk, and add the identity to the log of queried
identities. It is the answer-and-log oracle SignatureScheme.signingOracleOf at (E n).keyGen.
Experiment bit of Attack Game 15.6 (private IBE, [BS23], Section 15.6.2, p. 646)
with challenge-admissibility predicate valid: draw (mpk, msk); run the first stage on mpk
against the logging key oracle, from the empty log; if valid n mpk (id₀, m₀) (id₁, m₁), encrypt
the message of pair bit to the identity of pair bit, run the second stage on the ciphertext
with the same log, and return the guess when neither id₀ nor id₁ was queried, and false
otherwise; if the challenge is inadmissible, return false.
A scheme family with a structured identity space states membership in valid; since identities
are compared as words, no key issued for a word outside the space may decrypt a challenge.
A semantic-security adversary as a private-IBE adversary that names its challenge identity in
both pairs ([BS23], p. 646: Attack Game 15.5 is Attack Game 15.6 with id₀ = id₁).
A selective adversary as an adaptive one: its first stage draws the target identity from the security parameter alone, without looking at the master public key, and then chooses the messages.
The experiment on adversary.toPrivate is Attack Game 15.5 ([BS23], Section 15.6.1,
pp. 645–646): one challenge identity, an encryption of m_bit to it, and a final check that the
identity was not queried.
The experiment on adversary.toAdaptive.toPrivate has the law of Attack Game 15.7
([BS23], Section 15.6.2, p. 647): the target identity is drawn first, from the security
parameter alone, then the master keys; the message stage runs on the master public key.
toPrivate preserves the efficiency predicate: its first stage reshapes the output of the
adversary's first stage by a polynomial-time map.
toAdaptive preserves the efficiency predicate: its first stage samples the target stage and
runs the message stage on the target state and the master public key.
Semantically secure and private identity-based encryption ([BS23], Section 15.6.2,
Attack Game 15.6 and Definition 15.10, p. 646) for a scheme family E with challenge-admissibility
predicate valid: the two experiments of privateIBEGameOn are indistinguishable for every
uniform strict oracle PPT private-IBE adversary.
Semantically secure (adaptively secure) identity-based encryption ([BS23],
Section 15.6.1, Attack Game 15.5 and Definition 15.9, pp. 645–646): the experiments of
privateIBEGameOn on adversary.toPrivate, which are Attack Game 15.5
(privateIBEGameOn_toPrivate), are indistinguishable for every uniform strict oracle PPT
semantic-security adversary.
Selectively secure identity-based encryption ([BS23], Section 15.6.2, Attack
Game 15.7 and Definition 15.11, p. 647): the experiments of privateIBEGameOn on
adversary.toAdaptive.toPrivate, which have the laws of Attack Game 15.7
(eval_privateIBEGameOn_toAdaptive), are indistinguishable for every uniform strict (oracle) PPT
selective adversary.
A private identity-based encryption scheme is semantically secure ([BS23],
Section 15.6.2, p. 646: Attack Game 15.5 is the special case id₀ = id₁ of Attack Game 15.6).
A semantically secure identity-based encryption scheme is selectively secure ([BS23], Section 15.6.2, p. 647: selective security is "a weaker notion").