All Projects → scrtlabs → enigma-docker-network-deprecated

scrtlabs / enigma-docker-network-deprecated

Licence: AGPL-3.0 license
A containarized Enigma Protocol environment to start writing secret contracts

Programming Languages

shell
77523 projects
Dockerfile
14818 projects

Projects that are alternatives of or similar to enigma-docker-network-deprecated

discovery-cli
Command Line Interface (CLI) for the Discovery Enigma Protocol developer testnet
Stars: ✭ 12 (-76%)
Mutual labels:  enigma, secret-contracts
SecretNetwork
𝕊 The Secret Network
Stars: ✭ 466 (+832%)
Mutual labels:  enigma, secret-contracts
ultimate-defi-research-base
Here we collect and discuss the best DeFI & Blockchain researches and tools. Feel free to DM me on Twitter or open pool request.
Stars: ✭ 1,074 (+2048%)
Mutual labels:  smart-contracts
hi-blockchain
Awesome blockchain resources
Stars: ✭ 14 (-72%)
Mutual labels:  smart-contracts
colonySale
Colony Token and Crowdsale Contracts
Stars: ✭ 27 (-46%)
Mutual labels:  smart-contracts
FranklinPay-iOS
Secure Dollar Wallet
Stars: ✭ 35 (-30%)
Mutual labels:  smart-contracts
flora
A distributed smart contract package manager to create a better and shared authority in the space.
Stars: ✭ 19 (-62%)
Mutual labels:  smart-contracts
LNPBPs
LNP/BP standards for bitcoin layer 2 & 3 protocols
Stars: ✭ 158 (+216%)
Mutual labels:  smart-contracts
rICO-smart-contracts
Smart contracts for the Reversible ICO (rICO)
Stars: ✭ 38 (-24%)
Mutual labels:  smart-contracts
oasis-sdk
Official SDK for the Oasis Network.
Stars: ✭ 57 (+14%)
Mutual labels:  smart-contracts
eosgo-client
A simple Go wrapper of EOS (eosio) RPC API, and more!
Stars: ✭ 29 (-42%)
Mutual labels:  smart-contracts
t3rn
Composable smart contract hosting with fail-safe interoperable execution
Stars: ✭ 118 (+136%)
Mutual labels:  smart-contracts
luckydog
luckydog(锦鲤) 一个幸运小游戏
Stars: ✭ 14 (-72%)
Mutual labels:  smart-contracts
Solidity
Smart Contracts - Solidity
Stars: ✭ 122 (+144%)
Mutual labels:  smart-contracts
polar
Polar is a development environment to compile, deploy, test, run scrt contracts on different networks.
Stars: ✭ 34 (-32%)
Mutual labels:  smart-contracts
MCW-Azure-Blockchain
MCW Azure Blockchain
Stars: ✭ 35 (-30%)
Mutual labels:  smart-contracts
useWeb3
useWeb3 provides a curated overview of the best and latest resources on Ethereum, blockchain and Web3 development.
Stars: ✭ 325 (+550%)
Mutual labels:  smart-contracts
iot-device-management
Leveraging Ethereum blockchain platform for identity, authentication and reputation of IoT devices
Stars: ✭ 84 (+68%)
Mutual labels:  smart-contracts
react-truffle-metamask
Build an DApp using react, redux, saga, truffle, metamask
Stars: ✭ 25 (-50%)
Mutual labels:  smart-contracts
gas-reporting
Reference documentation on every gas price API and all the different formats
Stars: ✭ 85 (+70%)
Mutual labels:  smart-contracts

This repository has been deprecated in favor of a newer version available at https://github.com/enigmampc/discovery-docker-network/

Enigma Docker Network

The Enigma Docker Network is the first release of the Enigma Protocol in a containerized environment that offers a complete minimum viable test network (testnet). This release is aimed at developers to familiarize themselves with the unique and powerful features that the Enigma Protocol offers, and to provide a sandbox to start writing secret contracts.

For more information, please refer to the Enigma Protocol Documentation.

Requirements

  • Docker
  • Docker Compose version 1.23.2 or higher. Please be aware that docker introduced a bug in 1.23.0 (also present in 1.23.1) that appended random strings to container names that causes this network configuration to break.

If you want to run SGX in hardware mode, in the same way it will be run in production, you will also need:

  • A host machine with Intel Software Guard Extensions (SGX) enabled.

    • The SGX hardware repository provides a list of hardware that supports Intel SGX, as well as a simple script to check if SGX is enabled on your system.
  • A host machine with Linux SGX driver installed. Upon successful installation of the driver /dev/isgx should be present in the system.

However, for development purposes, the Enigma Docker Network can be run in simulation (or software mode), where no specialized hardware is required.

Dependencies

  • Core: The Core component as it's name suggests is responsible for the operations at the core of the network, that is the code that runs inside the SGX enclave. The core includes Remote Attestation (SGX SDK), Cryptography and the Blockchain Virtual Machine (VM).
  • Enigma's SputnikVM: The Enigma's Virtual Machine that runs inside SGX is a fork from the SputnikVM, an implementation of an Ethereum Virtual Machine that aims to be an efficient, pluggable virtual machine for different Ethereum-based blockchains. Enigma's VM differentiating features is that can run inside SGX, and that it does not have access to the global state.
  • Surface: The Surface component is responsible for operations that are outside of SGX, acting as a bridge between the outside world and the "Core" component.
  • Enigma Contract: The Enigma Contract component holds all the business logic of the Enigma network in Ethereum smart contracts.

SGX Modes

Mode Description
Hardware This is the default mode, in which the core runs inside the SGX enclave. The host machine needs to support SGX, and have the SGX driver installed.
Software Also known as Simulation Mode, allows for development in host machines that do not support SGX.

Network Modes

Mode Description Limitations
Standard This is the default or normal mode to run the enigma network, in which containers are launched for each of the services in the network, and privacy-preserving computations are run by the network when requested. Docker images for each service in the network are streamlined and kept to a minimum (albeit not small in some cases). You can attach to any container in the network and inspect it, but it becomes impractical to do anything more, and doing any development in this mode becomes cumbersome.
Development This is the development version geared for developers of secret contracts. All services are run as docker containers: core and surface are run the same way as in standard mode, but contract is pulled from a local folder, thus providing convenient access to modify code that can be immediately picked up by the network for active development.

Usage

After cloning this repository, launch the Enigma Docker Network by running:

$ ./launch.bash

This script accepts a number of parameters to configure the different modes available:

Usage:
  ./launch.bash [-t] [-d] [-h] [-s] [-q]

Options:
  -d    Run in development mode.
  -h    Show this help.
  -t    Spawn a terminal for every container/process.
  -q    Stops Enigma Docker Network and removes containers.
  -s    Run in simulation mode.

Options explained

Any of the following options can be combined with one another:

  • -d Runs in the Network Mode: development. You need to edit the .env file, and configure GIT_FOLDER_CONTRACT to point to your local copy of a valid Enigma contract repository. If you are interested in developing your own secret contracts, it is highly recommended you use this flag for your development.

  • -t Runs the Enigma Network and spawns a terminal for every container/process for greater clarity. You need to have xterm installed. Comes by default in Linux distributions. In MacOS, you need to install XQuartz. It is recommended to run the Enigma Docker Network with this flag.

  • -s Runs the Enigma Network in simulation mode, where your host machine does not need to have hardware support for SGX. This is also called software mode, as SGX is simulated in software instead of being run in the actual hardware.

You can spawn additional core+surface pairs by running (where N is the desired total number of pairs, for example N=2 will spawn one additional core+surface pair):

$ ./spawn_terminals.bash N

Stop the network by running:

$ ./launch.bash -q

License

The Enigma Docker Network is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.

You should have received a copy of the GNU Affero General Public License along with this program. If not, see https://www.gnu.org/licenses/.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].