Signatures in the random-oracle model #
A signature scheme in the random-oracle model ([BS23], Section 13.2.1) signs and
verifies with oracle access to a function H : Query → Digest, which the security experiment
draws uniformly at random. Signing draws its coins and then runs an OracleComp program against
H; verification is a deterministic OracleComp program. The oracle is sampled lazily: each new
point gets a uniform answer, remembered in an association list (oracle), so the query and digest
types need not be finite beyond the digests.
The existential-unforgeability experiment (eufCmaGame, [BS23], Attack Game 13.1 in
its random-oracle version) gives a forger the public key and oracle access to the signer and to
H; the forger wins with a valid signature on a message it never asked to have signed. A
Forger has explicit coins, drawn first, and is otherwise a deterministic OracleComp program;
this is the form in which a forger can be rerun on the same coins, as forking needs. Its signing
and hash calls are counted separately (Forger.CallBounded), as security bounds depend on them
differently.
These are exact probability laws for one scheme and one forger, with no efficiency claim. The
oracle interface is the library's OracleComp; it is meant to be re-expressed in the shared
interactive-protocol core of #643 once that core exists.
This interface is separate from the computational Cslib.Crypto.SignatureScheme, which packages
word encodings, strict PPT certificates and verification without an oracle. Here the key and
signing coins are arbitrary typed laws, and signing and verification share the hash oracle. A
computational statement about a scheme of this form needs encodings, an efficient realization of
the oracle and resource certificates on top of the exact bound; the two notions are not competing
computational interfaces.
Main definitions #
Cslib.Crypto.Protocols.ROMSignature.Scheme: key generation, signing and verification.Cslib.Crypto.Protocols.ROMSignature.Forger: a forger with explicit coins.Cslib.Crypto.Protocols.ROMSignature.Forger.CallBounded: bounds on a forger's signing and hash calls.Cslib.Crypto.Protocols.ROMSignature.oracle: the lazily sampled uniform random oracle.Cslib.Crypto.Protocols.ROMSignature.eufCmaGame: the random-oracle EUF-CMA experiment.Cslib.Crypto.Protocols.ROMSignature.Scheme.Correct: honest signatures verify.
References #
- D. Boneh, V. Shoup, A Graduate Course in Applied Cryptography, Version 0.6, Sections 13.1 and 13.2.1.
The calls of a forger: a signing call names a message and returns a signature, and a hash call names a point and returns its digest.
Instances For
A signature scheme in the random-oracle model, with public keys PK, secret keys SK,
messages M, signatures Sig, and oracle H : Query → Digest. Signing first draws coins.
Draw a public key and a secret key.
- SignCoins : Type
The signer's coins.
Draw the signer's coins for a message.
- sign : SK → M → self.SignCoins → OracleComp (fun (x : Query) => Digest) Sig
Sign, querying the oracle.
- verify : PK → M → Sig → OracleComp (fun (x : Query) => Digest) Bool
Verify, querying the oracle.
Instances For
A forger with explicit coins: it draws its coins, then, given the public key, calls the signer and the oracle and outputs a message and a signature.
- Coins : Type
The forger's coins.
Draw the forger's coins.
- forge : PK → self.Coins → OracleComp (ForgerSpec M Query Sig Digest) (M × Sig)
Forge, calling the signer and the oracle.
Instances For
A forger's call costs one when it is a signing call.
Instances For
A forger's call costs one when it is a hash call.
Instances For
The forger makes at most signs signing calls and at most hashes hash calls on every path,
for every public key and every choice of its coins.
Instances For
A forger making at most signs signing and hashes hash calls makes at most
signs + hashes calls.
Answer a forger's calls: sign with the secret key, recording the message, or query the oracle. Signing and the forger share the oracle.
Instances For
The random-oracle EUF-CMA experiment ([BS23], Attack Game 13.1): the forger wins with a valid signature, under the same oracle, on a message it never had signed.
Instances For
A scheme is correct when every honest signature verifies under the same oracle, from every state of the oracle.