[NOD-509] Change organization name to kaspanet (#524)

* [NOD-509] Change organization name to kaspanet

* [NOD-509] Reorganize imports
This commit is contained in:
Svarog 2019-12-08 17:33:42 +02:00 committed by stasatdaglabs
parent f4c6859e51
commit 369ec449a8
467 changed files with 1357 additions and 1357 deletions

View File

@ -3,7 +3,7 @@ btcd
[![Build Status](https://travis-ci.org/btcsuite/btcd.png?branch=master)](https://travis-ci.org/btcsuite/btcd) [![Build Status](https://travis-ci.org/btcsuite/btcd.png?branch=master)](https://travis-ci.org/btcsuite/btcd)
[![ISC License](http://img.shields.io/badge/license-ISC-blue.svg)](http://copyfree.org) [![ISC License](http://img.shields.io/badge/license-ISC-blue.svg)](http://copyfree.org)
[![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)](http://godoc.org/github.com/daglabs/kaspad) [![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)](http://godoc.org/github.com/kaspanet/kaspad)
btcd is an alternative full node bitcoin implementation written in Go (golang). btcd is an alternative full node bitcoin implementation written in Go (golang).
@ -41,7 +41,7 @@ which are both under active development.
#### Windows - MSI Available #### Windows - MSI Available
https://github.com/daglabs/kaspad/releases https://github.com/kaspanet/kaspad/releases
#### Linux/BSD/MacOSX/POSIX - Build from Source #### Linux/BSD/MacOSX/POSIX - Build from Source
@ -64,8 +64,8 @@ recommended that `GOPATH` is set to a directory in your home directory such as
```bash ```bash
$ # Install dep: https://golang.github.io/dep/docs/installation.html $ # Install dep: https://golang.github.io/dep/docs/installation.html
$ git clone https://github.com/daglabs/kaspad $GOPATH/src/github.com/daglabs/kaspad $ git clone https://github.com/kaspanet/kaspad $GOPATH/src/github.com/kaspanet/kaspad
$ cd $GOPATH/src/github.com/daglabs/kaspad $ cd $GOPATH/src/github.com/kaspanet/kaspad
$ dep ensure $ dep ensure
$ go install . ./cmd/... $ go install . ./cmd/...
``` ```
@ -85,7 +85,7 @@ Install a newer MSI
- Run the following commands to update btcd, all dependencies, and install it: - Run the following commands to update btcd, all dependencies, and install it:
```bash ```bash
$ cd $GOPATH/src/github.com/daglabs/kaspad $ cd $GOPATH/src/github.com/kaspanet/kaspad
$ git pull && dep ensure $ git pull && dep ensure
$ go install . ./cmd/... $ go install . ./cmd/...
``` ```
@ -114,12 +114,12 @@ $ ./btcd
## Issue Tracker ## Issue Tracker
The [integrated github issue tracker](https://github.com/daglabs/kaspad/issues) The [integrated github issue tracker](https://github.com/kaspanet/kaspad/issues)
is used for this project. is used for this project.
## Documentation ## Documentation
The documentation is a work-in-progress. It is located in the [docs](https://github.com/daglabs/kaspad/tree/master/docs) folder. The documentation is a work-in-progress. It is located in the [docs](https://github.com/kaspanet/kaspad/tree/master/docs) folder.
## GPG Verification Key ## GPG Verification Key

View File

@ -22,10 +22,10 @@ import (
"sync/atomic" "sync/atomic"
"time" "time"
"github.com/daglabs/kaspad/util/subnetworkid" "github.com/kaspanet/kaspad/util/subnetworkid"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
type newBucket [newBucketCount]map[string]*KnownAddress type newBucket [newBucketCount]map[string]*KnownAddress

View File

@ -7,17 +7,17 @@ package addrmgr
import ( import (
"bou.ke/monkey" "bou.ke/monkey"
"fmt" "fmt"
"github.com/daglabs/kaspad/config" "github.com/kaspanet/kaspad/config"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/pkg/errors" "github.com/pkg/errors"
"net" "net"
"reflect" "reflect"
"testing" "testing"
"time" "time"
"github.com/daglabs/kaspad/util/subnetworkid" "github.com/kaspanet/kaspad/util/subnetworkid"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
// naTest is used to describe a test to be performed against the NetAddressKey // naTest is used to describe a test to be performed against the NetAddressKey

View File

@ -7,7 +7,7 @@ package addrmgr
import ( import (
"time" "time"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
func TstKnownAddressIsBad(ka *KnownAddress) bool { func TstKnownAddressIsBad(ka *KnownAddress) bool {

View File

@ -7,9 +7,9 @@ package addrmgr
import ( import (
"time" "time"
"github.com/daglabs/kaspad/util/subnetworkid" "github.com/kaspanet/kaspad/util/subnetworkid"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
// KnownAddress tracks information about a known network address that is used // KnownAddress tracks information about a known network address that is used

View File

@ -9,8 +9,8 @@ import (
"testing" "testing"
"time" "time"
"github.com/daglabs/kaspad/addrmgr" "github.com/kaspanet/kaspad/addrmgr"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
func TestChance(t *testing.T) { func TestChance(t *testing.T) {

View File

@ -5,8 +5,8 @@
package addrmgr package addrmgr
import ( import (
"github.com/daglabs/kaspad/logger" "github.com/kaspanet/kaspad/logger"
"github.com/daglabs/kaspad/util/panics" "github.com/kaspanet/kaspad/util/panics"
) )
var log, _ = logger.Get(logger.SubsystemTags.ADXR) var log, _ = logger.Get(logger.SubsystemTags.ADXR)

View File

@ -8,9 +8,9 @@ import (
"fmt" "fmt"
"net" "net"
"github.com/daglabs/kaspad/config" "github.com/kaspanet/kaspad/config"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
var ( var (

View File

@ -6,13 +6,13 @@ package addrmgr_test
import ( import (
"bou.ke/monkey" "bou.ke/monkey"
"github.com/daglabs/kaspad/config" "github.com/kaspanet/kaspad/config"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"net" "net"
"testing" "testing"
"github.com/daglabs/kaspad/addrmgr" "github.com/kaspanet/kaspad/addrmgr"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
// TestIPTypes ensures the various functions which determine the type of an IP // TestIPTypes ensures the various functions which determine the type of an IP

View File

@ -3,7 +3,7 @@ blockchain
[![Build Status](http://img.shields.io/travis/btcsuite/btcd.svg)](https://travis-ci.org/btcsuite/btcd) [![Build Status](http://img.shields.io/travis/btcsuite/btcd.svg)](https://travis-ci.org/btcsuite/btcd)
[![ISC License](http://img.shields.io/badge/license-ISC-blue.svg)](http://copyfree.org) [![ISC License](http://img.shields.io/badge/license-ISC-blue.svg)](http://copyfree.org)
[![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)](http://godoc.org/github.com/daglabs/kaspad/blockchain) [![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)](http://godoc.org/github.com/kaspanet/kaspad/blockchain)
Package blockchain implements bitcoin block handling and chain selection rules. Package blockchain implements bitcoin block handling and chain selection rules.
The test coverage is currently only around 60%, but will be increasing over The test coverage is currently only around 60%, but will be increasing over
@ -21,7 +21,7 @@ block chain.
## Installation and Updating ## Installation and Updating
```bash ```bash
$ go get -u github.com/daglabs/kaspad/blockchain $ go get -u github.com/kaspanet/kaspad/blockchain
``` ```
## Bitcoin Chain Processing Overview ## Bitcoin Chain Processing Overview
@ -61,18 +61,18 @@ is by no means exhaustive:
## Examples ## Examples
* [ProcessBlock Example](http://godoc.org/github.com/daglabs/kaspad/blockchain#example-BlockChain-ProcessBlock) * [ProcessBlock Example](http://godoc.org/github.com/kaspanet/kaspad/blockchain#example-BlockChain-ProcessBlock)
Demonstrates how to create a new chain instance and use ProcessBlock to Demonstrates how to create a new chain instance and use ProcessBlock to
attempt to add a block to the chain. This example intentionally attempt to add a block to the chain. This example intentionally
attempts to insert a duplicate genesis block to illustrate how an invalid attempts to insert a duplicate genesis block to illustrate how an invalid
block is handled. block is handled.
* [CompactToBig Example](http://godoc.org/github.com/daglabs/kaspad/blockchain#example-CompactToBig) * [CompactToBig Example](http://godoc.org/github.com/kaspanet/kaspad/blockchain#example-CompactToBig)
Demonstrates how to convert the compact "bits" in a block header which Demonstrates how to convert the compact "bits" in a block header which
represent the target difficulty to a big integer and display it using the represent the target difficulty to a big integer and display it using the
typical hex notation. typical hex notation.
* [BigToCompact Example](http://godoc.org/github.com/daglabs/kaspad/blockchain#example-BigToCompact) * [BigToCompact Example](http://godoc.org/github.com/kaspanet/kaspad/blockchain#example-BigToCompact)
Demonstrates how to convert a target difficulty into the Demonstrates how to convert a target difficulty into the
compact "bits" in a block header which represent that target difficulty. compact "bits" in a block header which represent that target difficulty.

View File

@ -6,8 +6,8 @@ package blockdag
import ( import (
"fmt" "fmt"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
) )
func (dag *BlockDAG) addNodeToIndexWithInvalidAncestor(block *util.Block) error { func (dag *BlockDAG) addNodeToIndexWithInvalidAncestor(block *util.Block) error {

View File

@ -7,9 +7,9 @@ import (
"testing" "testing"
"bou.ke/monkey" "bou.ke/monkey"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
) )
func TestMaybeAcceptBlockErrors(t *testing.T) { func TestMaybeAcceptBlockErrors(t *testing.T) {

View File

@ -3,7 +3,7 @@ package blockdag
import ( import (
"container/heap" "container/heap"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
// baseHeap is an implementation for heap.Interface that sorts blocks by their height // baseHeap is an implementation for heap.Interface that sorts blocks by their height

View File

@ -3,8 +3,8 @@ package blockdag
import ( import (
"testing" "testing"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
// TestBlockHeap tests pushing, popping, and determining the length of the heap. // TestBlockHeap tests pushing, popping, and determining the length of the heap.

View File

@ -1,8 +1,8 @@
package blockdag package blockdag
import ( import (
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/pkg/errors" "github.com/pkg/errors"
) )

View File

@ -7,9 +7,9 @@ package blockdag
import ( import (
"sync" "sync"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
// blockIndex provides facilities for keeping track of an in-memory index of the // blockIndex provides facilities for keeping track of an in-memory index of the

View File

@ -7,8 +7,8 @@ import (
"time" "time"
"bou.ke/monkey" "bou.ke/monkey"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
) )
func TestAncestorErrors(t *testing.T) { func TestAncestorErrors(t *testing.T) {

View File

@ -1,8 +1,8 @@
package blockdag package blockdag
import ( import (
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
// BlockLocator is used to help locate a specific block. The algorithm for // BlockLocator is used to help locate a specific block. The algorithm for

View File

@ -8,8 +8,8 @@ import (
"fmt" "fmt"
"time" "time"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
// blockStatus is a bit field representing the validation state of the block. // blockStatus is a bit field representing the validation state of the block.

View File

@ -3,7 +3,7 @@ package blockdag
import ( import (
"strings" "strings"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
// blockSet implements a basic unsorted set of blocks // blockSet implements a basic unsorted set of blocks

View File

@ -4,7 +4,7 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
func TestHashes(t *testing.T) { func TestHashes(t *testing.T) {

View File

@ -1,7 +1,7 @@
package blockdag package blockdag
import ( import (
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/pkg/errors" "github.com/pkg/errors"
"math" "math"
"math/big" "math/big"

View File

@ -1,8 +1,8 @@
package blockdag package blockdag
import ( import (
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/pkg/errors" "github.com/pkg/errors"
"reflect" "reflect"
"testing" "testing"

View File

@ -6,10 +6,10 @@ package blockdag
import ( import (
"fmt" "fmt"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/txscript" "github.com/kaspanet/kaspad/txscript"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/pkg/errors" "github.com/pkg/errors"
) )

View File

@ -4,16 +4,16 @@ import (
"bufio" "bufio"
"bytes" "bytes"
"encoding/binary" "encoding/binary"
"github.com/daglabs/kaspad/util/subnetworkid" "github.com/kaspanet/kaspad/util/subnetworkid"
"github.com/pkg/errors" "github.com/pkg/errors"
"io" "io"
"math" "math"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/util/txsort" "github.com/kaspanet/kaspad/util/txsort"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
// compactFeeData is a specialized data type to store a compact list of fees // compactFeeData is a specialized data type to store a compact list of fees

View File

@ -16,11 +16,11 @@ import (
"testing" "testing"
"time" "time"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
_ "github.com/daglabs/kaspad/database/ffldb" _ "github.com/kaspanet/kaspad/database/ffldb"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
func loadBlocksWithLog(t *testing.T, filename string) ([]*util.Block, error) { func loadBlocksWithLog(t *testing.T, filename string) ([]*util.Block, error) {

View File

@ -5,8 +5,8 @@
package blockdag package blockdag
import ( import (
"github.com/daglabs/kaspad/btcec" "github.com/kaspanet/kaspad/btcec"
"github.com/daglabs/kaspad/txscript" "github.com/kaspanet/kaspad/txscript"
) )
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------

View File

@ -12,14 +12,14 @@ import (
"sync" "sync"
"time" "time"
"github.com/daglabs/kaspad/util/subnetworkid" "github.com/kaspanet/kaspad/util/subnetworkid"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/txscript" "github.com/kaspanet/kaspad/txscript"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
const ( const (

View File

@ -18,13 +18,13 @@ import (
"math/rand" "math/rand"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/txscript" "github.com/kaspanet/kaspad/txscript"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/util/subnetworkid" "github.com/kaspanet/kaspad/util/subnetworkid"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
func TestBlockCount(t *testing.T) { func TestBlockCount(t *testing.T) {

View File

@ -13,12 +13,12 @@ import (
"io" "io"
"sync" "sync"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/binaryserializer" "github.com/kaspanet/kaspad/util/binaryserializer"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/util/subnetworkid" "github.com/kaspanet/kaspad/util/subnetworkid"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
const ( const (

View File

@ -10,8 +10,8 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
// TestErrNotInDAG ensures the functions related to errNotInDAG work // TestErrNotInDAG ensures the functions related to errNotInDAG work

View File

@ -8,7 +8,7 @@ import (
"math/big" "math/big"
"time" "time"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
) )
// requiredDifficulty calculates the required difficulty for a // requiredDifficulty calculates the required difficulty for a

View File

@ -5,14 +5,14 @@
package blockdag package blockdag
import ( import (
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
"math/big" "math/big"
"testing" "testing"
"time" "time"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
) )
// TestBigToCompact ensures BigToCompact converts big integers to the expected // TestBigToCompact ensures BigToCompact converts big integers to the expected

View File

@ -6,17 +6,17 @@ import (
"math" "math"
"testing" "testing"
"github.com/daglabs/kaspad/util/subnetworkid" "github.com/kaspanet/kaspad/util/subnetworkid"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/util/testtools" "github.com/kaspanet/kaspad/util/testtools"
"github.com/daglabs/kaspad/blockdag" "github.com/kaspanet/kaspad/blockdag"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/mining" "github.com/kaspanet/kaspad/mining"
"github.com/daglabs/kaspad/txscript" "github.com/kaspanet/kaspad/txscript"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
// TestFinality checks that the finality mechanism works as expected. // TestFinality checks that the finality mechanism works as expected.

View File

@ -12,15 +12,15 @@ import (
"path/filepath" "path/filepath"
"testing" "testing"
"github.com/daglabs/kaspad/blockdag" "github.com/kaspanet/kaspad/blockdag"
"github.com/daglabs/kaspad/blockdag/fullblocktests" "github.com/kaspanet/kaspad/blockdag/fullblocktests"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
_ "github.com/daglabs/kaspad/database/ffldb" _ "github.com/kaspanet/kaspad/database/ffldb"
"github.com/daglabs/kaspad/txscript" "github.com/kaspanet/kaspad/txscript"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
const ( const (

View File

@ -3,7 +3,7 @@ fullblocktests
[![Build Status](http://img.shields.io/travis/btcsuite/btcd.svg)](https://travis-ci.org/btcsuite/btcd) [![Build Status](http://img.shields.io/travis/btcsuite/btcd.svg)](https://travis-ci.org/btcsuite/btcd)
[![ISC License](http://img.shields.io/badge/license-ISC-blue.svg)](http://copyfree.org) [![ISC License](http://img.shields.io/badge/license-ISC-blue.svg)](http://copyfree.org)
[![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)](http://godoc.org/github.com/daglabs/kaspad/blockchain/fullblocktests) [![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)](http://godoc.org/github.com/kaspanet/kaspad/blockchain/fullblocktests)
Package fullblocktests provides a set of full block tests to be used for testing Package fullblocktests provides a set of full block tests to be used for testing
the consensus validation rules. The tests are intended to be flexible enough to the consensus validation rules. The tests are intended to be flexible enough to
@ -20,7 +20,7 @@ of blocks that exercise the consensus validation rules.
## Installation and Updating ## Installation and Updating
```bash ```bash
$ go get -u github.com/daglabs/kaspad/blockchain/fullblocktests $ go get -u github.com/kaspanet/kaspad/blockchain/fullblocktests
``` ```
## License ## License

View File

@ -18,14 +18,14 @@ import (
"runtime" "runtime"
"time" "time"
"github.com/daglabs/kaspad/blockdag" "github.com/kaspanet/kaspad/blockdag"
"github.com/daglabs/kaspad/btcec" "github.com/kaspanet/kaspad/btcec"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/txscript" "github.com/kaspanet/kaspad/txscript"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/util/random" "github.com/kaspanet/kaspad/util/random"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
const ( const (

View File

@ -10,12 +10,12 @@ import (
"math/big" "math/big"
"time" "time"
"github.com/daglabs/kaspad/util/hdkeychain" "github.com/kaspanet/kaspad/util/hdkeychain"
"github.com/daglabs/kaspad/util/subnetworkid" "github.com/kaspanet/kaspad/util/subnetworkid"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
// newHashFromStr converts the passed big-endian hex string into a // newHashFromStr converts the passed big-endian hex string into a

View File

@ -3,7 +3,7 @@ indexers
[![Build Status](https://travis-ci.org/btcsuite/btcd.png?branch=master)](https://travis-ci.org/btcsuite/btcd) [![Build Status](https://travis-ci.org/btcsuite/btcd.png?branch=master)](https://travis-ci.org/btcsuite/btcd)
[![ISC License](http://img.shields.io/badge/license-ISC-blue.svg)](http://copyfree.org) [![ISC License](http://img.shields.io/badge/license-ISC-blue.svg)](http://copyfree.org)
[![GoDoc](https://godoc.org/github.com/daglabs/kaspad/blockchain/indexers?status.png)](http://godoc.org/github.com/daglabs/kaspad/blockchain/indexers) [![GoDoc](https://godoc.org/github.com/kaspanet/kaspad/blockchain/indexers?status.png)](http://godoc.org/github.com/kaspanet/kaspad/blockchain/indexers)
Package indexers implements optional block chain indexes. Package indexers implements optional block chain indexes.
@ -23,7 +23,7 @@ via an RPC interface.
## Installation ## Installation
```bash ```bash
$ go get -u github.com/daglabs/kaspad/blockchain/indexers $ go get -u github.com/kaspanet/kaspad/blockchain/indexers
``` ```
## License ## License

View File

@ -3,11 +3,11 @@ package indexers
import ( import (
"bytes" "bytes"
"encoding/gob" "encoding/gob"
"github.com/daglabs/kaspad/blockdag" "github.com/kaspanet/kaspad/blockdag"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
"github.com/pkg/errors" "github.com/pkg/errors"
) )

View File

@ -1,12 +1,12 @@
package indexers package indexers
import ( import (
"github.com/daglabs/kaspad/blockdag" "github.com/kaspanet/kaspad/blockdag"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
"github.com/pkg/errors" "github.com/pkg/errors"
"io" "io"
"io/ioutil" "io/ioutil"

View File

@ -9,13 +9,13 @@ import (
"github.com/pkg/errors" "github.com/pkg/errors"
"sync" "sync"
"github.com/daglabs/kaspad/blockdag" "github.com/kaspanet/kaspad/blockdag"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/txscript" "github.com/kaspanet/kaspad/txscript"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
const ( const (

View File

@ -10,7 +10,7 @@ import (
"github.com/pkg/errors" "github.com/pkg/errors"
"testing" "testing"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
// addrIndexBucket provides a mock address index database bucket by implementing // addrIndexBucket provides a mock address index database bucket by implementing

View File

@ -7,14 +7,14 @@ package indexers
import ( import (
"github.com/pkg/errors" "github.com/pkg/errors"
"github.com/daglabs/kaspad/blockdag" "github.com/kaspanet/kaspad/blockdag"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/util/gcs" "github.com/kaspanet/kaspad/util/gcs"
"github.com/daglabs/kaspad/util/gcs/builder" "github.com/kaspanet/kaspad/util/gcs/builder"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
const ( const (

View File

@ -9,9 +9,9 @@ package indexers
import ( import (
"encoding/binary" "encoding/binary"
"github.com/daglabs/kaspad/blockdag" "github.com/kaspanet/kaspad/blockdag"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/pkg/errors" "github.com/pkg/errors"
) )

View File

@ -5,8 +5,8 @@
package indexers package indexers
import ( import (
"github.com/daglabs/kaspad/logger" "github.com/kaspanet/kaspad/logger"
"github.com/daglabs/kaspad/util/panics" "github.com/kaspanet/kaspad/util/panics"
) )
var log, _ = logger.Get(logger.SubsystemTags.INDX) var log, _ = logger.Get(logger.SubsystemTags.INDX)

View File

@ -5,10 +5,10 @@
package indexers package indexers
import ( import (
"github.com/daglabs/kaspad/blockdag" "github.com/kaspanet/kaspad/blockdag"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
var ( var (

View File

@ -6,11 +6,11 @@ package indexers
import ( import (
"fmt" "fmt"
"github.com/daglabs/kaspad/blockdag" "github.com/kaspanet/kaspad/blockdag"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
"github.com/pkg/errors" "github.com/pkg/errors"
) )

View File

@ -5,13 +5,13 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/daglabs/kaspad/blockdag" "github.com/kaspanet/kaspad/blockdag"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/mining" "github.com/kaspanet/kaspad/mining"
"github.com/daglabs/kaspad/txscript" "github.com/kaspanet/kaspad/txscript"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
func createTransaction(t *testing.T, value uint64, originTx *wire.MsgTx, outputIndex uint32) *wire.MsgTx { func createTransaction(t *testing.T, value uint64, originTx *wire.MsgTx, outputIndex uint32) *wire.MsgTx {

View File

@ -5,8 +5,8 @@
package blockdag package blockdag
import ( import (
"github.com/daglabs/kaspad/logger" "github.com/kaspanet/kaspad/logger"
"github.com/daglabs/kaspad/util/panics" "github.com/kaspanet/kaspad/util/panics"
) )
var log, _ = logger.Get(logger.SubsystemTags.BDAG) var log, _ = logger.Get(logger.SubsystemTags.BDAG)

View File

@ -7,8 +7,8 @@ package blockdag
import ( import (
"math" "math"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
// MerkleTree holds the hashes of a merkle tree // MerkleTree holds the hashes of a merkle tree

View File

@ -5,10 +5,10 @@
package blockdag package blockdag
import ( import (
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"testing" "testing"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
) )
// TestMerkle tests the BuildHashMerkleTreeStore API. // TestMerkle tests the BuildHashMerkleTreeStore API.

View File

@ -6,8 +6,8 @@ package blockdag
import ( import (
"fmt" "fmt"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
// NotificationType represents the type of a notification message. // NotificationType represents the type of a notification message.

View File

@ -8,7 +8,7 @@ import (
"path/filepath" "path/filepath"
"testing" "testing"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
) )
// TestNotifications ensures that notification callbacks are fired on events. // TestNotifications ensures that notification callbacks are fired on events.

View File

@ -1,7 +1,7 @@
package blockdag package blockdag
import ( import (
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
// phantom calculates and returns the block's blue set, selected parent and blue score. // phantom calculates and returns the block's blue set, selected parent and blue score.

View File

@ -7,9 +7,9 @@ import (
"testing" "testing"
"time" "time"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
) )
type testBlockData struct { type testBlockData struct {

View File

@ -8,8 +8,8 @@ import (
"fmt" "fmt"
"time" "time"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
// BehaviorFlags is a bitmask defining tweaks to the normal behavior when // BehaviorFlags is a bitmask defining tweaks to the normal behavior when

View File

@ -3,9 +3,9 @@ package blockdag
import ( import (
"bou.ke/monkey" "bou.ke/monkey"
"fmt" "fmt"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"path/filepath" "path/filepath"
"testing" "testing"
"time" "time"

View File

@ -9,9 +9,9 @@ import (
"runtime" "runtime"
"time" "time"
"github.com/daglabs/kaspad/txscript" "github.com/kaspanet/kaspad/txscript"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
// txValidateItem holds a transaction along with which input to validate. // txValidateItem holds a transaction along with which input to validate.

View File

@ -10,7 +10,7 @@ import (
"runtime" "runtime"
"testing" "testing"
"github.com/daglabs/kaspad/txscript" "github.com/kaspanet/kaspad/txscript"
) )
// TestCheckBlockScripts ensures that validating the all of the scripts in a // TestCheckBlockScripts ensures that validating the all of the scripts in a

View File

@ -6,11 +6,11 @@ import (
"fmt" "fmt"
"github.com/pkg/errors" "github.com/pkg/errors"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/util/subnetworkid" "github.com/kaspanet/kaspad/util/subnetworkid"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
// SubnetworkStore stores the subnetworks data // SubnetworkStore stores the subnetworks data

View File

@ -5,7 +5,7 @@ package blockdag
import ( import (
"compress/bzip2" "compress/bzip2"
"encoding/binary" "encoding/binary"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/pkg/errors" "github.com/pkg/errors"
"io" "io"
"os" "os"
@ -13,13 +13,13 @@ import (
"strings" "strings"
"sync" "sync"
"github.com/daglabs/kaspad/util/subnetworkid" "github.com/kaspanet/kaspad/util/subnetworkid"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
_ "github.com/daglabs/kaspad/database/ffldb" // blank import ffldb so that its init() function runs before tests _ "github.com/kaspanet/kaspad/database/ffldb" // blank import ffldb so that its init() function runs before tests
"github.com/daglabs/kaspad/txscript" "github.com/kaspanet/kaspad/txscript"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
const ( const (

View File

@ -7,8 +7,8 @@ import (
"testing" "testing"
"bou.ke/monkey" "bou.ke/monkey"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
) )
func TestIsSupportedDbType(t *testing.T) { func TestIsSupportedDbType(t *testing.T) {

View File

@ -7,7 +7,7 @@ package blockdag
import ( import (
"fmt" "fmt"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
// ThresholdState define the various threshold states used when voting on // ThresholdState define the various threshold states used when voting on

View File

@ -7,7 +7,7 @@ package blockdag
import ( import (
"testing" "testing"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
// TestThresholdStateStringer tests the stringized output for the // TestThresholdStateStringer tests the stringized output for the

View File

@ -2,10 +2,10 @@ package blockdag
import ( import (
"bytes" "bytes"
"github.com/daglabs/kaspad/btcec"
"github.com/daglabs/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire"
"github.com/golang/groupcache/lru" "github.com/golang/groupcache/lru"
"github.com/kaspanet/kaspad/btcec"
"github.com/kaspanet/kaspad/util/daghash"
"github.com/kaspanet/kaspad/wire"
) )
const ecmhCacheSize = 4_000_000 const ecmhCacheSize = 4_000_000

View File

@ -1,9 +1,9 @@
package blockdag package blockdag
import ( import (
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/util/locks" "github.com/kaspanet/kaspad/util/locks"
"github.com/pkg/errors" "github.com/pkg/errors"
) )

View File

@ -2,10 +2,10 @@ package blockdag
import ( import (
"fmt" "fmt"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
"reflect" "reflect"
"testing" "testing"
) )

View File

@ -8,9 +8,9 @@ import (
"io" "io"
"math/big" "math/big"
"github.com/daglabs/kaspad/btcec" "github.com/kaspanet/kaspad/btcec"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
// serializeBlockUTXODiffData serializes diff data in the following format: // serializeBlockUTXODiffData serializes diff data in the following format:

View File

@ -7,8 +7,8 @@ import (
"sort" "sort"
"strings" "strings"
"github.com/daglabs/kaspad/btcec" "github.com/kaspanet/kaspad/btcec"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
const ( const (

View File

@ -1,14 +1,14 @@
package blockdag package blockdag
import ( import (
"github.com/daglabs/kaspad/util/subnetworkid" "github.com/kaspanet/kaspad/util/subnetworkid"
"math" "math"
"reflect" "reflect"
"testing" "testing"
"github.com/daglabs/kaspad/btcec" "github.com/kaspanet/kaspad/btcec"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
// TestUTXOCollection makes sure that utxoCollection cloning and string representations work as expected. // TestUTXOCollection makes sure that utxoCollection cloning and string representations work as expected.

View File

@ -11,12 +11,12 @@ import (
"sort" "sort"
"time" "time"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/txscript" "github.com/kaspanet/kaspad/txscript"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/util/subnetworkid" "github.com/kaspanet/kaspad/util/subnetworkid"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
const ( const (

View File

@ -12,11 +12,11 @@ import (
"testing" "testing"
"time" "time"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/util/subnetworkid" "github.com/kaspanet/kaspad/util/subnetworkid"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
// TestSequenceLocksActive tests the SequenceLockActive function to ensure it // TestSequenceLocksActive tests the SequenceLockActive function to ensure it

View File

@ -7,7 +7,7 @@ package blockdag
import ( import (
"math" "math"
"github.com/daglabs/kaspad/dagconfig" "github.com/kaspanet/kaspad/dagconfig"
) )
const ( const (

View File

@ -5,7 +5,7 @@
package blockdag package blockdag
import ( import (
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"sync" "sync"
) )

20
btcd.go
View File

@ -16,16 +16,16 @@ import (
"runtime/pprof" "runtime/pprof"
"strings" "strings"
"github.com/daglabs/kaspad/blockdag/indexers" "github.com/kaspanet/kaspad/blockdag/indexers"
"github.com/daglabs/kaspad/config" "github.com/kaspanet/kaspad/config"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
_ "github.com/daglabs/kaspad/database/ffldb" _ "github.com/kaspanet/kaspad/database/ffldb"
"github.com/daglabs/kaspad/limits" "github.com/kaspanet/kaspad/limits"
"github.com/daglabs/kaspad/server" "github.com/kaspanet/kaspad/server"
"github.com/daglabs/kaspad/signal" "github.com/kaspanet/kaspad/signal"
"github.com/daglabs/kaspad/util/fs" "github.com/kaspanet/kaspad/util/fs"
"github.com/daglabs/kaspad/util/panics" "github.com/kaspanet/kaspad/util/panics"
"github.com/daglabs/kaspad/version" "github.com/kaspanet/kaspad/version"
) )
const ( const (

View File

@ -3,7 +3,7 @@ btcec
[![Build Status](https://travis-ci.org/btcsuite/btcd.png?branch=master)](https://travis-ci.org/btcsuite/btcec) [![Build Status](https://travis-ci.org/btcsuite/btcd.png?branch=master)](https://travis-ci.org/btcsuite/btcec)
[![ISC License](http://img.shields.io/badge/license-ISC-blue.svg)](http://copyfree.org) [![ISC License](http://img.shields.io/badge/license-ISC-blue.svg)](http://copyfree.org)
[![GoDoc](https://godoc.org/github.com/daglabs/kaspad/btcec?status.png)](http://godoc.org/github.com/daglabs/kaspad/btcec) [![GoDoc](https://godoc.org/github.com/kaspanet/kaspad/btcec?status.png)](http://godoc.org/github.com/kaspanet/kaspad/btcec)
Package btcec implements elliptic curve cryptography needed for working with Package btcec implements elliptic curve cryptography needed for working with
Bitcoin (secp256k1 only for now). It is designed so that it may be used with the Bitcoin (secp256k1 only for now). It is designed so that it may be used with the
@ -20,24 +20,24 @@ use secp256k1 elliptic curve cryptography.
## Installation and Updating ## Installation and Updating
```bash ```bash
$ go get -u github.com/daglabs/kaspad/btcec $ go get -u github.com/kaspanet/kaspad/btcec
``` ```
## Examples ## Examples
* [Sign Message](http://godoc.org/github.com/daglabs/kaspad/btcec#example-package--SignMessage) * [Sign Message](http://godoc.org/github.com/kaspanet/kaspad/btcec#example-package--SignMessage)
Demonstrates signing a message with a secp256k1 private key that is first Demonstrates signing a message with a secp256k1 private key that is first
parsed form raw bytes and serializing the generated signature. parsed form raw bytes and serializing the generated signature.
* [Verify Signature](http://godoc.org/github.com/daglabs/kaspad/btcec#example-package--VerifySignature) * [Verify Signature](http://godoc.org/github.com/kaspanet/kaspad/btcec#example-package--VerifySignature)
Demonstrates verifying a secp256k1 signature against a public key that is Demonstrates verifying a secp256k1 signature against a public key that is
first parsed from raw bytes. The signature is also parsed from raw bytes. first parsed from raw bytes. The signature is also parsed from raw bytes.
* [Encryption](http://godoc.org/github.com/daglabs/kaspad/btcec#example-package--EncryptMessage) * [Encryption](http://godoc.org/github.com/kaspanet/kaspad/btcec#example-package--EncryptMessage)
Demonstrates encrypting a message for a public key that is first parsed from Demonstrates encrypting a message for a public key that is first parsed from
raw bytes, then decrypting it using the corresponding private key. raw bytes, then decrypting it using the corresponding private key.
* [Decryption](http://godoc.org/github.com/daglabs/kaspad/btcec#example-package--DecryptMessage) * [Decryption](http://godoc.org/github.com/kaspanet/kaspad/btcec#example-package--DecryptMessage)
Demonstrates decrypting a message using a private key that is first parsed Demonstrates decrypting a message using a private key that is first parsed
from raw bytes. from raw bytes.

View File

@ -5,7 +5,7 @@ import (
"encoding/binary" "encoding/binary"
"math/big" "math/big"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
// Multiset tracks the state of a multiset as used to calculate the ECMH // Multiset tracks the state of a multiset as used to calculate the ECMH

View File

@ -5,7 +5,7 @@ import (
"encoding/hex" "encoding/hex"
"testing" "testing"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
var testVectors = []struct { var testVectors = []struct {

View File

@ -7,9 +7,9 @@ package btcec_test
import ( import (
"encoding/hex" "encoding/hex"
"fmt" "fmt"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
"github.com/daglabs/kaspad/btcec" "github.com/kaspanet/kaspad/btcec"
) )
// This example demonstrates signing a message with a secp256k1 private key that // This example demonstrates signing a message with a secp256k1 private key that

View File

@ -17,7 +17,7 @@ import (
"log" "log"
"os" "os"
"github.com/daglabs/kaspad/btcec" "github.com/kaspanet/kaspad/btcec"
) )
func main() { func main() {

View File

@ -3,7 +3,7 @@ btcjson
[![Build Status](https://travis-ci.org/btcsuite/btcd.png?branch=master)](https://travis-ci.org/btcsuite/btcd) [![Build Status](https://travis-ci.org/btcsuite/btcd.png?branch=master)](https://travis-ci.org/btcsuite/btcd)
[![ISC License](http://img.shields.io/badge/license-ISC-blue.svg)](http://copyfree.org) [![ISC License](http://img.shields.io/badge/license-ISC-blue.svg)](http://copyfree.org)
[![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)](http://godoc.org/github.com/daglabs/kaspad/btcjson) [![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)](http://godoc.org/github.com/kaspanet/kaspad/btcjson)
Package btcjson implements concrete types for marshalling to and from the Package btcjson implements concrete types for marshalling to and from the
bitcoin JSON-RPC API. A comprehensive suite of tests is provided to ensure bitcoin JSON-RPC API. A comprehensive suite of tests is provided to ensure
@ -25,22 +25,22 @@ ints, etc) to higher-level types with many nice and useful properties.
## Installation and Updating ## Installation and Updating
```bash ```bash
$ go get -u github.com/daglabs/kaspad/btcjson $ go get -u github.com/kaspanet/kaspad/btcjson
``` ```
## Examples ## Examples
* [Marshal Command](http://godoc.org/github.com/daglabs/kaspad/btcjson#example-MarshalCmd) * [Marshal Command](http://godoc.org/github.com/kaspanet/kaspad/btcjson#example-MarshalCmd)
Demonstrates how to create and marshal a command into a JSON-RPC request. Demonstrates how to create and marshal a command into a JSON-RPC request.
* [Unmarshal Command](http://godoc.org/github.com/daglabs/kaspad/btcjson#example-UnmarshalCmd) * [Unmarshal Command](http://godoc.org/github.com/kaspanet/kaspad/btcjson#example-UnmarshalCmd)
Demonstrates how to unmarshal a JSON-RPC request and then unmarshal the Demonstrates how to unmarshal a JSON-RPC request and then unmarshal the
concrete request into a concrete command. concrete request into a concrete command.
* [Marshal Response](http://godoc.org/github.com/daglabs/kaspad/btcjson#example-MarshalResponse) * [Marshal Response](http://godoc.org/github.com/kaspanet/kaspad/btcjson#example-MarshalResponse)
Demonstrates how to marshal a JSON-RPC response. Demonstrates how to marshal a JSON-RPC response.
* [Unmarshal Response](http://godoc.org/github.com/daglabs/kaspad/btcjson#example-package--UnmarshalResponse) * [Unmarshal Response](http://godoc.org/github.com/kaspanet/kaspad/btcjson#example-package--UnmarshalResponse)
Demonstrates how to unmarshal a JSON-RPC response and then unmarshal the Demonstrates how to unmarshal a JSON-RPC response and then unmarshal the
result field in the response to a concrete type. result field in the response to a concrete type.

View File

@ -12,7 +12,7 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/daglabs/kaspad/btcjson" "github.com/kaspanet/kaspad/btcjson"
) )
// TestBtcdExtCmds tests all of the btcd extended commands marshal and unmarshal // TestBtcdExtCmds tests all of the btcd extended commands marshal and unmarshal

View File

@ -9,7 +9,7 @@ import (
"encoding/json" "encoding/json"
"testing" "testing"
"github.com/daglabs/kaspad/btcjson" "github.com/kaspanet/kaspad/btcjson"
) )
// TestBtcdExtCustomResults ensures any results that have custom marshalling // TestBtcdExtCustomResults ensures any results that have custom marshalling

View File

@ -8,7 +8,7 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/daglabs/kaspad/btcjson" "github.com/kaspanet/kaspad/btcjson"
) )
// TestCmdMethod tests the CmdMethod function to ensure it retunrs the expected // TestCmdMethod tests the CmdMethod function to ensure it retunrs the expected

View File

@ -10,7 +10,7 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/daglabs/kaspad/btcjson" "github.com/kaspanet/kaspad/btcjson"
) )
// TestAssignField tests the assignField function handles supported combinations // TestAssignField tests the assignField function handles supported combinations

View File

@ -11,7 +11,7 @@ import (
"encoding/json" "encoding/json"
"fmt" "fmt"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
// AddManualNodeCmd defines the addManualNode JSON-RPC command. // AddManualNodeCmd defines the addManualNode JSON-RPC command.

View File

@ -11,8 +11,8 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/daglabs/kaspad/btcjson" "github.com/kaspanet/kaspad/btcjson"
"github.com/daglabs/kaspad/wire" "github.com/kaspanet/kaspad/wire"
) )
// TestDAGSvrCmds tests all of the dag server commands marshal and unmarshal // TestDAGSvrCmds tests all of the dag server commands marshal and unmarshal

View File

@ -8,7 +8,7 @@ import (
"encoding/json" "encoding/json"
"testing" "testing"
"github.com/daglabs/kaspad/btcjson" "github.com/kaspanet/kaspad/btcjson"
) )
// TestDAGSvrCustomResults ensures any results that have custom marshalling // TestDAGSvrCustomResults ensures any results that have custom marshalling

View File

@ -12,7 +12,7 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/daglabs/kaspad/btcjson" "github.com/kaspanet/kaspad/btcjson"
) )
// TestDAGSvrWsCmds tests all of the dag server websocket-specific commands // TestDAGSvrWsCmds tests all of the dag server websocket-specific commands

View File

@ -12,10 +12,10 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/daglabs/kaspad/util/subnetworkid" "github.com/kaspanet/kaspad/util/subnetworkid"
"github.com/daglabs/kaspad/btcjson" "github.com/kaspanet/kaspad/btcjson"
"github.com/daglabs/kaspad/util/daghash" "github.com/kaspanet/kaspad/util/daghash"
) )
// TestDAGSvrWsNtfns tests all of the dag server websocket-specific // TestDAGSvrWsNtfns tests all of the dag server websocket-specific

View File

@ -9,7 +9,7 @@ import (
"encoding/json" "encoding/json"
"testing" "testing"
"github.com/daglabs/kaspad/btcjson" "github.com/kaspanet/kaspad/btcjson"
) )
// TestDAGSvrWsResults ensures any results that have custom marshalling // TestDAGSvrWsResults ensures any results that have custom marshalling

View File

@ -7,7 +7,7 @@ package btcjson_test
import ( import (
"testing" "testing"
"github.com/daglabs/kaspad/btcjson" "github.com/kaspanet/kaspad/btcjson"
) )
// TestErrorCodeStringer tests the stringized output for the ErrorCode type. // TestErrorCodeStringer tests the stringized output for the ErrorCode type.

View File

@ -8,7 +8,7 @@ import (
"encoding/json" "encoding/json"
"fmt" "fmt"
"github.com/daglabs/kaspad/btcjson" "github.com/kaspanet/kaspad/btcjson"
) )
// This example demonstrates how to create and marshal a command into a JSON-RPC // This example demonstrates how to create and marshal a command into a JSON-RPC

View File

@ -11,7 +11,7 @@ import (
"strings" "strings"
"text/tabwriter" "text/tabwriter"
"github.com/daglabs/kaspad/util" "github.com/kaspanet/kaspad/util"
) )
// baseHelpDescs house the various help labels, types, and example values used // baseHelpDescs house the various help labels, types, and example values used

View File

@ -8,7 +8,7 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/daglabs/kaspad/btcjson" "github.com/kaspanet/kaspad/btcjson"
) )
// TestHelpReflectInternals ensures the various help functions which deal with // TestHelpReflectInternals ensures the various help functions which deal with

View File

@ -8,7 +8,7 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/daglabs/kaspad/btcjson" "github.com/kaspanet/kaspad/btcjson"
) )
// TestHelpers tests the various helper functions which create pointers to // TestHelpers tests the various helper functions which create pointers to

View File

@ -9,7 +9,7 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/daglabs/kaspad/btcjson" "github.com/kaspanet/kaspad/btcjson"
) )
// TestIsValidIDType ensures the IsValidIDType function behaves as expected. // TestIsValidIDType ensures the IsValidIDType function behaves as expected.

View File

@ -9,7 +9,7 @@ import (
"sort" "sort"
"testing" "testing"
"github.com/daglabs/kaspad/btcjson" "github.com/kaspanet/kaspad/btcjson"
) )
// TestUsageFlagStringer tests the stringized output for the UsageFlag type. // TestUsageFlagStringer tests the stringized output for the UsageFlag type.

View File

@ -9,10 +9,10 @@ import (
"path/filepath" "path/filepath"
"runtime" "runtime"
"github.com/daglabs/kaspad/database" "github.com/kaspanet/kaspad/database"
"github.com/daglabs/kaspad/limits" "github.com/kaspanet/kaspad/limits"
"github.com/daglabs/kaspad/logs" "github.com/kaspanet/kaspad/logs"
"github.com/daglabs/kaspad/util/panics" "github.com/kaspanet/kaspad/util/panics"
) )
const ( const (

Some files were not shown because too many files have changed in this diff Show More