Code Monkey home page Code Monkey logo

ulcdocumentswebapp's Introduction

ULCDocuments Web Application

ULCDocuments logo

ULCDocuments is a free and open source project aimed at giving everyone a tool to sign all type of files permanently on the Ethereum Blockchain.

ULC is the acronym for Ultra Low Cost, because signing documents on the blockchain is very cheap.

We can separate the project into two parts:

  • The Blockchain App which handles the blockchain.
  • The Web App, which is an implementation made in javascript to use the Blockchain App.

Table of Contents:

What is Inside this Repo?

In this repo you will find the source code for the Web App which communicates with the Blockchain App. The Blockchain App is currently closed source, and its source code will be released when we reach a stable Web App version.

However, a beta version of the ABI files (which handle communication with the blockchain smart contracts) is available in the ULCDocuments/docs/js/abi folder.

How it Works

This app uses two main Smart Contracts: The Kernel and the Moderator.

The Smart Contract documentation is available here.

  • To be able to sign documents, you must own a Kernel. The Kernel is the address where your signatures are stored. It is the main part of the Blockchain Application. It handles multi-operator signing, multi-owner administration and so on. Every moral/physical person can have his own Kernel.

  • If users want to check a signature, they must connect to the signatory's Kernel address.

  • After creating your Kernel, you can then choose to be referenced on a Moderator. This Moderator will then be able to certify your kernel's identity to users connecting to it. Otherwise, users will only see your Kernel address.

For security reason, it is safer to only use Kernels that are registered on a trustworthy Moderator (such as the Blockchain-Elite Moderator on Ropsten Testnet, which is configured by default on the web app).

Warning! Because we are in beta, the default moderator address might change over time. But don't worry, the Web App will be updated to take into account those changes.

Setup & Configuration

Connection to a Kernel

Manual

  • Go to https://ulcdocuments.blockchain-elite.fr/ (This repo Github page).
  • Click on the Check button
  • Enter the Ethereum Address of the Kernel you want to connect to in the Kernel Connection section.
  • Press connect and wait.

Automatic

Once you are connected to a Kernel, you can save the page in a bookmark, or send the link to someone. Clicking the link will connect you automatically to the Kernel.

The Kernel address is stored in the kernel url parameter as follows:

ulcdocuments.blockchain-elite.fr/ulcdoc_interactor.html/#kernel:[ADDRESS].

Setup Signing

!!! WARNING : THIS APP IS STILL IN EARLY BETA. DO NOT USE IT ON MAINNET !!!

To be able to sign, you must first:

  • Have Metamask installed and configured on your browser (make sure you are connected to the Ropsten network), or use Dapp compatible browser like Mist.
  • Be the owner of a Kernel.

Smart Contracts are not open source yet. To be able to participate in the beta, please fill this form in order to get a free Kernel.

Usage

Checking Signatures

First, make sure you are connected to a Kernel.

You can check for Files, Raw text or directly hashes.

Files

  • Simply Drag & Drop the file you want to check on the File tab, or click the import button.
  • Click on the Check button, and wait for the results.

Raw Text

  • Go on the Text tab and click on "+".
  • Write your text.
  • Click on the Check button, and wait for the results.

Hashes

  • Hash manually your document with correct hash algorithm (SHA3-256 by default).
  • Go on the Hash tab and click on "+".
  • Paste your hash without the "0x" prefix if you have one.
  • Click on the Check button, and wait for the results.

You can also check several items at the same item.

Note : you can click on an element's card to display more information, provided by the Blockchain (available after checking) or simply basic file information (size, type, etc...)

Signing Documents

!!! WARNING : THIS APP IS STILL IN EARLY BETA. DO NOT USE IT ON MAINNET !!!

First, make sure you followed the setup procedure.

  • Launch the Web App on sign mode by clicking on the Sign button in the Homepage or simply reconnect to the kernel and check the Enable Sign Mode checkbox.
  • Make sure you are on the Sign a Document tab.
  • Import documents, write text or paste a hash like you would do on Check Mode.
  • Click on the Fetch button. This will check if the documents can be signed (Verifies it they are not already signed, have a signature pending, etc.).
  • Fill in information about the documents by clicking on them if you wish to. These information will be displayed each time a user checks this document.
  • When you are ready, click on the Sign button. This will create blockchain transactions and you will be prompted to accept them through your Ethereum connector (Metamask or others).

Contribute to the Project

This project is Open Source, this means you can help in its development by reporting bugs or requesting new features by creating a new Issue.

Who is Behind the Project?

ULCDocuments is developed as a Blockchain Elite Labs project. The goal of those projects is to create Open Source tools using the Blockchain technology, to promote practical blockchain public applications, as well as promoting Blockchain-Elite know-how.

Licenses

ULCDocuments has a license for the Web App, and an other one for the ABI files (which can be used in other projects):

ulcdocumentswebapp's People

Contributors

keplyx avatar theadri1900 avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

ulcdocumentswebapp's Issues

[BUG] [SIGN] Interactions allowed after accepted transaction

Describe the bug

After accepting transaction to sign document, at "pending" state. You can interact with UI with "fetch", "cancel".

To Reproduce
Steps to reproduce the behavior:

  1. Sign one document
  2. Accept metamask transaction
  3. You can use fetch again and delete documents pending, and so on

Expected behavior
Lock completely sign UI until all document signed callback

[FEATURE] [IMPORTANT] Network selection in GET URL

Is your feature request related to a problem? Please describe.

We can't select the network to connect with the autoconnect URL

Describe the solution you'd like
add "network" variable.

/ulcdoc_interactor.html#network:1&mode:check&kernel:0x99

If the user doesn't have metamask, configure web3 to connect to the right network.
If the user has metamask, you need to check if metamask network = configurated network. If not, then promp a message to say it's the wrong network.

Network:
1 = mainnet
2 = ropsten

if not provided :
Check in which network the smart contract exists.
If on both networks: then promp a message to choose.

Print hash type

When you see hash result of elements, we need to specify which hash algorithm lead to this result.
Need also to see hash algorithm on "hash" tab in check/sign mode !
The hash algorithm is set in the smart contract.

TODO :

  • Create getter for that info [BC related]
  • Adapt UI [UI related]

[FEATURE] Warn if used in mainnet

Is your feature request related to a problem? Please describe.
For the moment, the application is in beta, and can contains bugs. It is not safe at all to use it on mainnet for the moment.

Describe the solution you'd like
Add a BIG warn if user connected on mainnet and explain why.

[FEATURE] Add a share button for kernel

Is your feature request related to a problem? Please describe.
It may be difficult for some users to share an automatic connection link

Describe the solution you'd like
A button to copy in clipboard a sharable link to autoconnect to kernel

[FEATURE] Add a recent connections selection

Is your feature request related to a problem? Please describe.
Addresses are hard to remember.

Describe the solution you'd like
We should have recently used addresses shown somewhere in the UI.
The data could be saved as cache in a JSON format, saving the kernel address, the moderator address, and the kernel name on this moderator.

Bad title for Ropsten Blockchain-Élite Mod

Describe the bug
The name when loading default ropsten blockchain elite moderator is wrong.

Expected behavior
"Currently connected to Blockchain Élite ULCDocuments Ropsten"

For the moment it's "Currently connected to Blockchain Élite ULCDocuments Official", but in fact, when on testnet, things aren't official.

[enhancement] Make larger input text field

Is your feature request related to a problem? Please describe.
When we want to write long text to check, the only 2.5 displayable lines are too small to see text correctly and we have to manually make the textbox larger.

Describe the solution you'd like
Please make default displayable line up to at least 5 and make auto-resizing automatic so when you paste code you can see it completely with one clic.

Distinguish "Hashing file" and "Asking Blockchain"

For the moment :

If you want to check a file or fetch, UI only print "asking blockchain" info. In fact, there is two different step :

  1. Hashing element, which can even freeze app
  2. Asking blockchain

For more precise info purpose, we need to distinguish theses 2 process.

[FEATURE] Add multi-hash and multi-text import support

Is your feature request related to a problem? Please describe.
You can't import multiple hash or multiple text on the app like you can import multiple file. So, if you have like 50 texts to sign, it is very long to copy paste one by one.

Describe the solution you'd like
Let the possibility for user to import multiple-hash with a special file like CSV :
"hash", "DocType", "source", "extra:data"

For text, let possibility to import .txt file.

Plus, find a solution to apply multiple same properties to multiple file like make all files "DocumentType=Diploma".

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.