mirror of https://github.com/nucypher/nucypher.git
More detailed steps, ehnaced warnings, formatting, and innacuracy corrections for demos, guides.
parent
56ec2f2c53
commit
ba24cdb622
|
@ -1,29 +0,0 @@
|
|||
# Finnegan's Wake Demo
|
||||
|
||||
## Overview
|
||||
|
||||
This demo is an example of a NuCypher decentralized network allowing Alice to share
|
||||
data with Bob using proxy re-encryption. This enables the private sharing of data between
|
||||
participants in public consensus networks, without revealing data keys to intermediary entities.
|
||||
|
||||
|Step|Character|Operation |
|
||||
|----|---------|---------------------------------------------------------------------------------------------|
|
||||
|1 |Alice |Alice sets a Policy on the NuCypher network (2/3) and grants access to Bob |
|
||||
|2 |Alice |Label and Alice's key public key provided to Bob |
|
||||
|4 |Bob |Bob joins the policy with Label and Alice's public key |
|
||||
|5 |Enrico |DataSource created for the policy |
|
||||
|6 |Enrico |Each plaintext message gets encapsulated through the DataSource to messageKit |
|
||||
|5 |Bob |Bob receives and reconstructs the DataSource from Policy public key and DataSource public key|
|
||||
|6 |Bob |Bob retrieves the original message form DataSource and MessageKit |
|
||||
|
||||
|
||||
## 1. Install Nucypher
|
||||
|
||||
Acquire the nucypher application code and install the dependencies;
|
||||
For a full installation guide see the [NuCypher Installation Guide](../guides/installation_guide)
|
||||
|
||||
## 2. Download the Book Text
|
||||
`./download_finnegans_wake.sh`
|
||||
|
||||
## 3. Run the Demo
|
||||
`python3 finnegans-wake-concise-demo.py`
|
|
@ -0,0 +1,55 @@
|
|||
Finnegan's Wake Demo
|
||||
====================
|
||||
|
||||
.. figure:: https://cdn-images-1.medium.com/max/600/0*b42NPOnflrY07rEf.jpg
|
||||
:width: 100%
|
||||
|
||||
Overview
|
||||
--------
|
||||
|
||||
.. important::
|
||||
|
||||
This demo requires knowledge of a running network. By default the demo is hardcoded to connect to the local demo fleet.
|
||||
|
||||
|
||||
This demo is an example of a NuCypher decentralized network allowing Alice to share
|
||||
data with Bob using proxy re-encryption. This enables the private sharing of data between
|
||||
participants in public consensus networks, without revealing data keys to intermediary entities.
|
||||
|
||||
|
||||
+------+-----------+----------------------------------------------------------------------------------------------+
|
||||
| Step | Character | Operation |
|
||||
+======+===========+==============================================================================================+
|
||||
| 1 | Alice | Alice sets a Policy on the NuCypher network (2/3) and grants access to Bob |
|
||||
+------+-----------+----------------------------------------------------------------------------------------------+
|
||||
| 2 | Alice | Label and Alice's key public key provided to Bob |
|
||||
+------+-----------+----------------------------------------------------------------------------------------------+
|
||||
| 4 | Bob | Bob joins the policy with Label and Alice's public key |
|
||||
+------+-----------+----------------------------------------------------------------------------------------------+
|
||||
| 5 | Enrico | DataSource created for the policy |
|
||||
+------+-----------+----------------------------------------------------------------------------------------------+
|
||||
| 6 | Enrico | Each plaintext message gets encapsulated through the DataSource to messageKit |
|
||||
+------+-----------+----------------------------------------------------------------------------------------------+
|
||||
| 5 | Bob | Bob receives and reconstructs the DataSource from Policy public key and DataSource public key|
|
||||
+------+-----------+----------------------------------------------------------------------------------------------+
|
||||
| 6 | Bob | Bob retrieves the original message form DataSource and MessageKit |
|
||||
+------+-----------+----------------------------------------------------------------------------------------------+
|
||||
|
||||
|
||||
Install Nucypher
|
||||
----------------
|
||||
|
||||
Acquire the nucypher application code and install the dependencies;
|
||||
For a full installation guide see the [NuCypher Installation Guide](../guides/installation_guide)
|
||||
|
||||
Download the Book Text
|
||||
----------------------
|
||||
For your convienence we have provided a bash script to acquire the "Finnegan's Wake" text; However,
|
||||
feel free to use any text of your choice, as long you you edit the demo code accordingly.
|
||||
|
||||
To run the script: `./download_finnegans_wake.sh`
|
||||
|
||||
3. Run the Demo
|
||||
---------------
|
||||
|
||||
After acquiring a text file to re-encrypt, execute the demo by running: `python3 finnegans-wake-demo.py`
|
|
@ -1,8 +1,11 @@
|
|||
# Local Development Fleet Testing
|
||||
|
||||

|
||||
|
||||
## Overview
|
||||
|
||||
*Note: Currently only "Federated Only" mode is supported for local fleets*
|
||||
``` note:: Currently only "Federated Only" mode is supported for local fleets
|
||||
```
|
||||
|
||||
All Demo Ursulas:
|
||||
* Run on `localhost`
|
||||
|
@ -34,7 +37,7 @@ Next, launch subsequent Ursulas, informing them of the first Ursula:
|
|||
|
||||
`$ python run_demo_ursula_fleet.py`
|
||||
|
||||
This will run 5 temporary Ursulas:
|
||||
This will run 5 temporary Ursulas that:
|
||||
* All specify the lonely Ursula as a seednode
|
||||
* Run on ports `11501` through `11506`
|
||||
|
||||
|
@ -45,13 +48,21 @@ For this we provide the optional script `run_single_demo_ursula.py` for your con
|
|||
|
||||
`$ python run_single_demo_ursula.py`
|
||||
|
||||
This will run a single temporary Ursulas:
|
||||
* Specifies a random fleet node as a teacher
|
||||
This will run a single temporary Ursula:
|
||||
* That specifies a random fleet node as a teacher
|
||||
* On a random available port
|
||||
|
||||
## Connecting the the Local Fleet
|
||||
## Connecting to the Local Fleet
|
||||
|
||||
Alternately, you can connect any node run from the CLI by specifying one of the nodes
|
||||
in the local fleet as a teacher, the same network domain, and the same operating mode:
|
||||
in the local fleet as a teacher, the same network domain, and the same operating mode,
|
||||
by default nodes started with the `--dev` flag run on a dedicated domain (`TEMPORARY_DOMAIN`) and
|
||||
on a different port then the production default port (`9151`).
|
||||
Local fleet Ursulas range from ports `11500` to `11506` by default.
|
||||
|
||||
Here is an example of connecting to a node in the local development fleet:
|
||||
|
||||
`nucypher ursula run --dev --teacher-uri localhost:11501`
|
||||
|
||||
``` note:: The local development fleet is an *example* meant to demonstrate how to design and use your own local fleet.
|
||||
```
|
||||
|
|
|
@ -10,6 +10,7 @@
|
|||
|
||||
There are several test implementations in `nucypher`; However, the vast majority
|
||||
of test are written for execution with `pytest`.
|
||||
For more details see the [Pytest Documentation](https://docs.pytest.org/en/latest/)
|
||||
|
||||
To run the tests:
|
||||
|
||||
|
@ -23,10 +24,9 @@ Optionally, to run the full, slow, verbose test suite run:
|
|||
(nucypher)$ pytest --runslow -s
|
||||
```
|
||||
|
||||
|
||||
## Building Documentation
|
||||
|
||||
``` note:: 'spinx', 'recommonmark', and 'sphinx_rtd_theme' are non-stantdard dependencies that need to be installed as part the development installation or independently in order to build documentation.
|
||||
``` note:: 'spinx', 'recommonmark', and 'sphinx_rtd_theme' are non-stantdard dependencies that be installed by running 'pip install -e .[docs]' from the project directory.
|
||||
```
|
||||
|
||||
Documentation for `nucypher` is hosted on Read The Docs, and it automatically built without intervention by following the release procedure.
|
||||
|
@ -39,6 +39,9 @@ To build the project dependencies locally:
|
|||
(nucypher)$ make html
|
||||
```
|
||||
|
||||
If the build is successful, the resulting html output can be found in `nucypher/docs/build/html`;
|
||||
Opening `nucypher/docs/build/html/index.html` in a web browser is a reasonable next step.
|
||||
|
||||
|
||||
## Building Docker
|
||||
|
||||
|
@ -53,9 +56,9 @@ We provide both a `docker-compose.yml` and a `Dockerfile` which can be used as f
|
|||
(nucypher)$ docker-compose -f deploy/docker/docker-compose.yml build .
|
||||
```
|
||||
|
||||
## Issuing a New Release with `bumpversion`
|
||||
## Issuing a New Release
|
||||
|
||||
``` note:: 'bumpversion' is a non-stantdard dependency that may need to be installed as part the development installation or independently in order to issue a release.
|
||||
``` note:: 'bumpversion' is a non-stantdard dependency that can be installed by running 'pip install -e .[deployment]' or 'pip install bumpversion'.
|
||||
```
|
||||
|
||||
1. Ensure your local tree has no uncommitted changes
|
||||
|
|
|
@ -12,7 +12,7 @@ Before getting started, please note:
|
|||
* NuFT transmits application errors and crash reports to NuCypher’s sentry server. This functionality is enabled by default for NuFT only and will be deactivated by default for mainnet.
|
||||
|
||||
|
||||
``` warning:: WARNING The “NuCypher Federated Testnet” (NuFT) is an experimental pre-release of nucypher. Expect bugs, downtime, and unannounced domain-wide restarts. NuFT nodes do not connect to any blockchain. Do not perform transactions on NuFT node addresses.
|
||||
``` warning:: WARNING The “NuCypher Federated Testnet” (NuFT) is an experimental pre-release of nucypher. Expect bugs, downtime, and unannounced domain-wide restarts. NuFT nodes do not connect to any blockchain. **DO NOT** perform transactions using NuFT node addresses.
|
||||
```
|
||||
|
||||
``` important:: Exiting the setup process prior to completion may lead to issues/bugs. If you encounter issues, report feedback by opening an Issue on our GitHub (<https://github.com/nucypher/nucypher/issues>)
|
||||
|
@ -226,12 +226,17 @@ See the *“System Service Method”* section below.
|
|||
```bash
|
||||
$ sudo systemctl restart ursula
|
||||
```
|
||||
|
||||
|
||||
|
||||
## Updating a NuFT Node
|
||||
|
||||
Since Nucypher is under active development, you can expect frequent code changes to occur as bugs are discovered and code fixes are submitted. As a result, Ursula nodes will need to be frequently updated to use the most up-to-date version of the application code. The steps to update an Ursula running on NuFT are as follows and depends on the type of installation that was employed:
|
||||
Nucypher is under active development, you can expect frequent code changes to occur as bugs are
|
||||
discovered and code fixes are submitted. As a result, Ursula nodes will need to be frequently updated
|
||||
to use the most up-to-date version of the application code.
|
||||
|
||||
``` important:: The steps to update an Ursula running on NuFT are as follows and depends on the type of installation that was employed.
|
||||
```
|
||||
|
||||
|
||||
1. Stop the node
|
||||
|
||||
|
@ -276,4 +281,3 @@ Since Nucypher is under active development, you can expect frequent code changes
|
|||
```bash
|
||||
$ sudo systemctl start ursula
|
||||
```
|
||||
|
||||
|
|
|
@ -4,12 +4,12 @@
|
|||
## System Requirements
|
||||
|
||||
* At least 1 GB or RAM is required for key derivation functionality (SCrypt).
|
||||
* We have tested `nucypher` with windows, mac OS, and linux.
|
||||
* We have tested `nucypher` with windows, mac OS, and linux (Linux is recommended).
|
||||
|
||||
|
||||
## System Dependencies
|
||||
|
||||
If you don’t already have them, install Python;.
|
||||
If you don’t already have it, install Python;.
|
||||
As of January 2019, we are working with Python 3.6, 3.7, and 3.8.
|
||||
|
||||
* Official Python Website: <https://www.python.org/downloads/>
|
||||
|
@ -109,6 +109,7 @@ Here is the recommended procedure for setting up `nucypher` in this fashion:
|
|||
Additional dependencies and setup steps are required to perform a "developer installation".
|
||||
Ensure you have `git` installed ([Git Documentation](https://git-scm.com/doc)).
|
||||
|
||||
|
||||
### Acquire NuCypher Codebase
|
||||
|
||||
```
|
||||
|
@ -145,7 +146,7 @@ $(nucypher) pipenv run install-solc
|
|||
Alternately, you can install the development dependencies with pip:
|
||||
|
||||
```bash
|
||||
$ pip install -e .[testing]
|
||||
$ pip install -e .[development]
|
||||
$ ./scripts/install_solc.sh
|
||||
```
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
### Install NuCypher
|
||||
|
||||
```bash
|
||||
$ pip install nucypher
|
||||
$ pip3 install -U nucypher
|
||||
```
|
||||
|
||||
### Run a Federated-Only Development Ursula
|
||||
|
@ -14,6 +14,21 @@ $ pip install nucypher
|
|||
$ nucypher ursula run --dev --federated-only
|
||||
```
|
||||
|
||||
### Configure a Persistent Ursula
|
||||
|
||||
```bash
|
||||
$ nucypher ursula init --federated-only
|
||||
```
|
||||
|
||||
### Run a Persistent Ursula
|
||||
|
||||
```bash
|
||||
$ nucypher ursula run --teacher-uri <SEEDNODE_URI> --federated-only
|
||||
```
|
||||
|
||||
Replace `<SEEDNODE_URI>` with the URI of a node running on the network and domain you want
|
||||
to connect to (for example `0.0.0.0:9151` or `0xdeadbeef@0.0.0.0:9151`).
|
||||
|
||||
### Run a Geth-Connected Development Ursula
|
||||
|
||||
Run a local geth node in development mode:
|
||||
|
@ -29,8 +44,3 @@ $ nucypher ursula run --dev --provider-uri /tmp/geth.ipc --checksum-address <GET
|
|||
```
|
||||
|
||||
Replace `<GETH_ADDRESS>` with the geth node's public checksum address.
|
||||
|
||||
|
||||
## Alice
|
||||
|
||||
## Bob
|
||||
|
|
Loading…
Reference in New Issue