Privacy engine(s) for masking confidential information during verification processes within distributed systems
Various embodiments of the present technology generally relate to systems and methods for providing a privacy engine. In an example, the privacy engine converts, on a prover-side, confidential information into a plurality of tuples for a verification process and embeds the plurality of tuples with an embedding element. The prover-side privacy engine then generates a commitment using the tuples and transmits the commitment to a verifier-side privacy engine. Responsive to receiving the commitment, the verifier-side privacy engine verifies that the commitment includes the embedded element and generates a challenge to the commitment based on the commitment containing the embedded element. The verifier-side privacy engine then transmits the challenge to the prover-side privacy engine, which responsively generates a response containing the embedded element based on the challenge. Based on the response, the verifier-side privacy engine validates the response from the prover-side privacy engine based on the response containing the embedded element.
1 . A computing apparatus comprising:
a computer-readable storage medium;
processor-executable instructions stored on the computer-readable storage medium; and
one or more processors coupled to the computer-readable storage medium and configured to execute the processor-executable instructions to operate a prover-side privacy engine within a distributed system, such that the processor-executable instructions, when executed by the one or more processors, direct the computing apparatus, to at least:
identify confidential information for a verification process;
convert the confidential information into a plurality of tuples;
generate a random set of tuples from the plurality of tuples;
embed an embedding element into the random set of tuples;
generate a commitment based on the random set of tuples; and
transmit the commitment to a verifier-side privacy engine to initiate a zero-knowledge proof protocol, wherein based on the zero-knowledge proof protocol, the verifier-side privacy engine validates that the prover-side privacy engine possesses the confidential information.
2 . The computing apparatus of claim 1 , wherein the processor-executable instructions to generate the random set of tuples from the plurality of tuples, when executed by the one or more processors, further direct the computing apparatus to:
select a random value as a seed for a cryptographically Secure Pseudorandom Number Generator (CSPRNG); and
submit the plurality of tuples and the seed to the CSPRNG, wherein the CSPRNG responsively generates the random set of tuples.
3 . The computing apparatus of claim 1 , wherein the processor-executable instructions to generate the commitment based on the random set of tuples, when executed by the one or more processors, further direct the computing apparatus to:
select, by the prover-side privacy engine, a masking tuple from the random set of tuples; and
generate, by the prover-side privacy engine, the commitment based on the masking tuple, and the random set of tuples.
4 . The computing apparatus of claim 1 , wherein the processor-executable instructions, when executed by the one or more processors, further direct the computing apparatus to:
select a masking tuple from the random set of tuples;
receive, from the verifier-side privacy engine, a challenge to the commitment;
determine a binary value of the challenge; and
generate a response to the challenge based on the binary value, wherein the response comprises at least a portion of the random set of tuples, the masking tuple, and the embedding element.
5 . The computing apparatus of claim 1 , wherein the processor-executable instructions to embed the embedding element into the random set of tuples, when executed by the one or more processors, further direct the computing apparatus to:
generate the random set of tuples from the plurality of tuples comprising the embedding element.
6 . The computing apparatus of claim 1 , wherein:
the random set of tuples are generated using a random value as a seed; and
the processor-executable instructions to generate, by the prover-side privacy engine, the commitment based on the random set of tuples, when executed by the one or more processors, further direct the computing apparatus to:
generate a cryptographic hash of the random set of tuples and the seed as the commitment.
7 . A method comprising:
converting, by a prover-side privacy engine, confidential information into a plurality of tuples for a verification process;
embedding, by the prover-side privacy engine, the plurality of tuples with an embedding element;
generating, by the prover-side privacy engine, a commitment using the plurality of tuples;
transmitting by the prover-side privacy engine, the commitment to a verifier-side privacy engine to initiate a zero-knowledge proof protocol, wherein based on the zero-knowledge proof protocol, the verifier-side privacy engine validates that the prover-side privacy engine possesses the confidential information;
responsive to receiving the commitment, verifying, by the verifier-side privacy engine, that the commitment comprises the embedding element;
generating, by the verifier-side privacy engine, a challenge to the commitment based the commitment comprising the embedding element;
transmitting, by the verifier-side privacy engine, the challenge to the prover-side privacy engine;
responsive to receiving the challenge, generating, by the prover-side privacy engine, a response comprising the embedding element based on the challenge; and
validating, by the verifier-side privacy engine, the response from the prover-side privacy engine based on the response comprising the embedding element.
8 . The method of claim 7 , wherein embedding, by the prover-side privacy engine, the plurality of tuples with the embedding element comprises:
generating, by the prover-side privacy engine, a random set of tuples from the plurality of tuples; and
embedding, by the prover-side privacy engine, the random set of tuples with the embedding element.
9 . The method of claim 7 , wherein:
the method further comprises:
generating, by the prover-side privacy engine, a random set of tuples from the plurality of tuples; and
generating, by the prover-side privacy engine, the commitment using the plurality of tuples comprises generating, by the prover-side privacy engine, the commitment using the random set of tuples.
10 . The method of claim 9 , wherein generating the random set of tuples from the plurality of tuples comprises:
determined, by the prover-side privacy engine, a random value as a seed for a Cryptographically Secure Pseudorandom Number Generator (CSPRNG); and
generating, by the prover-side privacy engine, the random set of tuples from the plurality of tuples and the seed using the CSPRNG.
11 . The method of claim 7 , wherein verifying, by the verifier-side privacy engine, that the commitment comprises the embedding element comprises:
identifying, by the verifier-side privacy engine, an embedding function associated with the commitment;
decoding, by the verifier-side privacy engine, the commitment using the embedding function; and
extracting, by the verifier-side privacy engine, the embedding element from the commitment as decoded via the embedding function.
12 . The method of claim 7 , wherein:
generating, by the prover-side privacy engine, the commitment using the plurality of tuples comprises:
generating, by the prover-side privacy engine, a random set of tuples from the plurality of tuples; and
generating, by the prover-side privacy engine, the commitment using the random set of tuples; and
generating, by the prover-side privacy engine, the response comprising the embedding element based on the challenge comprises:
determining, by the prover-side privacy engine, one or more binary values based on the challenge;
selecting, by the prover-side privacy engine, at least a subset of the random set of tuples for the response based on the one or more binary values; and
generating, by the prover-side privacy engine, the response comprising the embedding element and the at least a subset of the random set of tuples.
13 . The method of claim 7 , wherein validating, by the verifier-side privacy engine, the response from the prover-side privacy engine based on the response comprising the embedding element comprises:
validating, by the verifier-side privacy engine, that the response comprises the embedding element; and
validating, by the verifier-side privacy engine, that the commitment comprises matching elements to the response.
14 . A computer-readable storage medium comprising processor-executable instructions, wherein the processor-executable instructions, in part, operate a privacy engine to perform a Zero-Knowledge Proof (ZKP) protocol between a prover and a verifier within a distributed system such to cause one or more processors to:
identify, by a prover-side privacy engine, confidential information for the ZKP protocol;
convert, by the prover-side privacy engine, the confidential information into a plurality of tuples;
generate, by the prover-side privacy engine, a random set of tuples from the plurality of tuples;
embed, by the prover-side privacy engine, an embedding element into the random set of tuples;
generate, by the prover-side privacy engine, a commitment based on the random set of tuples;
transmit, by the prover-side privacy engine, the commitment to a verifier-side privacy engine;
responsive to receiving the commitment, verify, by the verifier-side privacy engine, that the commitment comprises the embedding element; and
validate, by the verifier-side privacy engine, that the prover-side privacy engine possesses the confidential information using the commitment based on the ZKP protocol.
15 . The computer-readable storage medium of claim 14 , wherein the processor-executable instructions to generate, by the prover-side privacy engine, the random set of tuples from the plurality of tuples cause the one or more processors to further execute processor-executable instructions stored in the computer-readable storage medium to:
select, by the prover-side privacy engine, a random value as a seed for a cryptographically Secure Pseudorandom Number Generator (CSPRNG); and
generate, by the prover-side privacy engine, the random set of tuples from the plurality of tuples and the seed using the CSPRNG.
16 . The computer-readable storage medium of claim 14 , wherein the processor-executable instructions to generate, by the prover-side privacy engine, the commitment based on the random set of tuples cause the one or more processors to further execute processor-executable instructions stored in the computer-readable storage medium to:
select, by the prover-side privacy engine, a masking tuple from the random set of tuples; and
generate, by the prover-side privacy engine, the commitment based on the masking tuple, and the random set of tuples.
17 . The computer-readable storage medium of claim 14 , wherein the processor-executable instructions to embed, by the prover-side privacy engine, the embedding element into the random set of tuples cause the one or more processors to further execute processor-executable instructions stored in the computer-readable storage medium to:
embed, by the prover-side privacy engine, the embedding element into plurality of tuples; and
generate, by the prover-side privacy engine, the random set of tuples from the plurality of tuples comprising the embedding element.
18 . The computer-readable storage medium of claim 14 ,
wherein the processor-executable instructions to verify, by the verifier-side privacy engine, that the commitment comprises the embedding element cause the one or more processors to further execute processor-executable instructions stored in the computer-readable storage medium to:
identify, by the verifier-side privacy engine, an embedding function associated with the commitment;
decode, by the verifier-side privacy engine, the commitment using the embedding function; and
extract, by the verifier-side privacy engine, the embedding element from the commitment as decoded via the embedding function.
19 . The computer-readable storage medium of claim 14 ,
wherein the processor-executable instructions to validate, by the verifier-side privacy engine, that the prover-side privacy engine possesses the confidential information using the commitment cause the one or more processors to further execute processor-executable instructions stored in the computer-readable storage medium to:
generate, by the verifier-side privacy engine, a challenge to the commitment based the embedding element within the commitment;
determine, by the prover-side privacy engine, one or more binary values based on the challenge;
select, by the prover-side privacy engine, one or more tuples from the random set of tuples for a response based on the one or more binary values; and
generate, by the prover-side privacy engine, the response comprising the embedding element and the one or more tuples.
20 . The computer-readable storage medium of claim 14 , wherein the processor-executable instructions to validate, by the verifier-side privacy engine, that the prover-side privacy engine possesses the confidential information using the commitment cause the one or more processors to further execute processor-executable instructions stored in the computer-readable storage medium to:
generate, by the verifier-side privacy engine, a challenge to the commitment based the embedding element within the commitment;
generate, by the prover-side privacy engine, a response comprising the embedding element and the one or more tuples from the random set of tuples;
generate, by the verifier-side privacy engine, matching elements from the one or more tuples in the response; and
validate, by the verifier-side privacy engine, that the commitment comprises the matching elements.