Chain Core Developer Edition
Go JavaScript Java Ruby Swift Shell
Latest commit 39d1843 Jan 14, 2017 @oleganza oleganza committed with chainbot core/assets: createAsset response encodes IssuanceProgram in hex
Current implementation uses default base64 encoding that's inconsistent
with use elsewhere (e.g.
https://github.com/chain/chain/blob/27e2c5af0195d71aba8837e7e04fadf2ffbd2069/core/asset/block.go#L36).
This change ensures hex-encoding for the issuance program in the
"createAsset" response.

Closes #389
Permalink
Failed to load latest commit information.
.github .github: remove pull request template Nov 10, 2016
Godeps Godeps: add Godeps/Godeps.json so Heroku chills out Sep 2, 2016
bin bin/build-docker-de: upgrade cored to 1.0.2 Dec 6, 2016
builds/core builds/chainbot: remove chainbot build Oct 24, 2016
cmd core/config: make MaxIssuanceWindow a json.Duration Jan 10, 2017
core core/assets: createAsset response encodes IssuanceProgram in hex Jan 14, 2017
crypto crypto/ed25519/chainkd: remove ed25519 convenience constructor Oct 25, 2016
dashboard core: remove pointers for gRPC Jan 10, 2017
database database/pg: reuse slices in ForQueryRows Nov 23, 2016
docker bin/build-docker-de: rename build-ccde and use build-cored-release Nov 28, 2016
docs all: revise Ruby requirement from 2 to 2.1 Jan 10, 2017
encoding encoding/blockchain: Encapsulate "varstrlist" and "extensible string"… Jan 13, 2017
env all: address golint feedback Aug 24, 2016
errors errors: make WithData merge maps Nov 2, 2016
generated all: revise Ruby requirement from 2 to 2.1 Jan 10, 2017
installer all: remove dead code; fix misspellings Dec 20, 2016
log log: use fixed-width time format Nov 21, 2016
math/checked protocol/vm: don't overflow the program counter Oct 6, 2016
metrics all: extend gas coverage to all directories except vendor Nov 18, 2016
net all: extend gas coverage to all directories except vendor Nov 18, 2016
os/program os/program: add Path (in new package) Oct 7, 2016
packer cmd/chainbot: use local Postgres instead of RDS. Feb 8, 2016
perf sdk/java: make sdk Java 1.7 compliant Nov 14, 2016
protocol encoding/blockchain: Encapsulate "varstrlist" and "extensible string"… Jan 13, 2017
sdk all: revise Ruby requirement from 2 to 2.1 Jan 10, 2017
sync/idempotency sync/idempotency: make errors non-idempotent Nov 14, 2016
syscall os/program: add Path (in new package) Oct 7, 2016
testnet testnet: new directory Sep 30, 2016
testutil crypto/ed25519: replace hd25519 with chainkd throughout the core Sep 29, 2016
vendor vendor: add grpc dependencies Jan 13, 2017
.clang-format crypto/hsm/thales/xprvseeclient: new package Feb 24, 2016
.gitignore gitignore: ignore npm-debug.log Oct 22, 2016
CHANGELOG.md all: update changelog formats Nov 19, 2016
CODE_OF_CONDUCT.md Code of Conduct Sep 27, 2016
Contributing.md .github: update links Oct 22, 2016
LICENSE LICENSE: add license and notices Oct 24, 2016
NOTICE sync/idempotency: new package Nov 3, 2016
Procfile Procfile: add metricsd Oct 19, 2016
Readme.md chain: update Readme intro Nov 17, 2016
ReleaseNotes.md chain: ReleaseNotes.md Oct 10, 2016
app.json Procfile: abstract the web command to support monorepo Oct 5, 2016
wercker.yml wercker.yml: disable flaky dashboard linting in CI Jan 7, 2017

Readme.md

Chain Core Developer Edition

Chain Core is software designed to operate and connect to highly scalable permissioned blockchain networks conforming to the Chain Protocol. Each network maintains a cryptographically-secured transaction log, known as a blockchain, which allows partipicants to define, issue, and transfer digital assets on a multi-asset shared ledger. Digital assets share a common, interoperable format and can represent any units of value that are guaranteed by a trusted issuer — such as currencies, bonds, securities, IOUs, or loyalty points. Each Chain Core holds a copy of the ledger and independently validates each update, or “block,” while a federation of block signers ensures global consistency of the ledger.

Chain Core Developer Edition is a free, downloadable version of Chain Core that is open source and licensed under the AGPL. Individuals and organizations use Chain Core Developer Edition to learn, experiment, and build prototypes.

Chain Core Developer Edition can be run locally on Mac, Windows, or Linux to create a new blockchain network, connect to an existing blockchain network, or connect to the public Chain testnet, operated by Chain, Microsoft, and Cornell University’s IC3.

For more information about how to use Chain Core Developer Edition, see the docs: https://chain.com/docs

Download

To install Chain Core Developer Edition on Mac, Windows, or Linux, please visit our downloads page.

Contributing

Chain has adopted the code of conduct defined by the Contributor Covenant. It can be read in full here. This repository is the canonical source for Chain Core Developer Edition. Consequently, Chain engineers actively maintain this repository. If you are interested in contributing to this code base, please read our issue and pull request templates first.

Building from source

Environment

Set the CHAIN environment variable, in .profile in your home directory, to point to the root of the Chain source code repo:

export CHAIN=$GOPATH/src/chain

You should also add $CHAIN/bin to your path (as well as $GOPATH/bin, if it isn’t already):

PATH=$GOPATH/bin:$CHAIN/bin:$PATH

You might want to open a new terminal window to pick up the change.

Installation

Build and install from source:

$ git clone https://github.com/chain/chain $CHAIN
$ cd $CHAIN
$ go install ./cmd/...

Set up the database:

$ createdb core

Start Chain Core:

$ cored

Access the dashboard:

$ open http://localhost:1999/

Run tests:

$ go test $(go list ./... | grep -v vendor)

Developing Chain Core

Updating the schema with migrations

$ dumpschema

Dependencies

To add or update a Go dependency, do the following:

Copy the code from $GOPATH/src/x to $CHAIN/vendor/x. For example, to vendor the package github.com/kr/pretty, run

$ mkdir -p $CHAIN/vendor/github.com/kr
$ rm -r $CHAIN/vendor/github.com/kr/pretty
$ cp -r $GOPATH/src/github.com/kr/pretty $CHAIN/vendor/github.com/kr/pretty
$ rm -rf $CHAIN/vendor/github.com/kr/pretty/.git

(Note: don’t put a trailing slash (/) on these paths. It can change the behavior of cp and put the files in the wrong place.)

In your commit message, include the commit hash of the upstream repo for the dependency. (You can find this with git rev-parse HEAD in the upstream repo.) Also, make sure the upstream working tree is clean. (Check with git status.)

Deploy Options

Deploy

When Chain Core is deployed to a non-local host, all requests require authentication. To generate a client access token on Heroku, run the following command:

$ heroku run -a <your-heroku-app> corectl create-token <token-name>
<token-name>:<your-token>

License

Chain Core Developer Edition is licensed under the terms of the GNU Affero General Public License Version 3 (AGPL).

The Chain Java SDK (/sdk/java) is licensed under the terms of the Apache License Version 2.0.