mirror of https://github.com/lukechilds/docs.git
moxiegirl
6 years ago
37 changed files with 130 additions and 1698 deletions
@ -1,156 +0,0 @@ |
|||
# Glossary |
|||
|
|||
Commonly used terms and jargon in Blockstack |
|||
|
|||
## Account |
|||
|
|||
A field in a profile that links the name to an existing service, like Twitter or OpenBazaar. They are listed under the `accounts` listing in a profile. |
|||
|
|||
Some accounts serve as social proofs, but they can contain any data the user wants. |
|||
|
|||
## Atlas |
|||
|
|||
A peer-to-peer network maintained by Blockstack Core nodes that stores each |
|||
name's zone files and immutable data. See [this document]({{ site.baseurl }}/atlas/overview.html) for |
|||
details. |
|||
|
|||
## Blockstack ID |
|||
|
|||
(Also called a "name"). |
|||
|
|||
A human-readable name in Blockstack. It is comprised only of upper and lower-case ASCII characters, numbers, as well as `-`, `_`, and `.`. It must end with a `.`, followed by a namespace ID. It has at least 3 characters, and at most 37 (including the `.` and the namespace ID). |
|||
|
|||
Anyone can register a Blockstack ID, such as through the [Blockstack Browser](https://github.com/blockstack/blockstack-browser) |
|||
|
|||
## Blockstack Core |
|||
|
|||
A server that reads a blockchain with [virtualchain](https://github.com/blockstack/blockstack-virtualchain), filters out transactions that represent name operations, and builds up a database of (name, public key, state value) triples. |
|||
|
|||
## Blockstack Naming Service (BNS) |
|||
|
|||
This is the naming protocol that Blockstack Core implements. See [this |
|||
document]({{ site.baseurl }}/core/naming/introduction.html) for details. |
|||
|
|||
## Consensus Hash |
|||
|
|||
A cryptographic hash that represents a proof-of-computation by a Blockstack Core node. Two Blockstack Core nodes have seen and processed the same name operations up to block `n` if and only if they each calculate the same consensus hash at height `n`. |
|||
|
|||
A Blockstack Core node only accepts a name operation if it has a previously-calculated but recent consensus hash. Blockstack clients obtain a consensus hash from a Blockstack Core node in order to construct a name operation. |
|||
|
|||
## Gaia |
|||
|
|||
This is Blockstack's storage system. Gaia hosts all of your app-specific data. |
|||
|
|||
## Gaia Hub |
|||
|
|||
This is a publicly-routable server that serves as an entry point for Gaia data. |
|||
Anyone can stand up and run a Gaia hub by following [these |
|||
instructions](https://github.com/blockstack/gaia). |
|||
Blockstack provides a [default Gaia hub](https://gaia.blockstack.org). |
|||
|
|||
## Immutable Data |
|||
|
|||
This is the general term for chunks of data whose hash is cryptographically |
|||
bound to a blockchain transaction. This includes all data stored in the Atlas |
|||
network (such as your Blockstack ID's zone file), |
|||
as well as any data whose hash is stored in the Atlas network. |
|||
|
|||
## mnemonic |
|||
|
|||
A human-friendly representation of a seed. |
|||
|
|||
## Mutable Data |
|||
|
|||
This is the general term for data that is (1) signed by your Blockstack ID, and |
|||
(2) can be looked up using your Blockstack ID. This includes all your Gaia |
|||
data, as well as your profile. |
|||
|
|||
## Name |
|||
|
|||
See Blockstack ID. |
|||
|
|||
## Name Database |
|||
|
|||
The set of (name, public key, name state) triples that the Blockstack Core node generates by reading the blockchain. The name state is usually the hash of a DNS zone file stored in Atlas. |
|||
|
|||
## Name Operation |
|||
|
|||
A specially-crafted transaction in the underlying blockchain that, when processed, will change each Blockstack Core's name database. Examples include `NAME_PREORDER` (preorders a name), `NAME_REGISTRATION` (registers a name), `NAME_UPDATE` (changes a name's zonefile hash), `NAME_TRANSFER` (changes a name's public key), and `NAME_REVOKE` (locks everyone out of a name until it expires). |
|||
|
|||
Name operations are encoded on Bitcoin as `OP_RETURN` outputs that start with `id`, followed by a 1-byte character that identifies the particular operation. |
|||
|
|||
See the [wire format](wire-format.md) document for details. |
|||
|
|||
## Namespace |
|||
|
|||
Analogous to a DNS TLD, it represents a grouping of names. All names under the same namespace have the same pricing and lifetime rules. |
|||
|
|||
Anyone can create a namespace, but doing so is expensive by design. See the |
|||
[namespace creation]({{ site.baseurl }}/core/naming/tutorial_creation.html) tutorial for details. |
|||
|
|||
## Preorder |
|||
|
|||
The first of two steps to acquire a name. This operation writes the hash of both the name and the address that will own it. |
|||
|
|||
## Profile |
|||
|
|||
A signed JSON web token that describes a [Person](https://schema.org/Person), which describes the name's owner. You can put anything you want into your profile. |
|||
|
|||
Additionally, profiles hold lists of social verifications and pointers to your Gaia data. |
|||
|
|||
## Register |
|||
|
|||
(1) The act of acquiring a name in Blockstack. |
|||
|
|||
(2) The second of two steps to create a new name entry in the name database. Reveals the name as plaintext to the world. Must match a recent preorder to be accepted. |
|||
|
|||
## Registrar |
|||
|
|||
An online service that lets you sign up for and manage the profiles of Blockstack IDs. |
|||
|
|||
## Resolver |
|||
|
|||
An online service that displays zonefile and profile data for a Blockstack ID. [The Blockstack Explorer](https://explorer.blockstack.org) is a resolver. |
|||
|
|||
## Seed |
|||
|
|||
A 128 or 256 bits of random data used to generate a master public and privte key pair. |
|||
|
|||
## Social proof |
|||
|
|||
A post in an account on an existing Web service like Twitter, Facebook, or GitHub that points back to a Blockstack ID. Used to provide some evidence that the person who owns the Blockstack ID is also the person who owns the Web service account. |
|||
|
|||
Social proofs are listed in your profile. |
|||
|
|||
## Storage Provider |
|||
|
|||
This is any service that can serve your zone file, profile, or data. In all cases, the data is signed by one of your wallet's keys, so you can use any provider without having to worry about it trying to change the data. |
|||
|
|||
Storage providers are accessed through a Gaia hub. Gaia hubs ship with drivers |
|||
that allow them to treat storage providers as dumb hard drives, which store |
|||
signed encrypted data on the hub's behalf. |
|||
|
|||
Not all storage providers support writes--some of them are read-only. |
|||
|
|||
Supported storage providers today include: |
|||
* Amazon S3 |
|||
* Dropbox |
|||
* Your harddrive |
|||
* Any HTTP/HTTPS/FTP server (read-only) |
|||
* Any public-use Gaia hub |
|||
* IPFS |
|||
|
|||
Support is being added for: |
|||
* Google Drive |
|||
* Microsoft OneDrive |
|||
* Box.com |
|||
* BitTorrent |
|||
|
|||
If you have a preferred storage provider, and you're a developer, please consider sending us a pull request to add support for it! |
|||
|
|||
## Zone file |
|||
|
|||
A specially-formatted file that stores routing information for a Blockstack ID. |
|||
Blockstack clients use your zone file to find out where your preferred Gaia |
|||
hub(s) are. Ever Blockstack Core node stores a copy of every zone file for |
|||
every Blockstack ID by participating in the Atlas network. |
File diff suppressed because it is too large
@ -1,148 +0,0 @@ |
|||
## What is the Blockstack ecosystem |
|||
|
|||
In the Blockstack ecosystem, users control their data and apps run on their devices. There |
|||
are no middlemen, no passwords, no massive data silos to breach, and no services |
|||
tracking us around the internet. |
|||
|
|||
The applications on blockstack are server-less and decentralized. Developers |
|||
start by building a single-page application in Javascript, Then, instead of |
|||
plugging the frontend into a centralized API, they plug into an API run by the |
|||
user. Developers install a library called `blockstack.js` and don't have to |
|||
worry about running servers, maintaining databases, or building out user |
|||
management systems. |
|||
|
|||
Personal user APIs ship with the Blockstack app and handle everything from |
|||
identity and authentication to data storage. Applications can request |
|||
permissions from users and then gain read and write access to user resources. |
|||
|
|||
Data storage is simple and reliable and uses existing cloud infrastructure. |
|||
Users connect with their Dropbox, Google Drive, S3, etc... and data is synced |
|||
from their local device up to their cloud. |
|||
|
|||
Identity is user-controlled and utilizes the blockchain for secure management of |
|||
keys, devices and usernames. When users login with apps, they are anonymous by |
|||
default and use an app-specific key, but their full identity can be revealed and |
|||
proven at any time. Keys are for signing and encryption and can be changed as |
|||
devices need to be added or removed. |
|||
|
|||
Under the hood, Blockstack provides a decentralized domain name system (DNS), |
|||
decentralized public key distribution system, and registry for apps and user |
|||
identities. |
|||
|
|||
## What problems does Blockstack solve? |
|||
|
|||
Developers can now build Web applications where: |
|||
|
|||
- you own your data, not the application |
|||
- you control where your data is stored |
|||
- you control who can access your data |
|||
|
|||
Developers can now build Web applications where: |
|||
|
|||
- you don't have to deal with passwords |
|||
- you don't have to host everyone's data |
|||
- you don't have to run app-specific servers |
|||
|
|||
Right now, Web application users are "digital serfs" and applications are the "digital landlords". Users don't own their data; the app owns it. Users don't control where data gets stored; they can only store it on the application. Users don't control access to it; they only advise the application on how to control access (which the application can ignore). |
|||
|
|||
Blockstack applications solve both sets of problems. Users pick and choose highly-available storage providers like Dropbox or BitTorrent to host their data, and applications read it with the user's consent. Blockstack ensures that all data is signed and verified and (optionally) encrypted end-to-end, so users can treat storage providers like dumb hard drives: if you don't like yours, you can swap it out with a better one. Users can take their data with them if they leave the application, since it was never the application's in the first place. |
|||
|
|||
At the same time, developers are no longer on the hook for hosting user data. Since users bring their own storage and use public-key cryptography for authentication, applications don't have to store anything--there's nothing to steal when they get hacked. Moreover, many Web applications today can be re-factored so that everything happens client-side, obviating the need for running dedicated application servers. |
|||
|
|||
|
|||
## What is a Blockstack ID? |
|||
|
|||
Blockstack IDs are usernames. Unlike normal Web app usernames, Blockstack IDs |
|||
are usable *across every Blockstack app.* They fill a similar role to |
|||
centralized single-signon services like Facebook or Google. However, you and |
|||
only you control your Blockstack ID, and no one can track your logins. |
|||
|
|||
## How do I get a Blockstack ID? |
|||
|
|||
If you use the [Blockstack Browser]({{ site.baseurl }}/browser/browser-introduction.md) to create a |
|||
new ID. |
|||
|
|||
## Why do I need a Blockstack ID? |
|||
|
|||
Blockstack IDs are used to discover where you are keeping your |
|||
(publicly-readable) application data. For example, if `alice.id` wants to share |
|||
a document with `bob.id`, then `bob.id`'s browser uses the Blockstack ID |
|||
`alice.id` to look up where `alice.id` stored it. |
|||
|
|||
The technical descriptions of how and why this works are quite long. |
|||
Please see the [Blockstack Naming Service]({{site.baseurl}}/core/naming/introduction.html) |
|||
documentation for a full description. |
|||
|
|||
= |
|||
|
|||
## What components make ups the Blockstack ecosystem? |
|||
|
|||
The components that make up Blockstack do not have any central points of |
|||
control. |
|||
|
|||
* The [Blockstack Naming Service]({{ site.baseurl }}/core/naming/introduction.html) runs on top of |
|||
the Bitcoin blockchain, which itself is decentralized. It binds Blockstack |
|||
IDs to a small amount of on-chain data (usually a hash of off-chain data). |
|||
* The [Atlas Peer Network]({{ site.baseurl }}/core/atlas/overview.html) stores chunks of data referenced by |
|||
names in BNS. It operates under similar design principles to BitTorrent, and |
|||
has no single points of failure. The network is self-healing---if a node |
|||
crashes, it quickly recovers all of its state from its peers. |
|||
* The [Gaia storage system](https://github.com/blockstack/gaia) lets users |
|||
choose where their application data gets hosted. Gaia reduces all storage |
|||
systems---from cloud storage to peer-to-peer networks---to dumb, interchangeable |
|||
hard drives. Users have maximum flexibility and control over their data in a |
|||
way that is transparent to app developers. |
|||
|
|||
|
|||
## Blockstack vs Ethereum |
|||
|
|||
Blockstack and Ethereum both strive to provide a decentralized application |
|||
platform. Blockstack's design philosophy differs from Ethereum's design |
|||
philosophy in that Blockstack emphasizes treating the blockchain as a "dumb |
|||
ledger" with no special functionality or properties beyond a few bare minimum |
|||
requirements. Instead, it strives to do everything off-chain---an application of the [end-to-end principle](https://en.wikipedia.org/wiki/End-to-end_principle). |
|||
Most Blockstack applications do *not* |
|||
interact with the blockchain, and instead interact with Blockstack |
|||
infrastructure through client libraries and RESTful endpoints. |
|||
This is evidenced by Blockstack's decision to implement its naming system (BNS), discovery and routing system |
|||
(Atlas), and storage system (Gaia) as blockchain-agnostic components that can be |
|||
ported from one blockchain to another. |
|||
|
|||
Ethereum takes the opposite approach. Ethereum dapps are expected to interface |
|||
directly with on-chain smart contract logic, and are expected to host a |
|||
non-trivial amount of state in the blockchain itself. This is necessary for |
|||
them, because many Ethereum dapps' business logic is centered around the |
|||
mechanics of an ERC20 token. |
|||
|
|||
Blockstack does not implement a smart contract system (yet), but it will soon |
|||
implement a [native token](https://blockstack.com/distribution.pdf) that will be |
|||
accessible to Blockstack applications. |
|||
|
|||
|
|||
## What's the difference between Onename and Blockstack? |
|||
|
|||
Onename is the free Blockstack ID registrar run by Blockstack. It makes it easy to register your name and setup your profile. Once the name has been registered in Onename you can transfer it to a wallet you control, or leave it there and use it as you like. |
|||
|
|||
## How is Blockstack different from Namecoin? |
|||
|
|||
Blockstack DNS differs from Namecoin DNS in a few fundamental ways: blockchain layering, storage models, name pricing models, and incentives for miners. We wrote a post where you can learn more here: https://blockstack.org/docs/blockstack-vs-namecoin |
|||
|
|||
## I heard you guys were on Namecoin, what blockchain do you use now? |
|||
|
|||
We use the Bitcoin blockchain for our source of truth. |
|||
|
|||
## How long has the project been around? |
|||
|
|||
Work on the project started in late 2013. First public commits on the code are |
|||
from Jan 2014. The first registrar for Blockstack was launched in March 2014 and |
|||
the project has been growing since then. |
|||
|
|||
## Who started the project? Who maintains it? |
|||
|
|||
The project was started by two engineers from Princeton University. Muneeb Ali |
|||
and Ryan Shea met at the Computer Science department at Princeton, where Muneeb |
|||
was finishing his PhD and Ryan was running the enterprenurship club. In 2014, |
|||
frustrated by the walled-gardens and security problems of the current internet |
|||
they started working on a decentralized internet secured by blockchains. A full |
|||
list of contributors can be found |
|||
[here](https://github.com/blockstack/blockstack-core/graphs/contributors). |
@ -1,33 +0,0 @@ |
|||
# Blockstack Resolver |
|||
|
|||
During 2014-2016, Bockstack resolver was a separate service (like DNS resolvers). |
|||
It was merged into the Blockstack API in early 2017. |
|||
|
|||
The following (legacy) API call is still being supported by the Blockstack API: |
|||
|
|||
``` |
|||
http://localhost:5000/v2/users/fredwilson |
|||
``` |
|||
|
|||
And you can see a legacy resolver in action at http://resolver.onename.com/v2/users/fredwilson |
|||
|
|||
## Cron Job for Namespaces |
|||
|
|||
**Note: the instructions below need updating.** |
|||
|
|||
Currently, the resolver indexes all valid names in a local file which can be |
|||
populated by running |
|||
> $ ./refresh_names.sh |
|||
|
|||
On a production deployment, you should add a crond job to periodically run this |
|||
script. You can edit your crontab file by: |
|||
> $ crontab -e |
|||
|
|||
Here is a sample crontab file that runs the refresh script every two hours: |
|||
``` |
|||
SHELL=/bin/bash |
|||
HOME=/home/ubuntu |
|||
|
|||
#This is a comment |
|||
0 */2 * * * /home/ubuntu/resolver/resolver/refresh_names.sh |
|||
``` |
@ -1,114 +0,0 @@ |
|||
# Install Script |
|||
|
|||
We provide a [script](../images/scripts/ubuntu-17.04.sh) which will |
|||
perform all the steps outlined in this doc (except for creating a protocol handler -- see the bottom of the doc). The script creates a virtualenv of |
|||
Blockstack Core and installs Browser in a subdirectory. It additionally creates some |
|||
scripts for starting Core and Browser together. |
|||
|
|||
However, if you'd like to customize your install, step through it |
|||
yourself, or you are on a different distro, continue on with this doc! |
|||
|
|||
# Setting up Blockstack Core API Service |
|||
|
|||
Install required binaries in Ubuntu: |
|||
|
|||
``` |
|||
sudo apt update && sudo apt-get install -y python-pip python-dev libssl-dev libffi-dev rng-tools curl build-essential |
|||
``` |
|||
|
|||
|
|||
If you'd like to use a virtualenv to install Blockstack, you can do that |
|||
|
|||
``` |
|||
pip install virtualenv |
|||
virtualenv --python=python2.7 ~/.blockstack.venv/ && source ~/.blockstack.venv/bin/activate |
|||
``` |
|||
|
|||
Let's install virtualchain 0.14.3 and blockstack 0.14.3 |
|||
|
|||
``` |
|||
sudo apt install git |
|||
pip install git+https://github.com/blockstack/virtualchain.git@rc-0.14.3 |
|||
pip install git+https://github.com/blockstack/blockstack-core.git@rc-0.14.3 |
|||
``` |
|||
|
|||
Get Blockstack core configured with default settings and choose your Bitcoin wallet password |
|||
``` |
|||
blockstack setup -y --password BITCOIN_WALLET_PASSWORD --debug |
|||
``` |
|||
|
|||
# Setting up Blockstack Browser Node Application |
|||
|
|||
Install NodeJS through NodeSource PPA |
|||
|
|||
``` |
|||
curl -sL https://deb.nodesource.com/setup_7.x | sudo -E bash - |
|||
sudo apt install -y nodejs |
|||
``` |
|||
|
|||
Download Blockstack Browser and install its dependencies |
|||
|
|||
``` |
|||
git clone https://github.com/blockstack/blockstack-browser.git -bv0.11.1 |
|||
cd blockstack-browser |
|||
npm install node-sass |
|||
npm install |
|||
``` |
|||
|
|||
Note that `blockstack-browser` depends on `node-sass` which can sometimes install strangely on Linux, running `npm install node-sass` before trying to install the other dependencies solves that problem. |
|||
|
|||
# Running Blockstack Browser |
|||
|
|||
Now we're ready to run our Core API service and start the Browser node app. |
|||
|
|||
First, start the Core API service. |
|||
|
|||
``` |
|||
blockstack api start -y --password BITCOIN_WALLET_PASSWORD --debug |
|||
``` |
|||
|
|||
Start the CORS proxy. |
|||
|
|||
``` |
|||
npm run dev-proxy & |
|||
``` |
|||
|
|||
Start the Node Application |
|||
|
|||
``` |
|||
npm run dev |
|||
``` |
|||
|
|||
Then you can open `http://localhost:3000/` in your browser to get to the Blockstack Browser. |
|||
|
|||
|
|||
You can copy your api password to your clipboard with this command: |
|||
``` |
|||
grep api_password ~/.blockstack/client.ini | sed 's/api_password = //g' | xclip -selection clipboard |
|||
``` |
|||
|
|||
## Setting up a protocol handler |
|||
|
|||
If you'd like your browser to automatically handle links with the `blockstack:` protocol specifier, you will need to register a protocol handler with your desktop environment. In Ubuntu/Gnome, this can be done by creating a file |
|||
|
|||
`~/.local/share/applications/blockstack.desktop` |
|||
|
|||
With the following contents: |
|||
|
|||
``` |
|||
[Desktop Entry] |
|||
Type=Application |
|||
Terminal=false |
|||
Exec=bash -c 'xdg-open http://localhost:3000/auth?authRequest=$(echo "%u" | sed s,blockstack:////*,,)' |
|||
Name=Blockstack-Browser |
|||
MimeType=x-scheme-handler/blockstack; |
|||
``` |
|||
|
|||
Then you need to make this file executable, and register it as a protocol handler. |
|||
|
|||
``` |
|||
$ chmod +x ~/.local/share/applications/blockstack.desktop |
|||
$ xdg-mime default blockstack.desktop x-scheme-handler/blockstack |
|||
``` |
|||
|
|||
Now, `blockstack:` protocol URLs should get handled by your Blockstack Browser. If you're running Browser in your browser's private mode, you may have to copy and paste the link, as this protocol handler will try to open in a regular browser window. |
Loading…
Reference in new issue