Policy-Enhanced Private Set Intersection: Sharing Information While Enforcing Privacy Policies Emil Stefanov Elaine Shi Dawn Song emil@cs.berkeley.edu elaines@cs.berkeley.edu dawnsong@cs.berkeley.edu UC Berkeley http://www.emilstefanov.net/Research/ Private Set Intersection (PSI) Alice’s set Bob’s set Revealed • Alice has a set of elements. • Bob has a set of elements. • Goal: – Reveal elements that are both sets. – Hide all other elements [CKT10], [CT10], [DMR09], [FIP05], [HL08], [HN10], [JL09], [JL10], [LS05], … Alternative Approaches • Trusted third party – Trivial solution – Does not always exist. • Who can both parties trust? • Generic SMC (e.g., garbled circuits) – Less efficient in most scenarios • Homomorphic encryption – Not practical Applications • Healthcare – Common patients – Common symptoms • Social Networks – Common friends – Common group memberships • Distributed databases – JOIN operations • Many more – Set intersection is a fundamental operation The Problem with PSI • No restriction on sets. • Either party can insert fictitious elements. • Can be used to violate privacy. Known-Element Attack Alice’s set b Bob’s set a e • • • • c c d d c d f h g i Bob wants to learn if Alice has π. Bob inserts π into his own set They perform a private set intersection. π is in result ο¨ Bob learns that Alice has π. Our Contributions • • • • Technique to authenticate elements Rich privacy policies Multiple authorities Can be used to extend any private set intersection protocol. PPSI Problem Definition (single authority, symmetric) • Alice’s input: πΏ = ππ , ππ , … , ππ π¨ = πΆπ , πΆπ , … , πΆπ • Bob’s input: π = ππ , ππ , … , ππ • Signature verification: • Define valid sets: π© = π·π , π·π , … , π·π π½ π, π ∈ T, F πΏ′ = ππ ∈ πΏ βΆ π½ ππ , πΆπ = T π′ = ππ ∈ π βΆ π½ ππ , π·π = T • Output: π = πΏ′ ∩ π′ Known-Element Attack not Possible Alice’s set b Bob’s set a e c c d d c d f h g i • Bob wants to learn if Alice has π. • Bob inserts π into his own set (with invalid signature) • They perform PPSI – PPSI removes π from result (Bob has an invalid signature) • Bob cannot learn if Alice has π. PPSI Problem Definition (multiple authorities, symmetric) • Alice: πΏ = ππ , ππ , … , ππ π¨ = πΆπ , πΆπ , … , πΆπ • Bob: π = ππ , ππ , … , ππ π© = π·π , π·π , … , π·π • Privacy policy (known to both Alice and Bob) – Signer (authority) depends on the element – Authority for element π§: π π • Signature verification: π½ π, π – Verifies π against public key of π π • Multiple signatures/authorities per element – π π , πΆπ , and π·π can be a sets – π(π) can be a Boolean expression (DNF). PPSI Problem Definition (multiple authorities, asymmetric) • Alice: πΏ = ππ , ππ , … , ππ π¨ = πΆπ , πΆπ , … , πΆπ • Bob: π = ππ , ππ , … , ππ π© = π·π , π·π , … , π·π • Authorities depend on the element and party – Authority for element π§ and Alice: – Authority for element π§ and Bob: π π, π¨ π π, π© • Alice and Bob both know π ⋅, π¨ and π ⋅, π© Additional Goals • Signatures must be bound to a party – π π₯, π΄ : Alice is allowed to have π₯ in her set. – Non-transferable ο¨ π π₯, π΄ is useless to Bob • Require interaction – Bob must not be able to later re-run the protocol with a different set (without Alice’s cooperation). • Efficient. Complexity… … depends on: • Set size • Authorities per element … independent of: • Element universe • Authority universe So, how can we achieve this? Intersect then verify? Alice’s set b Bob’s set a e c c d d c d f h g i • After intersecting, Bob already learns π. • Verifying afterwards ensures integrity... • … but not confidentiality (already revealed π ) Verify then intersect? b e a d c c c d f h g i • E.g., using commitments and zero-knowledge proofs. • Problem: which authorities to verify elements against? • Complexity is linear with size of authority universe! Challenge • • • • • Can’t intersect then verify. Can’t verify then intersect. So what do we do? Must simultaneously intersect and verify. But how? Intersect signatures using PSI? ππ ππ ππ ππ ππ ππ ππ ππ ππ ′ ππ ππ ππ • Both parties must have identical signatures – Not possible to bind signatures to parties • πΊ π, π¨ for Alice and πΊ π, π© for Bob. – Does not work for asymmetric policies. Key technique: encode each element then intersect encodings π½π π½π π½π π½π π½π π½π π½π π½π π½π ′ π½π π½π π½π Main Property of Encodings • Alice’s encoding of π§ should match Bob’s encoding – if and only if the policy is satisfied – even though the signatures are different – even though the authorities might be different • Secret keys of two authorities: π π1 , π π2 • Alice has πΊπππ π, π¨ Bob has πΊπππ π, π© • Property: π¨πππππ¬ππππ π πΊπππ π, π¨ = π©πππ¬ππππ π πΊπππ π, π© PPSI Protocol Alice RA RB Exchange Challenges Generate Encodings Generate Encodings Regular Private Set Intersection Protocol Over Encodings Recover ∩ from result Done Recover ∩ from result Bob Encoding Challenge • Need: π¨πππππ¬ππππ π πΊπππ π, π¨ • • • • • = π©πππ¬ππππ π πΊπππ π, π© Encoding is a function of both πΊπππ π, π¨ and πΊπππ π, π© Alice doesn’t know πΊπππ π, π© Bob doesn’t know πΊπππ π, π¨ So how can they generate the same encoding for π§? Answer: – Specially chosen signature scheme: BLS signatures – Challenge phase – Our special encodings Signatures • We use standard BLS signatures. • In a group πΎ of prime order π – With bilinear map: πΎ × πΎ → πΎ π – Generators: π, π, π • Signature key of an authority – π π ∈π β€π • Verification key of the authority – π£π = π π π • Authority’s signature to Alice for element π₯: – πΊππ π, π¨ = H π, π¨ ππ Challenge Phase • Alice generates random: ππ ∈π β€π • Bob generates random: ππ ∈π β€π • Alice sends π π΄ = πππ to Bob • Bob sends π π΅ = πππ to Alice • Note that: – Only Alice knows ππ – Only Bob knows ππ Special Encodings • Alice’s encoding of πΊπππ π, π¨ to match Bob’s encoding of πΊπππ π, π© : π πΊπππ π, π¨ , πΉπ© ⋅ π π― π, π© , πππ Alice knows signature πππ ππ Alice knows ππ ππ = π π― π, π¨ , π ⋅ π π― π, π© , π = π π― π, π¨ , π πππ ⋅ππ ⋅ π π― π, π© , π πππ ππ πππ ⋅ππ • Bob’s encoding of πΊπππ π, π© to match Alice’s encoding of πΊπππ π, π¨ : π π― π, π¨ , πππ ππ Bob knows ππ = π π― π, π¨ ππ ππ π ,π πππ ⋅ππ ⋅ π πΊπππ π, π© , πΉπ¨ Bob knows signature ⋅ π π― π, π© πππ , πππ πππ ⋅ππ encodings match Encodings for More Complex Policies • Suppose that – π π, π¨ = authπ , authπ , authπ – π π, π© = authπ , authπ – Signing key for authπ is π ππ • Alice’s encoding for π§: π πΊπππ π, π¨ ⋅ πΊπππ π, π¨ ⋅ πΊπππ π, π¨ , πΉπ© ⋅ π π― π, π© , πππ ππ ⋅ πππ ππ • Bob’s encoding for π§: π πΊπππ π, π© ⋅ πΊπππ π, π© , πΉπ¨ ⋅ π π― π, π¨ , πππ ππ ⋅ πππ ππ ⋅ πππ π π, π¨ π π, π© π π, π© ππ π π, π¨ Summary Alice RA RB Exchange Challenges Generate Encodings Generate Encodings Regular Private Set Intersection Protocol Over Encodings Recover ∩ from result Done Recover ∩ from result Bob Extensions • Attributes – πΊππ ππ , attr, π¨ = H ππ , attr, π¨ ππ • Bundles – Merge encodings of all elements in bundle. • Disjunctions and DNF’s – One encoding per conjunctive clause of the DNF. Security • Assumptions: – CBDH, random oracle, underlying PSI security • Proof technique: – Define ideal world: A third party is doing the intersection and verifying the signatures. – Computationally indistinguishable from ideal world. • Secure against malicious adversaries. Performance • π elements • π authorities per element • Computation: π ππ + πππΌπππππ’π‘ππ‘πππ π – e.g., π ππ + π log log π • Bandwidth: π π + πππΌπππππ€πππ‘β π – e.g., π π • Rounds: 0 + πππΌπππ’πππ π – e.g., π 1 Time to encode an element with π signatures/authorities (in ms) m 1 Average 1.70 Standard 0.06 Deviation 2 3.10 3 4.45 4 5.65 5 7.07 0.17 0.22 0.04 0.27 Example Finding the customers who both bought a computer from Dell and a monitor from Newegg. Dell’s Sales Table • • • • ID Customer Product D1 Jennifer Robinson D2 Newegg’s Sales Table Card ID Customer Product Computer N1 David Thompson Monitor David Thompson Computer N2 James Young Monitor D3 Ronald Miller Computer N3 Maria Hall Monitor D4 Karen Carter Computer N4 Linda Clark Monitor D5 Maria Hall Computer N5 Donald Green Monitor D6 Donald Green Printer Elements: customers Attributes: product Authorities: MasterCard, Visa Policy: bought a computer from Dell and a monitor from Newegg • Result: {“David Thompson”, “Maria Hall”} Jennifer Robinson Ronald Miller Karen Carter Donald Green David Thompson Card James Young Linda Clark Maria Hall Donald Green Related Work • Private Set Intersection (PSI) – FNP04, FIP05, KS05, HL08, JL09, DMR09, HN10, CKT10, JL10, … • Authorized Private Set Intersection (APSI) – CKT09, CZ09, CT10, … Summary • Technique to authenticate elements • Rich privacy policies – – – – – – Symmetric & asymmetric Authority can depend on the element Multiple authorities (per element) Attributes Bundles Boolean expression (DNF) policy • Can be used to extend any private set intersection protocol.