Code Monkey home page Code Monkey logo

fxc's Introduction

FXC Simple Secret Sharing

software by Dyne.org

Build Status

Code Climate

Clojars Project

The "FXC" cryptographic protocol is used to split a secret string in multiple parts and to recover it using some of these parts (quorum). An functional application demonstrating its functionality is available at secrets.dyne.org

Simple Secret Sharing is fun

The FXC protocol and its use case (mostly related to social digital currency) are explained in this document Implementation of digital social currency infrastructure (D5.5) produced as part of the research conducted in the D-CENT project.

Usage

(require 'fxc.core)
(def secret (fxc.core/generate :url 32))
(def shares (fxc.core/encode fxc.core/settings secret))
(fxc.core/decode fxc.core/settings shares)

Default configuration settings:

{:salt "La gatta sul tetto che scotta",
 :description "FXC v1 (Simple Secret Sharing, Freecoin component)",
 :protocol "FXC1", :alphabet "ABCDEFGHJKLMNPQRSTUVWXYZ23456789",
 :quorum 3,
 :prime prime4096,
 :type "WEB",
 :total 5,
 :max 1024,
 :length 6,
 :entropy 3.1}

Public functions:

  • Encode
fxc.core/encode
([conf pass])
  Takes a string and returns multiple strings that can be used to
  retrieve the original according to settings.
  • Decode
fxc.core/decode
([conf slices])
  Takes a collection of strings and returns the original secret
  according to the settings.
  • Generate
fxc.core/generate
([type size])
  Generates a random password of type and size. Available types
  are :bytes :base64 :base32 :hex and :url

Acknowledgments

Haarlem's Alphabet textile, from a Vlisco exhibition

Industry standard addressed: Information technology -- Security techniques -- Secret sharing

The Secret Sharing algorithm adopted is based on Shamir's Secret Sharing, references:

  • Shamir, Adi (1979), "How to share a secret", Communications of the ACM 22 (11): 612โ€“613
  • Knuth, D. E. (1997), The Art of Computer Programming, II: Seminumerical Algorithms: 505

The implementation used is by Tim Tiemens with a 4096 cipher prime number. The Integer Compression algorithm used internally is the FastPFOR128 by Daniel Lemire, see: Lemire, D. and Boytsov, L. "Decoding billions of integers per second through vectorization" (2015).

License

FXC is Copyright (C) 2015-2019 by the Dyne.org Foundation

Designed, written and maintained by Denis Roio [email protected]

This project is licensed under the AGPL 3 License - see the LICENSE file for details

Additional permission under GNU AGPL version 3 section 7.

If you modify FXC, or any covered work, by linking or combining it with any library (or a modified version of that library), containing parts covered by the terms of EPL v 1.0, the licensors of this Program grant you additional permission to convey the resulting work. Your modified version must prominently offer all users interacting with it remotely through a computer network (if your version supports such interaction) an opportunity to receive the Corresponding Source of your version by providing access to the Corresponding Source from a network server at no charge, through some standard or customary means of facilitating copying of software. Corresponding Source for a non-source form of such a combination shall include the source code for the parts of the libraries (dependencies) covered by the terms of EPL v 1.0 used as well as that of the covered work.

fxc's People

Contributors

aspasia avatar jaromil avatar

Stargazers

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

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Forkers

gdassori vcgato29

fxc's Issues

Report faulty share not just general error

On failure to combine shares, there is no indication on which is the broken share (if only one).

An additional procedure may be triggered to try indicate which one is the faulty one, giving back more information to the user. If one share is faulty, the error can be isolated by changing the system to hold an extra share server-side and use it through a cycle of retries. If more than one share is faulty then the specific share cannot be isolated. Or there may be more strategies for this?

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.