23
Scott Fluhrer Principal Engineer September 15, 2017 A Survey Hash Based Signatures

Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

Embed Size (px)

Citation preview

Page 1: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

Scott Fluhrer Principal Engineer September 15, 2017

A Survey Hash Based Signatures

Page 2: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

Why Hash Based Signatures?

Confidence in its security

As strong as the hash function

Postquantum (assuming the hash function is postquantum)

Page 3: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

Basics of Hash Based Signatures

Page 4: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

Merkle Signatures

Overall structure

One Time Signatures

Public Key

Page 5: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

Multilevel Merkle Trees

Can sign billions

of messages

H=10

H=10

H=10

Page 6: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

Stateful Hash Based Signatures

Page 7: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

Stateful Signature Schemes

This is a straightforward implementation of a Merkle tree

We use one bottom level OTS leaf to sign each message

0 1 2 …

Page 8: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

Problem with Stateful Schemes

• State Management

You must never use the same index to issue two different signatures

That means that you must remember which you used

What if the disk write fails?

Managing multiple signers are problematic

Issues with VM state cloning

Page 9: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

LMS vs XMSS

These are two different proposals for doing stateful signatures.

They are mostly similar (signature sizes, public key sizes, etc), however there are two major differences between the two…

Page 10: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

LMS vs XMSS Proofs of Security

In XMSS, they randomize each hash that they perform

Hash

Value Random

+

Because XMSS always hashes random values, if you can generate an XMSS forgery, you must be able to generate (second) preimages

Page 11: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

LMS vs XMSS Proofs of Security

In LMS, they prepend a unique hash identifier

Value Unique

The proof shows that, if the Merkle Damgård compression function acts randomly, then the probability of the attacker finding a forgery is tiny

Merkle Damgård Hash

Page 12: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

LMS vs XMSS Performance

0 2 4 6

PK Gen

Sign

Verify

XMSS

LMS

XMSS takes 3x-5x more time for every operation (*) Sign and Verify benchmarks assumes short messages

Relative time (LMS normalized to 1)

Page 13: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

• XMSS has a stronger security model

• LMS is much faster (for short messages)

Bottom Line

Is there a Real Difference?

• Not if you’re happy with the LMS security model

• Not if the messages you’re signing are large

Page 14: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

Stateless Hash Based Signatures - SPHINCS

Page 15: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

Stateless Hash Based Signatures SPHINCS

XMSS and LMS has the disadvantage that we need to track state.

SPHINCS is a hash based signature method that doesn’t require that.

Page 16: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

SPHINCS

Internal Organization

H=60

Hypertree

HORST

Page 17: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

Pluses

• No more state

• Looks like a traditional signature method

• Up to 250 signatures per public key (before security of private key starts to erode)

Minuses

• Large signatures (41000 bytes)

• Relatively large signature generation time

SPHINCS Pluses and Minuses

Page 18: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

Hybrid Hash Based Signatures

Page 19: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

Intermediate Approach: Hybrid Signatures

The problem with state is keeping track of it long-term

What if we kept all state in memory?

Page 20: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

The Hybrid Approach

Key Generation

Public key Private key

Key Expansion Signature

Generation

Running state

Signatures

On Disk In Memory

Page 21: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

What does this gain us?

We have less concern about state

• No issues about not being able to write the update to the disk

• No issue with multiple signers

• No issues about cloning, as long as the clone doesn’t copy RAM

Signatures can also be shorter and faster to generate

Page 22: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)

The Trade-Offs

XMSS/LMS Smaller signatures

Fast siggen Problems with long term state

SPHINCS Large signatures

Slow siggen Practically perfect

otherwise

Hybrid Intermediate sized

signatures Less problems

with state Not fully defined

Page 23: Hash Based Signatures - ETSI Hash Based Signatures? Confidence in its security As strong as the hash function Postquantum (assuming the hash function is postquantum)