From d9841515494d8c9641f892bb85f2f07cf8180af0 Mon Sep 17 00:00:00 2001 From: stasatdaglabs <39559713+stasatdaglabs@users.noreply.github.com> Date: Thu, 2 Jan 2020 16:57:43 +0200 Subject: [PATCH] [NOD-517] Update doc.go files (#559) * [NOD-517] Remove copyright notices from all doc.go. * [NOD-517] Updated the root doc.go. * [NOD-517] Remove all cov_report.sh and test_coverage.txt. * [NOD-517] Make all doc.go use the same style of comment. * [NOD-517] Update dagconfig doc.go. * [NOD-517] Update blockdag doc.go. * [NOD-517] Update doc.go in connmgr. * [NOD-517] Update doc.go in fullblocktests. * [NOD-517] Update doc.go in database. * [NOD-517] Update doc.go in ecc. * [NOD-517] Update doc.go in rpctest. * [NOD-517] Removed superfluous license in logs. * [NOD-517] Update doc.go in mempool. * [NOD-517] Updated doc.go in peer. * [NOD-517] Update doc.go in rpcclient. * [NOD-517] Update doc.go in txscript. * [NOD-517] Update doc.go in util. * [NOD-517] Update doc.go in base58. * [NOD-517] Update doc.go in bech32. * [NOD-517] Update doc.go in txsort. * [NOD-517] Update doc.go in wire. * [NOD-517] Fix indentation. * [NOD-517] Add a copyright notice to the main doc.go. * [NOD-517] Add Conformal to the license notices. * [NOD-517] Remove superfluous language from a doc. * [NOD-517] Fix bad example. --- LICENSE | 1 + addrmgr/cov_report.sh | 17 ----- addrmgr/doc.go | 4 - addrmgr/test_coverage.txt | 62 --------------- blockdag/doc.go | 27 +++---- connmgr/doc.go | 17 ++++- dagconfig/README.md | 4 +- dagconfig/doc.go | 122 +++++++++++++++--------------- database/doc.go | 4 - database/ffldb/doc.go | 4 - database/internal/treap/doc.go | 4 - doc.go | 122 ++++-------------------------- ecc/doc.go | 9 +-- integration/rpctest/doc.go | 19 ++--- logs/LICENSE | 15 ---- logs/doc.go | 4 - mempool/doc.go | 8 -- netsync/doc.go | 4 - peer/doc.go | 12 --- rpcclient/doc.go | 13 +--- rpcmodel/doc.go | 4 - txscript/doc.go | 8 +- util/base58/cov_report.sh | 17 ----- util/base58/doc.go | 14 +--- util/bech32/doc.go | 8 +- util/bloom/cov_report.sh | 17 ----- util/bloom/test_coverage.txt | 28 ------- util/cov_report.sh | 17 ----- util/daghash/doc.go | 10 ++- util/doc.go | 19 ++--- util/hdkeychain/cov_report.sh | 17 ----- util/hdkeychain/doc.go | 4 - util/hdkeychain/test_coverage.txt | 20 ----- util/txsort/doc.go | 6 +- wire/doc.go | 22 ++---- 35 files changed, 140 insertions(+), 543 deletions(-) delete mode 100644 addrmgr/cov_report.sh delete mode 100644 addrmgr/test_coverage.txt delete mode 100644 logs/LICENSE delete mode 100644 util/base58/cov_report.sh delete mode 100644 util/bloom/cov_report.sh delete mode 100644 util/bloom/test_coverage.txt delete mode 100644 util/cov_report.sh delete mode 100644 util/hdkeychain/cov_report.sh delete mode 100644 util/hdkeychain/test_coverage.txt diff --git a/LICENSE b/LICENSE index 7fe8161a4..05759ed08 100644 --- a/LICENSE +++ b/LICENSE @@ -3,6 +3,7 @@ ISC License Copyright (c) 2018-2019 The kaspanet developers Copyright (c) 2013-2018 The btcsuite developers Copyright (c) 2015-2016 The Decred developers +Copyright (c) 2013-2014 Conformal Systems LLC. Permission to use, copy, modify, and distribute this software for any purpose with or without fee is hereby granted, provided that the above diff --git a/addrmgr/cov_report.sh b/addrmgr/cov_report.sh deleted file mode 100644 index 307f05b76..000000000 --- a/addrmgr/cov_report.sh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh - -# This script uses gocov to generate a test coverage report. -# The gocov tool my be obtained with the following command: -# go get github.com/axw/gocov/gocov -# -# It will be installed to $GOPATH/bin, so ensure that location is in your $PATH. - -# Check for gocov. -type gocov >/dev/null 2>&1 -if [ $? -ne 0 ]; then - echo >&2 "This script requires the gocov tool." - echo >&2 "You may obtain it with the following command:" - echo >&2 "go get github.com/axw/gocov/gocov" - exit 1 -fi -gocov test | gocov report diff --git a/addrmgr/doc.go b/addrmgr/doc.go index 86a0ad928..fc742fc02 100644 --- a/addrmgr/doc.go +++ b/addrmgr/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2014 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package addrmgr implements concurrency safe Kaspa address manager. diff --git a/addrmgr/test_coverage.txt b/addrmgr/test_coverage.txt deleted file mode 100644 index c67e0f6d0..000000000 --- a/addrmgr/test_coverage.txt +++ /dev/null @@ -1,62 +0,0 @@ - -github.com/conformal/btcd/addrmgr/network.go GroupKey 100.00% (23/23) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.reset 100.00% (6/6) -github.com/conformal/btcd/addrmgr/network.go IsRFC5737 100.00% (4/4) -github.com/conformal/btcd/addrmgr/network.go IsRFC1918 100.00% (4/4) -github.com/conformal/btcd/addrmgr/addrmanager.go New 100.00% (3/3) -github.com/conformal/btcd/addrmgr/addrmanager.go NetAddressKey 100.00% (2/2) -github.com/conformal/btcd/addrmgr/network.go IsRFC4862 100.00% (1/1) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.numAddresses 100.00% (1/1) -github.com/conformal/btcd/addrmgr/log.go init 100.00% (1/1) -github.com/conformal/btcd/addrmgr/log.go DisableLog 100.00% (1/1) -github.com/conformal/btcd/addrmgr/network.go ipNet 100.00% (1/1) -github.com/conformal/btcd/addrmgr/network.go IsIPv4 100.00% (1/1) -github.com/conformal/btcd/addrmgr/network.go IsLocal 100.00% (1/1) -github.com/conformal/btcd/addrmgr/network.go IsOnionCatTor 100.00% (1/1) -github.com/conformal/btcd/addrmgr/network.go IsRFC2544 100.00% (1/1) -github.com/conformal/btcd/addrmgr/network.go IsRFC3849 100.00% (1/1) -github.com/conformal/btcd/addrmgr/network.go IsRFC3927 100.00% (1/1) -github.com/conformal/btcd/addrmgr/network.go IsRFC3964 100.00% (1/1) -github.com/conformal/btcd/addrmgr/network.go IsRFC4193 100.00% (1/1) -github.com/conformal/btcd/addrmgr/network.go IsRFC4380 100.00% (1/1) -github.com/conformal/btcd/addrmgr/network.go IsRFC4843 100.00% (1/1) -github.com/conformal/btcd/addrmgr/network.go IsRFC6052 100.00% (1/1) -github.com/conformal/btcd/addrmgr/network.go IsRFC6145 100.00% (1/1) -github.com/conformal/btcd/addrmgr/network.go IsRFC6598 100.00% (1/1) -github.com/conformal/btcd/addrmgr/network.go IsValid 100.00% (1/1) -github.com/conformal/btcd/addrmgr/network.go IsRoutable 100.00% (1/1) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.GetBestLocalAddress 94.74% (18/19) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.AddLocalAddress 90.91% (10/11) -github.com/conformal/btcd/addrmgr/addrmanager.go getReachabilityFrom 51.52% (17/33) -github.com/conformal/btcd/addrmgr/addrmanager.go ipString 50.00% (2/4) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.GetAddress 9.30% (4/43) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.deserializePeers 0.00% (0/50) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.Good 0.00% (0/44) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.savePeers 0.00% (0/39) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.updateAddress 0.00% (0/30) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.expireNew 0.00% (0/22) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.AddressCache 0.00% (0/16) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.HostToNetAddress 0.00% (0/15) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.getNewBucket 0.00% (0/15) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.AddAddressByIP 0.00% (0/14) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.getTriedBucket 0.00% (0/14) -github.com/conformal/btcd/addrmgr/knownaddress.go knownAddress.chance 0.00% (0/13) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.loadPeers 0.00% (0/11) -github.com/conformal/btcd/addrmgr/knownaddress.go knownAddress.isBad 0.00% (0/11) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.Connected 0.00% (0/10) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.addressHandler 0.00% (0/9) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.pickTried 0.00% (0/8) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.DeserializeNetAddress 0.00% (0/7) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.Stop 0.00% (0/7) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.Attempt 0.00% (0/7) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.Start 0.00% (0/6) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.AddAddresses 0.00% (0/4) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.NeedMoreAddresses 0.00% (0/3) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.NumAddresses 0.00% (0/3) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.AddAddress 0.00% (0/3) -github.com/conformal/btcd/addrmgr/knownaddress.go knownAddress.LastAttempt 0.00% (0/1) -github.com/conformal/btcd/addrmgr/knownaddress.go knownAddress.NetAddress 0.00% (0/1) -github.com/conformal/btcd/addrmgr/addrmanager.go AddrManager.find 0.00% (0/1) -github.com/conformal/btcd/addrmgr/log.go UseLogger 0.00% (0/1) -github.com/conformal/btcd/addrmgr --------------------------------- 21.04% (113/537) - diff --git a/blockdag/doc.go b/blockdag/doc.go index cc461fd25..0ba771de5 100644 --- a/blockdag/doc.go +++ b/blockdag/doc.go @@ -1,28 +1,21 @@ -// Copyright (c) 2013-2014 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package blockdag implements kaspa block handling and DAG selection rules. The kaspa block handling and DAG selection rules are an integral, and quite -likely the most important, part of kaspa. At its core, kaspa is a -distributed consensus of which blocks are valid and which ones will comprise the -DAG (public ledger) that ultimately determines accepted -transactions, so it is extremely important that fully validating nodes agree on -all rules. +likely the most important, part of kaspa. At its core, kaspa is a distributed +consensus of which blocks are valid and which ones will comprise the DAG +(public ledger) that ultimately determines accepted transactions, so it is +extremely important that fully validating nodes agree on all rules. At a high level, this package provides support for inserting new blocks into -the block DAG according to the aforementioned rules. It includes -functionality such as rejecting duplicate blocks, ensuring blocks and -transactions follow all rules, orphan handling, and DAG order along -with reorganization. +the block DAG according to the aforementioned rules. It includes functionality +such as rejecting duplicate blocks, ensuring blocks and transactions follow all +rules, orphan handling, and DAG order along with reorganization. Since this package does not deal with other kaspa specifics such as network -communication or wallets, it provides a notification system which gives the -caller a high level of flexibility in how they want to react to certain events -such as orphan blocks which need their parents requested and newly connected -DAG blocks which might result in wallet updates. +communication, it provides a notification system which gives the caller a high +level of flexibility in how they want to react to certain events such as orphan +blocks which need their parents requested and newly connected DAG blocks. Kaspa DAG Processing Overview diff --git a/connmgr/doc.go b/connmgr/doc.go index f3fea8d58..482c92fc8 100644 --- a/connmgr/doc.go +++ b/connmgr/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2016 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package connmgr implements a generic Kaspa network connection manager. @@ -10,5 +6,18 @@ Connection Manager Overview Connection Manager handles all the general connection concerns such as maintaining a set number of outbound connections, sourcing peers, banning, limiting max connections, tor lookup, etc. + +The package provides a generic connection manager which is able to accept +connection requests from a source or a set of given addresses, dial them and +notify the caller on connections. The main intended use is to initialize a pool +of active connections and maintain them to remain connected to the P2P network. + +In addition the connection manager provides the following utilities: + +- Notifications on connections or disconnections +- Handle failures and retry new addresses from the source +- Connect only to specified addresses +- Permanent connections with increasing backoff retry timers +- Disconnect or Remove an established connection */ package connmgr diff --git a/dagconfig/README.md b/dagconfig/README.md index f5c8c538e..e1f3ea2dc 100644 --- a/dagconfig/README.md +++ b/dagconfig/README.md @@ -4,7 +4,7 @@ dagconfig [![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/kaspanet/kaspad/dagconfig) -Package dagconfig defines DAG configuration parameters for the four standard +Package dagconfig defines DAG configuration parameters for the standard Kaspad networks and provides the ability for callers to define their own custom Kaspad networks. @@ -25,7 +25,7 @@ import ( var testnet = flag.Bool("testnet", false, "operate on the testnet Kaspa network") // By default (without --testnet), use mainnet. -var chainParams = &dagconfig.MainNetParams +var dagParams = &dagconfig.MainNetParams func main() { flag.Parse() diff --git a/dagconfig/doc.go b/dagconfig/doc.go index 72fbe5c52..c75f69f29 100644 --- a/dagconfig/doc.go +++ b/dagconfig/doc.go @@ -1,61 +1,63 @@ -// Package dagconfig defines DAG configuration parameters. -// -// In addition to the main Kaspa network, which is intended for the transfer -// of monetary value, there also exists two currently active standard networks: -// regression test and testnet. These networks are incompatible -// with each other (each sharing a different genesis block) and software should -// handle errors where input intended for one network is used on an application -// instance running on a different network. -// -// For library packages, dagconfig provides the ability to lookup DAG -// parameters and encoding magics when passed a *Params. Older APIs not updated -// to the new convention of passing a *Params may lookup the parameters for a -// wire.KaspaNet using ParamsForNet, but be aware that this usage is -// deprecated and will be removed from dagconfig in the future. -// -// For main packages, a (typically global) var may be assigned the address of -// one of the standard Param vars for use as the application's "active" network. -// When a network parameter is needed, it may then be looked up through this -// variable (either directly, or hidden in a library call). -// -// package main -// -// import ( -// "flag" -// "fmt" -// "log" -// -// "github.com/kaspanet/kaspad/util" -// "github.com/kaspanet/kaspad/dagconfig" -// ) -// -// var testnet = flag.Bool("testnet", false, "operate on the testnet Kaspa network") -// -// // By default (without -testnet), use mainnet. -// var dagParams = &dagconfig.MainNetParams -// -// func main() { -// flag.Parse() -// -// // Modify active network parameters if operating on testnet. -// if *testnet { -// dagParams = &dagconfig.TestNetParams -// } -// -// // later... -// -// // Create and print new payment address, specific to the active network. -// pubKeyHash := make([]byte, 20) -// addr, err := util.NewAddressPubKeyHash(pubKeyHash, dagParams) -// if err != nil { -// log.Fatal(err) -// } -// fmt.Println(addr) -// } -// -// If an application does not use one of the three standard Kaspa networks, -// a new Params struct may be created which defines the parameters for the -// non-standard network. As a general rule of thumb, all network parameters -// should be unique to the network, but parameter collisions can still occur -// (unfortunately, this is the case with regtest and testnet sharing magics). +/* +Package dagconfig defines DAG configuration parameters. + +In addition to the main Kaspa network, which is intended for the transfer +of monetary value, there also exists the following standard networks: + * testnet + * simnet + * devnet + * regression test +These networks are incompatible with each other (each sharing a different +genesis block) and software should handle errors where input intended for +one network is used on an application instance running on a different +network. + +For library packages, dagconfig provides the ability to lookup DAG +parameters and encoding magics when passed a *Params. + +For main packages, a (typically global) var may be assigned the address of +one of the standard Param vars for use as the application's "active" network. +When a network parameter is needed, it may then be looked up through this +variable (either directly, or hidden in a library call). + + package main + + import ( + "flag" + "fmt" + "log" + + "github.com/kaspanet/kaspad/util" + "github.com/kaspanet/kaspad/dagconfig" + ) + + var testnet = flag.Bool("testnet", false, "operate on the testnet Kaspa network") + + // By default (without --testnet), use mainnet. + var dagParams = &dagconfig.MainNetParams + + func main() { + flag.Parse() + + // Modify active network parameters if operating on testnet. + if *testnet { + dagParams = &dagconfig.TestNetParams + } + + // later... + + // Create and print new payment address, specific to the active network. + pubKeyHash := make([]byte, 20) + addr, err := util.NewAddressPubKeyHash(pubKeyHash, dagParams) + if err != nil { + log.Fatal(err) + } + fmt.Println(addr) + } + +If an application does not use one of the standard Kaspa networks, a new +Params struct may be created which defines the parameters for the non- +standard network. As a general rule of thumb, all network parameters +should be unique to the network, but parameter collisions can still occur. +*/ package dagconfig diff --git a/database/doc.go b/database/doc.go index 37b5dadb3..a9202671e 100644 --- a/database/doc.go +++ b/database/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2015-2016 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package database provides a block and metadata storage database. diff --git a/database/ffldb/doc.go b/database/ffldb/doc.go index 52888d263..7e3b8beec 100644 --- a/database/ffldb/doc.go +++ b/database/ffldb/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2015-2016 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package ffldb implements a driver for the database package that uses leveldb for the backing metadata and flat files for block storage. diff --git a/database/internal/treap/doc.go b/database/internal/treap/doc.go index 6714e2f0d..f2cbcb8fa 100644 --- a/database/internal/treap/doc.go +++ b/database/internal/treap/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2015-2016 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package treap implements a treap data structure that is used to hold ordered key/value pairs using a combination of binary search tree and heap semantics. diff --git a/doc.go b/doc.go index d68eff1d6..972db3949 100644 --- a/doc.go +++ b/doc.go @@ -1,121 +1,27 @@ -// Copyright (c) 2013-2017 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* +Copyright (c) 2018-2019 The kaspanet developers +Copyright (c) 2013-2018 The btcsuite developers +Copyright (c) 2015-2016 The Decred developers +Copyright (c) 2013-2014 Conformal Systems LLC. +Use of this source code is governed by an ISC +license that can be found in the LICENSE file. + kaspad is a full-node kaspa implementation written in Go. The default options are sane for most users. This means kaspad will work 'out of the box' for most users. However, there are also a wide variety of flags that can be used to control it. -The following section provides a usage overview which enumerates the flags. An -interesting point to note is that the long form of all of these options -(except -C) can be specified in a configuration file that is automatically -parsed when kaspad starts up. By default, the configuration file is located at -~/.kaspad/kaspad.conf on POSIX-style operating systems and %LOCALAPPDATA%\kaspad\kaspad.conf -on Windows. The -C (--configfile) flag, as shown below, can be used to override -this location. - Usage: kaspad [OPTIONS] -Application Options: - -V, --version Display version information and exit - -C, --configfile= Path to configuration file - -b, --datadir= Directory to store data - --logdir= Directory to log output. - -a, --addpeer= Add a peer to connect with at startup - --connect= Connect only to the specified peers at startup - --nolisten Disable listening for incoming connections -- NOTE: - Listening is automatically disabled if the --connect - or --proxy options are used without also specifying - listen interfaces via --listen - --listen= Add an interface/port to listen for connections - (default all interfaces port: 16111, testnet: 16211) - --maxpeers= Max number of inbound and outbound peers (125) - --nobanning Disable banning of misbehaving peers - --banduration= How long to ban misbehaving peers. Valid time units - are {s, m, h}. Minimum 1 second (24h0m0s) - --banthreshold= Maximum allowed ban score before disconnecting and - banning misbehaving peers. - --whitelist= Add an IP network or IP that will not be banned. - (eg. 192.168.1.0/24 or ::1) - -u, --rpcuser= Username for RPC connections - -P, --rpcpass= Password for RPC connections - --rpclimituser= Username for limited RPC connections - --rpclimitpass= Password for limited RPC connections - --rpclisten= Add an interface/port to listen for RPC connections - (default port: 16110, testnet: 16210) - --rpccert= File containing the certificate file - --rpckey= File containing the certificate key - --rpcmaxclients= Max number of RPC clients for standard connections - (10) - --rpcmaxwebsockets= Max number of RPC websocket connections (25) - --norpc Disable built-in RPC server -- NOTE: The RPC server - is disabled by default if no rpcuser/rpcpass or - rpclimituser/rpclimitpass is specified - --notls Disable TLS for the RPC server -- NOTE: This is only - allowed if the RPC server is bound to localhost - --nodnsseed Disable DNS seeding for peers - --externalip= Add an ip to the list of local addresses we claim to - listen on to peers - --proxy= Connect via SOCKS5 proxy (eg. 127.0.0.1:9050) - --proxyuser= Username for proxy server - --proxypass= Password for proxy server - --onion= Connect to tor hidden services via SOCKS5 proxy - (eg. 127.0.0.1:9050) - --onionuser= Username for onion proxy server - --onionpass= Password for onion proxy server - --noonion Disable connecting to tor hidden services - --torisolation Enable Tor stream isolation by randomizing user - credentials for each connection. - --testnet Use the test network - --regtest Use the regression test network - --simnet Use the simulation test network - --uacomment= Comment to add to the user agent -- - See BIP 14 for more information. - --dbtype= Database backend to use for the Block DAG (ffldb) - --profile= Enable HTTP profiling on given port -- NOTE port - must be between 1024 and 65536 - --cpuprofile= Write CPU profile to the specified file - -d, --debuglevel= Logging level for all subsystems {trace, debug, - info, warn, error, critical} -- You may also specify - =,=,... to set - the log level for individual subsystems -- Use show - to list available subsystems (info) - --upnp Use UPnP to map our listening port outside of NAT - --minrelaytxfee= The minimum transaction fee in KAS/kB to be - considered a non-zero fee. - --limitfreerelay= Limit relay of transactions with no transaction fee - to the given amount in thousands of bytes per - minute (15) - --norelaypriority Do not require free or low-fee transactions to have - high priority for relaying - --maxorphantx= Max number of orphan transactions to keep in memory - (100) - --generate Generate (mine) kaspa using the CPU - --miningaddr= Add the specified payment address to the list of - addresses to use for generated blocks -- At least - one address is required if the generate option is - set - --blockminsize= Mininum block size in bytes to be used when creating - a block - --blockmaxsize= Maximum block size in bytes to be used when creating - a block (750000) - --blockprioritysize= Size in bytes for high-priority/low-fee transactions - when creating a block (50000) - --nopeerbloomfilters Disable bloom filtering support. - --sigcachemaxsize= The maximum number of entries in the signature - verification cache. - --blocksonly Do not accept transactions from remote peers. - --relaynonstd Relay non-standard transactions regardless of the - default settings for the active network. - --rejectnonstd Reject non-standard transactions regardless of the - default settings for the active network. - -Help Options: - -h, --help Show this help message +For an up-to-date help message: + kaspad --help +The long form of all option flags (except -C) can be specified in a configuration +file that is automatically parsed when kaspad starts up. By default, the +configuration file is located at ~/.kaspad/kaspad.conf on POSIX-style operating +systems and %LOCALAPPDATA%\kaspad\kaspad.conf on Windows. The -C (--configfile) +flag can be used to override this location. */ package main diff --git a/ecc/doc.go b/ecc/doc.go index 7f107b565..39452338d 100644 --- a/ecc/doc.go +++ b/ecc/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2013-2014 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package ecc implements support for the elliptic curves needed for kaspa. @@ -14,8 +10,7 @@ This package provides the data structures and functions implementing the crypto/elliptic Curve interface in order to permit using these curves with the standard crypto/ecdsa package provided with go. Helper functionality is provided to parse signatures and public keys from -standard formats. It was designed for use with kaspad, but should be -general enough for other uses of elliptic curve crypto. It was originally based -on some initial work by ThePiachu, but has significantly diverged since then. +standard formats. It was originally based on some initial work by +ThePiachu, but has significantly diverged since then. */ package ecc diff --git a/integration/rpctest/doc.go b/integration/rpctest/doc.go index e80f727e1..207fcc401 100644 --- a/integration/rpctest/doc.go +++ b/integration/rpctest/doc.go @@ -1,12 +1,9 @@ -// Package rpctest provides a kaspad-specific RPC testing harness crafting and -// executing integration tests by driving a `kaspad` instance via the `RPC` -// interface. Each instance of an active harness comes equipped with a simple -// in-memory HD wallet capable of properly syncing to the generated chain, -// creating new addresses, and crafting fully signed transactions paying to an -// arbitrary set of outputs. -// -// This package was designed specifically to act as an RPC testing harness for -// `kaspad`. However, the constructs presented are general enough to be adapted to -// any project wishing to programmatically drive a `kaspad` instance of its -// systems/integration tests. +/* +Package rpctest provides a kaspad-specific RPC testing harness crafting and +executing integration tests by driving a `kaspad` instance via the `RPC` +interface. Each instance of an active harness comes equipped with a simple +in-memory HD wallet capable of properly syncing to the generated chain, +creating new addresses, and crafting fully signed transactions paying to an +arbitrary set of outputs. +*/ package rpctest diff --git a/logs/LICENSE b/logs/LICENSE deleted file mode 100644 index 7b8140304..000000000 --- a/logs/LICENSE +++ /dev/null @@ -1,15 +0,0 @@ -ISC License - -Copyright (c) 2013-2014 Conformal Systems LLC. - -Permission to use, copy, modify, and distribute this software for any -purpose with or without fee is hereby granted, provided that the above -copyright notice and this permission notice appear in all copies. - -THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF -OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/logs/doc.go b/logs/doc.go index 3ee613f28..8d600aefa 100644 --- a/logs/doc.go +++ b/logs/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2013-2017 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package logs defines an interface and default implementation for subsystem logging. diff --git a/mempool/doc.go b/mempool/doc.go index d70cdb159..c0dbd5d2d 100644 --- a/mempool/doc.go +++ b/mempool/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2016 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package mempool provides a policy-enforced pool of unmined kaspa transactions. @@ -51,14 +47,10 @@ be an exhaustive list. - Configurable transaction acceptance policy - Option to accept or reject standard transactions - Option to accept or reject transactions based on priority calculations - - Rate limiting of low-fee and free transactions - - Non-zero fee threshold - Max signature operations per transaction - - Max orphan transaction size - Max number of orphan transactions allowed - Additional metadata tracking for each transaction - Timestamp when the transaction was added to the pool - - Most recent block height when the transaction was added to the pool - The fee the transaction pays - The starting priority for the transaction - Manual control of transaction removal diff --git a/netsync/doc.go b/netsync/doc.go index 2acda4694..b40dd60f2 100644 --- a/netsync/doc.go +++ b/netsync/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2017 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package netsync implements a concurrency safe block syncing protocol. The SyncManager communicates with connected peers to perform an initial block diff --git a/peer/doc.go b/peer/doc.go index 81b85e1f6..08237009a 100644 --- a/peer/doc.go +++ b/peer/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2015-2016 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package peer provides a common base for creating and managing kaspa network peers. @@ -133,13 +129,5 @@ Peer Statistics A snapshot of the current peer statistics can be obtained with the StatsSnapshot function. This includes statistics such as the total number of bytes read and written, the remote address, user agent, and negotiated protocol version. - -Logging - -This package provides extensive logging capabilities through the UseLogger -function which allows a logs.Logger to be specified. For example, logging at -the debug level provides summaries of every message sent and received, and -logging at the trace level provides full dumps of parsed messages as well as the -raw message bytes using a format similar to hexdump -C. */ package peer diff --git a/rpcclient/doc.go b/rpcclient/doc.go index c2c3818f8..be59a5088 100644 --- a/rpcclient/doc.go +++ b/rpcclient/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2014-2017 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package rpcclient implements a websocket-enabled kaspa JSON-RPC client. @@ -59,8 +55,8 @@ work when connected via websockets. This should intuitively make sense because HTTP POST mode does not keep a connection open! All notifications provided by kaspad require registration to opt-in. For example, -if you want to be notified when funds are received by a set of addresses, you -register the addresses via the NotifyReceived (or NotifyReceivedAsync) function. +if you want to be notified when blocks are added to the DAG, you register the +via the NotifyBlocks (or NotifyBlocksAsync) function. Notification Handlers @@ -123,7 +119,7 @@ The third category of errors, that is errors returned by the server, can be detected by type asserting the error in a *rpcmodel.RPCError. For example, to detect if a command is unimplemented by the remote RPC server: - amount, err := client.GetBalance("") + netTotals, err := client.GetNetTotals() if err != nil { if jerr, ok := err.(*rpcmodel.RPCError); ok { switch jerr.Code { @@ -147,7 +143,6 @@ The following full-blown client examples are in the examples directory: and gets the current block count - websockets Connects to a kaspad RPC server using TLS-secured websockets, registers for - block connected and block disconnected notifications, and gets the current - block count + block added notifications, and gets the current block count */ package rpcclient diff --git a/rpcmodel/doc.go b/rpcmodel/doc.go index 856fa188a..e5c4948d9 100644 --- a/rpcmodel/doc.go +++ b/rpcmodel/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2015 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package rpcmodel provides primitives for working with the kaspa JSON-RPC API. diff --git a/txscript/doc.go b/txscript/doc.go index 728b49a48..b7dbdf070 100644 --- a/txscript/doc.go +++ b/txscript/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2013-2017 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package txscript implements the kaspa transaction script language. @@ -18,8 +14,8 @@ performing basic and bitwise arithmetic, conditional branching, comparing hashes, and checking cryptographic signatures. Scripts are processed from left to right and intentionally do not provide loops. -The vast majority of kaspa scripts at the time of this writing are of several -standard forms which consist of a spender providing a public key and a signature +Typical kaspa scripts at the time of this writing are of several standard +forms which consist of a spender providing a public key and a signature which proves the spender owns the associated private key. This information is used to prove the the spender is authorized to perform the transaction. diff --git a/util/base58/cov_report.sh b/util/base58/cov_report.sh deleted file mode 100644 index 307f05b76..000000000 --- a/util/base58/cov_report.sh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh - -# This script uses gocov to generate a test coverage report. -# The gocov tool my be obtained with the following command: -# go get github.com/axw/gocov/gocov -# -# It will be installed to $GOPATH/bin, so ensure that location is in your $PATH. - -# Check for gocov. -type gocov >/dev/null 2>&1 -if [ $? -ne 0 ]; then - echo >&2 "This script requires the gocov tool." - echo >&2 "You may obtain it with the following command:" - echo >&2 "go get github.com/axw/gocov/gocov" - exit 1 -fi -gocov test | gocov report diff --git a/util/base58/doc.go b/util/base58/doc.go index e3fc1085a..0d61593a9 100644 --- a/util/base58/doc.go +++ b/util/base58/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2014 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package base58 provides an API for working with modified base58 and Base58Check encodings. @@ -17,13 +13,7 @@ The modified base58 alphabet used by kaspa, and hence this package, omits the 0, O, I, and l characters that look the same in many fonts and are therefore hard to humans to distinguish. -Base58Check Encoding Scheme - -The Base58Check encoding scheme is primarily used for kaspa addresses at the -time of this writing, however it can be used to generically encode arbitrary -byte arrays into human-readable strings along with a version byte that can be -used to differentiate the same payload. For kaspa addresses, the extra -version is used to differentiate the network of otherwise identical public keys -which helps prevent using an address intended for one network on another. +At the time of this writing, the Base58 encoding scheme is primarily used +for kaspa private keys. */ package base58 diff --git a/util/bech32/doc.go b/util/bech32/doc.go index 2c676ad32..ea994ca1b 100644 --- a/util/bech32/doc.go +++ b/util/bech32/doc.go @@ -1,12 +1,8 @@ -// Copyright (c) 2017 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package bech32 provides a Go implementation of the bech32 format. -Bech32 strings consist of a prefix, followed by the -separator :, then a checksummed data part encoded using the 32 characters +Bech32 strings consist of a prefix, followed by the separator :, +then a checksummed data part encoded using the 32 characters "qpzry9x8gf2tvdw0s3jn54khce6mua7l". */ package bech32 diff --git a/util/bloom/cov_report.sh b/util/bloom/cov_report.sh deleted file mode 100644 index 307f05b76..000000000 --- a/util/bloom/cov_report.sh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh - -# This script uses gocov to generate a test coverage report. -# The gocov tool my be obtained with the following command: -# go get github.com/axw/gocov/gocov -# -# It will be installed to $GOPATH/bin, so ensure that location is in your $PATH. - -# Check for gocov. -type gocov >/dev/null 2>&1 -if [ $? -ne 0 ]; then - echo >&2 "This script requires the gocov tool." - echo >&2 "You may obtain it with the following command:" - echo >&2 "go get github.com/axw/gocov/gocov" - exit 1 -fi -gocov test | gocov report diff --git a/util/bloom/test_coverage.txt b/util/bloom/test_coverage.txt deleted file mode 100644 index 60b4fbe56..000000000 --- a/util/bloom/test_coverage.txt +++ /dev/null @@ -1,28 +0,0 @@ - -github.com/conformal/btcutil/bloom/murmurhash3.go MurmurHash3 100.00% (31/31) -github.com/conformal/btcutil/bloom/merkleblock.go NewMerkleBlock 100.00% (19/19) -github.com/conformal/btcutil/bloom/merkleblock.go merkleBlock.traverseAndBuild 100.00% (10/10) -github.com/conformal/btcutil/bloom/merkleblock.go merkleBlock.calcHash 100.00% (8/8) -github.com/conformal/btcutil/bloom/filter.go Filter.maybeAddOutpoint 100.00% (7/7) -github.com/conformal/btcutil/bloom/filter.go Filter.addOutpoint 100.00% (4/4) -github.com/conformal/btcutil/bloom/filter.go Filter.IsLoaded 100.00% (4/4) -github.com/conformal/btcutil/bloom/filter.go Filter.MsgFilterLoad 100.00% (4/4) -github.com/conformal/btcutil/bloom/filter.go Filter.matchesOutpoint 100.00% (4/4) -github.com/conformal/btcutil/bloom/filter.go Filter.MatchesOutpoint 100.00% (4/4) -github.com/conformal/btcutil/bloom/filter.go Filter.MatchTxAndUpdate 100.00% (4/4) -github.com/conformal/btcutil/bloom/filter.go Filter.Matches 100.00% (4/4) -github.com/conformal/btcutil/bloom/filter.go Filter.Add 100.00% (3/3) -github.com/conformal/btcutil/bloom/filter.go Filter.Reload 100.00% (3/3) -github.com/conformal/btcutil/bloom/filter.go Filter.Unload 100.00% (3/3) -github.com/conformal/btcutil/bloom/filter.go Filter.AddShaHash 100.00% (3/3) -github.com/conformal/btcutil/bloom/filter.go Filter.AddOutpoint 100.00% (3/3) -github.com/conformal/btcutil/bloom/filter.go minUint32 100.00% (3/3) -github.com/conformal/btcutil/bloom/filter.go Filter.hash 100.00% (2/2) -github.com/conformal/btcutil/bloom/merkleblock.go merkleBlock.calcTreeWidth 100.00% (1/1) -github.com/conformal/btcutil/bloom/filter.go LoadFilter 100.00% (1/1) -github.com/conformal/btcutil/bloom/filter.go Filter.matchTxAndUpdate 91.30% (21/23) -github.com/conformal/btcutil/bloom/filter.go Filter.matches 85.71% (6/7) -github.com/conformal/btcutil/bloom/filter.go NewFilter 81.82% (9/11) -github.com/conformal/btcutil/bloom/filter.go Filter.add 80.00% (4/5) -github.com/conformal/btcutil/bloom ---------------------------- 96.49% (165/171) - diff --git a/util/cov_report.sh b/util/cov_report.sh deleted file mode 100644 index 307f05b76..000000000 --- a/util/cov_report.sh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh - -# This script uses gocov to generate a test coverage report. -# The gocov tool my be obtained with the following command: -# go get github.com/axw/gocov/gocov -# -# It will be installed to $GOPATH/bin, so ensure that location is in your $PATH. - -# Check for gocov. -type gocov >/dev/null 2>&1 -if [ $? -ne 0 ]; then - echo >&2 "This script requires the gocov tool." - echo >&2 "You may obtain it with the following command:" - echo >&2 "go get github.com/axw/gocov/gocov" - exit 1 -fi -gocov test | gocov report diff --git a/util/daghash/doc.go b/util/daghash/doc.go index f679572c4..df5c40aa6 100644 --- a/util/daghash/doc.go +++ b/util/daghash/doc.go @@ -1,5 +1,7 @@ -// Package daghash provides abstracted hash functionality. -// -// This package provides a generic hash type and associated functions that -// allows the specific hash algorithm to be abstracted. +/* +Package daghash provides abstracted hash functionality. + +This package provides a generic hash type and associated functions that +allows the specific hash algorithm to be abstracted. +*/ package daghash diff --git a/util/doc.go b/util/doc.go index 23881df9b..27fc03bf0 100644 --- a/util/doc.go +++ b/util/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2013-2014 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package util provides kaspa-specific convenience functions and types. @@ -24,19 +20,14 @@ Address Overview The Address interface provides an abstraction for a kaspa address. While the most common type is a pay-to-pubkey-hash, kaspa already supports others and may well support more in the future. This package currently provides -implementations for the pay-to-pubkey, pay-to-pubkey-hash, and -pay-to-script-hash address types. +implementations for the pay-to-pubkey-hash, and pay-to-script-hash address +types. To decode/encode an address: - // NOTE: The default network is only used for address types which do not - // already contain that information. At this time, that is only - // pay-to-pubkey addresses. - addrString := "04678afdb0fe5548271967f1a67130b7105cd6a828e03909a67962" + - "e0ea1f61deb649f6bc3f4cef38c4f35504e51ec112de5c384df7ba0b8d57" + - "8a4c702b6bf11d5f" - defaultNet := &dagconfig.MainNetParams - addr, err := util.DecodeAddress(addrString, defaultNet) + addrString := "kaspa:qqfgqp8l9l90zwetj84k2jcac2m8falvvyy8xjtnhd" + defaultPrefix := util.Bech32PrefixKaspa + addr, err := util.DecodeAddress(addrString, defaultPrefix) if err != nil { fmt.Println(err) return diff --git a/util/hdkeychain/cov_report.sh b/util/hdkeychain/cov_report.sh deleted file mode 100644 index 307f05b76..000000000 --- a/util/hdkeychain/cov_report.sh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh - -# This script uses gocov to generate a test coverage report. -# The gocov tool my be obtained with the following command: -# go get github.com/axw/gocov/gocov -# -# It will be installed to $GOPATH/bin, so ensure that location is in your $PATH. - -# Check for gocov. -type gocov >/dev/null 2>&1 -if [ $? -ne 0 ]; then - echo >&2 "This script requires the gocov tool." - echo >&2 "You may obtain it with the following command:" - echo >&2 "go get github.com/axw/gocov/gocov" - exit 1 -fi -gocov test | gocov report diff --git a/util/hdkeychain/doc.go b/util/hdkeychain/doc.go index a1a4dcd3a..81c681a22 100644 --- a/util/hdkeychain/doc.go +++ b/util/hdkeychain/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2014 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package hdkeychain provides an API for kaspa hierarchical deterministic extended keys (BIP0032). diff --git a/util/hdkeychain/test_coverage.txt b/util/hdkeychain/test_coverage.txt deleted file mode 100644 index c0bc7ef03..000000000 --- a/util/hdkeychain/test_coverage.txt +++ /dev/null @@ -1,20 +0,0 @@ - -github.com/conformal/btcutil/hdkeychain/extendedkey.go ExtendedKey.String 100.00% (18/18) -github.com/conformal/btcutil/hdkeychain/extendedkey.go ExtendedKey.Zero 100.00% (9/9) -github.com/conformal/btcutil/hdkeychain/extendedkey.go ExtendedKey.pubKeyBytes 100.00% (7/7) -github.com/conformal/btcutil/hdkeychain/extendedkey.go ExtendedKey.Neuter 100.00% (6/6) -github.com/conformal/btcutil/hdkeychain/extendedkey.go ExtendedKey.ECPrivKey 100.00% (4/4) -github.com/conformal/btcutil/hdkeychain/extendedkey.go zero 100.00% (3/3) -github.com/conformal/btcutil/hdkeychain/extendedkey.go ExtendedKey.SetNet 100.00% (3/3) -github.com/conformal/btcutil/hdkeychain/extendedkey.go ExtendedKey.Address 100.00% (2/2) -github.com/conformal/btcutil/hdkeychain/extendedkey.go newExtendedKey 100.00% (1/1) -github.com/conformal/btcutil/hdkeychain/extendedkey.go ExtendedKey.IsPrivate 100.00% (1/1) -github.com/conformal/btcutil/hdkeychain/extendedkey.go ExtendedKey.ParentFingerprint 100.00% (1/1) -github.com/conformal/btcutil/hdkeychain/extendedkey.go ExtendedKey.ECPubKey 100.00% (1/1) -github.com/conformal/btcutil/hdkeychain/extendedkey.go ExtendedKey.IsForNet 100.00% (1/1) -github.com/conformal/btcutil/hdkeychain/extendedkey.go NewKeyFromString 95.83% (23/24) -github.com/conformal/btcutil/hdkeychain/extendedkey.go ExtendedKey.Child 91.67% (33/36) -github.com/conformal/btcutil/hdkeychain/extendedkey.go NewMaster 91.67% (11/12) -github.com/conformal/btcutil/hdkeychain/extendedkey.go GenerateSeed 85.71% (6/7) -github.com/conformal/btcutil/hdkeychain ----------------------------- 95.59% (130/136) - diff --git a/util/txsort/doc.go b/util/txsort/doc.go index 88c161a89..8a9ac5e81 100644 --- a/util/txsort/doc.go +++ b/util/txsort/doc.go @@ -1,9 +1,5 @@ -// Copyright (c) 2015 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* -Package txsort provides the transaction sorting according to BIP 69. +Package txsort provides the transaction sorting compatible with BIP 69. Overview diff --git a/wire/doc.go b/wire/doc.go index bed811fec..1dc0d2c8c 100644 --- a/wire/doc.go +++ b/wire/doc.go @@ -1,7 +1,3 @@ -// Copyright (c) 2013-2016 The btcsuite developers -// Use of this source code is governed by an ISC -// license that can be found in the LICENSE file. - /* Package wire implements the kaspa wire protocol. @@ -47,14 +43,7 @@ interactions in no particular order. getdata message (MsgGetData) block message (MsgBlock) -or- tx message (MsgTx) -or- notfound message (MsgNotFound) - getheaders message (MsgGetHeaders) headers message (MsgHeaders) - ping message (MsgPing) pong message (MsgHeaders)* -or- - (none -- Ability to send message is enough) - - NOTES: - * The pong message was not added until later protocol versions as defined - in BIP0031. The BIP0031Version constant can be used to detect a recent - enough protocol version for this purpose (version > BIP0031Version). + ping message (MsgPing) pong message (MsgPong) Common Parameters @@ -77,10 +66,11 @@ The kaspa network is a magic number which is used to identify the start of a message and which kaspa network the message applies to. This package provides the following constants: - wire.MainNet - wire.RegTest (Regression test network) - wire.TestNet (Test network) - wire.SimNet (Simulation test network) + wire.MainNet + wire.TestNet (Test network) + wire.RegTest (Regression test network) + wire.SimNet (Simulation test network) + wire.DevNet (Development network) Determining Message Type