Proxy Re Encryption Key Generation

Posted on by

Proxy re-encryption (PRE) schemes are cryptosystems which allow third parties (proxies) to alter a ciphertext which has been encrypted for one party, so that it may be decrypted by another.

Examples of use[edit]

In a proxy re-encryption scheme, a proxy can convert an encryption computed under Alice’s public-key into an encryption intended for Bob. Such a scheme can be used by Alice to temporarily forward encrypted messages to Bob without giving him her secret key. Proxy Re-Encryption provides the ability to transform a ciphertext encrypted under some key to the one under another key. This seems interesting. But, something seems strange. Suppose Alice has a key pair (ska, pka) and Bob also has a key pair (skb, pkb). Proxy re-encryption is a special type of public-key encryption that permits a proxy to transform ciphertexts from one public key to another, without the proxy being able to learn any information. Proxy re-encryption (PRE) is a public key encryption that allows a semi-trusted proxy with some information (a.k.a., re-encryption key) to transform a ciphertext under one public key into another.

A proxy re-encryption is generally used when one party, say Bob, wants to reveal the contents of messages sent to him and encrypted with his public key to a third party, Charlie, without revealing his private key to Charlie. Bob does not want the proxy to be able to read the contents of his messages.[1] Bob could designate a proxy to re-encrypt one of his messages that is to be sent to Charlie. This generates a new key that Charlie can use to decrypt the message. Now if Bob sends Charlie a message that was encrypted under Bob's key, the proxy will alter the message, allowing Charlie to decrypt it. This method allows for a number of applications such as e-mail forwarding, law-enforcement monitoring, and content distribution.

A weaker re-encryption scheme is one in which the proxy possesses both parties' keys simultaneously. One key decrypts a plaintext, while the other encrypts it. Since the goal of many proxy re-encryption schemes is to avoid revealing either of the keys or the underlying plaintext to the proxy, this method is not ideal.

Defining functions[edit]

Proxy re-encryption schemes are similar to traditional symmetric or asymmetric encryption schemes, with the addition of two functions:

  • Delegation – allows a message recipient (keyholder) to generate a re-encryption key based on his secret key and the key of the delegated user. This re-encryption key is used by the proxy as input to the re-encryption function, which is executed by the proxy to translate ciphertexts to the delegated user's key. Asymmetric proxy re-encryption schemes come in bi-directional and uni-directional varieties.
    • In a bi-directional scheme, the re-encryption scheme is reversible—that is, the re-encryption key can be used to translate messages from Bob to Charlie, as well as from Charlie to Bob. This can have various security consequences, depending on the application. One notable characteristic of bi-directional schemes is that both the delegator and delegated party (e.g., Charlie and Bob) must combine their secret keys to produce the re-encryption key.
    • A uni-directional scheme is effectively one-way; messages can be re-encrypted from Bob to Charlie, but not the reverse. Uni-directional schemes can be constructed such that the delegated party need not reveal its secret key. For example, Bob could delegate to Charlie by combining his secret key with Charlie's public key.
  • Transitivity – Transitive proxy re-encryption schemes allow for a ciphertext to be re-encrypted an unlimited number of times. For example, a ciphertext might be re-encrypted from Bob to Charlie, and then again from Charlie to David and so on. Non-transitive schemes allow for only one (or a limited number) of re-encryptions on a given ciphertext. Currently, the only known uni-directional, transitive proxy re-encryption is done through the use of Homomorphic Encryption[2].
  • Cloud Computing – Proxy re-encryption has potential applications for secure sharing in a cloud computing environment. In the cloud scenario the re-encryption key is provided to the cloud operator/admin. Looking at the Bob, Charlie, David example, the cloud would take the place of Charlie. Bob generates a re-encryption key to supply to the cloud. The cloud operator/admin completes a re-encrypt of Bob’s encrypted files into David’s files whenever David downloads Bob’s files. Challenges exist with the cloud solution. A user could conspire with a cloud operator to gain access to all a user’s, such as Bob, files. A second potential challenge is segmentation via access control. A cloud user can restrict access to files via the assignment of conditional values. However, the number of re-encryption keys grows proportionately with the number of conditional values. This situation is not optimal for resource constrained devices.[3]

Proxy re-encryption should not be confused with proxy signatures, which is a separate construction with a different purpose.

See also[edit]

References[edit]

  1. ^Nabeel's Blog, Seen Nov 2014, http://mohamednabeel.blogspot.ca/2011/03/proxy-re-encryption.html
  2. ^Gentry, Craig (September 2009). A Fully Homomorphic Encryption System(PDF). p. 35.
  3. ^W. Chen, C. Fan, Y. Tseng (10–13 December 2018). 'Efficient Key-Aggregate Proxy Re-Encryption for Secure Data Sharing in Clouds'. 2018 IEEE Conference on Dependable and Secure Computing (DSC): 1–4. doi:10.1109/DESEC.2018.8625149. ISBN978-1-5386-5790-4.CS1 maint: multiple names: authors list (link) CS1 maint: date format (link)
  • M. Blaze, G. Bleumer, M. Strauss. Divertible Protocols and Atomic Proxy Cryptography.
  • Bertino, E., Sandhu, R. 'Database security - concepts, approaches, and challenges.'IEEE Transactions on Dependable and Secure Computing 2 (2005): 2-19
  • G. Ateniese, K. Fu, M. Green, S. Hohenberger. Improved Proxy Re-encryption Schemes with Applications to Secure Distributed Storage. Proceedings of the 12th Annual Network and Distributed Systems Security Symposium (NDSS 2005), San Diego, California, 2005.
  • M. Green, G. Ateniese. Identity-Based Proxy Re-encryption. Applied Cryptography and Network Security Conference, June 2007.
  • S. Hohenberger, G. Rothblum, a. shelat, and V. Vaikuntanathan. Securely Obfuscating Re-encryption. Proceedings of the Theory of Cryptography Conference (TCC), 2007.
Retrieved from 'https://en.wikipedia.org/w/index.php?title=Proxy_re-encryption&oldid=943575319'

A Proxy Re-Encryption library using Bilinear Map. It contains basic functions like encryption, decryption, re-encryption, re-decryption, sign and verify.

Usage

Setup

Set the generators of G1 and G2. It must pefrom at first.

Proxy Re Encryption Key Generation

Proxy Re Encryption Key Generation Download

Generate Random Element in Fr

PRE is supposed to encrypt symmetric key.

It's recommended to get the key from a random element in Fr and convert it to hex string instead of generating a random key and mapping it to Fr.

Generate Key Pairs

Generate key pairs of Delegator(A) and Delegatee(B).

You can get public key from existing secret key using getPkFromG1 and getPkFromG1.

Encryption & Decryption

A can of course encrypt and decrypt.

Generate Re-Encryption Key

A can generate reKey with A's secret key and B's public key.

Re-Encryption & Re-Decryption

Bulletstorm pc free. Anyone can convert encrypted with reKeyinto ciphertext that can be decrypted by B.

Encryption Software

Proxy Re Encryption Key Generation

Proxy Re Encryption Key Generation Free

Sign and Verify

Right now only signature by delegator is implemented, delegatee can have key pair with delegator's format (in G1) as well.

Tips

Almost every input parameters can either be hex string or Object in group. It'll automatically check the type and convert it to Object during caculation if necessary.

Encryption Key Generator

Algrithom

Proxy Re Encryption Scheme

  • Setup

    $g$ and $h$ are the generators of $G_1$ and $G_2$

    $Z=e(g,h)$

    $e:G_1 times G_2 to G_T$

  • Key Generation

    $sk_A in F_r$, $pk_A=g^{sk_A} in G_1$

    $sk_B in F_r$, ​$pk_B=h^{sk_B} in G_2$

  • Encryption$$C_1=((pk_A)^k,mZ^k)$$

  • Decryption

    $$frac{beta}{e(alpha,h)^{frac{1}{sk_A}}}=frac{me(g,h)^k}{e((pk_A)^k,h)^{frac{1}{sk_A}}}=frac{me(g,h)^k}{e((g^{sk_A})^k,h)^{frac{1}{sk_A}}}=m$$

  • Re-Encryption Key Generation

    $$rk_{A to B}=(pk_B)^{frac{1}{sk_A}}$$

  • Re-Encryption

    From $C_I=(alpha,beta)$

    Caculate $alpha{'}=e(alpha,rk_{P to D})$

    Output $C_2=(alpha ^{'},beta)$

  • Re-Decryption

    $$frac{beta}{(alpha^{'})^{frac{1}{sk_B}}}=frac{me(g,h)^k}{e(alpha,rk_{P to D}))^{frac{1}{sk_B}}}=frac{me(g,h)^k}{e((pk_A)^k,(pk_B)^{frac{1}{sk_A}})^{frac{1}{sk_B}}}=frac{me(g,h)^k}{e((g^{sk_A})^k,(h^{sk_B})^{frac{1}{sk_A}})^{frac{1}{sk_B}}}=m$$

  • Sign

    $$S=H^{sk_A}$$

  • Verify

    $$e(g,S)=e(g,H^{sk_A})=e(g^{sk_A},H)=e(pk_A,H)$$