Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Secret Data Validation #4

Closed
ainsleys opened this issue Jul 22, 2019 · 12 comments
Closed

Secret Data Validation #4

ainsleys opened this issue Jul 22, 2019 · 12 comments

Comments

@ainsleys
Copy link
Contributor

ainsleys commented Jul 22, 2019

Request

Enigma Secret Contracts enable dApps to compute over encrypted data. One simple use-case for this is validating the authenticity of a data set. This simple contract just checks to see if encrypted data inputs from different users are equivalent or not.

Solution Description

This solution should enable User A to upload a small dataset (email, phone number), and also enable a second user to submit their own dataset (with the same fields). Then, the secret contract should compare the two data sets. If they are equivalent, the secret contract should send an encrypted affirmation of this to User B, who has now verified their data set against user A. If they are not equivalent, the user should receive a false response.

This will involve:

  • Writing a secret contract that compares two datasets and returns true or false result to User B.
  • Using Enigma-JS to enable both User A and User B to encrypt and submit their datasets as Tasks to the Enigma network.
  • Creating a UI that enables users to both add data and view results

Implementation Details and Data Flow

  1. User A submits data via a UI (email, phone number).
  2. This data submission is encrypted locally via Enigma-JS and submitted to the secret contract.
  3. User B submits data via a UI (email, phone number)
  4. This data submission is encrypted locally via Enigma-JS and submitted to the secret contract.
  5. The secret contract (after receiving both datasets) executes a comparison to check equivalency.
  6. The secret contract returns either a False or True response.
  7. If data are equivalent, User B and User A are notified via the UI.
  8. If data are not equivalent, both users are notified via the UI.

Success

A working application, which should have a simple React-based UI (or similar), enable the solution, and handle failure (i.e., displays a meaningful message when improperly formatted data is submitted).

Other Deliverables

  • Migration scripts (if required)
  • Integration tests
  • Readme

Bounty Selection

For this first bounty round, the process works as follows:

  1. Developer / team submits a “pre-submission for approval” for a bounty
  2. Enigma reviews submissions, and selects an applicant (we don’t have a firm timeline for this, but hope to work quickly)
  3. Applicant completes the task satisfactorily and receives the bounty

If the task is not completed, or applicant is unable to continue work in a timely manner, Enigma will select another applicant.

To complete a pre-submission for approval,
First, comment on this issue within github and indicate your interest. Then, please also complete this application form.

Resources

These materials should help you get started:
Enigma Discovery Documentation

Developer Quickstart Guide
Secret Contracts Walkthrough
Enigma-JS
Walkthrough

@gitcoinbot
Copy link

Issue Status: 1. Open 2. Started 3. Submitted 4. Done


This issue now has a funding of 900.0 ENG (430.74 USD @ $0.48/ENG) attached to it as part of the enigmampc fund.

@izokay
Copy link

izokay commented Jul 26, 2019

I am interested.

@thaodt
Copy link

thaodt commented Jul 27, 2019

Hi @ainsleys , i'm arookie on Enigma forum & i'm interested with this one.

@gitcoinbot
Copy link

gitcoinbot commented Jul 27, 2019

Issue Status: 1. Open 2. Started 3. Submitted 4. Done


Work has been started.

These users each claimed they can complete the work by 2 years, 4 months ago.
Please review their action plans below:

1) nionis has applied to start work (Funders only: approve worker | reject worker).

Hi, I'm Thảo Đinh (aka @arookie on Enigma forum), currently working as a backend engineer & be a Data enthusiast.
Recently I start working on ETH dev (Solidity & Rust) and also found Enigma for privacy solution.
I'm really interested in it.

Could you please let me join this program?
Thank you.
3) bshevchenko has been approved to start work.

Will do in a most accurate way :)

Learn more on the Gitcoin Issue Details page.

@gitcoinbot
Copy link

@bshevchenko Hello from Gitcoin Core - are you still working on this issue? Please submit a WIP PR or comment back within the next 3 days or you will be removed from this ticket and it will be returned to an ‘Open’ status. Please let us know if you have questions!

  • reminder (3 days)
  • escalation to mods (6 days)

Funders only: Snooze warnings for 1 day | 3 days | 5 days | 10 days | 100 days

1 similar comment
@gitcoinbot
Copy link

@bshevchenko Hello from Gitcoin Core - are you still working on this issue? Please submit a WIP PR or comment back within the next 3 days or you will be removed from this ticket and it will be returned to an ‘Open’ status. Please let us know if you have questions!

  • reminder (3 days)
  • escalation to mods (6 days)

Funders only: Snooze warnings for 1 day | 3 days | 5 days | 10 days | 100 days

@bshevchenko
Copy link

@gitcoinbot https://github.com/bshevchenko/enigma-data-validation it's done
just need some gas to submit work via gitcoin
contacted @ainsleys

@bshevchenko
Copy link

Contract compares submitted dataset with the previous one.
Frontend is based on discovery CLI preset and article, but little bit refined.

@bshevchenko
Copy link

The reason why there is no list of datasets is the same as why we are not notifying user A – smart contract or some other storage is needed for that, that would serve data and push notification to subscribed user A. This was discussed with @ainsleys couple of days ago

@gitcoinbot
Copy link

Issue Status: 1. Open 2. Started 3. Submitted 4. Done


Work for 900.0 ENG (418.77 USD @ $0.47/ENG) has been submitted by:

  1. @bshevchenko

@ainsleys please take a look at the submitted work:


@gitcoinbot
Copy link

Issue Status: 1. Open 2. Started 3. Submitted 4. Done


The funding of 900.0 ENG (418.77 USD @ $0.47/ENG) attached to this issue has been approved & issued to @bshevchenko.

@ainsleys
Copy link
Contributor Author

This bounty is close now! Thanks everyone who applied (please keep an eye out for new bounties coming soon), and to @bshevchenko for the quick turnaround.

We'll also be open-sourcing this completed bounty shortly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants