Giter VIP home page Giter VIP logo

witness-encryption-functional-commitment's Introduction

Witness encryption for succinct functional commitments

This library contains a small implementation of witness encryption for succinct functional commitments for Libert et al.’s FC.

❗ This library has not been audited and should not be used in production

Witness encryption allows you to encrypt a value to whoever has knowledge of a witness. More concretely, in this work, the encryption statement consists of a commitment cm, a function G and a value y; the decryption witness consists of a (non succinct) NIZK proof about the fact that cm opens to v such that y=G(v).

The above is made possible through two main building blocks:

  1. Smooth Projective Hash Functions
  2. Functional Commitments

To see how it can be used, run cargo test encryption_decryption.

The SPHF tests use examples from Fabrice Benhamouda's thesis: Diverse modules and zero-knowledge.

Credits

A big thank you to the authors of Witness Encryption for Succinct Functional Commitments and Applications and its sources. Moreover, this existing SPHF repo was a great help.

witness-encryption-functional-commitment's People

Contributors

vicsn avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

novus677

witness-encryption-functional-commitment's Issues

Libert et al.’s FC is inconsistent with this implementation

The paper on which this library is based: Witness Encryption for Succinct Functional Commitments and Applications and it's cousin Subvector commitments with application to succinct
arguments
make use of Libert et al.’s FC scheme.

However, the equations don't seem to work out. More concretely, in order to make the equations fit, I have to
(1) In the Open equation, replace [u^i]_1 by [g^i]_1 - see ADJUSTMENT_1
(2) In the Verify equation, replace [1]_2 by [u]_2 - see ADJUSTMENT_2
(3) And then I still have to remove some terms - see ADJUSTMENT_3

Use native matrix-library multiplication

The nalgebra package should be able to just do A*B. There were still some compiler issues when attempting this using the BlsElement wrapper class as matrix type

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.