Reference articles on history, science, culture and more
Encyclopedia

Private set intersection

Secure multiparty computation cryptographic technique

Image credit is listed at the end of this article.

Private set intersection is a secure multiparty computation cryptographic technique that allows two parties holding sets to compare encrypted versions of these sets in order to compute the intersection. In this scenario, neither party reveals anything to the counterparty except for the elements in the intersection.

Other variants of this exist, such as the server-client scenario, in which only the client learns the intersection of her set with the set of the server, without the server learning intersection of his set with the clients.

For the comparison of data sets by cryptographic hashes on a small or predictable domain, precautions should be taken to prevent dictionary attacks.

Apple uses this technique in Password Monitoring. It has proposed using the technology for its announced Expanded Protections for Children

In general, PSI protocols can be categorized into two broad categories: (1) traditional PSI and (2) delegated PSI. In the traditional PSI category, the data owners interact directly with each other and need to have a copy of their set at the time of the computation, e.g.,. In the delegated PSI the computation of PSI and/or the storage of sets can be delegated to a third-party server (that is itself might be a passive or active adversary). The delegated PSI category can be further divided into two classes: (a) those that support one-off delegation, and (b) those that support repeated delegation. The PSI protocols that support one-off delegation require the data owner to re-encode its data and send the encoded data to the server for each computation, e.g.,. Those that support repeated delegation allow the data owners to upload their (encrypted) data to the server only once, and then re-use it many times for each computation carried out but the server, e.g.,

Recently, researchers have proposed a variant of PSI protocol (in both traditional and delegated categories) that support data update, e.g., . This type of PSI protocol lets data owners insert/delete set elements into/from their data with low overheads and in a privacy-preserving manner.

01Educational example

This educational example demonstrated the key idea of PSI, but does not provide real-world cryptographic security (hence should not be used with real-world data).

# Example sets party_a_set = {"apple", "banana", "cherry"} party_b_set = {"banana", "orange", "apple"} # Hashing the elements in both sets hashed_party_a_set = {hash(e) for e in party_a_set} hashed_party_b_set = {hash(e) for e in party_b_set} # Finding the intersection of the hashed sets intersection = hashed_party_a_set.intersection(hashed_party_b_set) # Printing hashed intersection for demonstration print(intersection)
Watch videos about Private set intersectionExplainers and documentaries on YouTube (opens in a new tab)

Sources and credits

This article is adapted from the Wikipedia article Private set intersection, written by its contributors and licensed under CC BY-SA 4.0. Fathomly has changed the layout, removed citation markers, navigation and maintenance notices, and adjusted punctuation. This adapted version is shared under the same license. For references, see the original article.

Images, from Wikimedia Commons:

Fathomly is not affiliated with or endorsed by the Wikimedia Foundation. Spotted a problem? Tell us.