404 error
+ +The page you are looking for does not exist. + +"var" - variable from the configuration file + + +## Example + + { + "file":"multiply.json", + "description":"Adds core parameters as option for daemon, simplewallet and walletd", + "required":[ "core/bytecoin.json", "print-genesis-tx.json", "genesis-block-reward.json" ], + "files": [ + { + "path":"/src/CryptoNoteConfig.h", + "changes": [ + { + "action":"add_above", + "marker":"} // parameters", + "parameters": { + "text":[ + "const char GENESIS_COINBASE_TX_HEX[] = \"%s\";" + ], + "var":"GENESIS_COINBASE_TX_HEX" + } + } + { + "action":"add_below", + "marker":"size_t blockGrantedFullRewardZone()", + "parameters": { + "text":[ + " size_t blockGrantedFullRewardZoneV1() const { return m_blockGrantedFullRewardZoneV1; }" + ] + } + } + ] + }, + { + "path":"/src/CryptoNoteCore/Currency.cpp", + "changes": [ + { + "action":"replace", + "marker":"CryptoNote::parameters::CRYPTONOTE_BLOCK_GRANTED_FULL_REWARD_ZONE_V1;", + "parameters": { + "text":[ + " m_blockGrantedFullRewardZoneV1;" + ] + } + } + + ] + }, + { + "path":"/README.md", + "action":"add", + "source":"/multiply/files/README.md" + } + ] + } + +## Adding extension to your configuration + +Add the created extension in your Cryptonote generator's configuration file to execute it + + { + "base_coin": { + ... + }, + "core": { + ... + }, + "extensions": [ + "core/bytecoin.json", + "print-genesis-tx.json", + "MY-EXTENSION.json" + ] + } + + + +[files_anchor]: #file +[changes_anchor]: #changes \ No newline at end of file diff --git a/content/documentation/cryptonote-generator/forknote.md b/content/documentation/cryptonote-generator/forknote.md new file mode 100644 index 0000000..934d42b --- /dev/null +++ b/content/documentation/cryptonote-generator/forknote.md @@ -0,0 +1,22 @@ +--- +title: Forknote overview | Forknote +layout: documentation +body_class: developers +subnav_class: docs-documentation +sidebar_nav: sidebar-documentation +--- + +# Cryptonote generator: Forknote + +* TOC +{:toc} + +Forknote adds the [parameters of Cryptonote generator][Cryptonote_generator_core_parameters_documentation] to the daemon, simplewallet and payment gateway. It allows easy creation of private blockchains. + + +## How it works + + + + +[Cryptonote_generator_core_parameters_documentation]: /documentation/cryptonote-generator/#core-parameters diff --git a/content/documentation/cryptonote-generator/index.md b/content/documentation/cryptonote-generator/index.md new file mode 100644 index 0000000..a0b59f9 --- /dev/null +++ b/content/documentation/cryptonote-generator/index.md @@ -0,0 +1,82 @@ +--- +title: Cryptonote generator overview | Forknote +layout: documentation +body_class: developers +subnav_class: docs-documentation +sidebar_nav: sidebar-documentation +--- + +# Cryptonote generator overview + +* TOC +{:toc} + +The Cryptonote generator is a collection of scripts for creating and maintaining a Bytecoin clone. The code produced by it have the same properties as its Forknote equivalent. + + +## How it works + +Instead of merging the changes from the seed into the clone, the Cryptonote genetor applies changes to the latest version of the seed. + + + + +## Core parameters + +Parameter | Description +SEED_NODES | Array of seed nodes +CHECKPOINTS | Array of checkpoints. See the example for the format +GENESIS_COINBASE_TX_HEX | The hex of the transaction in the genesis block +CRYPTONOTE_PUBLIC_ADDRESS_BASE58_PREFIX | Prefix of the wallet address. Since the rules for address prefixes are nontrivial you may use a prefix generator +MONEY_SUPPLY | Total amount of atomic units to be emitted. +EMISSION_SPEED_FACTOR | Constant defines emission curve slope. This parameter is required to calulate block reward. +DIFFICULTY_TARGET | Difficulty target is an ideal time period between blocks. Measured in seconds. +GENESIS_BLOCK_REWARD | Premine amount. Measured in atomic units. +CRYPTONOTE_BLOCK_GRANTED_FULL_REWARD_ZONE | The maximum size of a block not resulting into penelty. +CRYPTONOTE_BLOCK_GRANTED_FULL_REWARD_ZONE_V1 | The maximum size of a block not resulting into penelty. Used only by old (v1) blockchains +CRYPTONOTE_BLOCK_GRANTED_FULL_REWARD_ZONE_V2 | The maximum size of a block not resulting into penelty. Used only by old (v2) blockchains +CRYPTONOTE_DISPLAY_DECIMAL_POINT | 1 coin = 10^(this value) atomic units +MINIMUM_FEE | Transactions with less than this fee wouldn't be accepted by daemons +DEFAULT_DUST_THRESHOLD | The amount bellow this value will be considered as dust +CRYPTONOTE_MINED_MONEY_UNLOCK_WINDOW | Number of blocks to unlock miner transactions +MAX_BLOCK_SIZE_INITIAL | The size of the initial block. Used to correct error in v1 blockchains +EXPECTED_NUMBER_OF_BLOCKS_PER_DAY | Expected number of blocks per day. Used to correct error in v1 blockchains +UPGRADE_HEIGHT_V2 | Block hight to move to blocks with major version 2. Use '1' for new blockchains +UPGRADE_HEIGHT_V3 | Block hight to move to blocks with major version 3. Use '2' for new blockchains +DIFFICULTY_CUT | Timestamps to cut after sorting +DIFFICULTY_LAG | Lag of calculating the difficulty in terms of blocks + + +## Example + + { + "base_coin": { + "name": "bytecoin", + "git": "https://github.com/amjuarez/bytecoin.git" + }, + "core": { + "SEED_NODES": ["108.61.188.93:7610", "128.199.146.243:29080"], + "EMISSION_SPEED_FACTOR": 18, + "DIFFICULTY_TARGET": 120, + "CRYPTONOTE_DISPLAY_DECIMAL_POINT": 12, + "MONEY_SUPPLY": "18446744073709551615", + "GENESIS_BLOCK_REWARD": 0, + "DEFAULT_DUST_THRESHOLD": 1000000, + "MINIMUM_FEE": 1000000, + "CRYPTONOTE_MINED_MONEY_UNLOCK_WINDOW": 10, + "CRYPTONOTE_BLOCK_GRANTED_FULL_REWARD_ZONE": 100000, + "CRYPTONOTE_PUBLIC_ADDRESS_BASE58_PREFIX": 86, + "P2P_DEFAULT_PORT": 28134, + "RPC_DEFAULT_PORT": 28135, + "UPGRADE_HEIGHT_V2": 1, + "UPGRADE_HEIGHT_V3": 2, + "BYTECOIN_NETWORK": "3354bb33-28e2-66d3-7d92-9267413bede6", + "CRYPTONOTE_NAME": "newcoin", + "CHECKPOINTS": ["28000:70d2531151529ac00bf875281e15f51324934bc85e5733dcd92e1ccb1a665ff8", "40000:c181ec9223a91fef8658c7aa364c093c41c28d250870ca1ed829bf74f0abf038"], + "GENESIS_COINBASE_TX_HEX":"010a01ff0001ffffffffffff0f029b2e4c0271c0b42e7c53291a94d1c0cbff8883f8024f5142ee494ffbbd08807121013c086a48c15fb637a96991bc6d53caf77068b5ba6eeb3c82357228c49790584a" + }, + "extensions": [ + "core/bytecoin.json", + "print-genesis-tx.json" + ] + } diff --git a/content/documentation/daemon/html-rpc-api.md b/content/documentation/daemon/html-rpc-api.md new file mode 100644 index 0000000..0d5a980 --- /dev/null +++ b/content/documentation/daemon/html-rpc-api.md @@ -0,0 +1,18 @@ +--- +title: Daemon HTTP RPC API | Forknote +layout: documentation +body_class: developers +subnav_class: docs-documentation +sidebar_nav: sidebar-documentation +--- + +# Daemon HTTP RPC API + +Forknote's Daemon is using the same HTTP API as Bytecoin's daemon. A list of the available methods and usage examples can be found at the Bytecoin Wiki: + +[Bytecoin Daemon HTTP RPC API][Bytecoin_Daemon_HTTP_RPC_API] + + + +[Bytecoin_Daemon_HTTP_RPC_API]: https://wiki.bytecoin.org/wiki/Daemon_HTTP_RPC_API + diff --git a/content/documentation/daemon/index.md b/content/documentation/daemon/index.md new file mode 100644 index 0000000..024a0b6 --- /dev/null +++ b/content/documentation/daemon/index.md @@ -0,0 +1,136 @@ +--- +title: Daemon configuration and commands| Forknote +layout: documentation +body_class: developers +subnav_class: docs-documentation +sidebar_nav: sidebar-documentation +--- + +# Daemon configuration and commands + +* TOC +{:toc} + +##Command line options + + --help Produce help message + --version Output version information + --os-version + --data-dir arg (=/Users/USER/.forknote) + Specify data directory + --config-file arg (=./configs/-.conf) Specify configuration file + + --allow-local-ip Allow local ip add to peer list + + --print-genesis-tx Prints genesis block transaction hex and exits + --genesis-block-reward-address arg (=FPM...yR) + Addresses for premined coins + + +##Command line options and settings options + +Option | Description +-----------|-----------| +log-file | A name of log file that you want to use for logging. +log-level | Level of logging. Default is 1. +no-console | Disable daemon console commands +testnet | Used to deploy test nets. Checkpoints and hardcoded seeds are ignored, network id is --data-dir flag. The wallet must be launched with --testnet flag. +rpc-bind-ip | Specify ip to bind rpc server +rpc-bind-port | Specify port to bind rpc server +p2p-bind-ip | Interface for p2p network protocol +p2p-bind-port | Port for p2p network protocol +p2p-external-port | External port for p2p network protocol (if port forwarding used with NAT) +add-peer | Manually add peer to local peerlist +add-priority-node | Specify list of peers to connect to and attempt to keep the connection open +add-exclusive-node | Specify list of peers to connect to only. If this option is given the options add-priority-node and seed-node are ignored +seed-node | Connect to a node to retrieve peer addresses, and disconnect +hide-my-port | Do not announce yourself as peerlist candidate +extra-messages-file | Specify file for extra messages to include into coinbase transactions +start-mining | Specify wallet address to mining for +mining-threads | Specify mining threads count +enable-cors | Adds header 'Access-Control-Allow-Origin' to the daemon's RPC responses +enable-blockchain-indexes | Enable blockchain indexes + +##Blockchain options + +Option | Description +-----------|-----------| +BYTECOIN_NETWORK | Used for network packages in order not to mix two different cryptocoin networks +CHECKPOINT | Checkpoints. Format: HEIGHT:HASH +CRYPTONOTE_BLOCK_GRANTED_FULL_REWARD_ZONE | The maximum size of a block not resulting into penelty. +CRYPTONOTE_BLOCK_GRANTED_FULL_REWARD_ZONE_V1 | The maximum size of a block not resulting into penelty. Used by (v1) blockchains +CRYPTONOTE_BLOCK_GRANTED_FULL_REWARD_ZONE_V2 | The maximum size of a block not resulting into penelty. Used by (v2) blockchains +CRYPTONOTE_COIN_VERSION | Use '1' for Cryptonote coin clones (the new version) +CRYPTONOTE_DISPLAY_DECIMAL_POINT | 1 coin = 10^(this value) atomic units +CRYPTONOTE_MINED_MONEY_UNLOCK_WINDOW | Number of blocks to unlock miner transactions +CRYPTONOTE_NAME | Cryptonote name. Used for storage directory +CRYPTONOTE_PUBLIC_ADDRESS_BASE58_PREFIX | Prefix of the wallet address. Since the rules for address prefixes are nontrivial you may use a prefix generator +DEFAULT_DUST_THRESHOLD | The amount bellow this value will be considered as dust +DIFFICULTY_CUT | Timestamps to cut after sorting +DIFFICULTY_CUT_V1 | Timestamps to cut after sorting. Used by (v1) blockchains +DIFFICULTY_CUT_V2 | Timestamps to cut after sorting. Used by (v2) blockchains +DIFFICULTY_LAG | Lag of calculating the difficulty in terms of blocks +DIFFICULTY_LAG_V1 | Lag of calculating the difficulty in terms of blocks. Used by (v1) blockchains +DIFFICULTY_LAG_V2 | Lag of calculating the difficulty in terms of blocks. Used by (v2) blockchains +DIFFICULTY_TARGET | Difficulty target is an ideal time period between blocks. Measured in seconds. +DIFFICULTY_WINDOW | Window length for calculation the difficulty +DIFFICULTY_WINDOW_V1 | Window length for calculation the difficulty. Used by (v1) blockchains +DIFFICULTY_WINDOW_V2 | Window length for calculation the difficulty. Used by (v2) blockchains +EMISSION_SPEED_FACTOR | Constant defines emission curve slope. This parameter is required to calulate block reward. +EXPECTED_NUMBER_OF_BLOCKS_PER_DAY | Expected number of blocks per day. Used to correct errors +GENESIS_BLOCK_REWARD | Amount of premined coins. In atomic units +GENESIS_COINBASE_TX_HEX | The hex of the transaction in the genesis block +KILL_HEIGHT | End blockchain at height +MANDATORY_MIXIN_BLOCK_VERSION | Enforce minimum mixin MIN_MIXIN on blockchain level, after block with major version bigger than MANDATORY_MIXIN_BLOCK_VERSION +MANDATORY_TRANSACTION | Only blocks with more than 1 transactions are valid (exluding the base transaction) +MAX_BLOCK_SIZE_INITIAL | The size of the initial block. Used to correct error in v1 coins +MIN_MIXIN | minimum mixin amount. Not enforced by default on blockchain level +MINIMUM_FEE | Transactions with less than this fee wouldn't be accepted by daemons +MIXIN_START_HEIGHT | minimum block height of the used outputs for mixin +MONEY_SUPPLY | Total amount of coins to be emitted. +P2P_STAT_TRUSTED_PUB_KEY | P2P stat trusted pub key +TAIL_EMISSION_REWARD | Block reward will never drop below this value. +UPGRADE_HEIGHT_V2 | Block hight to move to blocks with major version 2. Use '1' for new blockchains +UPGRADE_HEIGHT_V3 | Block hight to move to blocks with major version 3. Use '2' for new blockchains +ZAWY_DIFFICULTY_BLOCK_INDEX | Activates Zawy difficulty after certain block height + +##Example of a config file + +
$ cat ./fakecoin.conf + +BYTECOIN_NETWORK=10101010-1010-1010-1010-101010101010 +CRYPTONOTE_DISPLAY_DECIMAL_POINT=12 +CRYPTONOTE_NAME=fakecoin +CRYPTONOTE_PUBLIC_ADDRESS_BASE58_PREFIX=72 +GENESIS_COINBASE_TX_HEX=010a01ff0001ffffffffffff0f029b2e4c0271c0b42e7c53291a94d1c0cbff8883f8024f5142ee494ffbbd08807121013c086a48c15fb637a96991bc6d53caf77068b5ba6eeb3c82357228c49790584a +P2P_STAT_TRUSTED_PUB_KEY= + +UPGRADE_HEIGHT_V2=1 +UPGRADE_HEIGHT_V3=30 +ZAWY_DIFFICULTY_BLOCK_INDEX=30 + +p2p-bind-port=8080 +rpc-bind-port=8081 + +seed-node=127.0.0.1:8080 + ++ +##Daemon commands + +Command | Description | Args +-----------|-----------|-----------| +help | print forknoted commands | - +start_mining | Start mining in several threads to a given wallet address | [string] wallet_address
[uint] threads +stop_mining | Stop mining | - +show_hr | Show current mining hashrate | - +hide_hr | Stop showing current mining hashrate | - +exit | Exit forknoted | - +print_bc | Print blockchain info in a given blocks range | [uint] begin_height
[uint] end_height (optional) +print_block | Print block | [string] block_hash or [uint] block_height +print_cn | Print connections | - +print_pl | Print peer list | - +print_pool | Print transaction pool (long format) | - +print_pool_sh | Print transaction pool (short format) | - +set_log | Change current log detailization level | [uint] log level (0 - 4) +print_tx | Print transaction | [string] transaction_hash diff --git a/content/documentation/daemon/json-rpc-api.md b/content/documentation/daemon/json-rpc-api.md new file mode 100644 index 0000000..550505d --- /dev/null +++ b/content/documentation/daemon/json-rpc-api.md @@ -0,0 +1,313 @@ +--- +title: Daemon JSON RPC API | Forknote +layout: documentation +body_class: developers +subnav_class: docs-documentation +sidebar_nav: sidebar-documentation +--- + +# Daemon JSON RPC API + +Forknote's Daemon is using the same JSON API as Bytecoin's daemon. A list of the available methods and usage examples can be found at the Bytecoin Wiki: + +[Bytecoin Daemon JSON RPC API][Bytecoin_Daemon_JSON_RPC_API] + + +#Additional method added to Forknote + +* TOC +{:toc} + +##f_get_blockchain_settings + +Returns the settings of the used configuration file + +URL: + + /json_rpc + +### Example (f_get_blockchain_settings) + +Input: + + { + "jsonrpc": "2.0", + "id": "test", + "method": "f_get_blockchain_settings" + } + +Output: + + { + "id": "test", + "jsonrpc": "2.0", + "result": { + "base_coin": { + "git": "https://github.com/amjuarez/bytecoin.git", + "name": "bytecoin" + }, + "core": { + "BYTECOIN_NETWORK": "12112111-1110-4101-1311-001212110110", + "CHECKPOINTS": [ + "28000:70d2531151529ac00bf875281e15f51324934bc85e5733dcd92e1ccb1a665ff8", + "40000:c181ec9223a91fef8658c7aa364c093c41c28d250870ca1ed829bf74f0abf038" + ], + "CRYPTONOTE_BLOCK_GRANTED_FULL_REWARD_ZONE": 20000, + "CRYPTONOTE_BLOCK_GRANTED_FULL_REWARD_ZONE_V1": 10000, + "CRYPTONOTE_DISPLAY_DECIMAL_POINT": 12, + "CRYPTONOTE_MINED_MONEY_UNLOCK_WINDOW": 10, + "CRYPTONOTE_NAME": "dashcoin", + "CRYPTONOTE_PUBLIC_ADDRESS_BASE58_PREFIX": 72, + "DEFAULT_DUST_THRESHOLD": 1000000, + "DIFFICULTY_CUT": 60, + "DIFFICULTY_LAG": 15, + "DIFFICULTY_TARGET": 120, + "EMISSION_SPEED_FACTOR": 18, + "EXPECTED_NUMBER_OF_BLOCKS_PER_DAY": 720, + "GENESIS_BLOCK_REWARD": 0, + "GENESIS_COINBASE_TX_HEX": "010a01ff0001ffffffffffff0f029b2e4c0271c0b42e7c53291a94d1c0cbff8883f8024f5142ee494ffbbd08807121013c086a48c15fb637a96991bc6d53caf77068b5ba6eeb3c82357228c49790584a", + "MAX_BLOCK_SIZE_INITIAL": 25600, + "MINIMUM_FEE": 1000000, + "MONEY_SUPPLY": "18446744073709551615", + "P2P_DEFAULT_PORT": 7610, + "RPC_DEFAULT_PORT": 7611, + "SEED_NODES": [ + "108.61.188.13:7610", + "128.199.146.23:29080" + ], + "UPGRADE_HEIGHT": 1 + }, + "extensions": [ + "core/bytecoin.json", + "print-genesis-tx.json", + "simplewallet-default-fee.json", + "max-transaction-size-limit.json", + "genesis-block-reward.json" + ], + "status": "OK" + } + } + + +##f_blocks_list_json + +Returns list of shortly described blocks. + +URL: + + /json_rpc + +### Example (f_blocks_list_json) + +Input: + + { + "jsonrpc": "2.0", + "id": "test", + "method": "f_blocks_list_json", + "params": { + "height": 10 + } + } + +Output: + + { + "id": "test", + "jsonrpc": "2.0", + "result": { + "blocks": [ + { + "cumul_size": 350, + "hash": "73c87db65839d0697627ef0a58fbe4d20340c74503df0c22aba5298e0814a16d", + "height": 10, + "timestamp": 1404556851, + "tx_count": 1 + }, + ... + { + "cumul_size": 120, + "hash": "2eb6307a9b1be29348db19fdd0a1dad483983cf25241ca27f56d333dbb913d85", + "height": 0, + "timestamp": 0, + "tx_count": 1 + } + ], + "status": "OK" + } + } + + +##f_block_json + +Returns detailed description of a block. + +URL: + + /json_rpc + +### Example (f_block_json) + +Input: + + { + "jsonrpc": "2.0", + "id": "test", + "method": "f_block_json", + "params": { + "hash": "74e21b7b7869465dd0bc0929a92df667d0fc88979999fe07ffa24ab925fad17d" + } + } + +Output: + + { + "id": "test", + "jsonrpc": "2.0", + "result": { + "block": { + "alreadyGeneratedCoins": 4907142100217515000, + "alreadyGeneratedTransactions": 672169, + "baseReward": 18719332960321, + "blockSize": 1515, + "depth": 15, + "difficulty": 308978448, + "hash": "74e21b7b7869465dd0bc0929a92df667d0fc88979999fe07ffa24ab925fad17d", + "height": 347655, + "major_version": 2, + "minor_version": 0, + "nonce": 2147485048, + "orphan_status": false, + "penalty": 0, + "prev_hash": "d1d2e3a67decae0cf7c6559cb5c50e908db572aa04f092c5f4db1693781702c6", + "reward": 18720332960321, + "sizeMedian": 386, + "timestamp": 1446725921, + "totalFeeAmount": 1000000000, + "transactions": [ + { + "amount_out": 60321, + "blockSize": 37383401493432, + "fee": 0, + "hash": "eba9c70143bf39a211a2ab2e0635d928455299da45f21cf8da31461ebc467a6a" + }, + { + "amount_out": 100000000000, + "blockSize": 7672522688954774000, + "fee": 1000000000, + "hash": "b3aacbdc9cdb3dbd80731621d3dbbcaf9d6bdc7b731933c5cc92b5ff12777852" + } + ], + "transactionsCumulativeSize": 1119 + }, + "status": "OK" + } + } + + +##f_transaction_json + +Returns detailed description of a transaction. + +URL: + + /json_rpc + +### Example (f_transaction_json) + +Input: + + { + "jsonrpc": "2.0", + "id": "test", + "method": "f_transaction_json", + "params": { + "hash": "17246c6ee2e8c05f93dd29ee499f38e8ce4023ea693a3a9e39fb41f2877bbd3d" + } + } + +Output: + + { + "id": "test", + "jsonrpc": "2.0", + "result": { + "block": { + "cumul_size": 8751, + "hash": "533380e35d0dcec920ed58d92eb6af81771e2f4e414fca54f6105f5208650730", + "height": 347985, + "timestamp": 1446765470, + "tx_count": 5 + }, + "status": "OK", + "tx": { + "": "288a8873fe8cbe233b51fd1d2c252f8a74e8eee3dae61d35b9b434645c27f704a502357be566a75ef168032d676d2e0936d50c6f38ea5317ea7a82dd2ce69f03", + "extra": "01d58d5fd664de79feb3f53ebf9a6a4fa0a5d7987a4c905840d29ef9f13fe380da", + "unlock_time": 0, + "version": 1, + "vin": [ + { + "type": "02", + "value": { + "amount": 200000000000, + "k_image": "1980a3e2d130c8548b92c63e16c6fedf79819755232eda22939c353c3b66046c", + "key_offsets": [ + 33019, + 22585, + 63469, + 65530 + ] + } + }, + ... + { + "type": "02", + "value": { + "amount": 8000000000000, + "k_image": "9831d04dc056d8ef5d562ba68ccaa276653594bc32ea687584bfc143c2089b84", + "key_offsets": [ + 46597, + 1208, + 4399, + 42365 + ] + } + } + ], + "vout": [ + { + "amount": 10000000, + "target": { + "data": { + "key": "de25ddd2a718fa274689a6a5c1d996b67c4b41ad30660a44a3a0fb5968d92547" + }, + "type": "02" + } + }, + ... + { + "amount": 5000000000000, + "target": { + "data": { + "key": "ba9bfb77a79b7b3a6a61c6fbaa441443e38d1a7f44279c78652f84121be3b4b9" + }, + "type": "02" + } + } + ] + }, + "txDetails": { + "amount_out": 8199010000000, + "fee": 1000000000, + "hash": "17246c6ee2e8c05f93dd29ee499f38e8ce4023ea693a3a9e39fb41f2877bbd3d", + "mixin": 4, + "paymentId": "", + "size": 1227 + } + } + } + + + +[Bytecoin_Daemon_JSON_RPC_API]: https://wiki.bytecoin.org/wiki/Daemon_JSON_RPC_API + diff --git a/content/documentation/index.md b/content/documentation/index.md new file mode 100644 index 0000000..d782d64 --- /dev/null +++ b/content/documentation/index.md @@ -0,0 +1,88 @@ +--- +title: Documentation | Forknote +layout: documentation +body_class: developers +subnav_class: docs-documentation +sidebar_nav: sidebar-documentation +--- + +# Forknote command line client overview + +Forknote works through 3 separate binary files operated through command line: + +* **forknoted** – daemon to synchronize the block chain and mine cryptonote tokens. + +* **simplewallet** – wallet to receive and send funds. + +* **walletd** – RPC wallet for services. + + +## Install Forknote + +1. Unzip the archive to one separate folder + +2. Create or download the desired configuration: [Forknote configurations][github_forknote_configs] + + + +## Launch Forknote + +1. Open forknoted. For downloadable Linux archive use: +
+ ./forknoted --config-file <path_to_config_file> ++ +2. Wait until forknoted is synchronized. You will be notified with several green "SYNCHRONIZED OK" messages. + +3. Open simplewallet. For downloadable Linux archive use: +
+ ./simplewallet --config-file <path_to_config_file> ++ +## Daemon: synchronization & mining + +*Main article: [Daemon configuration and commands][daemon_commands]* + +After forknoted is launched you will have to wait until it is synchronized with the network. You will be notified with several green "SYNCHRONIZED OK" messages. Here are the most important daemon commands: + + +Command | Description +-----------|-----------| +start_mining <wallet_address> [threads=1] | Start mining in several threads to a given wallet address +stop_mining | Stop mining +show_hr | Show current mining hashrate +hide_hr | Stop showing current mining hashrate +help | Show all daemon commands +exit | Exit forknoted + + +## Simplewallet: send and receive payments + +*Main article: [Simplewallet configuration and commands][simplewallet_commands]* + +Simplewallet can only be used after the daemon is launched and synchronized. Simlewallet automatically synchronizes with forknoted. Here are the most important wallet commands: + + +Command | Description +-----------|-----------| +address | Show your wallet address +balance | Show current wallet balance +transfer <mixin_count> <address> <amount> | Send money to <address> with a mixing degree of <mixin_count> +start_mining <threads> | Start mining in daemon with several threads to the current wallet address +stop_mining | Stop mining in daemon +help | Show all wallet commands +exit | Exit simplewallet + + +## Walletd: + +*Main article: [RPC wallet introduction][rpc_wallet_index]* + +The RPC wallet is the way for services to send, recieve and track transactions. + + + +[daemon_commands]: /documentation/daemon/ +[simplewallet_commands]: /documentation/simplewallet/ +[rpc_wallet_index]: /documentation/rpc-wallet/json-rpc-api/ +[github_forknote_configs]: https://github.com/forknote/configs diff --git a/content/documentation/rpc-wallet/index.md b/content/documentation/rpc-wallet/index.md new file mode 100644 index 0000000..c406507 --- /dev/null +++ b/content/documentation/rpc-wallet/index.md @@ -0,0 +1,189 @@ +--- +title: RPC Wallet overview and configuration | Forknote +layout: documentation +body_class: developers +subnav_class: docs-documentation +sidebar_nav: sidebar-documentation +--- + +# RPC Wallet overview and configuration + +* TOC +{:toc} + +This wiki section describes Forknote integration process into your service with Forknote e-commerce solution called Forknote RPC Wallet. Forknote RPC Wallet is a HTTP server which provides JSON 2.0 RPC interface for Forknote payment operations and address management. Forknote RPC Wallet allows you to accept incoming payments, generate an address for each user via [Forknote RPC Wallet JSON RPC API][Forknote_RPC_Wallet_JSON_RPC_API] and much more. [Forknote RPC Wallet JSON RPC API][Forknote_RPC_Wallet_JSON_RPC_API] page contains detailed description of every method. + + +##Configure Forknote RPC Wallet + +To configure RPC wallet you can use both command line and config file. Config file allows you to configure your settings only once and use "--config" option further. The command below launches Forknote RPC Wallet with a specific config file: + + $ ./walletd --config /home/Downloads/myconfig.conf + +To get help on available options run: + + $ ./walletd -h + +Please note, Forknote RPC Wallet config file may consist only of these options: + +Option | Description +-----------|-----------| +bind-address | Which address to bind Forknote RPC Wallet to. Default value is 0.0.0.0 +bind-port | Which port to bind Forknote RPC Wallet to. Default value is 8070 +daemon-address | Forknote daemon (forknoted) address for remote daemon connection infrastructure +daemon-port | Forknote daemon (forknoted) port for remote daemon connection infrastructure. Default Forknote daemon ports are 8080 and 8081 +container-file | Mandatory'''. Your container's file name +container-password | Mandatory. Your container's password +log-file | A name of log file that you want to use for logging. Default is walletd.log +server-root | Working directory that you wish to use for Forknote RPC Wallet. Default is current working directory. +log-level | Level of logging. Default is 1. +testnet | Allows you to run Forknote RPC Wallet in testnet. +local | Option that allows you to start Forknote RPC Wallet as an in-process node +p2p-bind-ip | Interface for p2p network protocol +p2p-bind-port | Port for p2p network protocol +p2p-external-port | External port for p2p network protocol (if port forwarding used with NAT) +add-peer | Manually add peer to local peerlist +add-priority-node | Specify list of peers to connect to and attempt to keep the connection open +add-exclusive-node | Specify list of peers to connect to only. If this option is given the options add-priority-node and seed-node are ignored +seed-node | Connect to a node to retrieve peer addresses, and disconnect +hide-my-port | Do not announce yourself as peerlist candidate +MAX_TRANSACTION_SIZE_LIMIT | Maximum size of the transactions sent +SYNC_FROM_ZERO | Sync from block 0. Use for premine wallet or brainwallet + +### Blockchain options + +See [Blockchain options][Blockchain_options] + + +##Example of a config file + +
$ cat ./fakecoin.conf + +BYTECOIN_NETWORK=10101010-1010-1010-1010-101010101010 +CRYPTONOTE_DISPLAY_DECIMAL_POINT=12 +CRYPTONOTE_NAME=fakecoin +CRYPTONOTE_PUBLIC_ADDRESS_BASE58_PREFIX=72 +GENESIS_COINBASE_TX_HEX=010a01ff0001ffffffffffff0f029b2e4c0271c0b42e7c53291a94d1c0cbff8883f8024f5142ee494ffbbd08807121013c086a48c15fb637a96991bc6d53caf77068b5ba6eeb3c82357228c49790584a +P2P_STAT_TRUSTED_PUB_KEY= + +UPGRADE_HEIGHT_V2=1 +UPGRADE_HEIGHT_V3=2 + +p2p-bind-port=8080 +rpc-bind-port=8081 + +seed-node=127.0.0.1:8080 + +container-file = mycontainer +container-password = mypassword +daemon-port = 8081 +bind-port = 9090 + ++ +*Note: config file's path is relative to current working directory, not server root.* + +*Note: options "container-file" and "container-password" should ALWAYS be set (in either command line or config file mode).* + +*Note: "container-file" and "log-file" options are relative to "server-root". "server-root" default is the current working directory.* + + +##Generate a new wallet + +To start using RPC wallet you must first generate a container. Container file is the only file that stores all data required to run your service. It contains user addresses and private keys required to operate them. Make sure to backup this file regularly. + +To generate a new wallet you should run the following command: + + $ ./walletd --config /home/Downloads/myconfig.conf --generate-container + +where: + +* **<mycontainer>** is the container file name and a path to it (relative or absolute); path is optional in this argument, specifying only a container's name will result in new file located in the same folder as RPC Wallet +* **<mypass>** is a secret password for the new wallet file. Whichever you like; +* **--generate-container** option tells RPC wallet to generate container file and exit. + +*Note: if **<mycontainer>** exists Bytecoin RPC Wallet will show you the notification and will ask you to provide a different name.* + +If the operation was successful you will get a corresponding message with your new Bytecoin address. At the same time Bytecoin RPC Wallet will save your container on the local disk (in the same folder where Bytecoin RPC Wallet is located) and shut down + + +##Start Forknote RPC Wallet + +There are two ways to start Forknote RPC Wallet: + +###Start with a remote connection to the Daemon + +Remote connection allows you to bind your Forknote RPC Wallet to a remote Forknote daemon (forknoted). You may establish Forknote daemon on both local and remote machines and connect to. Such type of connection allows you to start Forknote RPC Wallet on a relatively slow machine while heavy loaded daemon is going to work on a separate powerful server. + +* For local daemons use localhost or 127.0.0.1 as an IP address. +* For remote daemons specify the remote daemon's IP address. + +Default Forknote daemon ports are 8080 and 8081. + +Add the following lines to your configuration file to start Forknote RPC Wallet with a remote connection: + + daemon-address=
+curl -X POST -i -H "Accept: application/json" -d '{"params": {},"jsonrpc": "2.0", "id": "test","method":"reset"}' http://localhost:9090/json_rpc ++ +### viewSecretKey + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {"viewSecretKey": "4a2583e42d010e8aabfed22743789569714196246bf01b5f2fec35af9232d907"},"jsonrpc": "2.0", "id": "test","method":"reset"}' http://localhost:9090/json_rpc ++ + +## save + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {},"jsonrpc": "2.0", "id": "test","method":"save"}' http://localhost:9090/json_rpc ++ + +## getViewKey + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {},"jsonrpc": "2.0", "id": "test","method":"getViewKey"}' http://localhost:9090/json_rpc ++ + +## getSpendKeys + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {"address": "D5dLTBqbemtTFkM9HptxaEgx844trQP2kXk4BfobTYS2J4njZxsQP4nDSeHBf2cGGDWLejg1xaAnKFAAvGTs9rmnVZsmqio"} ,"jsonrpc": "2.0", "id": "test","method":"getSpendKeys"}' http://localhost:9090/json_rpc ++ + +## getStatus + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {},"jsonrpc": "2.0", "id": "test","method":"getStatus"}' http://localhost:9090/json_rpc ++ + +## getAddresses + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {},"jsonrpc": "2.0", "id": "test","method":"getAddresses"}' http://localhost:9090/json_rpc ++ + +## createAddress + +### no parameter + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {},"jsonrpc": "2.0", "id": "test","method":"createAddress"}' http://localhost:9090/json_rpc ++ +### secretSpendKey + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {"spendSecretKey": "7d2ba46048a75235cc260913d4fd85769bc02203583bfdc795bae996ff314421"},"jsonrpc": "2.0", "id": "test","method":"createAddress"}' http://localhost:9090/json_rpc ++ +### spendPublicKey + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {"spendPublicKey": "5c4da91676f4906575d03345aa3c822fadcbea432f2fd23701e2b466b73d0dec"},"jsonrpc": "2.0", "id": "test","method":"createAddress"}' http://localhost:9090/json_rpc ++ + +## deleteAddress + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {"address": "D4vADauhf7NBYTQ8AoKyByQxJ2g44uiZrLHc1j1iDTccEtTxJdK2pyxDSeHBf2cGGDWLejg1xaAnKFAAvGTs9rmnVZvQLJe"} ,"jsonrpc": "2.0", "id": "test","method":"deleteAddress"}' http://localhost:9090/json_rpc ++ + +## getBalance + +### no parameter + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {},"jsonrpc": "2.0", "id": "test","method":"getBalance"}' http://localhost:9090/json_rpc ++ +### address + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {"address": "D8ExoFUt2nU961ytoh3YGHb1wF5UoszHmEDjzoPvipdPHz5geH6SPZoddLoNAN5iSDQ6PCQPnMPshMgZMAfjdxmYFMvVuVe"} ,"jsonrpc": "2.0", "id": "test","method":"getBalance"}' http://localhost:9090/json_rpc ++ + +## getBlockHashes + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {"firstBlockIndex": 100, "blockCount": 20} ,"jsonrpc": "2.0", "id": "test","method":"getBlockHashes"}' http://localhost:9090/json_rpc ++ + +## getTransactionHashes + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {"firstBlockIndex": 100, "blockCount": 20} ,"jsonrpc": "2.0", "id": "test","method":"getBlockHashes"}' http://localhost:9090/json_rpc ++ + +## getTransactions + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {"firstBlockIndex": 100, "blockCount": 20} ,"jsonrpc": "2.0", "id": "test","method":"getTransactions"}' http://localhost:9090/json_rpc ++ + +## getUnconfirmedTransactionHashes + +### no parameters + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {} ,"jsonrpc": "2.0", "id": "test","method":"getUnconfirmedTransactionHashes"}' http://localhost:9090/json_rpc ++ +### addresses + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {"addresses": []} ,"jsonrpc": "2.0", "id": "test","method":"getUnconfirmedTransactionHashes"}' http://localhost:9090/json_rpc ++ + +## getTransaction + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {"transactionHash": "c47ba0bad3c62318732dde8029542df3c06a1577ba9152f8212e754190b1e593"} ,"jsonrpc": "2.0", "id": "test","method":"getTransaction"}' http://localhost:9090/json_rpc ++ + +## sendTransaction + +not working + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {"anonymity":0, "fee":1000000,"transfers":[{"amount":100000000,"address":"D8ExoFUt2nU961ytoh3YGHb1wF5UoszHmEDjzoPvipdPHz5geH6SPZoddLoNAN5iSDQ6PCQPnMPshMgZMAfjdxmYFMvVuVe"}], "changeAddress": "D8ExoFUt2nU961ytoh3YGHb1wF5UoszHmEDjzoPvipdPHz5geH6SPZoddLoNAN5iSDQ6PCQPnMPshMgZMAfjdxmYFMvVuVe"},"jsonrpc": "2.0", "id": "test","method":"sendTransaction"}' http://localhost:9090/json_rpc ++ + +## getUnspendOuts + +
+curl -X POST -i -H "Accept: application/json" -d '{"params": {"address": "D8ExoFUt2nU961ytoh3YGHb1wF5UoszHmEDjzoPvipdPHz5geH6SPZoddLoNAN5iSDQ6PCQPnMPshMgZMAfjdxmYFMvVuVe"} ,"jsonrpc": "2.0", "id": "test","method":"getUnspendOuts"}' http://localhost:9090/json_rpc +diff --git a/content/documentation/simplewallet/index.md b/content/documentation/simplewallet/index.md new file mode 100644 index 0000000..ac33df0 --- /dev/null +++ b/content/documentation/simplewallet/index.md @@ -0,0 +1,92 @@ +--- +title: Simplewallet configuration and commands | Forknote +layout: documentation +body_class: developers +subnav_class: docs-documentation +sidebar_nav: sidebar-documentation +--- + +# Simplewallet configuration and commands + +* TOC +{:toc} + +##General options + + --help Produce help message + --version Output version information + --data-dir arg (=/Users/USER/.forknote) + Specify data directory + --config-file arg (=./configs/-.conf) Specify configuration file + --command arg Specify command + --generate-new-wallet arg (=/home/USER/forknote/my.wallet) + Generate new wallet and save it to
$ cat >fakecoin.conf + +BYTECOIN_NETWORK=10101010-1010-1010-1010-101010101010 +CRYPTONOTE_DISPLAY_DECIMAL_POINT=12 +CRYPTONOTE_NAME=fakecoin +CRYPTONOTE_PUBLIC_ADDRESS_BASE58_PREFIX=72 +GENESIS_COINBASE_TX_HEX=010a01ff0001ffffffffffff0f029b2e4c0271c0b42e7c53291a94d1c0cbff8883f8024f5142ee494ffbbd08807121013c086a48c15fb637a96991bc6d53caf77068b5ba6eeb3c82357228c49790584a +P2P_STAT_TRUSTED_PUB_KEY= + +UPGRADE_HEIGHT_V2=1 +UPGRADE_HEIGHT_V3=2 + +p2p-bind-port=8080 +rpc-bind-port=8081 + +seed-node=127.0.0.1:8080 + +wallet-file=/home/USERNAME/forknote-linux/fake_wallet.wallet +password=FAKE_PASSWORD +wallet-rpc-bind-port=8082 ++ + +##Wallet commands + +Command | Description | Args +-----------|-----------|-----------| +address | Show current wallet public address | - +balance | Show current wallet balance | - +bc_height | Show blockchain height | - +help | Print help on wallet commands | - +incoming_transfers | Show incoming transfers | - +list_transfers | Show all known transfers | - +payments | Show payments with the corresponding payment_id's. You may indicate more than one payment_id. | [string] payment_id +reset | Discard cache data and start synchronizing from scratch | - +save | Save wallet synchronized data | - +set_log | Change current log detailization level | [uint] log level (0 - 4) +start_mining | Start mining in daemon | - +stop_mining | Stop mining in daemon | - +transfer | Transfer amount to address with mixin_count (number of transactions yours is indistinguishable from) | [uint] mixin_count
[string] address
[double] amount
[string] -p payment_id
[double] -f fee + + +[Blockchain_options]: /documentation/daemon/#blockchain-options \ No newline at end of file diff --git a/content/documentation/simplewallet/json-rpc-api.md b/content/documentation/simplewallet/json-rpc-api.md new file mode 100644 index 0000000..5691eef --- /dev/null +++ b/content/documentation/simplewallet/json-rpc-api.md @@ -0,0 +1,17 @@ +--- +title: Simplewallet JSON RPC API | Forknote +layout: documentation +body_class: developers +subnav_class: docs-documentation +sidebar_nav: sidebar-documentation +--- + +# Simplewallet JSON RPC API + +Forknote's Simplewallet is using the same JSON API as Bytecoin's Simplewallet. A list of the available methods and usage examples can be found at the Bytecoin Wiki: + +[Bytecoin Simplewallet JSON RPC API][Bytecoin_Simplewallet_JSON_RPC_API] + + +[Bytecoin_Simplewallet_JSON_RPC_API]: https://wiki.bytecoin.org/wiki/Simplewallet_JSON_RPC_API + diff --git a/content/download.md b/content/download.md new file mode 100644 index 0000000..6bdaa24 --- /dev/null +++ b/content/download.md @@ -0,0 +1,53 @@ +--- +title: Download | Forknote +layout: overview +body_class: download +--- + +
Join the Forknote Community.
+The easiest way to create Cryptonote blockchains. Create now.
+-
+
-
+
+
Windows CLI
+Daemon, simplewallet and payment gateway for Windows (64bit)
+
+ -
+
+
Linux CLI
+Daemon, simplewallet and payment gateway for Ubuntu (64bit)
+
+ -
+
+
Mac CLI
+Daemon, simplewallet and payment gateway for Mac (64bit)
+
+
Want to connect to existing Forknote network?
+Awesome! A few tips you may find useful:
+-
+
- List of supported coins +
- Daemon and wallet guide for newcomers +
Want to create your own cryptocurrency?
+Follow our guides and launch in a few minutes:
+-
+
- Create private Cryptonote blockchain with or without premine +
$ ./forknoted --config-file configs/imaginary_blockchain.conf --print-genesis-tx + +config path exist +Modify this line into your coin configuration file as is: +GENESIS_COINBASE_TX_HEX=010a01ff0001ffffffffffff0f029b2e4c0281c0b02e7c53291a94d1d0cbff8883f8024f5142ee494ffbbd0880712101fc680aba69fb5028ade093fb1186ca9de4e65a369ca13ae75fdeef9e952b9449 + ++ +## For coins with premine + +
$ ./forknoted --config-file configs/imaginary_blockchain.conf --print-genesis-tx --genesis-block-reward-address FXhKiPxMdJ6LL1iqkEDWbk1BiiQ7SzHY1b3L9KqqPmP95e9toTXKvQSVGePtjfoDUhMPqSEKFhzymA84o6fGPhQiUYP92rT --genesis-block-reward-address FPMfUYtRHcZJdL2nLDH7zi2bZUMzgdMPm8kHibeV4qLh8pfsvZsBF6eiHH8T2QkdZm4viA2F9S4YvUk2PXodvxRPDYVvXyR + +config path exist +outs: 922337203685477580 +outs: 922337203685477580 +Modify this line into your coin configuration file as is: +GENESIS_COINBASE_TX_HEX=010a01ff0002cc99b3e6cc99b3e60c024fe47e814d9f44c83184334fb3b5f9a4ab3ebb347050e3742729703086a5e130cc99b3e6cc99b3e60c021011cd9c37a669ea1e5a930cac793aa98431dfe77a9274385b4ed29e3e5e2ac021011afb48c42cbd0a72fc9d782580d6474cf68b5eaac224315447e9694809410930 + +diff --git a/content/guides/index.md b/content/guides/index.md new file mode 100644 index 0000000..14f9862 --- /dev/null +++ b/content/guides/index.md @@ -0,0 +1,95 @@ +--- +title: Getting Started | Forknote +layout: documentation +body_class: developers +subnav_class: docs-guides +sidebar_nav: sidebar-giudes +--- + +# Getting Started + +* TOC +{:toc} + +Let's walk through core Forknote concepts as we tackle a simple use case. + +## Overview + +Forknote uses configuration files to describe the properties of a Cryptonote blockchain. To get started you must [download][download] the latest version of Forknote. + +## Connecting the daemon to a blockchain + +To connect to the daemon to existing blockchain, just start `forknoted` with the corresponding configuration file. + +
+$ ./forknoted --config-file configs/imaginary_blockchain.conf ++ +New blockchains are created by creating new configuration files. Configuration files are created with our [blockchain creation form][create]. +You can find more about the available configuration options in our [documentation][documentation]. + +### Examples + +To connect the daemon to the Dashcoin, start `forknoted` with its corresponding configuration file: + +
+$ ./forknoted --config-file configs/dashcoin.conf ++ +To connect to the Bytecoin blockchain, start `forknoted` with its corresponding configuration file: + +
+$ ./forknoted --config-file configs/bytecoin.conf ++ + +## Starting simplewallet + +Simplewallet uses the same configuration file as the daemon. + +To start simplewallet: + +
+$ ./simplewallet --config-file configs/imaginary_blockchain.conf ++ + +### Examples + +Starting `simplewallet` for the Dashcoin blockchain: + +
+$ ./simplewallet --config-file configs/dashcoin.conf ++ +Starting `simplewallet` for the Bytecoin blockchain: + +
+$ ./simplewallet --config-file configs/bytecoin.conf ++ + +## Mining with miner + +`miner` needs a running and synced daemon. + +To start mining: + +
+$ ./miner --daemon-address 127.0.0.1:[DAEMON_RPC_PORT] --address [WALLET_ADDRESS] ++ + +### Examples + +Starting `miner` for the Dashcoin blockchain: + +
+$ ./miner --daemon-address 127.0.0.1:29081 --address D6WLtrV1SBWV8HWQzQv8uuYuGy3uwZ8ah5iT5HovSqhTKMauquoTsKP8RBJzVqVesX87poYWQgkGWB4 ++ + +[bytecoin]: https://bytecoin.org/ +[create]: /create/ +[download]: /download/ +[documentation]: /documentation/daemon/#configuration-options diff --git a/content/guides/setup-private-blockchain.md b/content/guides/setup-private-blockchain.md new file mode 100644 index 0000000..826b71b --- /dev/null +++ b/content/guides/setup-private-blockchain.md @@ -0,0 +1,116 @@ +--- +title: Setup Cryptonote blockchain guide | Forknote +layout: documentation +body_class: developers +subnav_class: docs-guides +sidebar_nav: sidebar-giudes +--- + +# Setup new Cryptonote blockchain + +* TOC +{:toc} + + +Let's walk through the process of creating a configuration file for a new private blockchain. + + + +## Creating simplewallet addresses + +*This step is only required for blockchains has premined coins* + +
$ ./simplewallet --config-file configs/dashcoin.conf --generate-new-wallet MY.wallet --password PASSWORD + +config path exist +forknote wallet v1.0.9.1.662() +Sync from timestamp: 1455950318 +Error: wallet failed to connect to daemon (http://localhost:29081). +Generated new wallet: D9CTMkRfsJ594cuvX2pGXNWMFK5ARwxPN1x7bFC5wY5XTZxf12LjWUK5QkMVeSkD6gT532FepdaohRYkt99e9gdF6hyrUgx +view key: f45a0505d89e4c3bbb91c3481861c12b2b0c6e43b9de23fa108a48a0db116901 +********************************************************************** +Your wallet has been generated. +Use "help" command to see the list of available commands. +Always use "exit" command when closing simplewallet to save +current session's state. Otherwise, you will possibly need to synchronize +your wallet again. Your wallet key is NOT under risk anyway. +********************************************************************** ++ +At this line is your wallet address: +``` +Generated new wallet: D9CTMkRfsJ594cuvX2pGXNWMFK5ARwxPN1x7bFC5wY5XTZxf12LjWUK5QkMVeSkD6gT532FepdaohRYkt99e9gdF6hyrUgx +``` + +**Caution: Don't forget to backup the wallets**
+**Notice: You can also use walletd or another wallet to create an address** + + +## Creating configuration file + +Create the configuration file of your coin by using our [configuration form][create]. + +Save the resulted configuration in the `configs` folder of Forknote. + + +###Example on Linux/Mac: + +
$ cat >configs/fakecoin.conf + +BYTECOIN_NETWORK=10101010-1010-1010-1010-101010101010 +CRYPTONOTE_DISPLAY_DECIMAL_POINT=12 +CRYPTONOTE_NAME=fakecoin +CRYPTONOTE_PUBLIC_ADDRESS_BASE58_PREFIX=86 +GENESIS_COINBASE_TX_HEX=010a01ff0001ffffffffffff0f029b2e4c0271c0b42e7c53291a94d1c0cbff8883f8024f5142ee494ffbbd08807121013c086a48c15fb637a96991bc6d53caf77068b5ba6eeb3c82357228c49790584a +P2P_STAT_TRUSTED_PUB_KEY= + +UPGRADE_HEIGHT_V2=1 +UPGRADE_HEIGHT_V3=30 +ZAWY_DIFFICULTY_BLOCK_INDEX=30 + +p2p-bind-port=8080 +rpc-bind-port=8081 + +seed-node=127.0.0.1:8080 ++ +Check is the configuration file working properly by: +
$ ./forknoted --config-file configs/fakecoin.conf ++ +**Notice: Be careful when you test different configurations with the same CRYPTONOTE_NAME. You may need to delete the blockchain folder to avoid conflict.**
+Example OSX/Linux: ~/.fakecoin/
+Example Windows: C:\Users\%user_name%\AppData\Roaming\fakecoin\ + + +## Adding seed nodes + +After you have all set in the configuration file, you can start the seed nodes. + +We recommend you use [Digital Ocean][ditital-ocean] or [Vultr][vultr]. The 5$ or 10$ option should be enough for most of the cases. +You can use our [guide about seed node creation][seed-node-guide] to get started fast. + +After you know the IP of the VPS, you have to add `seed-node` to your configuration file. + +
seed-node=1.1.1.1:8080 ++ +**Notice: Don't forget to delete the line seed-node=127.0.0.1:xxxxx** + + +## Starting Mining + +To see your premined coins, you must start mining: + +
+$ ./miner --daemon-address 127.0.0.1:8081 --address D9CTMkRfsJ594cuvX2pGXNWMFK5ARwxPN1x7bFC5wY5XTZxf12LjWUK5QkMVeSkD6gT532FepdaohRYkt99e9gdF6hyrUgx ++ +**Notice: The first few blocks may take a few hours to be found** + + +[supported-parameters]: /documentation/daemon/#command-line-options-and-settings-options +[create]: /create/ +[seed-node-guide]: /guides/starting-seed-node/ +[ditital-ocean]: https://www.digitalocean.com/?refcode=8ebba1ef9746 +[vultr]: http://www.vultr.com/?ref=6832621 diff --git a/content/guides/starting-seed-node.md b/content/guides/starting-seed-node.md new file mode 100644 index 0000000..f74634f --- /dev/null +++ b/content/guides/starting-seed-node.md @@ -0,0 +1,135 @@ +--- +title: Getting Started | Forknote +layout: documentation +body_class: developers +subnav_class: docs-guides +sidebar_nav: sidebar-giudes +--- + +# Starting seed node + +* TOC +{:toc} + +This guide will walk you through the process of starting a Forknote seed node on a **Ubuntu 14.04** VPS. + +## Getting a VPS + +Run forknoted on a VPS is the cheapest way to get your network started.
+You can get a VPS at [Digital Ocean][ditital-ocean] or [Vultr][vultr]. The 5$ option is what most coins need. + +[][vultr] + + +## Adding nodes to config file + +Once you have your VPS, you can see its IP. + + + +Add its IP to the seed nodes. + + + + +## Installing Forknote + +Once you connect to the VPS, create and log into user `fork`. + +
$ useradd -m fork +$ su fork +$ cd ~ ++ +Now you can download Forknote. + +
$ wget https://github.com/forknote/forknote/releases/download/1.0.11/forknote-linux.tar. + +--2015-10-10 03:34:36-- https://github.com/forknote/forknote/releases/download/1.0.11/forknote-linux.tar.gz +Resolving github.com (github.com)... 192.30.252.32 + ++ +Unarchive the downloaded file. + +
$ tar -zxvf forknote-linux.tar.gz + +forknote-linux/ +forknote-linux/configs/ +forknote-linux/forknoted +forknote-linux/simplewallet +forknote-linux/walletd +... ++ + +## Saving the configuration file + +Log into the forknote directory + +
$ cd forknote-linux+ +Write your configuration file + +
$ cat >configs/fakecoin.conf + +BYTECOIN_NETWORK=10101010-1010-1010-1010-101010101010 +CRYPTONOTE_DISPLAY_DECIMAL_POINT=12 +CRYPTONOTE_NAME=fakecoin +CRYPTONOTE_PUBLIC_ADDRESS_BASE58_PREFIX=86 +GENESIS_COINBASE_TX_HEX=010a01ff0001ffffffffffff0f029b2e4c0271c0b42e7c53291a94d1c0cbff8883f8024f5142ee494ffbbd08807121013c086a48c15fb637a96991bc6d53caf77068b5ba6eeb3c82357228c49790584a +P2P_STAT_TRUSTED_PUB_KEY= + +UPGRADE_HEIGHT_V2=1 +UPGRADE_HEIGHT_V3=30 +ZAWY_DIFFICULTY_BLOCK_INDEX=30 + +p2p-bind-port=8080 +rpc-bind-port=8081 + +seed-node=45.32.238.88:13539 + ++ + +## Starting in upstart + +Log with `root` user and change the directory to `/etc/init/`. + +
$ cd /etc/init ++ +Create the upstart config file. + +
$ cat >forknote-fakecoin-daemon.conf + +description "fakecoin daemon" + +start on runlevel [23] +stop on shutdown + +exec sudo -u fork /home/fork/forknote-linux/forknoted --no-console --config-file /home/fork/forknote-linux/configs/fakecoin.conf + +post-stop exec sleep 30 + +respawn +respawn limit 5 30 + ++ +Start the service. + +
$ start forknote-fakecoin-daemon ++ +You now have your seed node up and running. It will automatically restart if something goes wrong. + + +Stopping the service. + +
$ stop forknote-fakecoin-daemon ++ + +[ditital-ocean]: https://www.digitalocean.com/?refcode=8ebba1ef9746 +[vultr]: http://www.vultr.com/?ref=6832621 diff --git a/content/guides/troubleshooting.md b/content/guides/troubleshooting.md new file mode 100644 index 0000000..e4c1d00 --- /dev/null +++ b/content/guides/troubleshooting.md @@ -0,0 +1,60 @@ +--- +title: Troutbleshooting | Forknote +layout: documentation +body_class: developers +subnav_class: docs-guides +sidebar_nav: sidebar-giudes +--- + +# Troubleshooting + +* TOC +{:toc} + +A list of problems you may encounter on the way. + +##An existing connection was forcibly closed by the remote host + +###Symptom + +Nobody can connect to the seed node. `forknoted` on the seed node prints the following `WARNING` + +
+2015-Sep-22 22:51:12.627019 WARNING [node_server] [127.0.0.1:55741 INC] Exception in +connectionHandler: TcpConnection::read, WSAGetOverlappedResult failed, result=10054, +An existing connection was forcibly closed by the remote host. ++ +###Solution + +* Add the P2P port in "Inbound Rules" in the Windows Firewall on the seed node +* If you are behind NAT added `--p2p-external-port
+20:41:36.303639 ERROR Coinbase transaction doesn't use full amount of block reward: spent 70.368744177663, block reward is 1844674.407370955160 +20:41:36.303736 INFO Block <5668876f735d91e7a4b7230dedddfeead0004e83a913eb1d8782101c5f8fc13a> has invalid miner transaction +20:41:36.303830 ERROR Failed to add genesis block to blockchain +20:41:36.303898 ERROR Failed to initialize blockchain storage +20:41:36.303960 ERROR Failed to initialize core ++ +This error occurs when the loaded blockchain has different parameters than the configuration file. + +###Solution + +Delete the blockchain folder. + +On Windows delete this folder: + +
C:\Users\%user_name%\AppData\Roaming\%yourcoin%\+ +On Linux/OSX: + +
$ rm -rf ~/.YOURCOIN/diff --git a/content/index.md b/content/index.md new file mode 100644 index 0000000..1a000b5 --- /dev/null +++ b/content/index.md @@ -0,0 +1,41 @@ +--- +title: Create Cryptonote private blockchains | Forknote +layout: overview +--- + +
+ Leverage the power of
+ Bytecoin in your blockchain.
+
+ Get started with one of our guides, or jump straight into the download section.
+ Download +
Join the Forknote Community.
+The easiest way to create Cryptonote blockchains. Create now.
+-
+
-
+
+
Get Started
+New to Forknote? With these guides you’ll be up and running in a snap.
+
+ -
+
+
Existing blockchains
+List of existing Forknote-supported blockchains.
+
+ -
+
+
Support
+Are you stuck? Already tried our troubleshooting guide? Ask us.
+
+