2
.gitignore
vendored
2
.gitignore
vendored
@@ -124,3 +124,5 @@ src/komodo-tx.exe
|
||||
#output during builds, symbol tables?
|
||||
*.dSYM
|
||||
|
||||
|
||||
src/cryptoconditions/compile
|
||||
|
||||
83
qa/pull-tester/cc-tests.sh
Executable file
83
qa/pull-tester/cc-tests.sh
Executable file
@@ -0,0 +1,83 @@
|
||||
#!/bin/bash
|
||||
set -e -o pipefail
|
||||
|
||||
CURDIR=$(cd $(dirname "$0"); pwd)
|
||||
# Get BUILDDIR and REAL_BITCOIND
|
||||
. "${CURDIR}/tests-config.sh"
|
||||
|
||||
export BITCOINCLI=${BUILDDIR}/qa/pull-tester/run-bitcoin-cli
|
||||
export BITCOIND=${REAL_BITCOIND}
|
||||
|
||||
#Run the tests
|
||||
# FAUCET test should be permanently first!!!
|
||||
|
||||
testScripts=(
|
||||
'cryptoconditions_faucet.py'
|
||||
'cryptoconditions_channels.py'
|
||||
'cryptoconditions_dice.py'
|
||||
'cryptoconditions_oracles.py'
|
||||
'cryptoconditions_rewards.py'
|
||||
'cryptoconditions_token.py'
|
||||
'cryptoconditions_gateways.py'
|
||||
);
|
||||
|
||||
extArg="-extended"
|
||||
passOn=${@#$extArg}
|
||||
|
||||
successCount=0
|
||||
declare -a failures
|
||||
|
||||
function runTestScript
|
||||
{
|
||||
local testName="$1"
|
||||
shift
|
||||
|
||||
echo -e "=== Running testscript ${testName} ==="
|
||||
|
||||
if eval "$@"
|
||||
then
|
||||
successCount=$(expr $successCount + 1)
|
||||
echo "--- Success: ${testName} ---"
|
||||
else
|
||||
failures[${#failures[@]}]="$testName"
|
||||
echo "!!! FAIL: ${testName} !!!"
|
||||
fi
|
||||
|
||||
echo
|
||||
}
|
||||
|
||||
if [ "x${ENABLE_BITCOIND}${ENABLE_UTILS}${ENABLE_WALLET}" = "x111" ]; then
|
||||
for (( i = 0; i < ${#testScripts[@]}; i++ ))
|
||||
do
|
||||
if [ -z "$1" ] || [ "${1:0:1}" == "-" ] || [ "$1" == "${testScripts[$i]}" ] || [ "$1.py" == "${testScripts[$i]}" ]
|
||||
then
|
||||
runTestScript \
|
||||
"${testScripts[$i]}" \
|
||||
"${BUILDDIR}/qa/rpc-tests/${testScripts[$i]}" \
|
||||
--srcdir "${BUILDDIR}/src" ${passOn}
|
||||
fi
|
||||
done
|
||||
for (( i = 0; i < ${#testScriptsExt[@]}; i++ ))
|
||||
do
|
||||
if [ "$1" == $extArg ] || [ "$1" == "${testScriptsExt[$i]}" ] || [ "$1.py" == "${testScriptsExt[$i]}" ]
|
||||
then
|
||||
runTestScript \
|
||||
"${testScriptsExt[$i]}" \
|
||||
"${BUILDDIR}/qa/rpc-tests/${testScriptsExt[$i]}" \
|
||||
--srcdir "${BUILDDIR}/src" ${passOn}
|
||||
fi
|
||||
done
|
||||
|
||||
echo -e "\n\nTests completed: $(expr $successCount + ${#failures[@]})"
|
||||
echo "successes $successCount; failures: ${#failures[@]}"
|
||||
|
||||
if [ ${#failures[@]} -gt 0 ]
|
||||
then
|
||||
echo -e "\nFailing tests: ${failures[*]}"
|
||||
exit 1
|
||||
else
|
||||
exit 0
|
||||
fi
|
||||
else
|
||||
echo "No rpc tests to run. Wallet, utils, and bitcoind must all be enabled"
|
||||
fi
|
||||
@@ -13,12 +13,6 @@ export BITCOIND=${REAL_BITCOIND}
|
||||
testScripts=(
|
||||
'ac_private.py'
|
||||
'verushash.py'
|
||||
'cryptoconditions.py'
|
||||
'cryptoconditions_dice.py'
|
||||
'cryptoconditions_faucet.py'
|
||||
'cryptoconditions_oracles.py'
|
||||
'cryptoconditions_rewards.py'
|
||||
'cryptoconditions_token.py'
|
||||
'paymentdisclosure.py'
|
||||
'prioritisetransaction.py'
|
||||
'wallet_treestate.py'
|
||||
|
||||
@@ -14,6 +14,8 @@ You can run a single test by calling `qa/pull-tester/rpc-tests.sh <testname>`.
|
||||
|
||||
Run all possible tests with `qa/pull-tester/rpc-tests.sh -extended`.
|
||||
|
||||
Also it's possible to run CryptoConditions tests only by `qa/pull-tester/cc-tests.sh --noshutdown --tracerpc`
|
||||
|
||||
Possible options:
|
||||
|
||||
```
|
||||
|
||||
111
qa/rpc-tests/cryptoconditions_channels.py
Executable file
111
qa/rpc-tests/cryptoconditions_channels.py
Executable file
@@ -0,0 +1,111 @@
|
||||
#!/usr/bin/env python2
|
||||
# Copyright (c) 2018 SuperNET developers
|
||||
# Distributed under the MIT software license, see the accompanying
|
||||
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||
|
||||
|
||||
from test_framework.test_framework import CryptoconditionsTestFramework
|
||||
from test_framework.authproxy import JSONRPCException
|
||||
from test_framework.util import assert_equal, assert_greater_than, \
|
||||
initialize_chain_clean, initialize_chain, start_nodes, start_node, connect_nodes_bi, \
|
||||
stop_nodes, sync_blocks, sync_mempools, wait_bitcoinds, rpc_port, assert_raises
|
||||
from cryptoconditions import assert_success, assert_error, generate_random_string
|
||||
|
||||
|
||||
class CryptoconditionsChannelsTest(CryptoconditionsTestFramework):
|
||||
|
||||
def run_channels_tests(self):
|
||||
|
||||
|
||||
"""!!! for testing needed test daemon which built with custom flag
|
||||
export CONFIGURE_FLAGS='CPPFLAGS=-DTESTMODE'
|
||||
since in usual mode 101 confirmations are needed for payment/refund
|
||||
"""
|
||||
|
||||
rpc = self.nodes[0]
|
||||
rpc1 = self.nodes[1]
|
||||
|
||||
# getting empty channels list
|
||||
result = rpc.channelsinfo()
|
||||
assert_equal(len(result), 2)
|
||||
assert_equal(result["result"], "success")
|
||||
assert_equal(result["name"], "Channels Info")
|
||||
|
||||
# 10 payments, 100000 sat denomination channel opening with second node pubkey
|
||||
new_channel_hex = rpc.channelsopen(self.pubkey1, "10", "100000")
|
||||
assert_success(new_channel_hex)
|
||||
channel_txid = self.send_and_mine(new_channel_hex["hex"], rpc)
|
||||
assert channel_txid, "got channel txid"
|
||||
|
||||
# checking if our new channel in common channels list
|
||||
result = rpc.channelsinfo()
|
||||
assert_equal(len(result), 3)
|
||||
|
||||
# checking info about channel directly
|
||||
result = rpc.channelsinfo(channel_txid)
|
||||
assert_success(result)
|
||||
assert_equal(result["Open"], "10 payments of 100000 satoshi")
|
||||
|
||||
# open transaction should be confirmed
|
||||
rpc.generate(1)
|
||||
|
||||
# trying to make wrong denomination channel payment
|
||||
result = rpc.channelspayment(channel_txid, "199000")
|
||||
assert_error(result)
|
||||
|
||||
# trying to make 0 channel payment
|
||||
result = rpc.channelspayment(channel_txid, "0")
|
||||
assert_error(result)
|
||||
|
||||
# trying to make negative channel payment
|
||||
result = rpc.channelspayment(channel_txid, "-1")
|
||||
assert_error(result)
|
||||
|
||||
# valid channel payment
|
||||
result = rpc.channelspayment(channel_txid, "100000")
|
||||
assert_success(result)
|
||||
payment_tx_id = self.send_and_mine(result["hex"], rpc)
|
||||
assert payment_tx_id, "got txid"
|
||||
|
||||
# now in channelinfo payment information should appear
|
||||
result = rpc.channelsinfo(channel_txid)
|
||||
assert_equal(result["Payment"], "100000 satoshi to {}, 9 payments left".format(self.addr1))
|
||||
|
||||
# executing channel close
|
||||
result = rpc.channelsclose(channel_txid)
|
||||
assert_success(result)
|
||||
channel_close_txid = self.send_and_mine(result["hex"], rpc)
|
||||
assert channel_close_txid, "got txid"
|
||||
|
||||
rpc.generate(2)
|
||||
self.sync_all()
|
||||
|
||||
# now in channelinfo closed flag should appear
|
||||
result = rpc.channelsinfo(channel_txid)
|
||||
assert_equal(result["Close"], "channel")
|
||||
|
||||
# executing channel refund
|
||||
result = rpc.channelsrefund(channel_txid, channel_close_txid)
|
||||
assert_success(result)
|
||||
refund_txid = self.send_and_mine(result["hex"], rpc)
|
||||
assert refund_txid, "got txid"
|
||||
|
||||
def run_test(self):
|
||||
print("Mining blocks...")
|
||||
rpc = self.nodes[0]
|
||||
rpc1 = self.nodes[1]
|
||||
# utxos from block 1 become mature in block 101
|
||||
if not self.options.noshutdown:
|
||||
rpc.generate(101)
|
||||
self.sync_all()
|
||||
rpc.getinfo()
|
||||
rpc1.getinfo()
|
||||
# this corresponds to -pubkey above
|
||||
print("Importing privkeys")
|
||||
rpc.importprivkey(self.privkey)
|
||||
rpc1.importprivkey(self.privkey1)
|
||||
self.run_channels_tests()
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
CryptoconditionsChannelsTest().main()
|
||||
@@ -4,78 +4,15 @@
|
||||
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||
|
||||
|
||||
from test_framework.test_framework import BitcoinTestFramework
|
||||
from test_framework.test_framework import CryptoconditionsTestFramework
|
||||
from test_framework.authproxy import JSONRPCException
|
||||
from test_framework.util import assert_equal, assert_greater_than, \
|
||||
initialize_chain_clean, initialize_chain, start_nodes, start_node, connect_nodes_bi, \
|
||||
stop_nodes, sync_blocks, sync_mempools, wait_bitcoinds, rpc_port, assert_raises
|
||||
from cryptoconditions import assert_success, assert_error, generate_random_string
|
||||
|
||||
class CryptoconditionsDiceTest(BitcoinTestFramework):
|
||||
|
||||
def setup_chain(self):
|
||||
print("Initializing CC test directory "+self.options.tmpdir)
|
||||
self.num_nodes = 2
|
||||
initialize_chain_clean(self.options.tmpdir, self.num_nodes)
|
||||
|
||||
def setup_network(self, split = False):
|
||||
print("Setting up network...")
|
||||
self.addr = "RWPg8B91kfK5UtUN7z6s6TeV9cHSGtVY8D"
|
||||
self.pubkey = "02676d00110c2cd14ae24f95969e8598f7ccfaa675498b82654a5b5bd57fc1d8cf"
|
||||
self.privkey = "UqMgxk7ySPNQ4r9nKAFPjkXy6r5t898yhuNCjSZJLg3RAM4WW1m9"
|
||||
self.addr1 = "RXEXoa1nRmKhMbuZovpcYwQMsicwzccZBp"
|
||||
self.pubkey1 = "024026d4ad4ecfc1f705a9b42ca64af6d2ad947509c085534a30b8861d756c6ff0"
|
||||
self.privkey1 = "UtdydP56pGTFmawHzHr1wDrc4oUwCNW1ttX8Pc3KrvH3MA8P49Wi"
|
||||
self.nodes = start_nodes(self.num_nodes, self.options.tmpdir,
|
||||
extra_args=[[
|
||||
# always give -ac_name as first extra_arg and port as third
|
||||
'-ac_name=REGTEST',
|
||||
'-conf='+self.options.tmpdir+'/node0/REGTEST.conf',
|
||||
'-port=64367',
|
||||
'-rpcport=64368',
|
||||
'-regtest',
|
||||
'-addressindex=1',
|
||||
'-spentindex=1',
|
||||
'-ac_supply=5555555',
|
||||
'-ac_reward=10000000000000',
|
||||
'-pubkey=' + self.pubkey,
|
||||
'-ac_cc=2',
|
||||
'-whitelist=127.0.0.1',
|
||||
'-debug',
|
||||
'--daemon',
|
||||
'-rpcuser=rt',
|
||||
'-rpcpassword=rt'
|
||||
],
|
||||
['-ac_name=REGTEST',
|
||||
'-conf='+self.options.tmpdir+'/node1/REGTEST.conf',
|
||||
'-port=64365',
|
||||
'-rpcport=64366',
|
||||
'-regtest',
|
||||
'-addressindex=1',
|
||||
'-spentindex=1',
|
||||
'-ac_supply=5555555',
|
||||
'-ac_reward=10000000000000',
|
||||
'-pubkey=' + self.pubkey1,
|
||||
'-ac_cc=2',
|
||||
'-whitelist=127.0.0.1',
|
||||
'-debug',
|
||||
'-addnode=127.0.0.1:64367',
|
||||
'--daemon',
|
||||
'-rpcuser=rt',
|
||||
'-rpcpassword=rt']]
|
||||
)
|
||||
self.is_network_split = split
|
||||
self.rpc = self.nodes[0]
|
||||
self.rpc1 = self.nodes[1]
|
||||
self.sync_all()
|
||||
print("Done setting up network")
|
||||
|
||||
def send_and_mine(self, xtn, rpc_connection):
|
||||
txid = rpc_connection.sendrawtransaction(xtn)
|
||||
assert txid, 'got txid'
|
||||
# we need the tx above to be confirmed in the next block
|
||||
rpc_connection.generate(1)
|
||||
return txid
|
||||
class CryptoconditionsDiceTest(CryptoconditionsTestFramework):
|
||||
|
||||
def run_dice_tests(self):
|
||||
rpc = self.nodes[0]
|
||||
@@ -244,7 +181,8 @@ class CryptoconditionsDiceTest(BitcoinTestFramework):
|
||||
rpc = self.nodes[0]
|
||||
rpc1 = self.nodes[1]
|
||||
# utxos from block 1 become mature in block 101
|
||||
rpc.generate(101)
|
||||
if not self.options.noshutdown:
|
||||
rpc.generate(101)
|
||||
self.sync_all()
|
||||
rpc.getinfo()
|
||||
rpc1.getinfo()
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||
|
||||
|
||||
from test_framework.test_framework import BitcoinTestFramework
|
||||
from test_framework.test_framework import CryptoconditionsTestFramework
|
||||
from test_framework.authproxy import JSONRPCException
|
||||
from test_framework.util import assert_equal, assert_greater_than, \
|
||||
initialize_chain_clean, initialize_chain, start_nodes, start_node, connect_nodes_bi, \
|
||||
@@ -12,71 +12,7 @@ from test_framework.util import assert_equal, assert_greater_than, \
|
||||
from cryptoconditions import assert_success, assert_error, generate_random_string
|
||||
|
||||
|
||||
class CryptoconditionsFaucetTest(BitcoinTestFramework):
|
||||
|
||||
def setup_chain(self):
|
||||
print("Initializing CC test directory "+self.options.tmpdir)
|
||||
self.num_nodes = 2
|
||||
initialize_chain_clean(self.options.tmpdir, self.num_nodes)
|
||||
|
||||
def setup_network(self, split = False):
|
||||
print("Setting up network...")
|
||||
self.addr = "RWPg8B91kfK5UtUN7z6s6TeV9cHSGtVY8D"
|
||||
self.pubkey = "02676d00110c2cd14ae24f95969e8598f7ccfaa675498b82654a5b5bd57fc1d8cf"
|
||||
self.privkey = "UqMgxk7ySPNQ4r9nKAFPjkXy6r5t898yhuNCjSZJLg3RAM4WW1m9"
|
||||
self.addr1 = "RXEXoa1nRmKhMbuZovpcYwQMsicwzccZBp"
|
||||
self.pubkey1 = "024026d4ad4ecfc1f705a9b42ca64af6d2ad947509c085534a30b8861d756c6ff0"
|
||||
self.privkey1 = "UtdydP56pGTFmawHzHr1wDrc4oUwCNW1ttX8Pc3KrvH3MA8P49Wi"
|
||||
self.nodes = start_nodes(self.num_nodes, self.options.tmpdir,
|
||||
extra_args=[[
|
||||
# always give -ac_name as first extra_arg and port as third
|
||||
'-ac_name=REGTEST',
|
||||
'-conf='+self.options.tmpdir+'/node0/REGTEST.conf',
|
||||
'-port=64367',
|
||||
'-rpcport=64368',
|
||||
'-regtest',
|
||||
'-addressindex=1',
|
||||
'-spentindex=1',
|
||||
'-ac_supply=5555555',
|
||||
'-ac_reward=10000000000000',
|
||||
'-pubkey=' + self.pubkey,
|
||||
'-ac_cc=2',
|
||||
'-whitelist=127.0.0.1',
|
||||
'-debug',
|
||||
'--daemon',
|
||||
'-rpcuser=rt',
|
||||
'-rpcpassword=rt'
|
||||
],
|
||||
['-ac_name=REGTEST',
|
||||
'-conf='+self.options.tmpdir+'/node1/REGTEST.conf',
|
||||
'-port=64365',
|
||||
'-rpcport=64366',
|
||||
'-regtest',
|
||||
'-addressindex=1',
|
||||
'-spentindex=1',
|
||||
'-ac_supply=5555555',
|
||||
'-ac_reward=10000000000000',
|
||||
'-pubkey=' + self.pubkey1,
|
||||
'-ac_cc=2',
|
||||
'-whitelist=127.0.0.1',
|
||||
'-debug',
|
||||
'-addnode=127.0.0.1:64367',
|
||||
'--daemon',
|
||||
'-rpcuser=rt',
|
||||
'-rpcpassword=rt']]
|
||||
)
|
||||
self.is_network_split = split
|
||||
self.rpc = self.nodes[0]
|
||||
self.rpc1 = self.nodes[1]
|
||||
self.sync_all()
|
||||
print("Done setting up network")
|
||||
|
||||
def send_and_mine(self, xtn, rpc_connection):
|
||||
txid = rpc_connection.sendrawtransaction(xtn)
|
||||
assert txid, 'got txid'
|
||||
# we need the tx above to be confirmed in the next block
|
||||
rpc_connection.generate(1)
|
||||
return txid
|
||||
class CryptoconditionsFaucetTest(CryptoconditionsTestFramework):
|
||||
|
||||
def run_faucet_tests(self):
|
||||
rpc = self.rpc
|
||||
|
||||
94
qa/rpc-tests/cryptoconditions_gateways.py
Executable file
94
qa/rpc-tests/cryptoconditions_gateways.py
Executable file
@@ -0,0 +1,94 @@
|
||||
#!/usr/bin/env python2
|
||||
# Copyright (c) 2018 SuperNET developers
|
||||
# Distributed under the MIT software license, see the accompanying
|
||||
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||
|
||||
|
||||
from test_framework.test_framework import CryptoconditionsTestFramework
|
||||
from test_framework.authproxy import JSONRPCException
|
||||
from test_framework.util import assert_equal, assert_greater_than, \
|
||||
initialize_chain_clean, initialize_chain, start_nodes, start_node, connect_nodes_bi, \
|
||||
stop_nodes, sync_blocks, sync_mempools, wait_bitcoinds, rpc_port, assert_raises
|
||||
from cryptoconditions import assert_success, assert_error, generate_random_string
|
||||
|
||||
|
||||
class CryptoconditionsGatewaysTest(CryptoconditionsTestFramework):
|
||||
|
||||
def run_gateways_tests(self):
|
||||
rpc = self.nodes[0]
|
||||
rpc1 = self.nodes[1]
|
||||
|
||||
result = rpc.gatewaysaddress()
|
||||
assert_success(result)
|
||||
for x in ['GatewaysCCaddress', 'myCCaddress', 'Gatewaysmarker', 'myaddress']:
|
||||
assert_equal(result[x][0], 'R')
|
||||
|
||||
assert_equal("03ea9c062b9652d8eff34879b504eda0717895d27597aaeb60347d65eed96ccb40", result["GatewaysPubkey"])
|
||||
|
||||
# getting an empty gateways list
|
||||
|
||||
result = rpc.gatewayslist()
|
||||
assert_equal(result, [])
|
||||
|
||||
# Gateways binding preparation
|
||||
|
||||
# creating oracle
|
||||
oracle_hex = rpc.oraclescreate("Test", "Testing", "Ihh")
|
||||
assert_success(oracle_hex)
|
||||
oracle_txid = self.send_and_mine(oracle_hex["hex"], rpc)
|
||||
assert oracle_txid, "got txid"
|
||||
|
||||
# registering as an oracle publisher
|
||||
reg_hex = rpc.oraclesregister(oracle_txid, "10000")
|
||||
assert_success(reg_hex)
|
||||
reg_txid = self.send_and_mine(reg_hex["hex"], rpc)
|
||||
assert reg_txid, "got txid"
|
||||
|
||||
# subscribing on oracle
|
||||
sub_hex = rpc.oraclessubscribe(oracle_txid, self.pubkey, "1")
|
||||
assert_success(sub_hex)
|
||||
sub_txid = self.send_and_mine(sub_hex["hex"], rpc)
|
||||
assert sub_txid, "got txid"
|
||||
|
||||
# creating token
|
||||
token_hex = rpc.tokencreate("Test", "1", "Testing")
|
||||
assert_success(token_hex)
|
||||
token_txid = self.send_and_mine(token_hex["hex"], rpc)
|
||||
assert token_txid, "got txid"
|
||||
|
||||
# converting tokens
|
||||
convertion_hex = rpc.tokenconvert("241",token_txid,"03ea9c062b9652d8eff34879b504eda0717895d27597aaeb60347d65eed96ccb40","100000000")
|
||||
assert_success(convertion_hex)
|
||||
convertion_txid = self.send_and_mine(convertion_hex["hex"], rpc)
|
||||
assert convertion_txid, "got txid"
|
||||
|
||||
# binding gateway
|
||||
bind_hex = rpc.gatewaysbind(token_txid, oracle_txid, "KMD", "100000000", "1", "1", self.pubkey)
|
||||
assert_success(bind_hex)
|
||||
bind_txid = self.send_and_mine(bind_hex["hex"], rpc)
|
||||
assert bind_txid, "got txid"
|
||||
|
||||
# checking if created gateway in list
|
||||
result = rpc.gatewayslist()
|
||||
assert_equal(result[0], bind_txid)
|
||||
|
||||
|
||||
def run_test(self):
|
||||
print("Mining blocks...")
|
||||
rpc = self.nodes[0]
|
||||
rpc1 = self.nodes[1]
|
||||
# utxos from block 1 become mature in block 101
|
||||
if not self.options.noshutdown:
|
||||
rpc.generate(101)
|
||||
self.sync_all()
|
||||
rpc.getinfo()
|
||||
rpc1.getinfo()
|
||||
# this corresponds to -pubkey above
|
||||
print("Importing privkeys")
|
||||
rpc.importprivkey(self.privkey)
|
||||
rpc1.importprivkey(self.privkey1)
|
||||
self.run_gateways_tests()
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
CryptoconditionsGatewaysTest().main()
|
||||
@@ -4,7 +4,7 @@
|
||||
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||
|
||||
|
||||
from test_framework.test_framework import BitcoinTestFramework
|
||||
from test_framework.test_framework import CryptoconditionsTestFramework
|
||||
from test_framework.authproxy import JSONRPCException
|
||||
from test_framework.util import assert_equal, assert_greater_than, \
|
||||
initialize_chain_clean, initialize_chain, start_nodes, start_node, connect_nodes_bi, \
|
||||
@@ -12,72 +12,7 @@ from test_framework.util import assert_equal, assert_greater_than, \
|
||||
from cryptoconditions import assert_success, assert_error, generate_random_string
|
||||
|
||||
|
||||
class CryptoconditionsOraclesTest(BitcoinTestFramework):
|
||||
|
||||
|
||||
def setup_chain(self):
|
||||
print("Initializing CC test directory "+self.options.tmpdir)
|
||||
self.num_nodes = 2
|
||||
initialize_chain_clean(self.options.tmpdir, self.num_nodes)
|
||||
|
||||
def setup_network(self, split = False):
|
||||
print("Setting up network...")
|
||||
self.addr = "RWPg8B91kfK5UtUN7z6s6TeV9cHSGtVY8D"
|
||||
self.pubkey = "02676d00110c2cd14ae24f95969e8598f7ccfaa675498b82654a5b5bd57fc1d8cf"
|
||||
self.privkey = "UqMgxk7ySPNQ4r9nKAFPjkXy6r5t898yhuNCjSZJLg3RAM4WW1m9"
|
||||
self.addr1 = "RXEXoa1nRmKhMbuZovpcYwQMsicwzccZBp"
|
||||
self.pubkey1 = "024026d4ad4ecfc1f705a9b42ca64af6d2ad947509c085534a30b8861d756c6ff0"
|
||||
self.privkey1 = "UtdydP56pGTFmawHzHr1wDrc4oUwCNW1ttX8Pc3KrvH3MA8P49Wi"
|
||||
self.nodes = start_nodes(self.num_nodes, self.options.tmpdir,
|
||||
extra_args=[[
|
||||
# always give -ac_name as first extra_arg and port as third
|
||||
'-ac_name=REGTEST',
|
||||
'-conf='+self.options.tmpdir+'/node0/REGTEST.conf',
|
||||
'-port=64367',
|
||||
'-rpcport=64368',
|
||||
'-regtest',
|
||||
'-addressindex=1',
|
||||
'-spentindex=1',
|
||||
'-ac_supply=5555555',
|
||||
'-ac_reward=10000000000000',
|
||||
'-pubkey=' + self.pubkey,
|
||||
'-ac_cc=2',
|
||||
'-whitelist=127.0.0.1',
|
||||
'-debug',
|
||||
'--daemon',
|
||||
'-rpcuser=rt',
|
||||
'-rpcpassword=rt'
|
||||
],
|
||||
['-ac_name=REGTEST',
|
||||
'-conf='+self.options.tmpdir+'/node1/REGTEST.conf',
|
||||
'-port=64365',
|
||||
'-rpcport=64366',
|
||||
'-regtest',
|
||||
'-addressindex=1',
|
||||
'-spentindex=1',
|
||||
'-ac_supply=5555555',
|
||||
'-ac_reward=10000000000000',
|
||||
'-pubkey=' + self.pubkey1,
|
||||
'-ac_cc=2',
|
||||
'-whitelist=127.0.0.1',
|
||||
'-debug',
|
||||
'-addnode=127.0.0.1:64367',
|
||||
'--daemon',
|
||||
'-rpcuser=rt',
|
||||
'-rpcpassword=rt']]
|
||||
)
|
||||
self.is_network_split = split
|
||||
self.rpc = self.nodes[0]
|
||||
self.rpc1 = self.nodes[1]
|
||||
self.sync_all()
|
||||
print("Done setting up network")
|
||||
|
||||
def send_and_mine(self, xtn, rpc_connection):
|
||||
txid = rpc_connection.sendrawtransaction(xtn)
|
||||
assert txid, 'got txid'
|
||||
# we need the tx above to be confirmed in the next block
|
||||
rpc_connection.generate(1)
|
||||
return txid
|
||||
class CryptoconditionsOraclesTest(CryptoconditionsTestFramework):
|
||||
|
||||
def run_oracles_tests(self):
|
||||
rpc = self.nodes[0]
|
||||
@@ -269,8 +204,6 @@ class CryptoconditionsOraclesTest(BitcoinTestFramework):
|
||||
oraclesdata_Ihh = self.send_and_mine(result["hex"], rpc)
|
||||
result = rpc.oraclessamples(globals()["oracle_{}".format("Ihh")], oraclesdata_Ihh, "1")
|
||||
assert_equal("[u'0']", str(result["samples"][0]), "Data match")
|
||||
assert_equal("[u'00000000ffffffff00000000ffffffff00000000ffffffff00000000ffffffff']", str(result["samples"][1]), "Data match")
|
||||
assert_equal("[u'00000000ffffffff00000000ffffffff00000000ffffffff00000000ffffffff']", str(result["samples"][2]), "Data match")
|
||||
|
||||
|
||||
def run_test(self):
|
||||
@@ -278,7 +211,8 @@ class CryptoconditionsOraclesTest(BitcoinTestFramework):
|
||||
rpc = self.nodes[0]
|
||||
rpc1 = self.nodes[1]
|
||||
# utxos from block 1 become mature in block 101
|
||||
rpc.generate(101)
|
||||
if not self.options.noshutdown:
|
||||
rpc.generate(101)
|
||||
self.sync_all()
|
||||
rpc.getinfo()
|
||||
rpc1.getinfo()
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||
|
||||
|
||||
from test_framework.test_framework import BitcoinTestFramework
|
||||
from test_framework.test_framework import CryptoconditionsTestFramework
|
||||
from test_framework.authproxy import JSONRPCException
|
||||
from test_framework.util import assert_equal, assert_greater_than, \
|
||||
initialize_chain_clean, initialize_chain, start_nodes, start_node, connect_nodes_bi, \
|
||||
@@ -12,72 +12,7 @@ from test_framework.util import assert_equal, assert_greater_than, \
|
||||
from cryptoconditions import assert_success, assert_error, generate_random_string
|
||||
|
||||
|
||||
class CryptoconditionsRewardsTest(BitcoinTestFramework):
|
||||
|
||||
|
||||
def setup_chain(self):
|
||||
print("Initializing CC test directory "+self.options.tmpdir)
|
||||
self.num_nodes = 2
|
||||
initialize_chain_clean(self.options.tmpdir, self.num_nodes)
|
||||
|
||||
def setup_network(self, split = False):
|
||||
print("Setting up network...")
|
||||
self.addr = "RWPg8B91kfK5UtUN7z6s6TeV9cHSGtVY8D"
|
||||
self.pubkey = "02676d00110c2cd14ae24f95969e8598f7ccfaa675498b82654a5b5bd57fc1d8cf"
|
||||
self.privkey = "UqMgxk7ySPNQ4r9nKAFPjkXy6r5t898yhuNCjSZJLg3RAM4WW1m9"
|
||||
self.addr1 = "RXEXoa1nRmKhMbuZovpcYwQMsicwzccZBp"
|
||||
self.pubkey1 = "024026d4ad4ecfc1f705a9b42ca64af6d2ad947509c085534a30b8861d756c6ff0"
|
||||
self.privkey1 = "UtdydP56pGTFmawHzHr1wDrc4oUwCNW1ttX8Pc3KrvH3MA8P49Wi"
|
||||
self.nodes = start_nodes(self.num_nodes, self.options.tmpdir,
|
||||
extra_args=[[
|
||||
# always give -ac_name as first extra_arg and port as third
|
||||
'-ac_name=REGTEST',
|
||||
'-conf='+self.options.tmpdir+'/node0/REGTEST.conf',
|
||||
'-port=64367',
|
||||
'-rpcport=64368',
|
||||
'-regtest',
|
||||
'-addressindex=1',
|
||||
'-spentindex=1',
|
||||
'-ac_supply=5555555',
|
||||
'-ac_reward=10000000000000',
|
||||
'-pubkey=' + self.pubkey,
|
||||
'-ac_cc=2',
|
||||
'-whitelist=127.0.0.1',
|
||||
'-debug',
|
||||
'--daemon',
|
||||
'-rpcuser=rt',
|
||||
'-rpcpassword=rt'
|
||||
],
|
||||
['-ac_name=REGTEST',
|
||||
'-conf='+self.options.tmpdir+'/node1/REGTEST.conf',
|
||||
'-port=64365',
|
||||
'-rpcport=64366',
|
||||
'-regtest',
|
||||
'-addressindex=1',
|
||||
'-spentindex=1',
|
||||
'-ac_supply=5555555',
|
||||
'-ac_reward=10000000000000',
|
||||
'-pubkey=' + self.pubkey1,
|
||||
'-ac_cc=2',
|
||||
'-whitelist=127.0.0.1',
|
||||
'-debug',
|
||||
'-addnode=127.0.0.1:64367',
|
||||
'--daemon',
|
||||
'-rpcuser=rt',
|
||||
'-rpcpassword=rt']]
|
||||
)
|
||||
self.is_network_split = split
|
||||
self.rpc = self.nodes[0]
|
||||
self.rpc1 = self.nodes[1]
|
||||
self.sync_all()
|
||||
print("Done setting up network")
|
||||
|
||||
def send_and_mine(self, xtn, rpc_connection):
|
||||
txid = rpc_connection.sendrawtransaction(xtn)
|
||||
assert txid, 'got txid'
|
||||
# we need the tx above to be confirmed in the next block
|
||||
rpc_connection.generate(1)
|
||||
return txid
|
||||
class CryptoconditionsRewardsTest(CryptoconditionsTestFramework):
|
||||
|
||||
def run_rewards_tests(self):
|
||||
rpc = self.nodes[0]
|
||||
@@ -194,7 +129,8 @@ class CryptoconditionsRewardsTest(BitcoinTestFramework):
|
||||
rpc = self.nodes[0]
|
||||
rpc1 = self.nodes[1]
|
||||
# utxos from block 1 become mature in block 101
|
||||
rpc.generate(101)
|
||||
if not self.options.noshutdown:
|
||||
rpc.generate(101)
|
||||
self.sync_all()
|
||||
rpc.getinfo()
|
||||
rpc1.getinfo()
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||
|
||||
|
||||
from test_framework.test_framework import BitcoinTestFramework
|
||||
from test_framework.test_framework import CryptoconditionsTestFramework
|
||||
from test_framework.authproxy import JSONRPCException
|
||||
from test_framework.util import assert_equal, assert_greater_than, \
|
||||
initialize_chain_clean, initialize_chain, start_nodes, start_node, connect_nodes_bi, \
|
||||
@@ -12,72 +12,7 @@ from test_framework.util import assert_equal, assert_greater_than, \
|
||||
from cryptoconditions import assert_success, assert_error, generate_random_string
|
||||
|
||||
|
||||
class CryptoconditionsTokenTest(BitcoinTestFramework):
|
||||
|
||||
|
||||
def setup_chain(self):
|
||||
print("Initializing CC test directory "+self.options.tmpdir)
|
||||
self.num_nodes = 2
|
||||
initialize_chain_clean(self.options.tmpdir, self.num_nodes)
|
||||
|
||||
def setup_network(self, split = False):
|
||||
print("Setting up network...")
|
||||
self.addr = "RWPg8B91kfK5UtUN7z6s6TeV9cHSGtVY8D"
|
||||
self.pubkey = "02676d00110c2cd14ae24f95969e8598f7ccfaa675498b82654a5b5bd57fc1d8cf"
|
||||
self.privkey = "UqMgxk7ySPNQ4r9nKAFPjkXy6r5t898yhuNCjSZJLg3RAM4WW1m9"
|
||||
self.addr1 = "RXEXoa1nRmKhMbuZovpcYwQMsicwzccZBp"
|
||||
self.pubkey1 = "024026d4ad4ecfc1f705a9b42ca64af6d2ad947509c085534a30b8861d756c6ff0"
|
||||
self.privkey1 = "UtdydP56pGTFmawHzHr1wDrc4oUwCNW1ttX8Pc3KrvH3MA8P49Wi"
|
||||
self.nodes = start_nodes(self.num_nodes, self.options.tmpdir,
|
||||
extra_args=[[
|
||||
# always give -ac_name as first extra_arg and port as third
|
||||
'-ac_name=REGTEST',
|
||||
'-conf='+self.options.tmpdir+'/node0/REGTEST.conf',
|
||||
'-port=64367',
|
||||
'-rpcport=64368',
|
||||
'-regtest',
|
||||
'-addressindex=1',
|
||||
'-spentindex=1',
|
||||
'-ac_supply=5555555',
|
||||
'-ac_reward=10000000000000',
|
||||
'-pubkey=' + self.pubkey,
|
||||
'-ac_cc=2',
|
||||
'-whitelist=127.0.0.1',
|
||||
'-debug',
|
||||
'--daemon',
|
||||
'-rpcuser=rt',
|
||||
'-rpcpassword=rt'
|
||||
],
|
||||
['-ac_name=REGTEST',
|
||||
'-conf='+self.options.tmpdir+'/node1/REGTEST.conf',
|
||||
'-port=64365',
|
||||
'-rpcport=64366',
|
||||
'-regtest',
|
||||
'-addressindex=1',
|
||||
'-spentindex=1',
|
||||
'-ac_supply=5555555',
|
||||
'-ac_reward=10000000000000',
|
||||
'-pubkey=' + self.pubkey1,
|
||||
'-ac_cc=2',
|
||||
'-whitelist=127.0.0.1',
|
||||
'-debug',
|
||||
'-addnode=127.0.0.1:64367',
|
||||
'--daemon',
|
||||
'-rpcuser=rt',
|
||||
'-rpcpassword=rt']]
|
||||
)
|
||||
self.is_network_split = split
|
||||
self.rpc = self.nodes[0]
|
||||
self.rpc1 = self.nodes[1]
|
||||
self.sync_all()
|
||||
print("Done setting up network")
|
||||
|
||||
def send_and_mine(self, xtn, rpc_connection):
|
||||
txid = rpc_connection.sendrawtransaction(xtn)
|
||||
assert txid, 'got txid'
|
||||
# we need the tx above to be confirmed in the next block
|
||||
rpc_connection.generate(1)
|
||||
return txid
|
||||
class CryptoconditionsTokenTest(CryptoconditionsTestFramework):
|
||||
|
||||
def run_token_tests(self):
|
||||
rpc = self.nodes[0]
|
||||
@@ -274,7 +209,8 @@ class CryptoconditionsTokenTest(BitcoinTestFramework):
|
||||
rpc = self.nodes[0]
|
||||
rpc1 = self.nodes[1]
|
||||
# utxos from block 1 become mature in block 101
|
||||
rpc.generate(101)
|
||||
if not self.options.noshutdown:
|
||||
rpc.generate(101)
|
||||
self.sync_all()
|
||||
rpc.getinfo()
|
||||
rpc1.getinfo()
|
||||
|
||||
@@ -180,3 +180,72 @@ class ComparisonTestFramework(BitcoinTestFramework):
|
||||
extra_args=[['-debug', '-whitelist=127.0.0.1']] * self.num_nodes,
|
||||
binary=[self.options.testbinary] +
|
||||
[self.options.refbinary]*(self.num_nodes-1))
|
||||
|
||||
|
||||
class CryptoconditionsTestFramework(BitcoinTestFramework):
|
||||
|
||||
def __init__(self):
|
||||
self.num_nodes = 2
|
||||
|
||||
def setup_chain(self):
|
||||
print("Initializing CC test directory "+self.options.tmpdir)
|
||||
initialize_chain_clean(self.options.tmpdir, self.num_nodes)
|
||||
|
||||
def setup_network(self, split = False):
|
||||
print("Setting up network...")
|
||||
self.addr = "RWPg8B91kfK5UtUN7z6s6TeV9cHSGtVY8D"
|
||||
self.pubkey = "02676d00110c2cd14ae24f95969e8598f7ccfaa675498b82654a5b5bd57fc1d8cf"
|
||||
self.privkey = "UqMgxk7ySPNQ4r9nKAFPjkXy6r5t898yhuNCjSZJLg3RAM4WW1m9"
|
||||
self.addr1 = "RXEXoa1nRmKhMbuZovpcYwQMsicwzccZBp"
|
||||
self.pubkey1 = "024026d4ad4ecfc1f705a9b42ca64af6d2ad947509c085534a30b8861d756c6ff0"
|
||||
self.privkey1 = "UtdydP56pGTFmawHzHr1wDrc4oUwCNW1ttX8Pc3KrvH3MA8P49Wi"
|
||||
self.nodes = start_nodes(self.num_nodes, self.options.tmpdir,
|
||||
extra_args=[[
|
||||
# always give -ac_name as first extra_arg and port as third
|
||||
'-ac_name=REGTEST',
|
||||
'-conf='+self.options.tmpdir+'/node0/REGTEST.conf',
|
||||
'-port=64367',
|
||||
'-rpcport=64368',
|
||||
'-regtest',
|
||||
'-addressindex=1',
|
||||
'-spentindex=1',
|
||||
'-ac_supply=5555555',
|
||||
'-ac_reward=10000000000000',
|
||||
'-pubkey=' + self.pubkey,
|
||||
'-ac_cc=2',
|
||||
'-whitelist=127.0.0.1',
|
||||
'-debug',
|
||||
'--daemon',
|
||||
'-rpcuser=rt',
|
||||
'-rpcpassword=rt'
|
||||
],
|
||||
['-ac_name=REGTEST',
|
||||
'-conf='+self.options.tmpdir+'/node1/REGTEST.conf',
|
||||
'-port=64365',
|
||||
'-rpcport=64366',
|
||||
'-regtest',
|
||||
'-addressindex=1',
|
||||
'-spentindex=1',
|
||||
'-ac_supply=5555555',
|
||||
'-ac_reward=10000000000000',
|
||||
'-pubkey=' + self.pubkey1,
|
||||
'-ac_cc=2',
|
||||
'-whitelist=127.0.0.1',
|
||||
'-debug',
|
||||
'-addnode=127.0.0.1:64367',
|
||||
'--daemon',
|
||||
'-rpcuser=rt',
|
||||
'-rpcpassword=rt']]
|
||||
)
|
||||
self.is_network_split = split
|
||||
self.rpc = self.nodes[0]
|
||||
self.rpc1 = self.nodes[1]
|
||||
self.sync_all()
|
||||
print("Done setting up network")
|
||||
|
||||
def send_and_mine(self, xtn, rpc_connection):
|
||||
txid = rpc_connection.sendrawtransaction(xtn)
|
||||
assert txid, 'got txid'
|
||||
# we need the tx above to be confirmed in the next block
|
||||
rpc_connection.generate(1)
|
||||
return txid
|
||||
|
||||
2
src/ac/ksb
Executable file
2
src/ac/ksb
Executable file
@@ -0,0 +1,2 @@
|
||||
#!/bin/bash
|
||||
./komodo-cli -ac_name=KSB $1 $2 $3 $4 $5 $6
|
||||
@@ -124,7 +124,11 @@
|
||||
},
|
||||
{
|
||||
"ac_name": "ZILLA",
|
||||
"ac_supply": "11000000"
|
||||
"ac_supply": "11000000",
|
||||
"ac_sapling": "5000000",
|
||||
"addnode": [
|
||||
"51.68.215.104"
|
||||
]
|
||||
},
|
||||
{
|
||||
"ac_name": "RFOX",
|
||||
@@ -211,5 +215,14 @@
|
||||
"addnode": [
|
||||
"5.9.102.210"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"ac_name": "KSB",
|
||||
"ac_supply": "1000000000",
|
||||
"ac_end": "1",
|
||||
"ac_public": "1",
|
||||
"addnode": [
|
||||
"37.187.225.231"
|
||||
]
|
||||
}
|
||||
]
|
||||
|
||||
@@ -27,21 +27,22 @@ echo $pubkey
|
||||
./komodod -pubkey=$pubkey -ac_name=BEER -ac_supply=100000000 -addnode=78.47.196.146 &
|
||||
./komodod -pubkey=$pubkey -ac_name=PIZZA -ac_supply=100000000 -addnode=78.47.196.146 &
|
||||
./komodod -pubkey=$pubkey -ac_name=NINJA -ac_supply=100000000 -addnode=78.47.196.146 &
|
||||
./komodod -pubkey=$pubkey -ac_name=OOT -ac_supply=216000000 -ac_saplinig=5000000 -addnode=174.138.107.226 &
|
||||
./komodod -pubkey=$pubkey -ac_name=OOT -ac_supply=216000000 -ac_sapling=5000000 -addnode=174.138.107.226 &
|
||||
./komodod -pubkey=$pubkey -ac_name=BNTN -ac_supply=500000000 -addnode=94.130.169.205 &
|
||||
./komodod -pubkey=$pubkey -ac_name=CHAIN -ac_supply=999999 -addnode=78.47.146.222 &
|
||||
./komodod -pubkey=$pubkey -ac_name=PRLPAY -ac_supply=500000000 -addnode=13.250.226.125 &
|
||||
./komodod -pubkey=$pubkey -ac_name=DSEC -ac_supply=7000000 -addnode=185.148.147.30 &
|
||||
./komodod -pubkey=$pubkey -ac_name=GLXT -ac_supply=10000000000 -addnode=13.230.224.15 &
|
||||
./komodod -pubkey=$pubkey -ac_name=EQL -ac_supply=500000000 -ac_ccactivate=205000 -addnode=46.101.124.153 &
|
||||
./komodod -pubkey=$pubkey -ac_name=ZILLA -ac_supply=11000000 -addnode=54.39.23.248 &
|
||||
./komodod -pubkey=$pubkey -ac_name=ZILLA -ac_supply=11000000 -ac_sapling=5000000 -addnode=51.68.215.104 &
|
||||
./komodod -pubkey=$pubkey -ac_name=RFOX -ac_supply=1000000000 -ac_reward=100000000 -addnode=78.47.196.146 &
|
||||
~/VerusCoin/src/komodod -pubkey=$pubkey -ac_name=VRSC -ac_algo=verushash -ac_cc=1 -ac_veruspos=50 -ac_supply=0 -ac_eras=3 -ac_reward=0,38400000000,2400000000 -ac_halving=1,43200,1051920 -ac_decay=100000000,0,0 -ac_end=10080,226080,0 -ac_timelockgte=19200000000 -ac_timeunlockfrom=129600 -ac_timeunlockto=1180800 -addnode=185.25.48.236 -addnode=185.64.105.111 &
|
||||
./komodod -pubkey=$pubkey -ac_name=SEC -ac_cc=333 -ac_supply=1000000000 -addnode=185.148.145.43 &
|
||||
./komodod -pubkey=$pubkey -ac_name=CCL -ac_supply=200000000 -ac_end=1 -ac_cc=2 -addressindex=1 -spentindex=1 -addnode=142.93.136.89 -addnode=195.201.22.89 &
|
||||
./komodod -pubkey=$pubkey -ac_name=PIRATE -ac_supply=0 -ac_reward=25600000000 -ac_halving=77777 -ac_private=1 -addnode=136.243.102.225 &
|
||||
./komodod -pubkey=$pubkey -ac_name=PIRATE -ac_supply=0 -ac_reward=25600000000 -ac_halving=77777 -ac_private=1 -addnode=178.63.77.56 &
|
||||
./komodod -pubkey=$pubkey -ac_name=MGNX -ac_supply=12465003 -ac_staked=90 -ac_reward=2000000000 -ac_halving=525960 -ac_cc=2 -ac_end=2629800 -addnode=142.93.27.180 &
|
||||
./komodod -pubkey=$pubkey -ac_name=PGT -ac_supply=10000000 -ac_end=1 -addnode=190.114.254.104 &
|
||||
./komodod -pubkey=$pubkey -ac_name=KMDICE -ac_supply=10500000 -ac_reward=2500000000 -ac_halving=210000 -ac_cc=2 -addressindex=1 -spentindex=1 -addnode=144.76.217.232 &
|
||||
./komodod -pubkey=$pubkey -ac_name=DION -ac_supply=3900000000 -ac_reward=22260000000 -ac_staked=100 -ac_cc=1 -ac_end=4300000000 -addnode=51.75.124.34 &
|
||||
./komodod -pubkey=$pubkey -ac_name=ZEX -ac_cc=2 -ac_founders=1 -ac_halving=525600 -ac_reward=13000000000 -ac_pubkey=039d4a50cc70d1184e462a22edb3b66385da97cc8059196f8305c184a3e21440af -addnode=5.9.102.210 &
|
||||
./komodod -pubkey=$pubkey -ac_name=KSB -ac_supply=1000000000 -ac_end=1 -ac_public=1 -addnode=37.187.225.231 &
|
||||
|
||||
@@ -25,7 +25,7 @@ std::string ChannelOpen(uint64_t txfee,CPubKey destpub,int32_t numpayments,int64
|
||||
std::string ChannelPayment(uint64_t txfee,uint256 opentxid,int64_t amount, uint256 secret);
|
||||
std::string ChannelClose(uint64_t txfee,uint256 opentxid);
|
||||
std::string ChannelRefund(uint64_t txfee,uint256 opentxid,uint256 closetxid);
|
||||
|
||||
UniValue ChannelsList();
|
||||
// CCcustom
|
||||
UniValue ChannelsInfo(uint256 opentxid);
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@ so you can pay to a pubkey, or to its hash. or to a script's hash. the last is h
|
||||
all of the above are the standard bitcoin vout types and there should be plenty of materials about it
|
||||
Encrypted by a verified device
|
||||
what I did with the CC contracts is created a fourth type of vout, the CC vout. this is using the cryptoconditions standard and it is even a different signature mechanism. ed25519 instead of secp256k1. it is basically a big extension to the bitcoin script. There is a special opcode that is added that says it is a CC script.
|
||||
|
||||
|
||||
but it gets more interesting
|
||||
each CC script has an evalcode
|
||||
this is just an arbitrary number. but what it does is allows to create a self-contained universe of CC utxo that all have the same evalcode and that is how a faucet CC differentiates itself from a dice CC, the eval code is different
|
||||
@@ -73,7 +73,7 @@ struct CC_utxo
|
||||
|
||||
// these are the parameters stored after Verus crypto-condition vouts. new versions may change
|
||||
// the format
|
||||
struct CC_meta
|
||||
struct CC_meta
|
||||
{
|
||||
std::vector<unsigned char> version;
|
||||
uint8_t evalCode;
|
||||
@@ -110,7 +110,7 @@ int32_t komodo_nextheight();
|
||||
static const uint256 zeroid;
|
||||
bool myGetTransaction(const uint256 &hash, CTransaction &txOut, uint256 &hashBlock);
|
||||
int32_t is_hexstr(char *str,int32_t n);
|
||||
bool myAddtomempool(CTransaction &tx, CValidationState *pstate = NULL);
|
||||
bool myAddtomempool(CTransaction &tx, CValidationState *pstate = NULL, bool fSkipExpiry = false);
|
||||
//uint64_t myGettxout(uint256 hash,int32_t n);
|
||||
bool myIsutxo_spentinmempool(uint256 txid,int32_t vout);
|
||||
bool mytxid_inmempool(uint256 txid);
|
||||
|
||||
@@ -75,11 +75,11 @@ int64_t IsChannelsvout(struct CCcontract_info *cp,const CTransaction& tx,CPubKey
|
||||
return(0);
|
||||
}
|
||||
|
||||
int64_t IsChannelsMarkervout(struct CCcontract_info *cp,const CTransaction& tx,CPubKey srcpub,int32_t v)
|
||||
int64_t IsChannelsMarkervout(struct CCcontract_info *cp,const CTransaction& tx,CPubKey pubkey,int32_t v)
|
||||
{
|
||||
char destaddr[65],ccaddr[65];
|
||||
|
||||
GetCCaddress(cp,ccaddr,srcpub);
|
||||
GetCCaddress(cp,ccaddr,pubkey);
|
||||
if ( tx.vout[v].scriptPubKey.IsPayToCryptoCondition() != 0 )
|
||||
{
|
||||
if ( Getscriptaddress(destaddr,tx.vout[v].scriptPubKey) > 0 && strcmp(destaddr,ccaddr) == 0 )
|
||||
@@ -207,11 +207,11 @@ bool ChannelsValidate(struct CCcontract_info *cp,Eval* eval,const CTransaction &
|
||||
return eval->Invalid("vin.1 is CC for channelPayment!");
|
||||
else if ( IsCCInput(tx.vin[2].scriptSig) == 0 )
|
||||
return eval->Invalid("vin.2 is CC for channelPayment!");
|
||||
else if ( tx.vout[0].scriptPubKey.IsPayToCryptoCondition() == 0 )
|
||||
else if ( IsChannelsvout(cp,tx,srcpub,destpub,0)==0 )
|
||||
return eval->Invalid("vout.0 is CC for channelPayment!");
|
||||
else if ( tx.vout[1].scriptPubKey.IsPayToCryptoCondition() == 0 )
|
||||
else if ( IsChannelsMarkervout(cp,tx,srcpub,1)==0 )
|
||||
return eval->Invalid("vout.1 is CC for channelPayment (marker to srcPub)!");
|
||||
else if ( tx.vout[2].scriptPubKey.IsPayToCryptoCondition() == 0 )
|
||||
else if ( IsChannelsMarkervout(cp,tx,destpub,2)==0 )
|
||||
return eval->Invalid("vout.2 is CC for channelPayment (marker to dstPub)!");
|
||||
else if ( tx.vout[3].scriptPubKey.IsPayToCryptoCondition() != 0 )
|
||||
return eval->Invalid("vout.3 is normal for channelPayment!");
|
||||
@@ -269,11 +269,11 @@ bool ChannelsValidate(struct CCcontract_info *cp,Eval* eval,const CTransaction &
|
||||
return eval->Invalid("vin.1 is CC for channelClose!");
|
||||
else if ( IsCCInput(tx.vin[2].scriptSig) == 0 )
|
||||
return eval->Invalid("vin.2 is CC for channelClose!");
|
||||
else if ( tx.vout[0].scriptPubKey.IsPayToCryptoCondition() == 0 )
|
||||
else if ( IsChannelsvout(cp,tx,srcpub,destpub,0)==0 )
|
||||
return eval->Invalid("vout.0 is CC for channelClose!");
|
||||
else if ( tx.vout[1].scriptPubKey.IsPayToCryptoCondition() == 0 )
|
||||
else if ( IsChannelsMarkervout(cp,tx,srcpub,1)==0 )
|
||||
return eval->Invalid("vout.1 is CC for channelClose (marker to srcPub)!");
|
||||
else if ( tx.vout[2].scriptPubKey.IsPayToCryptoCondition() == 0 )
|
||||
else if ( IsChannelsMarkervout(cp,tx,destpub,2)==0 )
|
||||
return eval->Invalid("vout.2 is CC for channelClose (marker to dstPub)!");
|
||||
else if ( param1 > CHANNELS_MAXPAYMENTS)
|
||||
return eval->Invalid("too many payment increments!");
|
||||
@@ -314,9 +314,9 @@ bool ChannelsValidate(struct CCcontract_info *cp,Eval* eval,const CTransaction &
|
||||
return eval->Invalid("vin.1 is CC for channelRefund!");
|
||||
else if ( IsCCInput(tx.vin[2].scriptSig) == 0 )
|
||||
return eval->Invalid("vin.2 is CC for channelRefund!");
|
||||
else if ( tx.vout[0].scriptPubKey.IsPayToCryptoCondition() == 0 )
|
||||
else if ( IsChannelsMarkervout(cp,tx,srcpub,0)==0 )
|
||||
return eval->Invalid("vout.0 is CC for channelRefund (marker to srcPub)!");
|
||||
else if ( tx.vout[1].scriptPubKey.IsPayToCryptoCondition() == 0 )
|
||||
else if ( IsChannelsMarkervout(cp,tx,destpub,1)==0 )
|
||||
return eval->Invalid("vout.1 is CC for channelRefund (marker to dstPub)!");
|
||||
else if ( tx.vout[2].scriptPubKey.IsPayToCryptoCondition() != 0 )
|
||||
return eval->Invalid("vout.2 is normal for channelRefund!");
|
||||
@@ -366,12 +366,12 @@ bool ChannelsValidate(struct CCcontract_info *cp,Eval* eval,const CTransaction &
|
||||
|
||||
// helper functions for rpc calls in rpcwallet.cpp
|
||||
|
||||
int64_t AddChannelsInputs(struct CCcontract_info *cp,CMutableTransaction &mtx, CTransaction openTx, uint256 &prevtxid)
|
||||
int64_t AddChannelsInputs(struct CCcontract_info *cp,CMutableTransaction &mtx, CTransaction openTx, uint256 &prevtxid, CPubKey mypk)
|
||||
{
|
||||
char coinaddr[65]; int64_t param2,totalinputs = 0,numvouts; uint256 txid=zeroid,tmp_txid,hashBlock,param3; CTransaction tx; int32_t param1;
|
||||
char coinaddr[65]; int64_t param2,totalinputs = 0,numvouts; uint256 txid=zeroid,tmp_txid,hashBlock,param3; CTransaction tx; int32_t marker,param1;
|
||||
std::vector<std::pair<CAddressUnspentKey, CAddressUnspentValue> > unspentOutputs;
|
||||
CPubKey srcpub,destpub;
|
||||
uint8_t myprivkey[32];
|
||||
uint8_t myprivkey[32];
|
||||
|
||||
if ((numvouts=openTx.vout.size()) > 0 && DecodeChannelsOpRet(openTx.vout[numvouts-1].scriptPubKey,tmp_txid,srcpub,destpub,param1,param2,param3)=='O')
|
||||
{
|
||||
@@ -383,14 +383,15 @@ int64_t AddChannelsInputs(struct CCcontract_info *cp,CMutableTransaction &mtx, C
|
||||
fprintf(stderr,"invalid channel open txid\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (srcpub==mypk) marker=1;
|
||||
else marker=2;
|
||||
for (std::vector<std::pair<CAddressUnspentKey, CAddressUnspentValue> >::const_iterator it=unspentOutputs.begin(); it!=unspentOutputs.end(); it++)
|
||||
{
|
||||
if ( (int32_t)it->first.index==0 && GetTransaction(it->first.txhash,tx,hashBlock,false) != 0 && (numvouts=tx.vout.size()) > 0)
|
||||
{
|
||||
if (DecodeChannelsOpRet(tx.vout[numvouts-1].scriptPubKey,tmp_txid,srcpub,destpub,param1,param2,param3)!=0 &&
|
||||
(tmp_txid==openTx.GetHash() || tx.GetHash()==openTx.GetHash()) &&
|
||||
(totalinputs=IsChannelsvout(cp,tx,srcpub,destpub,0)+IsChannelsMarkervout(cp,tx,srcpub,1))>0)
|
||||
(totalinputs=IsChannelsvout(cp,tx,srcpub,destpub,0)+IsChannelsMarkervout(cp,tx,srcpub,marker))>0)
|
||||
{
|
||||
txid = it->first.txhash;
|
||||
break;
|
||||
@@ -419,7 +420,7 @@ int64_t AddChannelsInputs(struct CCcontract_info *cp,CMutableTransaction &mtx, C
|
||||
{
|
||||
prevtxid=txid;
|
||||
mtx.vin.push_back(CTxIn(txid,0,CScript()));
|
||||
mtx.vin.push_back(CTxIn(txid,1,CScript()));
|
||||
mtx.vin.push_back(CTxIn(txid,marker,CScript()));
|
||||
Myprivkey(myprivkey);
|
||||
CCaddr2set(cp,EVAL_CHANNELS,srcpub,myprivkey,coinaddr);
|
||||
CCaddr3set(cp,EVAL_CHANNELS,destpub,myprivkey,coinaddr);
|
||||
@@ -483,7 +484,7 @@ std::string ChannelPayment(uint64_t txfee,uint256 opentxid,int64_t amount, uint2
|
||||
}
|
||||
if (AddNormalinputs(mtx,mypk,2*txfee,3) > 0)
|
||||
{
|
||||
if ((funds=AddChannelsInputs(cp,mtx,channelOpenTx,prevtxid)) !=0 && (change=funds-amount-txfee)>=0)
|
||||
if ((funds=AddChannelsInputs(cp,mtx,channelOpenTx,prevtxid,mypk)) !=0 && (change=funds-amount-txfee)>=0)
|
||||
{
|
||||
if ((numvouts=channelOpenTx.vout.size()) > 0 && DecodeChannelsOpRet(channelOpenTx.vout[numvouts-1].scriptPubKey, txid, srcpub, destpub, totalnumpayments, payment, hashchain)=='O')
|
||||
{
|
||||
@@ -553,11 +554,11 @@ std::string ChannelPayment(uint64_t txfee,uint256 opentxid,int64_t amount, uint2
|
||||
fprintf(stderr, "invalid channel open tx\n");
|
||||
return ("");
|
||||
}
|
||||
mtx.vout.push_back(MakeCC1of2vout(EVAL_CHANNELS, change, mypk, destpub));
|
||||
mtx.vout.push_back(MakeCC1vout(EVAL_CHANNELS,txfee,mypk));
|
||||
mtx.vout.push_back(MakeCC1of2vout(EVAL_CHANNELS, change, srcpub, destpub));
|
||||
mtx.vout.push_back(MakeCC1vout(EVAL_CHANNELS,txfee,srcpub));
|
||||
mtx.vout.push_back(MakeCC1vout(EVAL_CHANNELS,txfee,destpub));
|
||||
mtx.vout.push_back(CTxOut(amount, CScript() << ParseHex(HexStr(destpub)) << OP_CHECKSIG));
|
||||
return (FinalizeCCTx(0, cp, mtx, mypk, txfee, EncodeChannelsOpRet('P', opentxid, mypk, destpub, prevdepth-numpayments, numpayments, secret)));
|
||||
return (FinalizeCCTx(0, cp, mtx, mypk, txfee, EncodeChannelsOpRet('P', opentxid, srcpub, destpub, prevdepth-numpayments, numpayments, secret)));
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -600,12 +601,12 @@ std::string ChannelClose(uint64_t txfee,uint256 opentxid)
|
||||
}
|
||||
if ( AddNormalinputs(mtx,mypk,2*txfee,3) > 0 )
|
||||
{
|
||||
if ((funds=AddChannelsInputs(cp,mtx,channelOpenTx,prevtxid)) !=0 && funds-txfee>0)
|
||||
if ((funds=AddChannelsInputs(cp,mtx,channelOpenTx,prevtxid,mypk)) !=0 && funds-txfee>0)
|
||||
{
|
||||
mtx.vout.push_back(MakeCC1of2vout(EVAL_CHANNELS, funds-txfee, mypk, destpub));
|
||||
mtx.vout.push_back(MakeCC1vout(EVAL_CHANNELS,txfee,mypk));
|
||||
mtx.vout.push_back(MakeCC1vout(EVAL_CHANNELS,txfee,destpub));
|
||||
return(FinalizeCCTx(0,cp,mtx,mypk,txfee,EncodeChannelsOpRet('C',opentxid,mypk,destpub,funds/payment,payment,zeroid)));
|
||||
return(FinalizeCCTx(0,cp,mtx,mypk,txfee,EncodeChannelsOpRet('C',opentxid,mypk,destpub,(funds-txfee)/payment,payment,zeroid)));
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -664,7 +665,7 @@ std::string ChannelRefund(uint64_t txfee,uint256 opentxid,uint256 closetxid)
|
||||
}
|
||||
if ( AddNormalinputs(mtx,mypk,2*txfee,3) > 0 )
|
||||
{
|
||||
if ((funds=AddChannelsInputs(cp,mtx,channelOpenTx,prevtxid)) !=0 && funds-txfee>0)
|
||||
if ((funds=AddChannelsInputs(cp,mtx,channelOpenTx,prevtxid,mypk)) !=0 && funds-txfee>0)
|
||||
{
|
||||
if ((GetTransaction(prevtxid,prevTx,hashblock,false) != 0) && (numvouts=prevTx.vout.size()) > 0 &&
|
||||
DecodeChannelsOpRet(prevTx.vout[numvouts-1].scriptPubKey, txid, srcpub, destpub, param1, param2, param3) != 0)
|
||||
@@ -696,84 +697,117 @@ std::string ChannelRefund(uint64_t txfee,uint256 opentxid,uint256 closetxid)
|
||||
}
|
||||
return("");
|
||||
}
|
||||
|
||||
UniValue ChannelsInfo(uint256 channeltxid)
|
||||
UniValue ChannelsList()
|
||||
{
|
||||
UniValue result(UniValue::VOBJ); CTransaction tx,opentx; uint256 txid,tmp_txid,hashBlock,param3,opentxid,hashchain,prevtxid;
|
||||
struct CCcontract_info *cp,C; char myCCaddr[65],addr[65],str1[512],str2[256]; int32_t vout,numvouts,param1,numpayments;
|
||||
int64_t nValue,param2,payment; CPubKey srcpub,destpub,mypk;
|
||||
std::vector<std::pair<CAddressIndexKey, CAmount> > txids;
|
||||
UniValue result(UniValue::VOBJ); std::vector<std::pair<CAddressIndexKey, CAmount> > txids; struct CCcontract_info *cp,C; uint256 txid,hashBlock,tmp_txid,param3;
|
||||
CTransaction tx; char myCCaddr[65],addr[65],str[256]; CPubKey mypk,srcpub,destpub; int32_t vout,numvouts,param1;
|
||||
int64_t nValue,param2;
|
||||
|
||||
result.push_back(Pair("result","success"));
|
||||
cp = CCinit(&C,EVAL_CHANNELS);
|
||||
mypk = pubkey2pk(Mypubkey());
|
||||
if (channeltxid==zeroid)
|
||||
GetCCaddress(cp,myCCaddr,mypk);
|
||||
SetCCtxids(txids,myCCaddr);
|
||||
result.push_back(Pair("result","success"));
|
||||
result.push_back(Pair("name","Channels List"));
|
||||
for (std::vector<std::pair<CAddressIndexKey, CAmount> >::const_iterator it=txids.begin(); it!=txids.end(); it++)
|
||||
{
|
||||
result.push_back(Pair("name","Channels Info"));
|
||||
GetCCaddress(cp,myCCaddr,mypk);
|
||||
SetCCtxids(txids,myCCaddr);
|
||||
for (std::vector<std::pair<CAddressIndexKey, CAmount> >::const_iterator it=txids.begin(); it!=txids.end(); it++)
|
||||
txid = it->first.txhash;
|
||||
vout = (int32_t)it->first.index;
|
||||
nValue = (int64_t)it->second;
|
||||
if ( (vout == 1 || vout == 2) && nValue == 10000 && GetTransaction(txid,tx,hashBlock,false) != 0 && (numvouts= tx.vout.size()) > 0 )
|
||||
{
|
||||
//int height = it->first.blockHeight;
|
||||
txid = it->first.txhash;
|
||||
vout = (int32_t)it->first.index;
|
||||
nValue = (int64_t)it->second;
|
||||
if ( (vout == 1 || vout == 2) && nValue == 10000 && GetTransaction(txid,tx,hashBlock,false) != 0 && (numvouts= tx.vout.size()) > 0 )
|
||||
{
|
||||
if (DecodeChannelsOpRet(tx.vout[numvouts-1].scriptPubKey,tmp_txid,srcpub,destpub,param1,param2,param3) == 'O')
|
||||
{
|
||||
GetCCaddress1of2(cp,addr,srcpub,destpub);
|
||||
sprintf(str1,"%s - %lld payments of %lld satoshi - %s",addr,(long long)param1,(long long)param2,tx.GetHash().ToString().c_str());
|
||||
result.push_back(Pair("Channel", str1));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (GetTransaction(channeltxid,tx,hashBlock,false) != 0 && (numvouts= tx.vout.size()) > 0 &&
|
||||
(DecodeChannelsOpRet(tx.vout[numvouts-1].scriptPubKey,opentxid,srcpub,destpub,param1,param2,param3) == 'O'))
|
||||
{
|
||||
GetCCaddress1of2(cp,addr,srcpub,destpub);
|
||||
sprintf(str1,"Channel %s",addr);
|
||||
result.push_back(Pair("name",str1));
|
||||
SetCCtxids(txids,addr);
|
||||
prevtxid=zeroid;
|
||||
for (std::vector<std::pair<CAddressIndexKey, CAmount> >::const_iterator it=txids.begin(); it!=txids.end(); it++)
|
||||
{
|
||||
|
||||
txid = it->first.txhash;
|
||||
if (txid!=prevtxid && GetTransaction(txid,tx,hashBlock,false) != 0 && (numvouts= tx.vout.size()) > 0 )
|
||||
{
|
||||
if (DecodeChannelsOpRet(tx.vout[numvouts-1].scriptPubKey,tmp_txid,srcpub,destpub,param1,param2,param3) == 'O' && tx.GetHash()==channeltxid)
|
||||
{
|
||||
sprintf(str1,"%lld payments of %lld satoshi",(long long)param1,(long long)param2);
|
||||
result.push_back(Pair("Open", str1));
|
||||
}
|
||||
else if (DecodeChannelsOpRet(tx.vout[numvouts-1].scriptPubKey,opentxid,srcpub,destpub,param1,param2,param3) == 'P' && opentxid==channeltxid)
|
||||
{
|
||||
if (GetTransaction(opentxid,opentx,hashBlock,false) != 0 && (numvouts=opentx.vout.size()) > 0 &&
|
||||
DecodeChannelsOpRet(opentx.vout[numvouts-1].scriptPubKey,tmp_txid,srcpub,destpub,numpayments,payment,hashchain) == 'O')
|
||||
{
|
||||
Getscriptaddress(str2,tx.vout[3].scriptPubKey);
|
||||
sprintf(str1,"%lld satoshi to %s, %lld payments left",(long long)(param2*payment),str2,(long long)param1);
|
||||
result.push_back(Pair("Payment",str1));
|
||||
}
|
||||
}
|
||||
else if (DecodeChannelsOpRet(tx.vout[numvouts-1].scriptPubKey,opentxid,srcpub,destpub,param1,param2,param3) == 'C' && opentxid==channeltxid)
|
||||
{
|
||||
result.push_back(Pair("Close","channel"));
|
||||
}
|
||||
else if (DecodeChannelsOpRet(tx.vout[numvouts-1].scriptPubKey,opentxid,srcpub,destpub,param1,param2,param3) == 'R' && opentxid==channeltxid)
|
||||
{
|
||||
Getscriptaddress(str2,tx.vout[2].scriptPubKey);
|
||||
sprintf(str1,"%lld satoshi back to %s",(long long)(param1*param2),str2);
|
||||
result.push_back(Pair("Refund",str1));
|
||||
}
|
||||
}
|
||||
prevtxid=txid;
|
||||
if (DecodeChannelsOpRet(tx.vout[numvouts-1].scriptPubKey,tmp_txid,srcpub,destpub,param1,param2,param3) == 'O')
|
||||
{
|
||||
GetCCaddress1of2(cp,addr,srcpub,destpub);
|
||||
sprintf(str,"%s - %lld payments of %lld satoshi",addr,(long long)param1,(long long)param2);
|
||||
result.push_back(Pair(txid.GetHex().data(),str));
|
||||
}
|
||||
}
|
||||
}
|
||||
return(result);
|
||||
}
|
||||
|
||||
UniValue ChannelsInfo(uint256 channeltxid)
|
||||
{
|
||||
UniValue result(UniValue::VOBJ),array(UniValue::VARR); CTransaction tx,opentx; uint256 txid,tmp_txid,hashBlock,param3,opentxid,hashchain,prevtxid;
|
||||
struct CCcontract_info *cp,C; char CCaddr[65],addr[65],str[512]; int32_t vout,numvouts,param1,numpayments;
|
||||
int64_t nValue,param2,payment; CPubKey srcpub,destpub,mypk;
|
||||
std::vector<std::pair<CAddressIndexKey, CAmount> > addressIndex; std::vector<uint256> txids;
|
||||
|
||||
cp = CCinit(&C,EVAL_CHANNELS);
|
||||
mypk = pubkey2pk(Mypubkey());
|
||||
|
||||
if (GetTransaction(channeltxid,tx,hashBlock,false) != 0 && (numvouts= tx.vout.size()) > 0 &&
|
||||
(DecodeChannelsOpRet(tx.vout[numvouts-1].scriptPubKey,opentxid,srcpub,destpub,param1,param2,param3) == 'O'))
|
||||
{
|
||||
GetCCaddress(cp,CCaddr,mypk);
|
||||
Getscriptaddress(addr,CScript() << ParseHex(HexStr(destpub)) << OP_CHECKSIG);
|
||||
result.push_back(Pair("result","success"));
|
||||
result.push_back(Pair("Channel CC address",CCaddr));
|
||||
result.push_back(Pair("Destination address",addr));
|
||||
result.push_back(Pair("Number of payments",param1));
|
||||
result.push_back(Pair("Denomination",param2));
|
||||
result.push_back(Pair("Amount",i64tostr(param1*param2)+" satoshi"));
|
||||
SetCCtxids(addressIndex,CCaddr);
|
||||
for (std::vector<std::pair<CAddressIndexKey, CAmount> >::const_iterator it=addressIndex.begin(); it!=addressIndex.end(); it++)
|
||||
{
|
||||
if (GetTransaction(it->first.txhash,tx,hashBlock,false) != 0 && (numvouts= tx.vout.size()) > 0 )
|
||||
if (DecodeChannelsOpRet(tx.vout[numvouts-1].scriptPubKey,tmp_txid,srcpub,destpub,param1,param2,param3)!=0 && (tmp_txid==channeltxid || tx.GetHash()==channeltxid))
|
||||
txids.push_back(it->first.txhash);
|
||||
}
|
||||
BOOST_FOREACH(const CTxMemPoolEntry &e, mempool.mapTx)
|
||||
{
|
||||
const CTransaction &txmempool = e.GetTx();
|
||||
const uint256 &hash = txmempool.GetHash();
|
||||
|
||||
if ((numvouts=txmempool.vout.size()) > 0 && DecodeChannelsOpRet(txmempool.vout[numvouts-1].scriptPubKey,tmp_txid,srcpub,destpub,param1,param2,param3) == 'P' && tmp_txid==channeltxid)
|
||||
txids.push_back(hash);
|
||||
}
|
||||
prevtxid=zeroid;
|
||||
for (std::vector<uint256>::const_iterator it=txids.begin(); it!=txids.end(); it++)
|
||||
{
|
||||
txid=*it;
|
||||
if (txid!=prevtxid && GetTransaction(txid,tx,hashBlock,false) != 0 && (numvouts= tx.vout.size()) > 0 )
|
||||
{
|
||||
UniValue obj(UniValue::VOBJ);
|
||||
if (DecodeChannelsOpRet(tx.vout[numvouts-1].scriptPubKey,tmp_txid,srcpub,destpub,param1,param2,param3) == 'O' && tx.GetHash()==channeltxid)
|
||||
{
|
||||
obj.push_back(Pair("Open",txid.GetHex().data()));
|
||||
}
|
||||
else if (DecodeChannelsOpRet(tx.vout[numvouts-1].scriptPubKey,opentxid,srcpub,destpub,param1,param2,param3) == 'P' && opentxid==channeltxid)
|
||||
{
|
||||
if (GetTransaction(opentxid,opentx,hashBlock,false) != 0 && (numvouts=opentx.vout.size()) > 0 &&
|
||||
DecodeChannelsOpRet(opentx.vout[numvouts-1].scriptPubKey,tmp_txid,srcpub,destpub,numpayments,payment,hashchain) == 'O')
|
||||
{
|
||||
Getscriptaddress(str,tx.vout[3].scriptPubKey);
|
||||
obj.push_back(Pair("Payment",txid.GetHex().data()));
|
||||
obj.push_back(Pair("Number",param2));
|
||||
obj.push_back(Pair("Amount",param2*payment));
|
||||
obj.push_back(Pair("Destination",str));
|
||||
obj.push_back(Pair("Secret",param3.ToString().c_str()));
|
||||
}
|
||||
}
|
||||
else if (DecodeChannelsOpRet(tx.vout[numvouts-1].scriptPubKey,opentxid,srcpub,destpub,param1,param2,param3) == 'C' && opentxid==channeltxid)
|
||||
{
|
||||
obj.push_back(Pair("Close",txid.GetHex().data()));
|
||||
}
|
||||
else if (DecodeChannelsOpRet(tx.vout[numvouts-1].scriptPubKey,opentxid,srcpub,destpub,param1,param2,param3) == 'R' && opentxid==channeltxid)
|
||||
{
|
||||
Getscriptaddress(str,tx.vout[2].scriptPubKey);
|
||||
obj.push_back(Pair("Refund",txid.GetHex().data()));
|
||||
obj.push_back(Pair("Amount",param1*param2));
|
||||
obj.push_back(Pair("Destination",str));
|
||||
}
|
||||
array.push_back(obj);
|
||||
}
|
||||
prevtxid=txid;
|
||||
}
|
||||
result.push_back(Pair("Transactions",array));
|
||||
}
|
||||
else
|
||||
{
|
||||
result.push_back(Pair("result","error"));
|
||||
result.push_back(Pair("Error","Channel not found!"));
|
||||
}
|
||||
return(result);
|
||||
}
|
||||
11
src/cc/dapps/Makefile
Normal file
11
src/cc/dapps/Makefile
Normal file
@@ -0,0 +1,11 @@
|
||||
# just type make to compile all dapps
|
||||
all: zmigrate oraclefeed
|
||||
|
||||
zmigrate:
|
||||
$(CC) zmigrate.c -o zmigrate -lm
|
||||
|
||||
oraclefeed:
|
||||
$(CC) oraclefeed.c -o oraclefeed -lm
|
||||
|
||||
clean:
|
||||
rm zmigrate oraclefeed
|
||||
28
src/cc/dapps/README.md
Normal file
28
src/cc/dapps/README.md
Normal file
@@ -0,0 +1,28 @@
|
||||
# CryptoCondition dApps
|
||||
|
||||
## Compiling
|
||||
|
||||
To compile all dapps in this directory:
|
||||
|
||||
make
|
||||
|
||||
## zmigrate - Sprout to Sapling Migration dApp
|
||||
|
||||
This tool converts Sprout zaddress funds into Sapling funds in a new Sapling address.
|
||||
|
||||
### Usage
|
||||
|
||||
./zmigrate COIN zsaplingaddr
|
||||
|
||||
The above command may need to be run multiple times to complete the process.
|
||||
|
||||
This CLI implementation will be called by GUI wallets, average users do not
|
||||
need to worry about using this low-level tool.
|
||||
|
||||
## oraclefeed - feed of price data using oracles
|
||||
|
||||
### Usage
|
||||
|
||||
./oraclefeed $ACNAME $ORACLETXID $MYPUBKEY $FORMAT $BINDTXID [refcoin_cli]
|
||||
|
||||
Supported formats are L and Ihh. Price data from CoinDesk API.
|
||||
@@ -647,21 +647,57 @@ int64_t z_getbalance(char *refcoin,char *acname,char *coinaddr)
|
||||
return (amount);
|
||||
}
|
||||
|
||||
int32_t z_exportkey(char *privkey,char *refcoin,char *acname,char *zaddr)
|
||||
{
|
||||
cJSON *retjson; char *retstr,cmpstr[64]; int64_t amount=0; int32_t retval = -1;
|
||||
privkey[0] = 0;
|
||||
if ( (retjson= get_komodocli(refcoin,&retstr,acname,"z_exportkey",zaddr,"","","")) != 0 )
|
||||
{
|
||||
fprintf(stderr,"z_exportkey.(%s) %s returned json!\n",refcoin,acname);
|
||||
free_json(retjson);
|
||||
}
|
||||
else if ( retstr != 0 )
|
||||
{
|
||||
//printf("retstr %s -> %.8f\n",retstr,dstr(amount));
|
||||
strcpy(privkey,retstr);
|
||||
free(retstr);
|
||||
retval = 0;
|
||||
}
|
||||
return(retval);
|
||||
}
|
||||
|
||||
int32_t getnewaddress(char *coinaddr,char *refcoin,char *acname)
|
||||
{
|
||||
cJSON *retjson; char *retstr; int64_t amount=0;
|
||||
cJSON *retjson; char *retstr; int64_t amount=0; int32_t retval = -1;
|
||||
if ( (retjson= get_komodocli(refcoin,&retstr,acname,"getnewaddress","","","","")) != 0 )
|
||||
{
|
||||
fprintf(stderr,"getnewaddress.(%s) %s returned json!\n",refcoin,acname);
|
||||
free_json(retjson);
|
||||
return(-1);
|
||||
}
|
||||
else if ( retstr != 0 )
|
||||
{
|
||||
strcpy(coinaddr,retstr);
|
||||
free(retstr);
|
||||
return(0);
|
||||
retval = 0;
|
||||
}
|
||||
return(retval);
|
||||
}
|
||||
|
||||
int32_t z_getnewaddress(char *coinaddr,char *refcoin,char *acname,char *typestr)
|
||||
{
|
||||
cJSON *retjson; char *retstr; int64_t amount=0; int32_t retval = -1;
|
||||
if ( (retjson= get_komodocli(refcoin,&retstr,acname,"z_getnewaddress",typestr,"","","")) != 0 )
|
||||
{
|
||||
fprintf(stderr,"z_getnewaddress.(%s) %s returned json!\n",refcoin,acname);
|
||||
free_json(retjson);
|
||||
}
|
||||
else if ( retstr != 0 )
|
||||
{
|
||||
strcpy(coinaddr,retstr);
|
||||
free(retstr);
|
||||
retval = 0;
|
||||
}
|
||||
return(retval);
|
||||
}
|
||||
|
||||
int64_t find_onetime_amount(char *coinstr,char *coinaddr)
|
||||
@@ -670,11 +706,16 @@ int64_t find_onetime_amount(char *coinstr,char *coinaddr)
|
||||
coinaddr[0] = 0;
|
||||
if ( (array= get_listunspent(coinstr,"")) != 0 )
|
||||
{
|
||||
//printf("got listunspent.(%s)\n",jprint(array,0));
|
||||
if ( (n= cJSON_GetArraySize(array)) > 0 )
|
||||
{
|
||||
for (i=0; i<n; i++)
|
||||
{
|
||||
item = jitem(array,i);
|
||||
if (is_cJSON_False(jobj(item, "spendable")) != 0)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
if ( (addr= jstr(item,"address")) != 0 )
|
||||
{
|
||||
strcpy(coinaddr,addr);
|
||||
@@ -731,22 +772,56 @@ void importaddress(char *refcoin,char *acname,char *depositaddr)
|
||||
|
||||
int32_t z_sendmany(char *opidstr,char *coinstr,char *acname,char *srcaddr,char *destaddr,int64_t amount)
|
||||
{
|
||||
cJSON *retjson; char *retstr,params[1024],addr[128];
|
||||
cJSON *retjson; char *retstr,params[1024],addr[128]; int32_t retval = -1;
|
||||
sprintf(params,"'[{\"address\":\"%s\",\"amount\":%.8f}]'",destaddr,dstr(amount));
|
||||
sprintf(addr,"\"%s\"",srcaddr);
|
||||
printf("z_sendmany from.(%s) -> %s\n",srcaddr,params);
|
||||
if ( (retjson= get_komodocli(coinstr,&retstr,acname,"z_sendmany",addr,params,"","")) != 0 )
|
||||
{
|
||||
printf("unexpected json z_sendmany.(%s)\n",jprint(retjson,0));
|
||||
free_json(retjson);
|
||||
return(-1);
|
||||
}
|
||||
else if ( retstr != 0 )
|
||||
{
|
||||
fprintf(stderr,"z_sendmany.(%s) -> opid.(%s)\n",coinstr,retstr);
|
||||
strcpy(opidstr,retstr);
|
||||
free(retstr);
|
||||
return(0);
|
||||
retval = 0;
|
||||
}
|
||||
return(retval);
|
||||
}
|
||||
|
||||
int32_t z_mergetoaddress(char *opidstr,char *coinstr,char *acname,char *destaddr)
|
||||
{
|
||||
cJSON *retjson; char *retstr,addr[128],*opstr; int32_t retval = -1;
|
||||
sprintf(addr,"[\\\"ANY_SPROUT\\\"]");
|
||||
//printf("z_sendmany from.(%s) -> %s\n",addr,destaddr);
|
||||
if ( (retjson= get_komodocli(coinstr,&retstr,acname,"z_mergetoaddress",addr,destaddr,"","")) != 0 )
|
||||
{
|
||||
/*{
|
||||
"remainingUTXOs": 0,
|
||||
"remainingTransparentValue": 0.00000000,
|
||||
"remainingNotes": 222,
|
||||
"remainingShieldedValue": 5413.39093055,
|
||||
"mergingUTXOs": 0,
|
||||
"mergingTransparentValue": 0.00000000,
|
||||
"mergingNotes": 10,
|
||||
"mergingShieldedValue": 822.47447172,
|
||||
"opid": "opid-f28f6261-4120-436c-aca5-859870a40a70"
|
||||
}*/
|
||||
if ( (opstr= jstr(retjson,"opid")) != 0 )
|
||||
strcpy(opidstr,opstr);
|
||||
retval = jint(retjson,"remainingNotes");
|
||||
fprintf(stderr,"%s\n",jprint(retjson,0));
|
||||
free_json(retjson);
|
||||
}
|
||||
else if ( retstr != 0 )
|
||||
{
|
||||
fprintf(stderr,"z_mergetoaddress.(%s) -> opid.(%s)\n",coinstr,retstr);
|
||||
strcpy(opidstr,retstr);
|
||||
free(retstr);
|
||||
}
|
||||
return(retval);
|
||||
}
|
||||
|
||||
int32_t empty_mempool(char *coinstr,char *acname)
|
||||
@@ -905,10 +980,25 @@ int32_t main(int32_t argc,char **argv)
|
||||
}
|
||||
zsaddr = clonestr(argv[2]);
|
||||
printf("%s: %s %s\n",REFCOIN_CLI,coinstr,zsaddr);
|
||||
uint32_t lastopid; char coinaddr[64],zcaddr[128],opidstr[128]; int32_t finished; int64_t amount,stdamount,txfee;
|
||||
stdamount = 10000 * SATOSHIDEN;
|
||||
uint32_t lastopid; char coinaddr[64],privkey[1024],zcaddr[128],opidstr[128]; int32_t finished; int64_t amount,stdamount,txfee;
|
||||
//stdamount = 500 * SATOSHIDEN;
|
||||
txfee = 10000;
|
||||
again:
|
||||
if ( z_getnewaddress(zcaddr,coinstr,"","sprout") == 0 )
|
||||
{
|
||||
z_exportkey(privkey,coinstr,"",zcaddr);
|
||||
printf("zcaddr.(%s) -> z_exportkey.(%s)\n",zcaddr,privkey);
|
||||
while ( 1 )
|
||||
{
|
||||
if ( have_pending_opid(coinstr,0) != 0 )
|
||||
{
|
||||
sleep(10);
|
||||
continue;
|
||||
}
|
||||
if ( z_mergetoaddress(opidstr,coinstr,"",zcaddr) <= 0 )
|
||||
break;
|
||||
}
|
||||
}
|
||||
printf("start processing zmigrate\n");
|
||||
lastopid = (uint32_t)time(NULL);
|
||||
finished = 0;
|
||||
@@ -916,7 +1006,7 @@ again:
|
||||
{
|
||||
if ( have_pending_opid(coinstr,0) != 0 )
|
||||
{
|
||||
sleep(60);
|
||||
sleep(10);
|
||||
continue;
|
||||
}
|
||||
if ( (amount= find_onetime_amount(coinstr,coinaddr)) > txfee )
|
||||
@@ -930,14 +1020,33 @@ again:
|
||||
if ( (amount= find_sprout_amount(coinstr,zcaddr)) > txfee )
|
||||
{
|
||||
// generate taddr, send max of 10000.0001
|
||||
if ( amount > stdamount+txfee )
|
||||
amount = stdamount + txfee;
|
||||
static int64_t lastamount,lastamount2,lastamount3,lastamount4,refamount = 5000 * SATOSHIDEN;
|
||||
stdamount = refamount;
|
||||
if ( amount == lastamount && amount == lastamount2 )
|
||||
{
|
||||
stdamount /= 10;
|
||||
if ( amount == lastamount3 && amount == lastamount4 )
|
||||
stdamount /= 10;
|
||||
}
|
||||
if ( stdamount < SATOSHIDEN )
|
||||
{
|
||||
stdamount = SATOSHIDEN;
|
||||
refamount = SATOSHIDEN * 50;
|
||||
}
|
||||
if ( stdamount < refamount )
|
||||
refamount = stdamount;
|
||||
lastamount4 = lastamount3;
|
||||
lastamount3 = lastamount2;
|
||||
lastamount2 = lastamount;
|
||||
lastamount = amount;
|
||||
if ( amount > stdamount+2*txfee )
|
||||
amount = stdamount + 2*txfee;
|
||||
if ( getnewaddress(coinaddr,coinstr,"") == 0 )
|
||||
{
|
||||
z_sendmany(opidstr,coinstr,"",zcaddr,coinaddr,amount-txfee);
|
||||
lastopid = (uint32_t)time(NULL);
|
||||
} else printf("couldnt getnewaddress!\n");
|
||||
sleep(30);
|
||||
sleep(3);
|
||||
continue;
|
||||
}
|
||||
if ( time(NULL) > lastopid+600 )
|
||||
|
||||
@@ -427,11 +427,11 @@ void *dicefinish(void *_ptr)
|
||||
if ( vin0_needed > 0 )
|
||||
{
|
||||
num = 0;
|
||||
//fprintf(stderr,"iter.%d vin0_needed.%d\n",iter,vin0_needed);
|
||||
//fprintf(stderr,"iter.%d vin0_needed.%d\n",iter,vin0_needed);
|
||||
utxos = (struct dicefinish_utxo *)calloc(vin0_needed,sizeof(*utxos));
|
||||
if ( (n= dicefinish_utxosget(num,utxos,vin0_needed,coinaddr)) > 0 )
|
||||
{
|
||||
//fprintf(stderr,"iter.%d vin0_needed.%d got %d, num 0.0002 %d\n",iter,vin0_needed,n,num);
|
||||
//fprintf(stderr,"iter.%d vin0_needed.%d got %d, num 0.0002 %d\n",iter,vin0_needed,n,num);
|
||||
m = 0;
|
||||
DL_FOREACH_SAFE(DICEFINISH_LIST,ptr,tmp)
|
||||
{
|
||||
@@ -484,7 +484,8 @@ void *dicefinish(void *_ptr)
|
||||
//fprintf(stderr,"error ready.%d dicefinish %d of %d process %s %s using need %.8f finish.%s size.%d betspent.%d\n",ptr->bettxid_ready,m,n,iter<0?"loss":"win",ptr->bettxid.GetHex().c_str(),(double)(iter<0 ? 0 : ptr->winamount)/COIN,ptr->txid.GetHex().c_str(),(int32_t)ptr->rawtx.size(),dice_betspent((char *)"dicefinish",ptr->bettxid));
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if ( system("cc/dapps/sendmany100") != 0 )
|
||||
fprintf(stderr,"error issing cc/dapps/sendmany100\n");
|
||||
free(utxos);
|
||||
}
|
||||
}
|
||||
@@ -533,7 +534,7 @@ void DiceQueue(int32_t iswin,uint64_t sbits,uint256 fundingtxid,uint256 bettxid,
|
||||
else
|
||||
{
|
||||
//fprintf(stderr,"DiceQueue status bettxid.%s already in list\n",bettxid.GetHex().c_str());
|
||||
_dicehash_clear(bettxid);
|
||||
//_dicehash_clear(bettxid);
|
||||
}
|
||||
pthread_mutex_unlock(&DICE_MUTEX);
|
||||
}
|
||||
|
||||
@@ -219,7 +219,7 @@ public:
|
||||
CBlockIndex* pskip;
|
||||
|
||||
//! height of the entry in the chain. The genesis block has height 0
|
||||
int64_t newcoins,zfunds; int8_t segid; // jl777 fields
|
||||
int64_t newcoins,zfunds,sproutfunds; int8_t segid; // jl777 fields
|
||||
//! Which # file this block is stored in (blk?????.dat)
|
||||
int nFile;
|
||||
|
||||
|
||||
@@ -1,348 +0,0 @@
|
||||
#! /bin/sh
|
||||
# Wrapper for compilers which do not understand '-c -o'.
|
||||
|
||||
scriptversion=2018-03-07.03; # UTC
|
||||
|
||||
# Copyright (C) 1999-2018 Free Software Foundation, Inc.
|
||||
# Written by Tom Tromey <tromey@cygnus.com>.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2, or (at your option)
|
||||
# any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
|
||||
# As a special exception to the GNU General Public License, if you
|
||||
# distribute this file as part of a program that contains a
|
||||
# configuration script generated by Autoconf, you may include it under
|
||||
# the same distribution terms that you use for the rest of that program.
|
||||
|
||||
# This file is maintained in Automake, please report
|
||||
# bugs to <bug-automake@gnu.org> or send patches to
|
||||
# <automake-patches@gnu.org>.
|
||||
|
||||
nl='
|
||||
'
|
||||
|
||||
# We need space, tab and new line, in precisely that order. Quoting is
|
||||
# there to prevent tools from complaining about whitespace usage.
|
||||
IFS=" "" $nl"
|
||||
|
||||
file_conv=
|
||||
|
||||
# func_file_conv build_file lazy
|
||||
# Convert a $build file to $host form and store it in $file
|
||||
# Currently only supports Windows hosts. If the determined conversion
|
||||
# type is listed in (the comma separated) LAZY, no conversion will
|
||||
# take place.
|
||||
func_file_conv ()
|
||||
{
|
||||
file=$1
|
||||
case $file in
|
||||
/ | /[!/]*) # absolute file, and not a UNC file
|
||||
if test -z "$file_conv"; then
|
||||
# lazily determine how to convert abs files
|
||||
case `uname -s` in
|
||||
MINGW*)
|
||||
file_conv=mingw
|
||||
;;
|
||||
CYGWIN*)
|
||||
file_conv=cygwin
|
||||
;;
|
||||
*)
|
||||
file_conv=wine
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
case $file_conv/,$2, in
|
||||
*,$file_conv,*)
|
||||
;;
|
||||
mingw/*)
|
||||
file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'`
|
||||
;;
|
||||
cygwin/*)
|
||||
file=`cygpath -m "$file" || echo "$file"`
|
||||
;;
|
||||
wine/*)
|
||||
file=`winepath -w "$file" || echo "$file"`
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
# func_cl_dashL linkdir
|
||||
# Make cl look for libraries in LINKDIR
|
||||
func_cl_dashL ()
|
||||
{
|
||||
func_file_conv "$1"
|
||||
if test -z "$lib_path"; then
|
||||
lib_path=$file
|
||||
else
|
||||
lib_path="$lib_path;$file"
|
||||
fi
|
||||
linker_opts="$linker_opts -LIBPATH:$file"
|
||||
}
|
||||
|
||||
# func_cl_dashl library
|
||||
# Do a library search-path lookup for cl
|
||||
func_cl_dashl ()
|
||||
{
|
||||
lib=$1
|
||||
found=no
|
||||
save_IFS=$IFS
|
||||
IFS=';'
|
||||
for dir in $lib_path $LIB
|
||||
do
|
||||
IFS=$save_IFS
|
||||
if $shared && test -f "$dir/$lib.dll.lib"; then
|
||||
found=yes
|
||||
lib=$dir/$lib.dll.lib
|
||||
break
|
||||
fi
|
||||
if test -f "$dir/$lib.lib"; then
|
||||
found=yes
|
||||
lib=$dir/$lib.lib
|
||||
break
|
||||
fi
|
||||
if test -f "$dir/lib$lib.a"; then
|
||||
found=yes
|
||||
lib=$dir/lib$lib.a
|
||||
break
|
||||
fi
|
||||
done
|
||||
IFS=$save_IFS
|
||||
|
||||
if test "$found" != yes; then
|
||||
lib=$lib.lib
|
||||
fi
|
||||
}
|
||||
|
||||
# func_cl_wrapper cl arg...
|
||||
# Adjust compile command to suit cl
|
||||
func_cl_wrapper ()
|
||||
{
|
||||
# Assume a capable shell
|
||||
lib_path=
|
||||
shared=:
|
||||
linker_opts=
|
||||
for arg
|
||||
do
|
||||
if test -n "$eat"; then
|
||||
eat=
|
||||
else
|
||||
case $1 in
|
||||
-o)
|
||||
# configure might choose to run compile as 'compile cc -o foo foo.c'.
|
||||
eat=1
|
||||
case $2 in
|
||||
*.o | *.[oO][bB][jJ])
|
||||
func_file_conv "$2"
|
||||
set x "$@" -Fo"$file"
|
||||
shift
|
||||
;;
|
||||
*)
|
||||
func_file_conv "$2"
|
||||
set x "$@" -Fe"$file"
|
||||
shift
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
-I)
|
||||
eat=1
|
||||
func_file_conv "$2" mingw
|
||||
set x "$@" -I"$file"
|
||||
shift
|
||||
;;
|
||||
-I*)
|
||||
func_file_conv "${1#-I}" mingw
|
||||
set x "$@" -I"$file"
|
||||
shift
|
||||
;;
|
||||
-l)
|
||||
eat=1
|
||||
func_cl_dashl "$2"
|
||||
set x "$@" "$lib"
|
||||
shift
|
||||
;;
|
||||
-l*)
|
||||
func_cl_dashl "${1#-l}"
|
||||
set x "$@" "$lib"
|
||||
shift
|
||||
;;
|
||||
-L)
|
||||
eat=1
|
||||
func_cl_dashL "$2"
|
||||
;;
|
||||
-L*)
|
||||
func_cl_dashL "${1#-L}"
|
||||
;;
|
||||
-static)
|
||||
shared=false
|
||||
;;
|
||||
-Wl,*)
|
||||
arg=${1#-Wl,}
|
||||
save_ifs="$IFS"; IFS=','
|
||||
for flag in $arg; do
|
||||
IFS="$save_ifs"
|
||||
linker_opts="$linker_opts $flag"
|
||||
done
|
||||
IFS="$save_ifs"
|
||||
;;
|
||||
-Xlinker)
|
||||
eat=1
|
||||
linker_opts="$linker_opts $2"
|
||||
;;
|
||||
-*)
|
||||
set x "$@" "$1"
|
||||
shift
|
||||
;;
|
||||
*.cc | *.CC | *.cxx | *.CXX | *.[cC]++)
|
||||
func_file_conv "$1"
|
||||
set x "$@" -Tp"$file"
|
||||
shift
|
||||
;;
|
||||
*.c | *.cpp | *.CPP | *.lib | *.LIB | *.Lib | *.OBJ | *.obj | *.[oO])
|
||||
func_file_conv "$1" mingw
|
||||
set x "$@" "$file"
|
||||
shift
|
||||
;;
|
||||
*)
|
||||
set x "$@" "$1"
|
||||
shift
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
shift
|
||||
done
|
||||
if test -n "$linker_opts"; then
|
||||
linker_opts="-link$linker_opts"
|
||||
fi
|
||||
exec "$@" $linker_opts
|
||||
exit 1
|
||||
}
|
||||
|
||||
eat=
|
||||
|
||||
case $1 in
|
||||
'')
|
||||
echo "$0: No command. Try '$0 --help' for more information." 1>&2
|
||||
exit 1;
|
||||
;;
|
||||
-h | --h*)
|
||||
cat <<\EOF
|
||||
Usage: compile [--help] [--version] PROGRAM [ARGS]
|
||||
|
||||
Wrapper for compilers which do not understand '-c -o'.
|
||||
Remove '-o dest.o' from ARGS, run PROGRAM with the remaining
|
||||
arguments, and rename the output as expected.
|
||||
|
||||
If you are trying to build a whole package this is not the
|
||||
right script to run: please start by reading the file 'INSTALL'.
|
||||
|
||||
Report bugs to <bug-automake@gnu.org>.
|
||||
EOF
|
||||
exit $?
|
||||
;;
|
||||
-v | --v*)
|
||||
echo "compile $scriptversion"
|
||||
exit $?
|
||||
;;
|
||||
cl | *[/\\]cl | cl.exe | *[/\\]cl.exe | \
|
||||
icl | *[/\\]icl | icl.exe | *[/\\]icl.exe )
|
||||
func_cl_wrapper "$@" # Doesn't return...
|
||||
;;
|
||||
esac
|
||||
|
||||
ofile=
|
||||
cfile=
|
||||
|
||||
for arg
|
||||
do
|
||||
if test -n "$eat"; then
|
||||
eat=
|
||||
else
|
||||
case $1 in
|
||||
-o)
|
||||
# configure might choose to run compile as 'compile cc -o foo foo.c'.
|
||||
# So we strip '-o arg' only if arg is an object.
|
||||
eat=1
|
||||
case $2 in
|
||||
*.o | *.obj)
|
||||
ofile=$2
|
||||
;;
|
||||
*)
|
||||
set x "$@" -o "$2"
|
||||
shift
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
*.c)
|
||||
cfile=$1
|
||||
set x "$@" "$1"
|
||||
shift
|
||||
;;
|
||||
*)
|
||||
set x "$@" "$1"
|
||||
shift
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
shift
|
||||
done
|
||||
|
||||
if test -z "$ofile" || test -z "$cfile"; then
|
||||
# If no '-o' option was seen then we might have been invoked from a
|
||||
# pattern rule where we don't need one. That is ok -- this is a
|
||||
# normal compilation that the losing compiler can handle. If no
|
||||
# '.c' file was seen then we are probably linking. That is also
|
||||
# ok.
|
||||
exec "$@"
|
||||
fi
|
||||
|
||||
# Name of file we expect compiler to create.
|
||||
cofile=`echo "$cfile" | sed 's|^.*[\\/]||; s|^[a-zA-Z]:||; s/\.c$/.o/'`
|
||||
|
||||
# Create the lock directory.
|
||||
# Note: use '[/\\:.-]' here to ensure that we don't use the same name
|
||||
# that we are using for the .o file. Also, base the name on the expected
|
||||
# object file name, since that is what matters with a parallel build.
|
||||
lockdir=`echo "$cofile" | sed -e 's|[/\\:.-]|_|g'`.d
|
||||
while true; do
|
||||
if mkdir "$lockdir" >/dev/null 2>&1; then
|
||||
break
|
||||
fi
|
||||
sleep 1
|
||||
done
|
||||
# FIXME: race condition here if user kills between mkdir and trap.
|
||||
trap "rmdir '$lockdir'; exit 1" 1 2 15
|
||||
|
||||
# Run the compile.
|
||||
"$@"
|
||||
ret=$?
|
||||
|
||||
if test -f "$cofile"; then
|
||||
test "$cofile" = "$ofile" || mv "$cofile" "$ofile"
|
||||
elif test -f "${cofile}bj"; then
|
||||
test "${cofile}bj" = "$ofile" || mv "${cofile}bj" "$ofile"
|
||||
fi
|
||||
|
||||
rmdir "$lockdir"
|
||||
exit $ret
|
||||
|
||||
# Local Variables:
|
||||
# mode: shell-script
|
||||
# sh-indentation: 2
|
||||
# eval: (add-hook 'before-save-hook 'time-stamp)
|
||||
# time-stamp-start: "scriptversion="
|
||||
# time-stamp-format: "%:y-%02m-%02d.%02H"
|
||||
# time-stamp-time-zone: "UTC0"
|
||||
# time-stamp-end: "; # UTC"
|
||||
# End:
|
||||
2
src/fiat/ksb
Executable file
2
src/fiat/ksb
Executable file
@@ -0,0 +1,2 @@
|
||||
#!/bin/bash
|
||||
./komodo-cli -ac_name=KSB $1 $2 $3 $4 $5 $6
|
||||
705
src/fundnotaries
705
src/fundnotaries
@@ -1,705 +0,0 @@
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RNJmgYaFF5DbnrNUX6pMYz9rcnDKC2tuAc 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RDhEGYScNQYetCyG75Kf8Fg61UWPdwc1C5 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RHPGxpiwRHP4dKZXjYPdpon1nCto7qVE8s 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RLQoAcs1RaqW1xfN2NJwoZWW5twexPhuGB 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RXF3aHUaWDUY4fRRYmBNALoHWkgSQCiJ4f 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RL2SkPSCGMvcHqZ56ErfMxbQGdA4nk7MZp 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RFssbc211PJdVy1bvcvAG5X2N4ovPAoy5o 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RNoz2DKPZ2ppMxgYx5tce9sjZBHefvPvNB 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RVxtoUT9CXbC1LdhztNAf9yR5ySnFnSPQh 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress R9XBrbj8iKkwy9M4erUqRaBinAiZSTXav3 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RSHdRnHHGdPtVej7fiehHBQ6dyTbEM1GHi 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RDW8EDkCkzQ1LA4xbVUoAERsBVhhYRLXCr 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RAxQTHdsy89tfSXwoce2sHeWrYXmDsMXQq 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RT2k2voy9n8jwppeTTJMQAhvaqA9pc9jHh 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RRvaVyKS59NJWhPp8Pn7mVPGhMuhJJXrdh 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RBpp98VwHx7SFv7dNbw8NY65t14XFq9fVD 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RPjUmFNcWEW9Bu275kPxzRXyWDz6bfQpPD 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RDY2CvzydimY2AtDqSjBAB1eCeogRE55DX 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RUgW6fLfVsLJ87Ng4zJTqNedJSKYQ9ToAf 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RUreYvNjhZYc1vP8cND9Cztpni1pYsigXb 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RHv3wyVnnanG2kSQmLNmjwAQeYRRAptxUy 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RLVwuTM5TitV4Gk79Rja731RwYkAzz7GWn 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RHbxwDa7JT1KJLHDKwb5n3gd8NREErqtQY 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RFDAZ1yCvKPmpqcgzg8r2qQJ8nPPgeoMrB 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RHsZesZXMfkdrsSEper3JWUBKwk29JTFfT 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RPJjzoKPb8idoUCT9XLBkNojNgysjJ5qrE 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RFQNjTfcvSAmf8D83og1NrdHj1wH2fc5X4 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RPknkGAHMwUBvfKQfvw9FyatTZzicSiN4y 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RMqbQz4NPNbG15QBwy9EFvLn4NX5Fa7w5g 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RQipE6ycbVVb9vCkhqrK8PGZs2p5YmiBtg 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RCA8H1npFPW5pnJRzycF8tFEJmn6XZhD4j 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RJD5jRidYW9Cu8qxjg9HDCsx6J3A4wQ4LU 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RQMwcDYMVBx9f4QCFfFk31px8QZP4e8uhA 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RXzsovGBQ3W97xnVC6JnWxXsV4qb7p7iBi 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RLHr8gUm2MZ3EEgDU4EmK7bdn5ZsxLYmnt 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RFTsWSzgKRd5Xa7d287w9eRFeYefKBso6Z 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress REuQ7EoxKeMYk4EGptV6EwdfV9LZXuc44g 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RX1tP6ftwe96p6scgJn4dpgNdHDgyg9R87 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RERp696QtNTeWDfBy3x3QbRwPYN2NxwxfA 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RNZKqUgoAPwWd7wNtuSKP7k1HSJAyPeH4N 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress R9jhJCwgT78pyjnkNuxgH3CE8ekxgT8iwB 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RSCQKVUhihKb13rb5VJwXsbSY6pdRPUZ6V 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RDVqM6t5xZw9jbYXEw2CJgkiSbrHBHiKR3 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RSSNgf98kiMGUxs55DvhNnumyxVudd2KQQ 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RXqdRmv7n9hygf9C7f7vj4VQyNR9RvzXss 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RE3P8D8rcWZBeKmT8DURPdezW87MU5Ho3F 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RS3v2u6d4SJ1ujLz7CHNSFLSmxn6Tx6mJp 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RREc88bQzxHCvzqErPDnTQH2Qg5yUtjbyp 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RJ9wAk3ZNrFwdso1RVbwASiqqQaDNyKjd2 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RVKtRKozg8RKvEYCumMD43fCU6f212M5RD 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RCvsbvzCwA1AaxeoYVSL9Q3BdnybEWfXaH 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RXtADsErZLmsGhNyQdW2DekHMGZ23cLrav 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RYGrWs5b8CVFFpxGpjiBaMwfYV9X5UqFaB 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RHASfhhM6bvDFakRDqkzA2wc3V4R4oNmXi 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RATaU3jjn4RwHK61YWoJ4eg7Eggk3puZW8 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RXbb9PkefXcsqq8wqiUZZUuq8e3p29mw1G 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RDY9LJZTEJ9FsvugUuD69gceA98uqan5XL 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress R9tjkpdNbzw6mNfxorb5bvTPmsuon5aLrC 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RT2JyVts5tb1prC7KYykmznrqw7VXJo1HB 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RFHRWQ5pAXNfmudHfxdxw3Wo8yFGoeDn6z 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RTw3vi3dGa9n8LLbKvk7jDAwLdt3A5ET7a 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RQeuhk4KcPM3F5hefwTBWezDdcktSGQQSq 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress R9TGdzN25MgdRkYfsYfxZWzHCLVCyWFAei 0.010000
|
||||
./komodo-cli -ac_name=REVS sendtoaddress RDYsrWBZkYSWhRDupGRrfGqrVnFtK9hJGC 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RNJmgYaFF5DbnrNUX6pMYz9rcnDKC2tuAc 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RDhEGYScNQYetCyG75Kf8Fg61UWPdwc1C5 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RHPGxpiwRHP4dKZXjYPdpon1nCto7qVE8s 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RLQoAcs1RaqW1xfN2NJwoZWW5twexPhuGB 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RXF3aHUaWDUY4fRRYmBNALoHWkgSQCiJ4f 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RL2SkPSCGMvcHqZ56ErfMxbQGdA4nk7MZp 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RFssbc211PJdVy1bvcvAG5X2N4ovPAoy5o 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RNoz2DKPZ2ppMxgYx5tce9sjZBHefvPvNB 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RVxtoUT9CXbC1LdhztNAf9yR5ySnFnSPQh 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress R9XBrbj8iKkwy9M4erUqRaBinAiZSTXav3 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RSHdRnHHGdPtVej7fiehHBQ6dyTbEM1GHi 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RDW8EDkCkzQ1LA4xbVUoAERsBVhhYRLXCr 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RAxQTHdsy89tfSXwoce2sHeWrYXmDsMXQq 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RT2k2voy9n8jwppeTTJMQAhvaqA9pc9jHh 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RRvaVyKS59NJWhPp8Pn7mVPGhMuhJJXrdh 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RBpp98VwHx7SFv7dNbw8NY65t14XFq9fVD 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RPjUmFNcWEW9Bu275kPxzRXyWDz6bfQpPD 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RDY2CvzydimY2AtDqSjBAB1eCeogRE55DX 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RUgW6fLfVsLJ87Ng4zJTqNedJSKYQ9ToAf 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RUreYvNjhZYc1vP8cND9Cztpni1pYsigXb 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RHv3wyVnnanG2kSQmLNmjwAQeYRRAptxUy 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RLVwuTM5TitV4Gk79Rja731RwYkAzz7GWn 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RHbxwDa7JT1KJLHDKwb5n3gd8NREErqtQY 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RFDAZ1yCvKPmpqcgzg8r2qQJ8nPPgeoMrB 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RHsZesZXMfkdrsSEper3JWUBKwk29JTFfT 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RPJjzoKPb8idoUCT9XLBkNojNgysjJ5qrE 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RFQNjTfcvSAmf8D83og1NrdHj1wH2fc5X4 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RPknkGAHMwUBvfKQfvw9FyatTZzicSiN4y 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RMqbQz4NPNbG15QBwy9EFvLn4NX5Fa7w5g 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RQipE6ycbVVb9vCkhqrK8PGZs2p5YmiBtg 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RCA8H1npFPW5pnJRzycF8tFEJmn6XZhD4j 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RJD5jRidYW9Cu8qxjg9HDCsx6J3A4wQ4LU 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RQMwcDYMVBx9f4QCFfFk31px8QZP4e8uhA 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RXzsovGBQ3W97xnVC6JnWxXsV4qb7p7iBi 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RLHr8gUm2MZ3EEgDU4EmK7bdn5ZsxLYmnt 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RFTsWSzgKRd5Xa7d287w9eRFeYefKBso6Z 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress REuQ7EoxKeMYk4EGptV6EwdfV9LZXuc44g 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RX1tP6ftwe96p6scgJn4dpgNdHDgyg9R87 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RERp696QtNTeWDfBy3x3QbRwPYN2NxwxfA 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RNZKqUgoAPwWd7wNtuSKP7k1HSJAyPeH4N 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress R9jhJCwgT78pyjnkNuxgH3CE8ekxgT8iwB 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RSCQKVUhihKb13rb5VJwXsbSY6pdRPUZ6V 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RDVqM6t5xZw9jbYXEw2CJgkiSbrHBHiKR3 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RSSNgf98kiMGUxs55DvhNnumyxVudd2KQQ 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RXqdRmv7n9hygf9C7f7vj4VQyNR9RvzXss 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RE3P8D8rcWZBeKmT8DURPdezW87MU5Ho3F 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RS3v2u6d4SJ1ujLz7CHNSFLSmxn6Tx6mJp 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RREc88bQzxHCvzqErPDnTQH2Qg5yUtjbyp 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RJ9wAk3ZNrFwdso1RVbwASiqqQaDNyKjd2 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RVKtRKozg8RKvEYCumMD43fCU6f212M5RD 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RCvsbvzCwA1AaxeoYVSL9Q3BdnybEWfXaH 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RXtADsErZLmsGhNyQdW2DekHMGZ23cLrav 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RYGrWs5b8CVFFpxGpjiBaMwfYV9X5UqFaB 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RHASfhhM6bvDFakRDqkzA2wc3V4R4oNmXi 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RATaU3jjn4RwHK61YWoJ4eg7Eggk3puZW8 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RXbb9PkefXcsqq8wqiUZZUuq8e3p29mw1G 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RDY9LJZTEJ9FsvugUuD69gceA98uqan5XL 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress R9tjkpdNbzw6mNfxorb5bvTPmsuon5aLrC 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RT2JyVts5tb1prC7KYykmznrqw7VXJo1HB 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RFHRWQ5pAXNfmudHfxdxw3Wo8yFGoeDn6z 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RTw3vi3dGa9n8LLbKvk7jDAwLdt3A5ET7a 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RQeuhk4KcPM3F5hefwTBWezDdcktSGQQSq 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress R9TGdzN25MgdRkYfsYfxZWzHCLVCyWFAei 0.010000
|
||||
./komodo-cli -ac_name=SUPERNET sendtoaddress RDYsrWBZkYSWhRDupGRrfGqrVnFtK9hJGC 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RNJmgYaFF5DbnrNUX6pMYz9rcnDKC2tuAc 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RDhEGYScNQYetCyG75Kf8Fg61UWPdwc1C5 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RHPGxpiwRHP4dKZXjYPdpon1nCto7qVE8s 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RLQoAcs1RaqW1xfN2NJwoZWW5twexPhuGB 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RXF3aHUaWDUY4fRRYmBNALoHWkgSQCiJ4f 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RL2SkPSCGMvcHqZ56ErfMxbQGdA4nk7MZp 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RFssbc211PJdVy1bvcvAG5X2N4ovPAoy5o 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RNoz2DKPZ2ppMxgYx5tce9sjZBHefvPvNB 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RVxtoUT9CXbC1LdhztNAf9yR5ySnFnSPQh 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress R9XBrbj8iKkwy9M4erUqRaBinAiZSTXav3 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RSHdRnHHGdPtVej7fiehHBQ6dyTbEM1GHi 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RDW8EDkCkzQ1LA4xbVUoAERsBVhhYRLXCr 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RAxQTHdsy89tfSXwoce2sHeWrYXmDsMXQq 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RT2k2voy9n8jwppeTTJMQAhvaqA9pc9jHh 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RRvaVyKS59NJWhPp8Pn7mVPGhMuhJJXrdh 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RBpp98VwHx7SFv7dNbw8NY65t14XFq9fVD 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RPjUmFNcWEW9Bu275kPxzRXyWDz6bfQpPD 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RDY2CvzydimY2AtDqSjBAB1eCeogRE55DX 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RUgW6fLfVsLJ87Ng4zJTqNedJSKYQ9ToAf 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RUreYvNjhZYc1vP8cND9Cztpni1pYsigXb 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RHv3wyVnnanG2kSQmLNmjwAQeYRRAptxUy 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RLVwuTM5TitV4Gk79Rja731RwYkAzz7GWn 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RHbxwDa7JT1KJLHDKwb5n3gd8NREErqtQY 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RFDAZ1yCvKPmpqcgzg8r2qQJ8nPPgeoMrB 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RHsZesZXMfkdrsSEper3JWUBKwk29JTFfT 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RPJjzoKPb8idoUCT9XLBkNojNgysjJ5qrE 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RFQNjTfcvSAmf8D83og1NrdHj1wH2fc5X4 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RPknkGAHMwUBvfKQfvw9FyatTZzicSiN4y 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RMqbQz4NPNbG15QBwy9EFvLn4NX5Fa7w5g 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RQipE6ycbVVb9vCkhqrK8PGZs2p5YmiBtg 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RCA8H1npFPW5pnJRzycF8tFEJmn6XZhD4j 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RJD5jRidYW9Cu8qxjg9HDCsx6J3A4wQ4LU 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RQMwcDYMVBx9f4QCFfFk31px8QZP4e8uhA 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RXzsovGBQ3W97xnVC6JnWxXsV4qb7p7iBi 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RLHr8gUm2MZ3EEgDU4EmK7bdn5ZsxLYmnt 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RFTsWSzgKRd5Xa7d287w9eRFeYefKBso6Z 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress REuQ7EoxKeMYk4EGptV6EwdfV9LZXuc44g 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RX1tP6ftwe96p6scgJn4dpgNdHDgyg9R87 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RERp696QtNTeWDfBy3x3QbRwPYN2NxwxfA 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RNZKqUgoAPwWd7wNtuSKP7k1HSJAyPeH4N 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress R9jhJCwgT78pyjnkNuxgH3CE8ekxgT8iwB 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RSCQKVUhihKb13rb5VJwXsbSY6pdRPUZ6V 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RDVqM6t5xZw9jbYXEw2CJgkiSbrHBHiKR3 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RSSNgf98kiMGUxs55DvhNnumyxVudd2KQQ 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RXqdRmv7n9hygf9C7f7vj4VQyNR9RvzXss 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RE3P8D8rcWZBeKmT8DURPdezW87MU5Ho3F 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RS3v2u6d4SJ1ujLz7CHNSFLSmxn6Tx6mJp 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RREc88bQzxHCvzqErPDnTQH2Qg5yUtjbyp 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RJ9wAk3ZNrFwdso1RVbwASiqqQaDNyKjd2 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RVKtRKozg8RKvEYCumMD43fCU6f212M5RD 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RCvsbvzCwA1AaxeoYVSL9Q3BdnybEWfXaH 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RXtADsErZLmsGhNyQdW2DekHMGZ23cLrav 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RYGrWs5b8CVFFpxGpjiBaMwfYV9X5UqFaB 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RHASfhhM6bvDFakRDqkzA2wc3V4R4oNmXi 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RATaU3jjn4RwHK61YWoJ4eg7Eggk3puZW8 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RXbb9PkefXcsqq8wqiUZZUuq8e3p29mw1G 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RDY9LJZTEJ9FsvugUuD69gceA98uqan5XL 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress R9tjkpdNbzw6mNfxorb5bvTPmsuon5aLrC 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RT2JyVts5tb1prC7KYykmznrqw7VXJo1HB 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RFHRWQ5pAXNfmudHfxdxw3Wo8yFGoeDn6z 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RTw3vi3dGa9n8LLbKvk7jDAwLdt3A5ET7a 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RQeuhk4KcPM3F5hefwTBWezDdcktSGQQSq 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress R9TGdzN25MgdRkYfsYfxZWzHCLVCyWFAei 0.010000
|
||||
./komodo-cli -ac_name=DEX sendtoaddress RDYsrWBZkYSWhRDupGRrfGqrVnFtK9hJGC 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RNJmgYaFF5DbnrNUX6pMYz9rcnDKC2tuAc 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RDhEGYScNQYetCyG75Kf8Fg61UWPdwc1C5 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RHPGxpiwRHP4dKZXjYPdpon1nCto7qVE8s 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RLQoAcs1RaqW1xfN2NJwoZWW5twexPhuGB 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RXF3aHUaWDUY4fRRYmBNALoHWkgSQCiJ4f 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RL2SkPSCGMvcHqZ56ErfMxbQGdA4nk7MZp 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RFssbc211PJdVy1bvcvAG5X2N4ovPAoy5o 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RNoz2DKPZ2ppMxgYx5tce9sjZBHefvPvNB 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RVxtoUT9CXbC1LdhztNAf9yR5ySnFnSPQh 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress R9XBrbj8iKkwy9M4erUqRaBinAiZSTXav3 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RSHdRnHHGdPtVej7fiehHBQ6dyTbEM1GHi 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RDW8EDkCkzQ1LA4xbVUoAERsBVhhYRLXCr 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RAxQTHdsy89tfSXwoce2sHeWrYXmDsMXQq 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RT2k2voy9n8jwppeTTJMQAhvaqA9pc9jHh 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RRvaVyKS59NJWhPp8Pn7mVPGhMuhJJXrdh 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RBpp98VwHx7SFv7dNbw8NY65t14XFq9fVD 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RPjUmFNcWEW9Bu275kPxzRXyWDz6bfQpPD 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RDY2CvzydimY2AtDqSjBAB1eCeogRE55DX 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RUgW6fLfVsLJ87Ng4zJTqNedJSKYQ9ToAf 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RUreYvNjhZYc1vP8cND9Cztpni1pYsigXb 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RHv3wyVnnanG2kSQmLNmjwAQeYRRAptxUy 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RLVwuTM5TitV4Gk79Rja731RwYkAzz7GWn 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RHbxwDa7JT1KJLHDKwb5n3gd8NREErqtQY 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RFDAZ1yCvKPmpqcgzg8r2qQJ8nPPgeoMrB 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RHsZesZXMfkdrsSEper3JWUBKwk29JTFfT 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RPJjzoKPb8idoUCT9XLBkNojNgysjJ5qrE 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RFQNjTfcvSAmf8D83og1NrdHj1wH2fc5X4 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RPknkGAHMwUBvfKQfvw9FyatTZzicSiN4y 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RMqbQz4NPNbG15QBwy9EFvLn4NX5Fa7w5g 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RQipE6ycbVVb9vCkhqrK8PGZs2p5YmiBtg 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RCA8H1npFPW5pnJRzycF8tFEJmn6XZhD4j 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RJD5jRidYW9Cu8qxjg9HDCsx6J3A4wQ4LU 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RQMwcDYMVBx9f4QCFfFk31px8QZP4e8uhA 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RXzsovGBQ3W97xnVC6JnWxXsV4qb7p7iBi 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RLHr8gUm2MZ3EEgDU4EmK7bdn5ZsxLYmnt 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RFTsWSzgKRd5Xa7d287w9eRFeYefKBso6Z 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress REuQ7EoxKeMYk4EGptV6EwdfV9LZXuc44g 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RX1tP6ftwe96p6scgJn4dpgNdHDgyg9R87 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RERp696QtNTeWDfBy3x3QbRwPYN2NxwxfA 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RNZKqUgoAPwWd7wNtuSKP7k1HSJAyPeH4N 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress R9jhJCwgT78pyjnkNuxgH3CE8ekxgT8iwB 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RSCQKVUhihKb13rb5VJwXsbSY6pdRPUZ6V 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RDVqM6t5xZw9jbYXEw2CJgkiSbrHBHiKR3 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RSSNgf98kiMGUxs55DvhNnumyxVudd2KQQ 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RXqdRmv7n9hygf9C7f7vj4VQyNR9RvzXss 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RE3P8D8rcWZBeKmT8DURPdezW87MU5Ho3F 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RS3v2u6d4SJ1ujLz7CHNSFLSmxn6Tx6mJp 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RREc88bQzxHCvzqErPDnTQH2Qg5yUtjbyp 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RJ9wAk3ZNrFwdso1RVbwASiqqQaDNyKjd2 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RVKtRKozg8RKvEYCumMD43fCU6f212M5RD 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RCvsbvzCwA1AaxeoYVSL9Q3BdnybEWfXaH 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RXtADsErZLmsGhNyQdW2DekHMGZ23cLrav 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RYGrWs5b8CVFFpxGpjiBaMwfYV9X5UqFaB 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RHASfhhM6bvDFakRDqkzA2wc3V4R4oNmXi 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RATaU3jjn4RwHK61YWoJ4eg7Eggk3puZW8 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RXbb9PkefXcsqq8wqiUZZUuq8e3p29mw1G 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RDY9LJZTEJ9FsvugUuD69gceA98uqan5XL 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress R9tjkpdNbzw6mNfxorb5bvTPmsuon5aLrC 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RT2JyVts5tb1prC7KYykmznrqw7VXJo1HB 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RFHRWQ5pAXNfmudHfxdxw3Wo8yFGoeDn6z 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RTw3vi3dGa9n8LLbKvk7jDAwLdt3A5ET7a 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RQeuhk4KcPM3F5hefwTBWezDdcktSGQQSq 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress R9TGdzN25MgdRkYfsYfxZWzHCLVCyWFAei 0.010000
|
||||
./komodo-cli -ac_name=PANGEA sendtoaddress RDYsrWBZkYSWhRDupGRrfGqrVnFtK9hJGC 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RNJmgYaFF5DbnrNUX6pMYz9rcnDKC2tuAc 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RDhEGYScNQYetCyG75Kf8Fg61UWPdwc1C5 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RHPGxpiwRHP4dKZXjYPdpon1nCto7qVE8s 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RLQoAcs1RaqW1xfN2NJwoZWW5twexPhuGB 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RXF3aHUaWDUY4fRRYmBNALoHWkgSQCiJ4f 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RL2SkPSCGMvcHqZ56ErfMxbQGdA4nk7MZp 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RFssbc211PJdVy1bvcvAG5X2N4ovPAoy5o 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RNoz2DKPZ2ppMxgYx5tce9sjZBHefvPvNB 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RVxtoUT9CXbC1LdhztNAf9yR5ySnFnSPQh 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress R9XBrbj8iKkwy9M4erUqRaBinAiZSTXav3 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RSHdRnHHGdPtVej7fiehHBQ6dyTbEM1GHi 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RDW8EDkCkzQ1LA4xbVUoAERsBVhhYRLXCr 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RAxQTHdsy89tfSXwoce2sHeWrYXmDsMXQq 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RT2k2voy9n8jwppeTTJMQAhvaqA9pc9jHh 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RRvaVyKS59NJWhPp8Pn7mVPGhMuhJJXrdh 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RBpp98VwHx7SFv7dNbw8NY65t14XFq9fVD 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RPjUmFNcWEW9Bu275kPxzRXyWDz6bfQpPD 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RDY2CvzydimY2AtDqSjBAB1eCeogRE55DX 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RUgW6fLfVsLJ87Ng4zJTqNedJSKYQ9ToAf 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RUreYvNjhZYc1vP8cND9Cztpni1pYsigXb 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RHv3wyVnnanG2kSQmLNmjwAQeYRRAptxUy 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RLVwuTM5TitV4Gk79Rja731RwYkAzz7GWn 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RHbxwDa7JT1KJLHDKwb5n3gd8NREErqtQY 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RFDAZ1yCvKPmpqcgzg8r2qQJ8nPPgeoMrB 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RHsZesZXMfkdrsSEper3JWUBKwk29JTFfT 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RPJjzoKPb8idoUCT9XLBkNojNgysjJ5qrE 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RFQNjTfcvSAmf8D83og1NrdHj1wH2fc5X4 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RPknkGAHMwUBvfKQfvw9FyatTZzicSiN4y 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RMqbQz4NPNbG15QBwy9EFvLn4NX5Fa7w5g 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RQipE6ycbVVb9vCkhqrK8PGZs2p5YmiBtg 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RCA8H1npFPW5pnJRzycF8tFEJmn6XZhD4j 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RJD5jRidYW9Cu8qxjg9HDCsx6J3A4wQ4LU 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RQMwcDYMVBx9f4QCFfFk31px8QZP4e8uhA 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RXzsovGBQ3W97xnVC6JnWxXsV4qb7p7iBi 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RLHr8gUm2MZ3EEgDU4EmK7bdn5ZsxLYmnt 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RFTsWSzgKRd5Xa7d287w9eRFeYefKBso6Z 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress REuQ7EoxKeMYk4EGptV6EwdfV9LZXuc44g 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RX1tP6ftwe96p6scgJn4dpgNdHDgyg9R87 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RERp696QtNTeWDfBy3x3QbRwPYN2NxwxfA 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RNZKqUgoAPwWd7wNtuSKP7k1HSJAyPeH4N 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress R9jhJCwgT78pyjnkNuxgH3CE8ekxgT8iwB 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RSCQKVUhihKb13rb5VJwXsbSY6pdRPUZ6V 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RDVqM6t5xZw9jbYXEw2CJgkiSbrHBHiKR3 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RSSNgf98kiMGUxs55DvhNnumyxVudd2KQQ 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RXqdRmv7n9hygf9C7f7vj4VQyNR9RvzXss 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RE3P8D8rcWZBeKmT8DURPdezW87MU5Ho3F 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RS3v2u6d4SJ1ujLz7CHNSFLSmxn6Tx6mJp 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RREc88bQzxHCvzqErPDnTQH2Qg5yUtjbyp 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RJ9wAk3ZNrFwdso1RVbwASiqqQaDNyKjd2 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RVKtRKozg8RKvEYCumMD43fCU6f212M5RD 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RCvsbvzCwA1AaxeoYVSL9Q3BdnybEWfXaH 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RXtADsErZLmsGhNyQdW2DekHMGZ23cLrav 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RYGrWs5b8CVFFpxGpjiBaMwfYV9X5UqFaB 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RHASfhhM6bvDFakRDqkzA2wc3V4R4oNmXi 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RATaU3jjn4RwHK61YWoJ4eg7Eggk3puZW8 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RXbb9PkefXcsqq8wqiUZZUuq8e3p29mw1G 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RDY9LJZTEJ9FsvugUuD69gceA98uqan5XL 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress R9tjkpdNbzw6mNfxorb5bvTPmsuon5aLrC 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RT2JyVts5tb1prC7KYykmznrqw7VXJo1HB 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RFHRWQ5pAXNfmudHfxdxw3Wo8yFGoeDn6z 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RTw3vi3dGa9n8LLbKvk7jDAwLdt3A5ET7a 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RQeuhk4KcPM3F5hefwTBWezDdcktSGQQSq 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress R9TGdzN25MgdRkYfsYfxZWzHCLVCyWFAei 0.010000
|
||||
./komodo-cli -ac_name=JUMBLR sendtoaddress RDYsrWBZkYSWhRDupGRrfGqrVnFtK9hJGC 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RNJmgYaFF5DbnrNUX6pMYz9rcnDKC2tuAc 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RDhEGYScNQYetCyG75Kf8Fg61UWPdwc1C5 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RHPGxpiwRHP4dKZXjYPdpon1nCto7qVE8s 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RLQoAcs1RaqW1xfN2NJwoZWW5twexPhuGB 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RXF3aHUaWDUY4fRRYmBNALoHWkgSQCiJ4f 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RL2SkPSCGMvcHqZ56ErfMxbQGdA4nk7MZp 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RFssbc211PJdVy1bvcvAG5X2N4ovPAoy5o 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RNoz2DKPZ2ppMxgYx5tce9sjZBHefvPvNB 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RVxtoUT9CXbC1LdhztNAf9yR5ySnFnSPQh 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress R9XBrbj8iKkwy9M4erUqRaBinAiZSTXav3 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RSHdRnHHGdPtVej7fiehHBQ6dyTbEM1GHi 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RDW8EDkCkzQ1LA4xbVUoAERsBVhhYRLXCr 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RAxQTHdsy89tfSXwoce2sHeWrYXmDsMXQq 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RT2k2voy9n8jwppeTTJMQAhvaqA9pc9jHh 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RRvaVyKS59NJWhPp8Pn7mVPGhMuhJJXrdh 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RBpp98VwHx7SFv7dNbw8NY65t14XFq9fVD 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RPjUmFNcWEW9Bu275kPxzRXyWDz6bfQpPD 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RDY2CvzydimY2AtDqSjBAB1eCeogRE55DX 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RUgW6fLfVsLJ87Ng4zJTqNedJSKYQ9ToAf 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RUreYvNjhZYc1vP8cND9Cztpni1pYsigXb 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RHv3wyVnnanG2kSQmLNmjwAQeYRRAptxUy 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RLVwuTM5TitV4Gk79Rja731RwYkAzz7GWn 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RHbxwDa7JT1KJLHDKwb5n3gd8NREErqtQY 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RFDAZ1yCvKPmpqcgzg8r2qQJ8nPPgeoMrB 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RHsZesZXMfkdrsSEper3JWUBKwk29JTFfT 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RPJjzoKPb8idoUCT9XLBkNojNgysjJ5qrE 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RFQNjTfcvSAmf8D83og1NrdHj1wH2fc5X4 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RPknkGAHMwUBvfKQfvw9FyatTZzicSiN4y 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RMqbQz4NPNbG15QBwy9EFvLn4NX5Fa7w5g 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RQipE6ycbVVb9vCkhqrK8PGZs2p5YmiBtg 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RCA8H1npFPW5pnJRzycF8tFEJmn6XZhD4j 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RJD5jRidYW9Cu8qxjg9HDCsx6J3A4wQ4LU 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RQMwcDYMVBx9f4QCFfFk31px8QZP4e8uhA 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RXzsovGBQ3W97xnVC6JnWxXsV4qb7p7iBi 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RLHr8gUm2MZ3EEgDU4EmK7bdn5ZsxLYmnt 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RFTsWSzgKRd5Xa7d287w9eRFeYefKBso6Z 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress REuQ7EoxKeMYk4EGptV6EwdfV9LZXuc44g 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RX1tP6ftwe96p6scgJn4dpgNdHDgyg9R87 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RERp696QtNTeWDfBy3x3QbRwPYN2NxwxfA 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RNZKqUgoAPwWd7wNtuSKP7k1HSJAyPeH4N 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress R9jhJCwgT78pyjnkNuxgH3CE8ekxgT8iwB 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RSCQKVUhihKb13rb5VJwXsbSY6pdRPUZ6V 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RDVqM6t5xZw9jbYXEw2CJgkiSbrHBHiKR3 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RSSNgf98kiMGUxs55DvhNnumyxVudd2KQQ 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RXqdRmv7n9hygf9C7f7vj4VQyNR9RvzXss 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RE3P8D8rcWZBeKmT8DURPdezW87MU5Ho3F 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RS3v2u6d4SJ1ujLz7CHNSFLSmxn6Tx6mJp 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RREc88bQzxHCvzqErPDnTQH2Qg5yUtjbyp 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RJ9wAk3ZNrFwdso1RVbwASiqqQaDNyKjd2 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RVKtRKozg8RKvEYCumMD43fCU6f212M5RD 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RCvsbvzCwA1AaxeoYVSL9Q3BdnybEWfXaH 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RXtADsErZLmsGhNyQdW2DekHMGZ23cLrav 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RYGrWs5b8CVFFpxGpjiBaMwfYV9X5UqFaB 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RHASfhhM6bvDFakRDqkzA2wc3V4R4oNmXi 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RATaU3jjn4RwHK61YWoJ4eg7Eggk3puZW8 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RXbb9PkefXcsqq8wqiUZZUuq8e3p29mw1G 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RDY9LJZTEJ9FsvugUuD69gceA98uqan5XL 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress R9tjkpdNbzw6mNfxorb5bvTPmsuon5aLrC 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RT2JyVts5tb1prC7KYykmznrqw7VXJo1HB 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RFHRWQ5pAXNfmudHfxdxw3Wo8yFGoeDn6z 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RTw3vi3dGa9n8LLbKvk7jDAwLdt3A5ET7a 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RQeuhk4KcPM3F5hefwTBWezDdcktSGQQSq 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress R9TGdzN25MgdRkYfsYfxZWzHCLVCyWFAei 0.010000
|
||||
./komodo-cli -ac_name=BET sendtoaddress RDYsrWBZkYSWhRDupGRrfGqrVnFtK9hJGC 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RNJmgYaFF5DbnrNUX6pMYz9rcnDKC2tuAc 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RDhEGYScNQYetCyG75Kf8Fg61UWPdwc1C5 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RHPGxpiwRHP4dKZXjYPdpon1nCto7qVE8s 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RLQoAcs1RaqW1xfN2NJwoZWW5twexPhuGB 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RXF3aHUaWDUY4fRRYmBNALoHWkgSQCiJ4f 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RL2SkPSCGMvcHqZ56ErfMxbQGdA4nk7MZp 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RFssbc211PJdVy1bvcvAG5X2N4ovPAoy5o 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RNoz2DKPZ2ppMxgYx5tce9sjZBHefvPvNB 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RVxtoUT9CXbC1LdhztNAf9yR5ySnFnSPQh 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress R9XBrbj8iKkwy9M4erUqRaBinAiZSTXav3 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RSHdRnHHGdPtVej7fiehHBQ6dyTbEM1GHi 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RDW8EDkCkzQ1LA4xbVUoAERsBVhhYRLXCr 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RAxQTHdsy89tfSXwoce2sHeWrYXmDsMXQq 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RT2k2voy9n8jwppeTTJMQAhvaqA9pc9jHh 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RRvaVyKS59NJWhPp8Pn7mVPGhMuhJJXrdh 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RBpp98VwHx7SFv7dNbw8NY65t14XFq9fVD 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RPjUmFNcWEW9Bu275kPxzRXyWDz6bfQpPD 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RDY2CvzydimY2AtDqSjBAB1eCeogRE55DX 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RUgW6fLfVsLJ87Ng4zJTqNedJSKYQ9ToAf 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RUreYvNjhZYc1vP8cND9Cztpni1pYsigXb 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RHv3wyVnnanG2kSQmLNmjwAQeYRRAptxUy 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RLVwuTM5TitV4Gk79Rja731RwYkAzz7GWn 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RHbxwDa7JT1KJLHDKwb5n3gd8NREErqtQY 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RFDAZ1yCvKPmpqcgzg8r2qQJ8nPPgeoMrB 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RHsZesZXMfkdrsSEper3JWUBKwk29JTFfT 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RPJjzoKPb8idoUCT9XLBkNojNgysjJ5qrE 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RFQNjTfcvSAmf8D83og1NrdHj1wH2fc5X4 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RPknkGAHMwUBvfKQfvw9FyatTZzicSiN4y 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RMqbQz4NPNbG15QBwy9EFvLn4NX5Fa7w5g 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RQipE6ycbVVb9vCkhqrK8PGZs2p5YmiBtg 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RCA8H1npFPW5pnJRzycF8tFEJmn6XZhD4j 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RJD5jRidYW9Cu8qxjg9HDCsx6J3A4wQ4LU 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RQMwcDYMVBx9f4QCFfFk31px8QZP4e8uhA 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RXzsovGBQ3W97xnVC6JnWxXsV4qb7p7iBi 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RLHr8gUm2MZ3EEgDU4EmK7bdn5ZsxLYmnt 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RFTsWSzgKRd5Xa7d287w9eRFeYefKBso6Z 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress REuQ7EoxKeMYk4EGptV6EwdfV9LZXuc44g 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RX1tP6ftwe96p6scgJn4dpgNdHDgyg9R87 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RERp696QtNTeWDfBy3x3QbRwPYN2NxwxfA 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RNZKqUgoAPwWd7wNtuSKP7k1HSJAyPeH4N 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress R9jhJCwgT78pyjnkNuxgH3CE8ekxgT8iwB 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RSCQKVUhihKb13rb5VJwXsbSY6pdRPUZ6V 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RDVqM6t5xZw9jbYXEw2CJgkiSbrHBHiKR3 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RSSNgf98kiMGUxs55DvhNnumyxVudd2KQQ 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RXqdRmv7n9hygf9C7f7vj4VQyNR9RvzXss 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RE3P8D8rcWZBeKmT8DURPdezW87MU5Ho3F 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RS3v2u6d4SJ1ujLz7CHNSFLSmxn6Tx6mJp 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RREc88bQzxHCvzqErPDnTQH2Qg5yUtjbyp 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RJ9wAk3ZNrFwdso1RVbwASiqqQaDNyKjd2 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RVKtRKozg8RKvEYCumMD43fCU6f212M5RD 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RCvsbvzCwA1AaxeoYVSL9Q3BdnybEWfXaH 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RXtADsErZLmsGhNyQdW2DekHMGZ23cLrav 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RYGrWs5b8CVFFpxGpjiBaMwfYV9X5UqFaB 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RHASfhhM6bvDFakRDqkzA2wc3V4R4oNmXi 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RATaU3jjn4RwHK61YWoJ4eg7Eggk3puZW8 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RXbb9PkefXcsqq8wqiUZZUuq8e3p29mw1G 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RDY9LJZTEJ9FsvugUuD69gceA98uqan5XL 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress R9tjkpdNbzw6mNfxorb5bvTPmsuon5aLrC 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RT2JyVts5tb1prC7KYykmznrqw7VXJo1HB 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RFHRWQ5pAXNfmudHfxdxw3Wo8yFGoeDn6z 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RTw3vi3dGa9n8LLbKvk7jDAwLdt3A5ET7a 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RQeuhk4KcPM3F5hefwTBWezDdcktSGQQSq 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress R9TGdzN25MgdRkYfsYfxZWzHCLVCyWFAei 0.010000
|
||||
./komodo-cli -ac_name=CRYPTO sendtoaddress RDYsrWBZkYSWhRDupGRrfGqrVnFtK9hJGC 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RNJmgYaFF5DbnrNUX6pMYz9rcnDKC2tuAc 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RDhEGYScNQYetCyG75Kf8Fg61UWPdwc1C5 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RHPGxpiwRHP4dKZXjYPdpon1nCto7qVE8s 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RLQoAcs1RaqW1xfN2NJwoZWW5twexPhuGB 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RXF3aHUaWDUY4fRRYmBNALoHWkgSQCiJ4f 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RL2SkPSCGMvcHqZ56ErfMxbQGdA4nk7MZp 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RFssbc211PJdVy1bvcvAG5X2N4ovPAoy5o 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RNoz2DKPZ2ppMxgYx5tce9sjZBHefvPvNB 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RVxtoUT9CXbC1LdhztNAf9yR5ySnFnSPQh 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress R9XBrbj8iKkwy9M4erUqRaBinAiZSTXav3 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RSHdRnHHGdPtVej7fiehHBQ6dyTbEM1GHi 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RDW8EDkCkzQ1LA4xbVUoAERsBVhhYRLXCr 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RAxQTHdsy89tfSXwoce2sHeWrYXmDsMXQq 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RT2k2voy9n8jwppeTTJMQAhvaqA9pc9jHh 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RRvaVyKS59NJWhPp8Pn7mVPGhMuhJJXrdh 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RBpp98VwHx7SFv7dNbw8NY65t14XFq9fVD 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RPjUmFNcWEW9Bu275kPxzRXyWDz6bfQpPD 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RDY2CvzydimY2AtDqSjBAB1eCeogRE55DX 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RUgW6fLfVsLJ87Ng4zJTqNedJSKYQ9ToAf 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RUreYvNjhZYc1vP8cND9Cztpni1pYsigXb 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RHv3wyVnnanG2kSQmLNmjwAQeYRRAptxUy 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RLVwuTM5TitV4Gk79Rja731RwYkAzz7GWn 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RHbxwDa7JT1KJLHDKwb5n3gd8NREErqtQY 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RFDAZ1yCvKPmpqcgzg8r2qQJ8nPPgeoMrB 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RHsZesZXMfkdrsSEper3JWUBKwk29JTFfT 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RPJjzoKPb8idoUCT9XLBkNojNgysjJ5qrE 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RFQNjTfcvSAmf8D83og1NrdHj1wH2fc5X4 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RPknkGAHMwUBvfKQfvw9FyatTZzicSiN4y 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RMqbQz4NPNbG15QBwy9EFvLn4NX5Fa7w5g 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RQipE6ycbVVb9vCkhqrK8PGZs2p5YmiBtg 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RCA8H1npFPW5pnJRzycF8tFEJmn6XZhD4j 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RJD5jRidYW9Cu8qxjg9HDCsx6J3A4wQ4LU 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RQMwcDYMVBx9f4QCFfFk31px8QZP4e8uhA 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RXzsovGBQ3W97xnVC6JnWxXsV4qb7p7iBi 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RLHr8gUm2MZ3EEgDU4EmK7bdn5ZsxLYmnt 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RFTsWSzgKRd5Xa7d287w9eRFeYefKBso6Z 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress REuQ7EoxKeMYk4EGptV6EwdfV9LZXuc44g 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RX1tP6ftwe96p6scgJn4dpgNdHDgyg9R87 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RERp696QtNTeWDfBy3x3QbRwPYN2NxwxfA 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RNZKqUgoAPwWd7wNtuSKP7k1HSJAyPeH4N 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress R9jhJCwgT78pyjnkNuxgH3CE8ekxgT8iwB 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RSCQKVUhihKb13rb5VJwXsbSY6pdRPUZ6V 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RDVqM6t5xZw9jbYXEw2CJgkiSbrHBHiKR3 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RSSNgf98kiMGUxs55DvhNnumyxVudd2KQQ 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RXqdRmv7n9hygf9C7f7vj4VQyNR9RvzXss 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RE3P8D8rcWZBeKmT8DURPdezW87MU5Ho3F 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RS3v2u6d4SJ1ujLz7CHNSFLSmxn6Tx6mJp 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RREc88bQzxHCvzqErPDnTQH2Qg5yUtjbyp 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RJ9wAk3ZNrFwdso1RVbwASiqqQaDNyKjd2 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RVKtRKozg8RKvEYCumMD43fCU6f212M5RD 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RCvsbvzCwA1AaxeoYVSL9Q3BdnybEWfXaH 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RXtADsErZLmsGhNyQdW2DekHMGZ23cLrav 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RYGrWs5b8CVFFpxGpjiBaMwfYV9X5UqFaB 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RHASfhhM6bvDFakRDqkzA2wc3V4R4oNmXi 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RATaU3jjn4RwHK61YWoJ4eg7Eggk3puZW8 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RXbb9PkefXcsqq8wqiUZZUuq8e3p29mw1G 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RDY9LJZTEJ9FsvugUuD69gceA98uqan5XL 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress R9tjkpdNbzw6mNfxorb5bvTPmsuon5aLrC 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RT2JyVts5tb1prC7KYykmznrqw7VXJo1HB 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RFHRWQ5pAXNfmudHfxdxw3Wo8yFGoeDn6z 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RTw3vi3dGa9n8LLbKvk7jDAwLdt3A5ET7a 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RQeuhk4KcPM3F5hefwTBWezDdcktSGQQSq 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress R9TGdzN25MgdRkYfsYfxZWzHCLVCyWFAei 0.010000
|
||||
./komodo-cli -ac_name=HODL sendtoaddress RDYsrWBZkYSWhRDupGRrfGqrVnFtK9hJGC 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RNJmgYaFF5DbnrNUX6pMYz9rcnDKC2tuAc 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RDhEGYScNQYetCyG75Kf8Fg61UWPdwc1C5 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RHPGxpiwRHP4dKZXjYPdpon1nCto7qVE8s 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RLQoAcs1RaqW1xfN2NJwoZWW5twexPhuGB 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RXF3aHUaWDUY4fRRYmBNALoHWkgSQCiJ4f 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RL2SkPSCGMvcHqZ56ErfMxbQGdA4nk7MZp 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RFssbc211PJdVy1bvcvAG5X2N4ovPAoy5o 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RNoz2DKPZ2ppMxgYx5tce9sjZBHefvPvNB 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RVxtoUT9CXbC1LdhztNAf9yR5ySnFnSPQh 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress R9XBrbj8iKkwy9M4erUqRaBinAiZSTXav3 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RSHdRnHHGdPtVej7fiehHBQ6dyTbEM1GHi 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RDW8EDkCkzQ1LA4xbVUoAERsBVhhYRLXCr 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RAxQTHdsy89tfSXwoce2sHeWrYXmDsMXQq 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RT2k2voy9n8jwppeTTJMQAhvaqA9pc9jHh 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RRvaVyKS59NJWhPp8Pn7mVPGhMuhJJXrdh 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RBpp98VwHx7SFv7dNbw8NY65t14XFq9fVD 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RPjUmFNcWEW9Bu275kPxzRXyWDz6bfQpPD 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RDY2CvzydimY2AtDqSjBAB1eCeogRE55DX 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RUgW6fLfVsLJ87Ng4zJTqNedJSKYQ9ToAf 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RUreYvNjhZYc1vP8cND9Cztpni1pYsigXb 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RHv3wyVnnanG2kSQmLNmjwAQeYRRAptxUy 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RLVwuTM5TitV4Gk79Rja731RwYkAzz7GWn 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RHbxwDa7JT1KJLHDKwb5n3gd8NREErqtQY 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RFDAZ1yCvKPmpqcgzg8r2qQJ8nPPgeoMrB 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RHsZesZXMfkdrsSEper3JWUBKwk29JTFfT 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RPJjzoKPb8idoUCT9XLBkNojNgysjJ5qrE 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RFQNjTfcvSAmf8D83og1NrdHj1wH2fc5X4 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RPknkGAHMwUBvfKQfvw9FyatTZzicSiN4y 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RMqbQz4NPNbG15QBwy9EFvLn4NX5Fa7w5g 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RQipE6ycbVVb9vCkhqrK8PGZs2p5YmiBtg 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RCA8H1npFPW5pnJRzycF8tFEJmn6XZhD4j 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RJD5jRidYW9Cu8qxjg9HDCsx6J3A4wQ4LU 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RQMwcDYMVBx9f4QCFfFk31px8QZP4e8uhA 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RXzsovGBQ3W97xnVC6JnWxXsV4qb7p7iBi 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RLHr8gUm2MZ3EEgDU4EmK7bdn5ZsxLYmnt 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RFTsWSzgKRd5Xa7d287w9eRFeYefKBso6Z 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress REuQ7EoxKeMYk4EGptV6EwdfV9LZXuc44g 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RX1tP6ftwe96p6scgJn4dpgNdHDgyg9R87 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RERp696QtNTeWDfBy3x3QbRwPYN2NxwxfA 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RNZKqUgoAPwWd7wNtuSKP7k1HSJAyPeH4N 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress R9jhJCwgT78pyjnkNuxgH3CE8ekxgT8iwB 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RSCQKVUhihKb13rb5VJwXsbSY6pdRPUZ6V 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RDVqM6t5xZw9jbYXEw2CJgkiSbrHBHiKR3 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RSSNgf98kiMGUxs55DvhNnumyxVudd2KQQ 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RXqdRmv7n9hygf9C7f7vj4VQyNR9RvzXss 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RE3P8D8rcWZBeKmT8DURPdezW87MU5Ho3F 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RS3v2u6d4SJ1ujLz7CHNSFLSmxn6Tx6mJp 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RREc88bQzxHCvzqErPDnTQH2Qg5yUtjbyp 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RJ9wAk3ZNrFwdso1RVbwASiqqQaDNyKjd2 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RVKtRKozg8RKvEYCumMD43fCU6f212M5RD 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RCvsbvzCwA1AaxeoYVSL9Q3BdnybEWfXaH 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RXtADsErZLmsGhNyQdW2DekHMGZ23cLrav 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RYGrWs5b8CVFFpxGpjiBaMwfYV9X5UqFaB 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RHASfhhM6bvDFakRDqkzA2wc3V4R4oNmXi 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RATaU3jjn4RwHK61YWoJ4eg7Eggk3puZW8 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RXbb9PkefXcsqq8wqiUZZUuq8e3p29mw1G 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RDY9LJZTEJ9FsvugUuD69gceA98uqan5XL 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress R9tjkpdNbzw6mNfxorb5bvTPmsuon5aLrC 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RT2JyVts5tb1prC7KYykmznrqw7VXJo1HB 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RFHRWQ5pAXNfmudHfxdxw3Wo8yFGoeDn6z 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RTw3vi3dGa9n8LLbKvk7jDAwLdt3A5ET7a 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RQeuhk4KcPM3F5hefwTBWezDdcktSGQQSq 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress R9TGdzN25MgdRkYfsYfxZWzHCLVCyWFAei 0.010000
|
||||
./komodo-cli -ac_name=SHARK sendtoaddress RDYsrWBZkYSWhRDupGRrfGqrVnFtK9hJGC 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RNJmgYaFF5DbnrNUX6pMYz9rcnDKC2tuAc 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RDhEGYScNQYetCyG75Kf8Fg61UWPdwc1C5 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RHPGxpiwRHP4dKZXjYPdpon1nCto7qVE8s 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RLQoAcs1RaqW1xfN2NJwoZWW5twexPhuGB 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RXF3aHUaWDUY4fRRYmBNALoHWkgSQCiJ4f 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RL2SkPSCGMvcHqZ56ErfMxbQGdA4nk7MZp 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RFssbc211PJdVy1bvcvAG5X2N4ovPAoy5o 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RNoz2DKPZ2ppMxgYx5tce9sjZBHefvPvNB 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RVxtoUT9CXbC1LdhztNAf9yR5ySnFnSPQh 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress R9XBrbj8iKkwy9M4erUqRaBinAiZSTXav3 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RSHdRnHHGdPtVej7fiehHBQ6dyTbEM1GHi 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RDW8EDkCkzQ1LA4xbVUoAERsBVhhYRLXCr 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RAxQTHdsy89tfSXwoce2sHeWrYXmDsMXQq 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RT2k2voy9n8jwppeTTJMQAhvaqA9pc9jHh 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RRvaVyKS59NJWhPp8Pn7mVPGhMuhJJXrdh 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RBpp98VwHx7SFv7dNbw8NY65t14XFq9fVD 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RPjUmFNcWEW9Bu275kPxzRXyWDz6bfQpPD 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RDY2CvzydimY2AtDqSjBAB1eCeogRE55DX 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RUgW6fLfVsLJ87Ng4zJTqNedJSKYQ9ToAf 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RUreYvNjhZYc1vP8cND9Cztpni1pYsigXb 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RHv3wyVnnanG2kSQmLNmjwAQeYRRAptxUy 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RLVwuTM5TitV4Gk79Rja731RwYkAzz7GWn 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RHbxwDa7JT1KJLHDKwb5n3gd8NREErqtQY 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RFDAZ1yCvKPmpqcgzg8r2qQJ8nPPgeoMrB 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RHsZesZXMfkdrsSEper3JWUBKwk29JTFfT 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RPJjzoKPb8idoUCT9XLBkNojNgysjJ5qrE 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RFQNjTfcvSAmf8D83og1NrdHj1wH2fc5X4 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RPknkGAHMwUBvfKQfvw9FyatTZzicSiN4y 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RMqbQz4NPNbG15QBwy9EFvLn4NX5Fa7w5g 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RQipE6ycbVVb9vCkhqrK8PGZs2p5YmiBtg 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RCA8H1npFPW5pnJRzycF8tFEJmn6XZhD4j 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RJD5jRidYW9Cu8qxjg9HDCsx6J3A4wQ4LU 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RQMwcDYMVBx9f4QCFfFk31px8QZP4e8uhA 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RXzsovGBQ3W97xnVC6JnWxXsV4qb7p7iBi 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RLHr8gUm2MZ3EEgDU4EmK7bdn5ZsxLYmnt 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RFTsWSzgKRd5Xa7d287w9eRFeYefKBso6Z 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress REuQ7EoxKeMYk4EGptV6EwdfV9LZXuc44g 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RX1tP6ftwe96p6scgJn4dpgNdHDgyg9R87 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RERp696QtNTeWDfBy3x3QbRwPYN2NxwxfA 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RNZKqUgoAPwWd7wNtuSKP7k1HSJAyPeH4N 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress R9jhJCwgT78pyjnkNuxgH3CE8ekxgT8iwB 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RSCQKVUhihKb13rb5VJwXsbSY6pdRPUZ6V 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RDVqM6t5xZw9jbYXEw2CJgkiSbrHBHiKR3 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RSSNgf98kiMGUxs55DvhNnumyxVudd2KQQ 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RXqdRmv7n9hygf9C7f7vj4VQyNR9RvzXss 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RE3P8D8rcWZBeKmT8DURPdezW87MU5Ho3F 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RS3v2u6d4SJ1ujLz7CHNSFLSmxn6Tx6mJp 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RREc88bQzxHCvzqErPDnTQH2Qg5yUtjbyp 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RJ9wAk3ZNrFwdso1RVbwASiqqQaDNyKjd2 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RVKtRKozg8RKvEYCumMD43fCU6f212M5RD 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RCvsbvzCwA1AaxeoYVSL9Q3BdnybEWfXaH 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RXtADsErZLmsGhNyQdW2DekHMGZ23cLrav 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RYGrWs5b8CVFFpxGpjiBaMwfYV9X5UqFaB 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RHASfhhM6bvDFakRDqkzA2wc3V4R4oNmXi 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RATaU3jjn4RwHK61YWoJ4eg7Eggk3puZW8 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RXbb9PkefXcsqq8wqiUZZUuq8e3p29mw1G 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RDY9LJZTEJ9FsvugUuD69gceA98uqan5XL 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress R9tjkpdNbzw6mNfxorb5bvTPmsuon5aLrC 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RT2JyVts5tb1prC7KYykmznrqw7VXJo1HB 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RFHRWQ5pAXNfmudHfxdxw3Wo8yFGoeDn6z 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RTw3vi3dGa9n8LLbKvk7jDAwLdt3A5ET7a 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RQeuhk4KcPM3F5hefwTBWezDdcktSGQQSq 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress R9TGdzN25MgdRkYfsYfxZWzHCLVCyWFAei 0.010000
|
||||
./komodo-cli -ac_name=BOTS sendtoaddress RDYsrWBZkYSWhRDupGRrfGqrVnFtK9hJGC 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RNJmgYaFF5DbnrNUX6pMYz9rcnDKC2tuAc 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RDhEGYScNQYetCyG75Kf8Fg61UWPdwc1C5 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RHPGxpiwRHP4dKZXjYPdpon1nCto7qVE8s 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RLQoAcs1RaqW1xfN2NJwoZWW5twexPhuGB 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RXF3aHUaWDUY4fRRYmBNALoHWkgSQCiJ4f 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RL2SkPSCGMvcHqZ56ErfMxbQGdA4nk7MZp 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RFssbc211PJdVy1bvcvAG5X2N4ovPAoy5o 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RNoz2DKPZ2ppMxgYx5tce9sjZBHefvPvNB 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RVxtoUT9CXbC1LdhztNAf9yR5ySnFnSPQh 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress R9XBrbj8iKkwy9M4erUqRaBinAiZSTXav3 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RSHdRnHHGdPtVej7fiehHBQ6dyTbEM1GHi 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RDW8EDkCkzQ1LA4xbVUoAERsBVhhYRLXCr 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RAxQTHdsy89tfSXwoce2sHeWrYXmDsMXQq 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RT2k2voy9n8jwppeTTJMQAhvaqA9pc9jHh 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RRvaVyKS59NJWhPp8Pn7mVPGhMuhJJXrdh 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RBpp98VwHx7SFv7dNbw8NY65t14XFq9fVD 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RPjUmFNcWEW9Bu275kPxzRXyWDz6bfQpPD 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RDY2CvzydimY2AtDqSjBAB1eCeogRE55DX 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RUgW6fLfVsLJ87Ng4zJTqNedJSKYQ9ToAf 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RUreYvNjhZYc1vP8cND9Cztpni1pYsigXb 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RHv3wyVnnanG2kSQmLNmjwAQeYRRAptxUy 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RLVwuTM5TitV4Gk79Rja731RwYkAzz7GWn 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RHbxwDa7JT1KJLHDKwb5n3gd8NREErqtQY 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RFDAZ1yCvKPmpqcgzg8r2qQJ8nPPgeoMrB 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RHsZesZXMfkdrsSEper3JWUBKwk29JTFfT 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RPJjzoKPb8idoUCT9XLBkNojNgysjJ5qrE 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RFQNjTfcvSAmf8D83og1NrdHj1wH2fc5X4 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RPknkGAHMwUBvfKQfvw9FyatTZzicSiN4y 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RMqbQz4NPNbG15QBwy9EFvLn4NX5Fa7w5g 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RQipE6ycbVVb9vCkhqrK8PGZs2p5YmiBtg 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RCA8H1npFPW5pnJRzycF8tFEJmn6XZhD4j 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RJD5jRidYW9Cu8qxjg9HDCsx6J3A4wQ4LU 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RQMwcDYMVBx9f4QCFfFk31px8QZP4e8uhA 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RXzsovGBQ3W97xnVC6JnWxXsV4qb7p7iBi 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RLHr8gUm2MZ3EEgDU4EmK7bdn5ZsxLYmnt 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RFTsWSzgKRd5Xa7d287w9eRFeYefKBso6Z 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress REuQ7EoxKeMYk4EGptV6EwdfV9LZXuc44g 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RX1tP6ftwe96p6scgJn4dpgNdHDgyg9R87 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RERp696QtNTeWDfBy3x3QbRwPYN2NxwxfA 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RNZKqUgoAPwWd7wNtuSKP7k1HSJAyPeH4N 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress R9jhJCwgT78pyjnkNuxgH3CE8ekxgT8iwB 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RSCQKVUhihKb13rb5VJwXsbSY6pdRPUZ6V 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RDVqM6t5xZw9jbYXEw2CJgkiSbrHBHiKR3 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RSSNgf98kiMGUxs55DvhNnumyxVudd2KQQ 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RXqdRmv7n9hygf9C7f7vj4VQyNR9RvzXss 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RE3P8D8rcWZBeKmT8DURPdezW87MU5Ho3F 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RS3v2u6d4SJ1ujLz7CHNSFLSmxn6Tx6mJp 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RREc88bQzxHCvzqErPDnTQH2Qg5yUtjbyp 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RJ9wAk3ZNrFwdso1RVbwASiqqQaDNyKjd2 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RVKtRKozg8RKvEYCumMD43fCU6f212M5RD 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RCvsbvzCwA1AaxeoYVSL9Q3BdnybEWfXaH 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RXtADsErZLmsGhNyQdW2DekHMGZ23cLrav 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RYGrWs5b8CVFFpxGpjiBaMwfYV9X5UqFaB 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RHASfhhM6bvDFakRDqkzA2wc3V4R4oNmXi 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RATaU3jjn4RwHK61YWoJ4eg7Eggk3puZW8 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RXbb9PkefXcsqq8wqiUZZUuq8e3p29mw1G 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RDY9LJZTEJ9FsvugUuD69gceA98uqan5XL 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress R9tjkpdNbzw6mNfxorb5bvTPmsuon5aLrC 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RT2JyVts5tb1prC7KYykmznrqw7VXJo1HB 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RFHRWQ5pAXNfmudHfxdxw3Wo8yFGoeDn6z 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RTw3vi3dGa9n8LLbKvk7jDAwLdt3A5ET7a 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RQeuhk4KcPM3F5hefwTBWezDdcktSGQQSq 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress R9TGdzN25MgdRkYfsYfxZWzHCLVCyWFAei 0.010000
|
||||
./komodo-cli -ac_name=MGW sendtoaddress RDYsrWBZkYSWhRDupGRrfGqrVnFtK9hJGC 0.010000
|
||||
|
||||
12
src/init.cpp
12
src/init.cpp
@@ -76,6 +76,7 @@ using namespace std;
|
||||
extern void ThreadSendAlert();
|
||||
extern int32_t KOMODO_LOADINGBLOCKS;
|
||||
extern bool VERUS_MINTBLOCKS;
|
||||
extern char ASSETCHAINS_SYMBOL[];
|
||||
|
||||
ZCJoinSplit* pzcashParams = NULL;
|
||||
|
||||
@@ -195,7 +196,10 @@ void Shutdown()
|
||||
/// for example if the data directory was found to be locked.
|
||||
/// Be sure that anything that writes files or flushes caches only does this if the respective
|
||||
/// module was initialized.
|
||||
RenameThread("verus-shutoff");
|
||||
static char shutoffstr[128];
|
||||
sprintf(shutoffstr,"%s-shutoff",ASSETCHAINS_SYMBOL);
|
||||
//RenameThread("verus-shutoff");
|
||||
RenameThread(shutoffstr);
|
||||
mempool.AddTransactionsUpdated(1);
|
||||
|
||||
StopHTTPRPC();
|
||||
@@ -1501,7 +1505,7 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler)
|
||||
fReindex = true;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
bool clearWitnessCaches = false;
|
||||
|
||||
bool fLoaded = false;
|
||||
@@ -1874,9 +1878,9 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler)
|
||||
VERUS_MINTBLOCKS = GetBoolArg("-mint", false);
|
||||
|
||||
if (pwalletMain || !GetArg("-mineraddress", "").empty())
|
||||
GenerateBitcoins(GetBoolArg("-gen", false), pwalletMain, GetArg("-genproclimit", 0));
|
||||
GenerateBitcoins(GetBoolArg("-gen", false), pwalletMain, GetArg("-genproclimit", -1));
|
||||
#else
|
||||
GenerateBitcoins(GetBoolArg("-gen", false), GetArg("-genproclimit", 0));
|
||||
GenerateBitcoins(GetBoolArg("-gen", false), GetArg("-genproclimit", -1));
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
@@ -167,7 +167,7 @@ try_again:
|
||||
curl_handle = curl_easy_init();
|
||||
init_string(&s);
|
||||
headers = curl_slist_append(0,"Expect:");
|
||||
|
||||
|
||||
curl_easy_setopt(curl_handle,CURLOPT_USERAGENT,"mozilla/4.0");//"Mozilla/4.0 (compatible; )");
|
||||
curl_easy_setopt(curl_handle,CURLOPT_HTTPHEADER, headers);
|
||||
curl_easy_setopt(curl_handle,CURLOPT_URL, url);
|
||||
@@ -196,7 +196,7 @@ try_again:
|
||||
bracket0 = (char *)"[";
|
||||
bracket1 = (char *)"]";
|
||||
}
|
||||
|
||||
|
||||
databuf = (char *)malloc(256 + strlen(command) + strlen(params));
|
||||
sprintf(databuf,"{\"id\":\"jl777\",\"method\":\"%s\",\"params\":%s%s%s}",command,bracket0,params,bracket1);
|
||||
//printf("url.(%s) userpass.(%s) databuf.(%s)\n",url,userpass,databuf);
|
||||
@@ -236,7 +236,7 @@ try_again:
|
||||
free(s.ptr);
|
||||
sleep((1<<numretries));
|
||||
goto try_again;
|
||||
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -522,7 +522,7 @@ int32_t komodo_verifynotarization(char *symbol,char *dest,int32_t height,int32_t
|
||||
}
|
||||
return(hash);
|
||||
}
|
||||
|
||||
|
||||
uint256 _komodo_getblockhash(int32_t height);*/
|
||||
|
||||
uint64_t komodo_seed(int32_t height)
|
||||
@@ -889,9 +889,9 @@ int32_t komodo_eligiblenotary(uint8_t pubkeys[66][33],int32_t *mids,uint32_t blo
|
||||
|
||||
int32_t komodo_minerids(uint8_t *minerids,int32_t height,int32_t width)
|
||||
{
|
||||
int32_t i,j,n,nonz,numnotaries; CBlock block; CBlockIndex *pindex; uint8_t notarypubs33[64][33],pubkey33[33];
|
||||
int32_t i,j,nonz,numnotaries; CBlock block; CBlockIndex *pindex; uint8_t notarypubs33[64][33],pubkey33[33];
|
||||
numnotaries = komodo_notaries(notarypubs33,height,0);
|
||||
for (i=nonz=0; i<width; i++,n++)
|
||||
for (i=nonz=0; i<width; i++)
|
||||
{
|
||||
if ( height-i <= 0 )
|
||||
continue;
|
||||
@@ -1106,9 +1106,9 @@ int32_t komodo_validate_interest(const CTransaction &tx,int32_t txheight,uint32_
|
||||
|
||||
/*
|
||||
komodo_checkPOW (fast) is called early in the process and should only refer to data immediately available. it is a filter to prevent bad blocks from going into the local DB. The more blocks we can filter out at this stage, the less junk in the local DB that will just get purged later on.
|
||||
|
||||
|
||||
komodo_checkPOW (slow) is called right before connecting blocks so all prior blocks can be assumed to be there and all checks must pass
|
||||
|
||||
|
||||
commission must be in coinbase.vout[1] and must be >= 10000 sats
|
||||
PoS stake must be without txfee and in the last tx in the block at vout[0]
|
||||
*/
|
||||
@@ -1123,11 +1123,13 @@ uint64_t komodo_commission(const CBlock *pblock,int32_t height)
|
||||
{
|
||||
nSubsidy = GetBlockSubsidy(height,Params().GetConsensus());
|
||||
//fprintf(stderr,"ht.%d nSubsidy %.8f prod %llu\n",height,(double)nSubsidy/COIN,(long long)(nSubsidy * ASSETCHAINS_COMMISSION));
|
||||
return((nSubsidy * ASSETCHAINS_COMMISSION) / COIN);
|
||||
n = pblock->vtx[0].vout.size();
|
||||
for (j=0; j<n; j++)
|
||||
if ( j != 1 )
|
||||
total += pblock->vtx[0].vout[j].nValue;
|
||||
commission = ((nSubsidy * ASSETCHAINS_COMMISSION) / COIN);
|
||||
if ( ASSETCHAINS_FOUNDERS > 1 )
|
||||
{
|
||||
if ( (height % ASSETCHAINS_FOUNDERS) == 0 )
|
||||
commission = commission * ASSETCHAINS_FOUNDERS;
|
||||
else commission = 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -1141,9 +1143,8 @@ uint64_t komodo_commission(const CBlock *pblock,int32_t height)
|
||||
total += pblock->vtx[i].vout[j].nValue;
|
||||
}
|
||||
}
|
||||
commission = ((total * ASSETCHAINS_COMMISSION) / COIN);
|
||||
}
|
||||
//fprintf(stderr,"txn.%d n.%d commission total %.8f -> %.8f\n",txn_count,n,dstr(total),dstr((total * ASSETCHAINS_COMMISSION) / COIN));
|
||||
commission = ((total * ASSETCHAINS_COMMISSION) / COIN);
|
||||
if ( commission < 10000 )
|
||||
commission = 0;
|
||||
return(commission);
|
||||
@@ -1545,7 +1546,7 @@ bool verusCheckPOSBlock(int32_t slowflag, CBlock *pblock, int32_t height)
|
||||
{
|
||||
fprintf(stderr,"ERROR: chain not fully loaded or invalid PoS block %s - no past block found\n",blkHash.ToString().c_str());
|
||||
}
|
||||
else
|
||||
else
|
||||
#ifndef KOMODO_ZCASH
|
||||
if (!GetTransaction(txid, tx, Params().GetConsensus(), blkHash, true))
|
||||
#else
|
||||
@@ -1578,7 +1579,7 @@ bool verusCheckPOSBlock(int32_t slowflag, CBlock *pblock, int32_t height)
|
||||
{
|
||||
BlockMap::const_iterator it = mapBlockIndex.find(blkHash);
|
||||
if ((it == mapBlockIndex.end()) ||
|
||||
!(pastBlockIndex = it->second) ||
|
||||
!(pastBlockIndex = it->second) ||
|
||||
(height - pastBlockIndex->GetHeight()) < VERUS_MIN_STAKEAGE)
|
||||
{
|
||||
fprintf(stderr,"ERROR: invalid PoS block %s - stake source too new or not found\n",blkHash.ToString().c_str());
|
||||
@@ -1695,7 +1696,7 @@ int64_t komodo_checkcommission(CBlock *pblock,int32_t height)
|
||||
// fprintf(stderr,"%02x",script[i]);
|
||||
//fprintf(stderr," payment to wrong pubkey scriptlen.%d, scriptpub[%d]\n",scriptlen,(int32_t)ASSETCHAINS_SCRIPTPUB.size()/2);
|
||||
return(-1);
|
||||
|
||||
|
||||
}
|
||||
if ( pblock->vtx[0].vout[1].nValue != checktoshis )
|
||||
{
|
||||
@@ -1806,7 +1807,9 @@ int32_t komodo_checkPOW(int32_t slowflag,CBlock *pblock,int32_t height)
|
||||
if ( ASSETCHAINS_SCRIPTPUB.size() > 1 )
|
||||
{
|
||||
int32_t scriptlen; uint8_t scripthex[10000];
|
||||
if ( ASSETCHAINS_SCRIPTPUB.size()/2 == pblock->vtx[0].vout[0].scriptPubKey.size() && scriptlen < sizeof(scripthex) )
|
||||
script = (uint8_t *)&pblock->vtx[0].vout[0].scriptPubKey[0];
|
||||
scriptlen = (int32_t)pblock->vtx[0].vout[0].scriptPubKey.size();
|
||||
if ( ASSETCHAINS_SCRIPTPUB.size()/2 == scriptlen && scriptlen < sizeof(scripthex) )
|
||||
{
|
||||
decode_hex(scripthex,scriptlen,(char *)ASSETCHAINS_SCRIPTPUB.c_str());
|
||||
if ( memcmp(scripthex,script,scriptlen) != 0 )
|
||||
@@ -1848,9 +1851,9 @@ int32_t komodo_acpublic(uint32_t tiptime)
|
||||
return(acpublic);
|
||||
}
|
||||
|
||||
int64_t komodo_newcoins(int64_t *zfundsp,int32_t nHeight,CBlock *pblock)
|
||||
int64_t komodo_newcoins(int64_t *zfundsp,int64_t *sproutfundsp,int32_t nHeight,CBlock *pblock)
|
||||
{
|
||||
CTxDestination address; int32_t i,j,m,n,vout; uint8_t *script; uint256 txid,hashBlock; int64_t zfunds=0,vinsum=0,voutsum=0;
|
||||
CTxDestination address; int32_t i,j,m,n,vout; uint8_t *script; uint256 txid,hashBlock; int64_t zfunds=0,vinsum=0,voutsum=0,sproutfunds=0;
|
||||
n = pblock->vtx.size();
|
||||
for (i=0; i<n; i++)
|
||||
{
|
||||
@@ -1890,10 +1893,13 @@ int64_t komodo_newcoins(int64_t *zfundsp,int32_t nHeight,CBlock *pblock)
|
||||
{
|
||||
zfunds -= joinsplit.vpub_new;
|
||||
zfunds += joinsplit.vpub_old;
|
||||
sproutfunds -= joinsplit.vpub_new;
|
||||
sproutfunds += joinsplit.vpub_old;
|
||||
}
|
||||
zfunds -= tx.valueBalance;
|
||||
}
|
||||
*zfundsp = zfunds;
|
||||
*sproutfundsp = sproutfunds;
|
||||
if ( ASSETCHAINS_SYMBOL[0] == 0 && (voutsum-vinsum) == 100003*SATOSHIDEN ) // 15 times
|
||||
return(3 * SATOSHIDEN);
|
||||
//if ( voutsum-vinsum+zfunds > 100000*SATOSHIDEN || voutsum-vinsum+zfunds < 0 )
|
||||
@@ -1901,11 +1907,11 @@ int64_t komodo_newcoins(int64_t *zfundsp,int32_t nHeight,CBlock *pblock)
|
||||
return(voutsum - vinsum);
|
||||
}
|
||||
|
||||
int64_t komodo_coinsupply(int64_t *zfundsp,int32_t height)
|
||||
int64_t komodo_coinsupply(int64_t *zfundsp,int64_t *sproutfundsp,int32_t height)
|
||||
{
|
||||
CBlockIndex *pindex; CBlock block; int64_t zfunds=0,supply = 0;
|
||||
CBlockIndex *pindex; CBlock block; int64_t zfunds=0,sproutfunds=0,supply = 0;
|
||||
//fprintf(stderr,"coinsupply %d\n",height);
|
||||
*zfundsp = 0;
|
||||
*zfundsp = *sproutfundsp = 0;
|
||||
if ( (pindex= komodo_chainactive(height)) != 0 )
|
||||
{
|
||||
while ( pindex != 0 && pindex->GetHeight() > 0 )
|
||||
@@ -1913,7 +1919,7 @@ int64_t komodo_coinsupply(int64_t *zfundsp,int32_t height)
|
||||
if ( pindex->newcoins == 0 && pindex->zfunds == 0 )
|
||||
{
|
||||
if ( komodo_blockload(block,pindex) == 0 )
|
||||
pindex->newcoins = komodo_newcoins(&pindex->zfunds,pindex->GetHeight(),&block);
|
||||
pindex->newcoins = komodo_newcoins(&pindex->zfunds,&pindex->sproutfunds,pindex->GetHeight(),&block);
|
||||
else
|
||||
{
|
||||
fprintf(stderr,"error loading block.%d\n",pindex->GetHeight());
|
||||
@@ -1922,10 +1928,12 @@ int64_t komodo_coinsupply(int64_t *zfundsp,int32_t height)
|
||||
}
|
||||
supply += pindex->newcoins;
|
||||
zfunds += pindex->zfunds;
|
||||
sproutfunds += pindex->sproutfunds;
|
||||
//printf("start ht.%d new %.8f -> supply %.8f zfunds %.8f -> %.8f\n",pindex->GetHeight(),dstr(pindex->newcoins),dstr(supply),dstr(pindex->zfunds),dstr(zfunds));
|
||||
pindex = pindex->pprev;
|
||||
}
|
||||
}
|
||||
*zfundsp = zfunds;
|
||||
*sproutfundsp = sproutfunds;
|
||||
return(supply);
|
||||
}
|
||||
|
||||
@@ -90,7 +90,7 @@ struct pax_transaction *komodo_paxmark(int32_t height,uint256 txid,uint16_t vout
|
||||
pax->marked = mark;
|
||||
//if ( height > 214700 || pax->height > 214700 )
|
||||
// printf("mark ht.%d %.8f %.8f\n",pax->height,dstr(pax->komodoshis),dstr(pax->fiatoshis));
|
||||
|
||||
|
||||
}
|
||||
pthread_mutex_unlock(&komodo_mutex);
|
||||
return(pax);
|
||||
@@ -203,9 +203,9 @@ int32_t komodo_issued_opreturn(char *base,uint256 *txids,uint16_t *vouts,int64_t
|
||||
// return(0);
|
||||
incr = 34 + (iskomodo * (2*sizeof(fiatoshis) + 2*sizeof(height) + 20 + 4));
|
||||
//41e77b91cb68dc2aa02fa88550eae6b6d44db676a7e935337b6d1392d9718f03cb0200305c90660400000000fbcbeb1f000000bde801006201000058e7945ad08ddba1eac9c9b6c8e1e97e8016a2d152
|
||||
|
||||
|
||||
// 41e94d736ec69d88c08b5d238abeeca609c02357a8317e0d56c328bcb1c259be5d0200485bc80200000000404b4c000000000059470200b80b000061f22ba7d19fe29ac3baebd839af8b7127d1f9075553440046bb4cc7a3b5cd39dffe7206507a3482a00780e617f68b273cce9817ed69298d02001069ca1b0000000080f0fa02000000005b470200b90b000061f22ba7d19fe29ac3baebd839af8b7127d1f90755
|
||||
|
||||
|
||||
//for (i=0; i<opretlen; i++)
|
||||
// printf("%02x",opretbuf[i]);
|
||||
//printf(" opretlen.%d (%s)\n",opretlen,base);
|
||||
@@ -688,7 +688,7 @@ int32_t komodo_check_deposit(int32_t height,const CBlock& block,uint32_t prevtim
|
||||
}
|
||||
}
|
||||
// we don't want these checks in VRSC, leave it at the Sapling upgrade
|
||||
if ( ASSETCHAINS_SYMBOL[0] == 0 ||
|
||||
if ( ASSETCHAINS_SYMBOL[0] == 0 ||
|
||||
(ASSETCHAINS_COMMISSION != 0 && height > 1) ||
|
||||
NetworkUpgradeActive(height, Params().GetConsensus(), Consensus::UPGRADE_SAPLING) )
|
||||
{
|
||||
@@ -740,6 +740,11 @@ int32_t komodo_check_deposit(int32_t height,const CBlock& block,uint32_t prevtim
|
||||
else if ( height > 814000 )
|
||||
{
|
||||
script = (uint8_t *)&block.vtx[0].vout[0].scriptPubKey[0];
|
||||
//int32_t notary = komodo_electednotary(&num,script+1,height,0);
|
||||
//if ( (-1 * (komodo_electednotary(&num,script+1,height,0) >= 0) * (height > 1000000)) < 0 )
|
||||
// fprintf(stderr, ">>>>>>> FAILED BLOCK.%d notary.%d insync.%d\n",height,notary,KOMODO_INSYNC);
|
||||
//else
|
||||
// fprintf(stderr, "<<<<<<< VALID BLOCK.%d notary.%d insync.%d\n",height,notary,KOMODO_INSYNC);
|
||||
return(-1 * (komodo_electednotary(&num,script+1,height,0) >= 0) * (height > 1000000));
|
||||
}
|
||||
}
|
||||
@@ -774,7 +779,7 @@ int32_t komodo_check_deposit(int32_t height,const CBlock& block,uint32_t prevtim
|
||||
|
||||
const char *komodo_opreturn(int32_t height,uint64_t value,uint8_t *opretbuf,int32_t opretlen,uint256 txid,uint16_t vout,char *source)
|
||||
{
|
||||
uint8_t rmd160[20],rmd160s[64*20],addrtype,shortflag,pubkey33[33]; int32_t didstats,i,j,n,kvheight,len,tokomodo,kmdheight,otherheights[64],kmdheights[64]; int8_t baseids[64]; char base[4],coinaddr[64],destaddr[64]; uint256 txids[64]; uint16_t vouts[64]; uint64_t convtoshis,seed; int64_t fee,fiatoshis,komodoshis,checktoshis,values[64],srcvalues[64]; struct pax_transaction *pax,*pax2; struct komodo_state *basesp; double diff;
|
||||
uint8_t rmd160[20],rmd160s[64*20],addrtype,shortflag,pubkey33[33]; int32_t didstats,i,j,n,kvheight,len,tokomodo,kmdheight,otherheights[64],kmdheights[64]; int8_t baseids[64]; char base[4],coinaddr[64],destaddr[64]; uint256 txids[64]; uint16_t vouts[64]; uint64_t convtoshis,seed; int64_t fee,fiatoshis,komodoshis,checktoshis,values[64],srcvalues[64]; struct pax_transaction *pax,*pax2; struct komodo_state *basesp; double diff;
|
||||
const char *typestr = "unknown";
|
||||
if ( ASSETCHAINS_SYMBOL[0] != 0 && komodo_baseid(ASSETCHAINS_SYMBOL) < 0 && opretbuf[0] != 'K' )
|
||||
{
|
||||
@@ -1187,7 +1192,7 @@ void komodo_stateind_set(struct komodo_state *sp,uint32_t *inds,int32_t n,uint8_
|
||||
printf("numR.%d numV.%d numN.%d count.%d\n",numR,numV,numN,count);
|
||||
/*else if ( func == 'K' ) // KMD height: stop after 1st
|
||||
else if ( func == 'T' ) // KMD height+timestamp: stop after 1st
|
||||
|
||||
|
||||
else if ( func == 'N' ) // notarization, scan backwards 1440+ blocks;
|
||||
else if ( func == 'V' ) // price feed: can stop after 1440+
|
||||
else if ( func == 'R' ) // opreturn:*/
|
||||
@@ -1373,7 +1378,7 @@ void komodo_passport_iteration()
|
||||
{
|
||||
static long lastpos[34]; static char userpass[33][1024]; static uint32_t lasttime,callcounter,lastinterest;
|
||||
int32_t maxseconds = 10;
|
||||
FILE *fp; uint8_t *filedata; long fpos,datalen,lastfpos; int32_t baseid,limit,n,ht,isrealtime,expired,refid,blocks,longest; struct komodo_state *sp,*refsp; char *retstr,fname[512],*base,symbol[KOMODO_ASSETCHAIN_MAXLEN],dest[KOMODO_ASSETCHAIN_MAXLEN]; uint32_t buf[3],starttime; cJSON *infoobj,*result; uint64_t RTmask = 0;
|
||||
FILE *fp; uint8_t *filedata; long fpos,datalen,lastfpos; int32_t baseid,limit,n,ht,isrealtime,expired,refid,blocks,longest; struct komodo_state *sp,*refsp; char *retstr,fname[512],*base,symbol[KOMODO_ASSETCHAIN_MAXLEN],dest[KOMODO_ASSETCHAIN_MAXLEN]; uint32_t buf[3],starttime; cJSON *infoobj,*result; uint64_t RTmask = 0; //CBlockIndex *pindex;
|
||||
expired = 0;
|
||||
while ( KOMODO_INITDONE == 0 )
|
||||
{
|
||||
@@ -1521,4 +1526,3 @@ void komodo_passport_iteration()
|
||||
printf("READY for %s RPC calls at %u! done PASSPORT %s refid.%d\n",ASSETCHAINS_SYMBOL,(uint32_t)time(NULL),ASSETCHAINS_SYMBOL,refid);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -45,10 +45,10 @@ struct komodo_state KOMODO_STATES[34];
|
||||
#define _COINBASE_MATURITY 100
|
||||
int COINBASE_MATURITY = _COINBASE_MATURITY;//100;
|
||||
|
||||
int32_t KOMODO_MININGTHREADS = -1,IS_KOMODO_NOTARY,USE_EXTERNAL_PUBKEY,KOMODO_CHOSEN_ONE,ASSETCHAINS_SEED,KOMODO_ON_DEMAND,KOMODO_EXTERNAL_NOTARIES,KOMODO_PASSPORT_INITDONE,KOMODO_PAX,KOMODO_EXCHANGEWALLET,KOMODO_REWIND,KOMODO_CONNECTING = -1,KOMODO_DEALERNODE,KOMODO_EXTRASATOSHI;
|
||||
int32_t KOMODO_MININGTHREADS = -1,IS_KOMODO_NOTARY,USE_EXTERNAL_PUBKEY,KOMODO_CHOSEN_ONE,ASSETCHAINS_SEED,KOMODO_ON_DEMAND,KOMODO_EXTERNAL_NOTARIES,KOMODO_PASSPORT_INITDONE,KOMODO_PAX,KOMODO_EXCHANGEWALLET,KOMODO_REWIND,KOMODO_CONNECTING = -1,KOMODO_DEALERNODE,KOMODO_EXTRASATOSHI,ASSETCHAINS_FOUNDERS;
|
||||
int32_t KOMODO_INSYNC,KOMODO_LASTMINED,prevKOMODO_LASTMINED,KOMODO_CCACTIVATE,JUMBLR_PAUSE = 1;
|
||||
std::string NOTARY_PUBKEY,ASSETCHAINS_NOTARIES,ASSETCHAINS_OVERRIDE_PUBKEY,DONATION_PUBKEY,ASSETCHAINS_SCRIPTPUB;
|
||||
uint8_t NOTARY_PUBKEY33[33],ASSETCHAINS_OVERRIDE_PUBKEY33[33],ASSETCHAINS_OVERRIDE_PUBKEYHASH[20],ASSETCHAINS_PUBLIC,ASSETCHAINS_PRIVATE,ASSETCHAINS_TXPOW,ASSETCHAINS_FOUNDERS;
|
||||
uint8_t NOTARY_PUBKEY33[33],ASSETCHAINS_OVERRIDE_PUBKEY33[33],ASSETCHAINS_OVERRIDE_PUBKEYHASH[20],ASSETCHAINS_PUBLIC,ASSETCHAINS_PRIVATE,ASSETCHAINS_TXPOW;
|
||||
bool VERUS_MINTBLOCKS;
|
||||
|
||||
char ASSETCHAINS_SYMBOL[KOMODO_ASSETCHAIN_MAXLEN],ASSETCHAINS_USERPASS[4096];
|
||||
@@ -131,7 +131,7 @@ int64_t komodo_current_supply(uint32_t nHeight)
|
||||
|
||||
if ( (baseid = komodo_baseid(ASSETCHAINS_SYMBOL)) >= 0 && baseid < 32 )
|
||||
cur_money = ASSETCHAINS_GENESISTXVAL + ASSETCHAINS_SUPPLY + nHeight * ASSETCHAINS_REWARD[0] / SATOSHIDEN;
|
||||
else
|
||||
else
|
||||
{
|
||||
// figure out max_money by adding up supply to a maximum of 10,000,000 blocks
|
||||
cur_money = (ASSETCHAINS_SUPPLY+1) * SATOSHIDEN + (ASSETCHAINS_MAGIC & 0xffffff) + ASSETCHAINS_GENESISTXVAL;
|
||||
@@ -144,7 +144,7 @@ int64_t komodo_current_supply(uint32_t nHeight)
|
||||
for ( int j = 0; j <= ASSETCHAINS_LASTERA; j++ )
|
||||
{
|
||||
// if any condition means we have no more rewards, break
|
||||
if (j != 0 && (nHeight <= ASSETCHAINS_ENDSUBSIDY[j - 1] || (ASSETCHAINS_ENDSUBSIDY[j - 1] == 0 &&
|
||||
if (j != 0 && (nHeight <= ASSETCHAINS_ENDSUBSIDY[j - 1] || (ASSETCHAINS_ENDSUBSIDY[j - 1] == 0 &&
|
||||
(ASSETCHAINS_REWARD[j] == 0 && (j == ASSETCHAINS_LASTERA || ASSETCHAINS_DECAY[j] != SATOSHIDEN)))))
|
||||
break;
|
||||
|
||||
@@ -155,6 +155,8 @@ int64_t komodo_current_supply(uint32_t nHeight)
|
||||
uint64_t lastEnd = j == 0 ? 0 : ASSETCHAINS_ENDSUBSIDY[j - 1];
|
||||
uint64_t curEnd = ASSETCHAINS_ENDSUBSIDY[j] == 0 ? nHeight : nHeight > ASSETCHAINS_ENDSUBSIDY[j] ? ASSETCHAINS_ENDSUBSIDY[j] : nHeight;
|
||||
uint64_t period = ASSETCHAINS_HALVING[j];
|
||||
if ( period == 0 )
|
||||
period = 210000;
|
||||
uint32_t nSteps = (curEnd - lastEnd) / period;
|
||||
uint32_t modulo = (curEnd - lastEnd) % period;
|
||||
uint64_t decay = ASSETCHAINS_DECAY[j];
|
||||
@@ -178,7 +180,7 @@ int64_t komodo_current_supply(uint32_t nHeight)
|
||||
lowestSubsidy = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
{
|
||||
// Ex: -ac_eras=3 -ac_reward=0,384,24 -ac_end=1440,260640,0 -ac_halving=1,1440,2103840 -ac_decay 100000000,97750000,0
|
||||
subsidyDifference = reward - ASSETCHAINS_REWARD[j + 1];
|
||||
if (subsidyDifference < 0)
|
||||
@@ -208,7 +210,8 @@ int64_t komodo_current_supply(uint32_t nHeight)
|
||||
|
||||
// calculate amount in one step's triangular protrusion over minor triangle's hypotenuse
|
||||
denominator = nSteps * period;
|
||||
|
||||
if ( denominator == 0 )
|
||||
denominator = 1;
|
||||
// difference of one step vs. total
|
||||
stepDifference = (period * subsidyDifference) / denominator;
|
||||
|
||||
@@ -231,7 +234,7 @@ int64_t komodo_current_supply(uint32_t nHeight)
|
||||
// if negative slope, the minor triangle is the full number of steps, as the highest
|
||||
// level step is full. lowest subsidy is just the lowest so far
|
||||
lowestSubsidy = reward - (stepDifference * nSteps);
|
||||
|
||||
|
||||
// add the step triangles, one per step
|
||||
cur_money += stepTriangle * nSteps;
|
||||
|
||||
@@ -258,4 +261,3 @@ int64_t komodo_current_supply(uint32_t nHeight)
|
||||
}
|
||||
return((int64_t)(cur_money + (cur_money * ASSETCHAINS_COMMISSION)));
|
||||
}
|
||||
|
||||
|
||||
@@ -1068,7 +1068,7 @@ uint64_t komodo_block_prg(uint32_t nHeight)
|
||||
|
||||
// given a block height, this returns the unlock time for that block height, derived from
|
||||
// the ASSETCHAINS_MAGIC number as well as the block height, providing different random numbers
|
||||
// for corresponding blocks across chains, but the same sequence in each chain
|
||||
// for corresponding blocks across chains, but the same sequence in each chain
|
||||
int64_t komodo_block_unlocktime(uint32_t nHeight)
|
||||
{
|
||||
uint64_t fromTime, toTime, unlocktime;
|
||||
@@ -1500,6 +1500,9 @@ uint32_t komodo_assetmagic(char *symbol,uint64_t supply,uint8_t *extraptr,int32_
|
||||
{
|
||||
vcalc_sha256(0,hash.bytes,extraptr,extralen);
|
||||
crc0 = hash.uints[0];
|
||||
int32_t i; for (i=0; i<extralen; i++)
|
||||
fprintf(stderr,"%02x",extraptr[i]);
|
||||
fprintf(stderr," extralen.%d crc0.%x\n",extralen,crc0);
|
||||
}
|
||||
return(calc_crc32(crc0,buf,len));
|
||||
}
|
||||
@@ -1535,7 +1538,7 @@ uint16_t komodo_port(char *symbol,uint64_t supply,uint32_t *magicp,uint8_t *extr
|
||||
printf("ports\n");
|
||||
}*/
|
||||
|
||||
char *iguanafmtstr = (char *)"curl --url \"http://127.0.0.1:7776\" --data \"{\\\"conf\\\":\\\"%s.conf\\\",\\\"path\\\":\\\"${HOME#\"/\"}/.komodo/%s\\\",\\\"unitval\\\":\\\"20\\\",\\\"zcash\\\":1,\\\"RELAY\\\":-1,\\\"VALIDATE\\\":0,\\\"prefetchlag\\\":-1,\\\"poll\\\":100,\\\"active\\\":1,\\\"agent\\\":\\\"iguana\\\",\\\"method\\\":\\\"addcoin\\\",\\\"startpend\\\":4,\\\"endpend\\\":4,\\\"services\\\":129,\\\"maxpeers\\\":8,\\\"newcoin\\\":\\\"%s\\\",\\\"name\\\":\\\"%s\\\",\\\"hasheaders\\\":1,\\\"useaddmultisig\\\":0,\\\"netmagic\\\":\\\"%s\\\",\\\"p2p\\\":%u,\\\"rpc\\\":%u,\\\"pubval\\\":60,\\\"p2shval\\\":85,\\\"wifval\\\":188,\\\"txfee_satoshis\\\":\\\"10000\\\",\\\"isPoS\\\":0,\\\"minoutput\\\":10000,\\\"minconfirms\\\":2,\\\"genesishash\\\":\\\"027e3758c3a65b12aa1046462b486d0a63bfa1beae327897f56c5cfb7daaae71\\\",\\\"protover\\\":170002,\\\"genesisblock\\\":\\\"0100000000000000000000000000000000000000000000000000000000000000000000003ba3edfd7a7b12b27ac72c3e67768f617fc81bc3888a51323a9fb8aa4b1e5e4a000000000000000000000000000000000000000000000000000000000000000029ab5f490f0f0f200b00000000000000000000000000000000000000000000000000000000000000fd4005000d5ba7cda5d473947263bf194285317179d2b0d307119c2e7cc4bd8ac456f0774bd52b0cd9249be9d40718b6397a4c7bbd8f2b3272fed2823cd2af4bd1632200ba4bf796727d6347b225f670f292343274cc35099466f5fb5f0cd1c105121b28213d15db2ed7bdba490b4cedc69742a57b7c25af24485e523aadbb77a0144fc76f79ef73bd8530d42b9f3b9bed1c135ad1fe152923fafe98f95f76f1615e64c4abb1137f4c31b218ba2782bc15534788dda2cc08a0ee2987c8b27ff41bd4e31cd5fb5643dfe862c9a02ca9f90c8c51a6671d681d04ad47e4b53b1518d4befafefe8cadfb912f3d03051b1efbf1dfe37b56e93a741d8dfd80d576ca250bee55fab1311fc7b3255977558cdda6f7d6f875306e43a14413facdaed2f46093e0ef1e8f8a963e1632dcbeebd8e49fd16b57d49b08f9762de89157c65233f60c8e38a1f503a48c555f8ec45dedecd574a37601323c27be597b956343107f8bd80f3a925afaf30811df83c402116bb9c1e5231c70fff899a7c82f73c902ba54da53cc459b7bf1113db65cc8f6914d3618560ea69abd13658fa7b6af92d374d6eca9529f8bd565166e4fcbf2a8dfb3c9b69539d4d2ee2e9321b85b331925df195915f2757637c2805e1d4131e1ad9ef9bc1bb1c732d8dba4738716d351ab30c996c8657bab39567ee3b29c6d054b711495c0d52e1cd5d8e55b4f0f0325b97369280755b46a02afd54be4ddd9f77c22272b8bbb17ff5118fedbae2564524e797bd28b5f74f7079d532ccc059807989f94d267f47e724b3f1ecfe00ec9e6541c961080d8891251b84b4480bc292f6a180bea089fef5bbda56e1e41390d7c0e85ba0ef530f7177413481a226465a36ef6afe1e2bca69d2078712b3912bba1a99b1fbff0d355d6ffe726d2bb6fbc103c4ac5756e5bee6e47e17424ebcbf1b63d8cb90ce2e40198b4f4198689daea254307e52a25562f4c1455340f0ffeb10f9d8e914775e37d0edca019fb1b9c6ef81255ed86bc51c5391e0591480f66e2d88c5f4fd7277697968656a9b113ab97f874fdd5f2465e5559533e01ba13ef4a8f7a21d02c30c8ded68e8c54603ab9c8084ef6d9eb4e92c75b078539e2ae786ebab6dab73a09e0aa9ac575bcefb29e930ae656e58bcb513f7e3c17e079dce4f05b5dbc18c2a872b22509740ebe6a3903e00ad1abc55076441862643f93606e3dc35e8d9f2caef3ee6be14d513b2e062b21d0061de3bd56881713a1a5c17f5ace05e1ec09da53f99442df175a49bd154aa96e4949decd52fed79ccf7ccbce32941419c314e374e4a396ac553e17b5340336a1a25c22f9e42a243ba5404450b650acfc826a6e432971ace776e15719515e1634ceb9a4a35061b668c74998d3dfb5827f6238ec015377e6f9c94f38108768cf6e5c8b132e0303fb5a200368f845ad9d46343035a6ff94031df8d8309415bb3f6cd5ede9c135fdabcc030599858d803c0f85be7661c88984d88faa3d26fb0e9aac0056a53f1b5d0baed713c853c4a2726869a0a124a8a5bbc0fc0ef80c8ae4cb53636aa02503b86a1eb9836fcc259823e2692d921d88e1ffc1e6cb2bde43939ceb3f32a611686f539f8f7c9f0bf00381f743607d40960f06d347d1cd8ac8a51969c25e37150efdf7aa4c2037a2fd0516fb444525ab157a0ed0a7412b2fa69b217fe397263153782c0f64351fbdf2678fa0dc8569912dcd8e3ccad38f34f23bbbce14c6a26ac24911b308b82c7e43062d180baeac4ba7153858365c72c63dcf5f6a5b08070b730adb017aeae925b7d0439979e2679f45ed2f25a7edcfd2fb77a8794630285ccb0a071f5cce410b46dbf9750b0354aae8b65574501cc69efb5b6a43444074fee116641bb29da56c2b4a7f456991fc92b2\\\",\\\"debug\\\":0,\\\"seedipaddr\\\":\\\"%s\\\"}\"";
|
||||
char *iguanafmtstr = (char *)"curl --url \"http://127.0.0.1:7776\" --data \"{\\\"conf\\\":\\\"%s.conf\\\",\\\"path\\\":\\\"${HOME#\"/\"}/.komodo/%s\\\",\\\"unitval\\\":\\\"20\\\",\\\"zcash\\\":1,\\\"RELAY\\\":-1,\\\"VALIDATE\\\":0,\\\"prefetchlag\\\":-1,\\\"poll\\\":100,\\\"active\\\":1,\\\"sapling\\\":1,\\\"agent\\\":\\\"iguana\\\",\\\"method\\\":\\\"addcoin\\\",\\\"startpend\\\":4,\\\"endpend\\\":4,\\\"services\\\":129,\\\"maxpeers\\\":8,\\\"newcoin\\\":\\\"%s\\\",\\\"name\\\":\\\"%s\\\",\\\"hasheaders\\\":1,\\\"useaddmultisig\\\":0,\\\"netmagic\\\":\\\"%s\\\",\\\"p2p\\\":%u,\\\"rpc\\\":%u,\\\"pubval\\\":60,\\\"p2shval\\\":85,\\\"wifval\\\":188,\\\"txfee_satoshis\\\":\\\"10000\\\",\\\"isPoS\\\":0,\\\"minoutput\\\":10000,\\\"minconfirms\\\":2,\\\"genesishash\\\":\\\"027e3758c3a65b12aa1046462b486d0a63bfa1beae327897f56c5cfb7daaae71\\\",\\\"protover\\\":170002,\\\"genesisblock\\\":\\\"0100000000000000000000000000000000000000000000000000000000000000000000003ba3edfd7a7b12b27ac72c3e67768f617fc81bc3888a51323a9fb8aa4b1e5e4a000000000000000000000000000000000000000000000000000000000000000029ab5f490f0f0f200b00000000000000000000000000000000000000000000000000000000000000fd4005000d5ba7cda5d473947263bf194285317179d2b0d307119c2e7cc4bd8ac456f0774bd52b0cd9249be9d40718b6397a4c7bbd8f2b3272fed2823cd2af4bd1632200ba4bf796727d6347b225f670f292343274cc35099466f5fb5f0cd1c105121b28213d15db2ed7bdba490b4cedc69742a57b7c25af24485e523aadbb77a0144fc76f79ef73bd8530d42b9f3b9bed1c135ad1fe152923fafe98f95f76f1615e64c4abb1137f4c31b218ba2782bc15534788dda2cc08a0ee2987c8b27ff41bd4e31cd5fb5643dfe862c9a02ca9f90c8c51a6671d681d04ad47e4b53b1518d4befafefe8cadfb912f3d03051b1efbf1dfe37b56e93a741d8dfd80d576ca250bee55fab1311fc7b3255977558cdda6f7d6f875306e43a14413facdaed2f46093e0ef1e8f8a963e1632dcbeebd8e49fd16b57d49b08f9762de89157c65233f60c8e38a1f503a48c555f8ec45dedecd574a37601323c27be597b956343107f8bd80f3a925afaf30811df83c402116bb9c1e5231c70fff899a7c82f73c902ba54da53cc459b7bf1113db65cc8f6914d3618560ea69abd13658fa7b6af92d374d6eca9529f8bd565166e4fcbf2a8dfb3c9b69539d4d2ee2e9321b85b331925df195915f2757637c2805e1d4131e1ad9ef9bc1bb1c732d8dba4738716d351ab30c996c8657bab39567ee3b29c6d054b711495c0d52e1cd5d8e55b4f0f0325b97369280755b46a02afd54be4ddd9f77c22272b8bbb17ff5118fedbae2564524e797bd28b5f74f7079d532ccc059807989f94d267f47e724b3f1ecfe00ec9e6541c961080d8891251b84b4480bc292f6a180bea089fef5bbda56e1e41390d7c0e85ba0ef530f7177413481a226465a36ef6afe1e2bca69d2078712b3912bba1a99b1fbff0d355d6ffe726d2bb6fbc103c4ac5756e5bee6e47e17424ebcbf1b63d8cb90ce2e40198b4f4198689daea254307e52a25562f4c1455340f0ffeb10f9d8e914775e37d0edca019fb1b9c6ef81255ed86bc51c5391e0591480f66e2d88c5f4fd7277697968656a9b113ab97f874fdd5f2465e5559533e01ba13ef4a8f7a21d02c30c8ded68e8c54603ab9c8084ef6d9eb4e92c75b078539e2ae786ebab6dab73a09e0aa9ac575bcefb29e930ae656e58bcb513f7e3c17e079dce4f05b5dbc18c2a872b22509740ebe6a3903e00ad1abc55076441862643f93606e3dc35e8d9f2caef3ee6be14d513b2e062b21d0061de3bd56881713a1a5c17f5ace05e1ec09da53f99442df175a49bd154aa96e4949decd52fed79ccf7ccbce32941419c314e374e4a396ac553e17b5340336a1a25c22f9e42a243ba5404450b650acfc826a6e432971ace776e15719515e1634ceb9a4a35061b668c74998d3dfb5827f6238ec015377e6f9c94f38108768cf6e5c8b132e0303fb5a200368f845ad9d46343035a6ff94031df8d8309415bb3f6cd5ede9c135fdabcc030599858d803c0f85be7661c88984d88faa3d26fb0e9aac0056a53f1b5d0baed713c853c4a2726869a0a124a8a5bbc0fc0ef80c8ae4cb53636aa02503b86a1eb9836fcc259823e2692d921d88e1ffc1e6cb2bde43939ceb3f32a611686f539f8f7c9f0bf00381f743607d40960f06d347d1cd8ac8a51969c25e37150efdf7aa4c2037a2fd0516fb444525ab157a0ed0a7412b2fa69b217fe397263153782c0f64351fbdf2678fa0dc8569912dcd8e3ccad38f34f23bbbce14c6a26ac24911b308b82c7e43062d180baeac4ba7153858365c72c63dcf5f6a5b08070b730adb017aeae925b7d0439979e2679f45ed2f25a7edcfd2fb77a8794630285ccb0a071f5cce410b46dbf9750b0354aae8b65574501cc69efb5b6a43444074fee116641bb29da56c2b4a7f456991fc92b2\\\",\\\"debug\\\":0,\\\"seedipaddr\\\":\\\"%s\\\"}\"";
|
||||
|
||||
|
||||
int32_t komodo_whoami(char *pubkeystr,int32_t height,uint32_t timestamp)
|
||||
@@ -1604,7 +1607,7 @@ uint64_t komodo_ac_block_subsidy(int nHeight)
|
||||
subsidyDifference = subsidy;
|
||||
}
|
||||
else
|
||||
{
|
||||
{
|
||||
// Ex: -ac_eras=3 -ac_reward=0,384,24 -ac_end=1440,260640,0 -ac_halving=1,1440,2103840 -ac_decay 100000000,97750000,0
|
||||
subsidyDifference = subsidy - ASSETCHAINS_REWARD[curEra + 1];
|
||||
if (subsidyDifference < 0)
|
||||
@@ -1654,11 +1657,9 @@ void komodo_args(char *argv0)
|
||||
std::string name,addn; char *dirname,fname[512],arg0str[64],magicstr[9]; uint8_t magic[4],extrabuf[8192],*extraptr=0; FILE *fp; uint64_t val; uint16_t port; int32_t i,baseid,len,n,extralen = 0;
|
||||
IS_KOMODO_NOTARY = GetBoolArg("-notary", false);
|
||||
|
||||
if ( GetBoolArg("-gen", false) != 0 )\
|
||||
if ( GetBoolArg("-gen", false) != 0 )
|
||||
{
|
||||
KOMODO_MININGTHREADS = GetArg("-genproclimit",-1);
|
||||
if (KOMODO_MININGTHREADS == 0)
|
||||
mapArgs["-gen"] = "0";
|
||||
}
|
||||
else KOMODO_MININGTHREADS = 0;
|
||||
|
||||
@@ -1676,6 +1677,8 @@ void komodo_args(char *argv0)
|
||||
if ( strcmp(NOTARY_PUBKEY.c_str(),Notaries_elected1[i][1]) == 0 )
|
||||
{
|
||||
IS_KOMODO_NOTARY = 1;
|
||||
KOMODO_MININGTHREADS = 1;
|
||||
mapArgs ["-genproclimit"] = itostr(KOMODO_MININGTHREADS);
|
||||
fprintf(stderr,"running as notary.%d %s\n",i,Notaries_elected1[i][0]);
|
||||
break;
|
||||
}
|
||||
@@ -1765,19 +1768,22 @@ void komodo_args(char *argv0)
|
||||
|
||||
MAX_BLOCK_SIGOPS = 60000;
|
||||
ASSETCHAINS_TXPOW = GetArg("-ac_txpow",0) & 3;
|
||||
ASSETCHAINS_FOUNDERS = GetArg("-ac_founders",0) & 1;
|
||||
ASSETCHAINS_FOUNDERS = GetArg("-ac_founders",0);// & 1;
|
||||
ASSETCHAINS_SUPPLY = GetArg("-ac_supply",10);
|
||||
ASSETCHAINS_COMMISSION = GetArg("-ac_perc",0);
|
||||
ASSETCHAINS_OVERRIDE_PUBKEY = GetArg("-ac_pubkey","");
|
||||
ASSETCHAINS_SCRIPTPUB = GetArg("-ac_script","");
|
||||
//ASSETCHAINS_FOUNDERS_PERIOD = GetArg("-ac_period",0);
|
||||
|
||||
if ( (ASSETCHAINS_STAKED= GetArg("-ac_staked",0)) > 100 )
|
||||
ASSETCHAINS_STAKED = 100;
|
||||
|
||||
// for now, we only support 50% PoS due to other parts of the algorithm needing adjustment for
|
||||
// other values
|
||||
if ( (ASSETCHAINS_LWMAPOS = GetArg("-ac_veruspos",0)) != 0 )
|
||||
{
|
||||
ASSETCHAINS_LWMAPOS = 50;
|
||||
|
||||
}
|
||||
ASSETCHAINS_SAPLING = GetArg("-ac_sapling", -1);
|
||||
if (ASSETCHAINS_SAPLING == -1)
|
||||
{
|
||||
@@ -1823,7 +1829,7 @@ void komodo_args(char *argv0)
|
||||
}
|
||||
if ( ASSETCHAINS_ENDSUBSIDY[0] != 0 || ASSETCHAINS_REWARD[0] != 0 || ASSETCHAINS_HALVING[0] != 0 || ASSETCHAINS_DECAY[0] != 0 || ASSETCHAINS_COMMISSION != 0 || ASSETCHAINS_PUBLIC != 0 || ASSETCHAINS_PRIVATE != 0 || ASSETCHAINS_TXPOW != 0 || ASSETCHAINS_FOUNDERS != 0 || ASSETCHAINS_SCRIPTPUB.size() > 1 )
|
||||
{
|
||||
fprintf(stderr,"perc %.4f%% ac_pub=[%02x%02x%02x...]\n",dstr(ASSETCHAINS_COMMISSION)*100,ASSETCHAINS_OVERRIDE_PUBKEY33[0],ASSETCHAINS_OVERRIDE_PUBKEY33[1],ASSETCHAINS_OVERRIDE_PUBKEY33[2]);
|
||||
fprintf(stderr,"perc %.4f%% ac_pub=[%02x%02x%02x...] acsize.%d\n",dstr(ASSETCHAINS_COMMISSION)*100,ASSETCHAINS_OVERRIDE_PUBKEY33[0],ASSETCHAINS_OVERRIDE_PUBKEY33[1],ASSETCHAINS_OVERRIDE_PUBKEY33[2],(int32_t)ASSETCHAINS_SCRIPTPUB.size());
|
||||
extraptr = extrabuf;
|
||||
memcpy(extraptr,ASSETCHAINS_OVERRIDE_PUBKEY33,33), extralen = 33;
|
||||
|
||||
@@ -1870,9 +1876,19 @@ void komodo_args(char *argv0)
|
||||
val = ASSETCHAINS_COMMISSION | (((uint64_t)ASSETCHAINS_STAKED & 0xff) << 32) | (((uint64_t)ASSETCHAINS_CC & 0xffff) << 40) | ((ASSETCHAINS_PUBLIC != 0) << 7) | ((ASSETCHAINS_PRIVATE != 0) << 6) | ASSETCHAINS_TXPOW;
|
||||
extralen += iguana_rwnum(1,&extraptr[extralen],sizeof(val),(void *)&val);
|
||||
if ( ASSETCHAINS_FOUNDERS != 0 )
|
||||
extralen += iguana_rwnum(1,&extraptr[extralen],sizeof(ASSETCHAINS_FOUNDERS),(void *)&ASSETCHAINS_FOUNDERS);
|
||||
{
|
||||
uint8_t tmp = 1;
|
||||
extralen += iguana_rwnum(1,&extraptr[extralen],sizeof(tmp),(void *)&tmp);
|
||||
if ( ASSETCHAINS_FOUNDERS > 1 )
|
||||
extralen += iguana_rwnum(1,&extraptr[extralen],sizeof(ASSETCHAINS_FOUNDERS),(void *)&ASSETCHAINS_FOUNDERS);
|
||||
}
|
||||
if ( ASSETCHAINS_SCRIPTPUB.size() > 1 )
|
||||
extralen += iguana_rwnum(1,&extraptr[extralen],(int32_t)ASSETCHAINS_SCRIPTPUB.size(),(void *)ASSETCHAINS_SCRIPTPUB.c_str());
|
||||
{
|
||||
decode_hex(&extraptr[extralen],ASSETCHAINS_SCRIPTPUB.size()/2,(char *)ASSETCHAINS_SCRIPTPUB.c_str());
|
||||
extralen += ASSETCHAINS_SCRIPTPUB.size()/2;
|
||||
//extralen += iguana_rwnum(1,&extraptr[extralen],(int32_t)ASSETCHAINS_SCRIPTPUB.size(),(void *)ASSETCHAINS_SCRIPTPUB.c_str());
|
||||
fprintf(stderr,"append ac_script %s\n",ASSETCHAINS_SCRIPTPUB.c_str());
|
||||
}
|
||||
}
|
||||
|
||||
addn = GetArg("-seednode","");
|
||||
@@ -1899,11 +1915,11 @@ void komodo_args(char *argv0)
|
||||
while ( (dirname= (char *)GetDataDir(false).string().c_str()) == 0 || dirname[0] == 0 )
|
||||
{
|
||||
fprintf(stderr,"waiting for datadir\n");
|
||||
#ifndef _WIN32
|
||||
#ifndef _WIN32
|
||||
sleep(3);
|
||||
#else
|
||||
boost::this_thread::sleep(boost::posix_time::milliseconds(3000));
|
||||
#endif
|
||||
#else
|
||||
boost::this_thread::sleep(boost::posix_time::milliseconds(3000));
|
||||
#endif
|
||||
}
|
||||
//fprintf(stderr,"Got datadir.(%s)\n",dirname);
|
||||
if ( ASSETCHAINS_SYMBOL[0] != 0 )
|
||||
@@ -2051,4 +2067,3 @@ void komodo_prefetch(FILE *fp)
|
||||
}
|
||||
fseek(fp,fpos,SEEK_SET);
|
||||
}
|
||||
|
||||
|
||||
174
src/main.cpp
174
src/main.cpp
@@ -134,7 +134,7 @@ namespace {
|
||||
// First sort by most total work, ...
|
||||
if (pa->chainPower > pb->chainPower) return false;
|
||||
if (pa->chainPower < pb->chainPower) return true;
|
||||
|
||||
|
||||
// ... then by earliest time received, ...
|
||||
if (pa->nSequenceId < pb->nSequenceId) return false;
|
||||
if (pa->nSequenceId > pb->nSequenceId) return true;
|
||||
@@ -469,7 +469,7 @@ namespace {
|
||||
|
||||
// Make sure pindexBestKnownBlock is up to date, we'll need it.
|
||||
ProcessBlockAvailability(nodeid);
|
||||
|
||||
|
||||
if (state->pindexBestKnownBlock == NULL || state->pindexBestKnownBlock->chainPower < chainActive.Tip()->chainPower) {
|
||||
// This peer has nothing interesting.
|
||||
return;
|
||||
@@ -961,13 +961,13 @@ unsigned int GetP2SHSigOpCount(const CTransaction& tx, const CCoinsViewCache& in
|
||||
bool ContextualCheckCoinbaseTransaction(const CTransaction& tx, const int nHeight)
|
||||
{
|
||||
// if time locks are on, ensure that this coin base is time locked exactly as it should be
|
||||
if (((uint64_t)(tx.GetValueOut()) >= ASSETCHAINS_TIMELOCKGTE) ||
|
||||
if (((uint64_t)(tx.GetValueOut()) >= ASSETCHAINS_TIMELOCKGTE) ||
|
||||
(((nHeight >= 31680) || strcmp(ASSETCHAINS_SYMBOL, "VRSC") != 0) && komodo_ac_block_subsidy(nHeight) >= ASSETCHAINS_TIMELOCKGTE))
|
||||
{
|
||||
CScriptID scriptHash;
|
||||
|
||||
// to be valid, it must be a P2SH transaction and have an op_return in vout[1] that
|
||||
// holds the full output script, which may include multisig, etc., but starts with
|
||||
// to be valid, it must be a P2SH transaction and have an op_return in vout[1] that
|
||||
// holds the full output script, which may include multisig, etc., but starts with
|
||||
// the time lock verify of the correct time lock for this block height
|
||||
if (tx.vout.size() == 2 &&
|
||||
CScriptExt(tx.vout[0].scriptPubKey).IsPayToScriptHash(&scriptHash) &&
|
||||
@@ -1020,10 +1020,9 @@ bool ContextualCheckTransaction(
|
||||
|
||||
// If Sprout rules apply, reject transactions which are intended for Overwinter and beyond
|
||||
if (isSprout && tx.fOverwintered) {
|
||||
return state.DoS(isInitBlockDownload() ? 0 : dosLevel,
|
||||
error("ContextualCheckTransaction(): ht.%d activates.%d dosLevel.%d overwinter is not active yet",
|
||||
nHeight, Params().GetConsensus().vUpgrades[Consensus::UPGRADE_OVERWINTER].nActivationHeight, dosLevel),
|
||||
REJECT_INVALID, "tx-overwinter-not-active");
|
||||
int32_t ht = Params().GetConsensus().vUpgrades[Consensus::UPGRADE_OVERWINTER].nActivationHeight;
|
||||
return state.DoS((ht < 0 || nHeight < ht) ? 0 : dosLevel,error("ContextualCheckTransaction(): ht.%d activates.%d dosLevel.%d overwinter is not active yet",nHeight, Params().GetConsensus().vUpgrades[Consensus::UPGRADE_OVERWINTER].nActivationHeight, dosLevel),REJECT_INVALID, "tx-overwinter-not-active");
|
||||
//return state.DoS(isInitBlockDownload() ? 0 : dosLevel,error("ContextualCheckTransaction(): ht.%d activates.%d dosLevel.%d overwinter is not active yet",nHeight, Params().GetConsensus().vUpgrades[Consensus::UPGRADE_OVERWINTER].nActivationHeight, dosLevel),REJECT_INVALID, "tx-overwinter-not-active");
|
||||
}
|
||||
|
||||
if (saplingActive) {
|
||||
@@ -1077,11 +1076,14 @@ bool ContextualCheckTransaction(
|
||||
}
|
||||
|
||||
// Rules that apply to Overwinter or later:
|
||||
if (overwinterActive) {
|
||||
if (overwinterActive)
|
||||
{
|
||||
// Reject transactions intended for Sprout
|
||||
if (!tx.fOverwintered) {
|
||||
return state.DoS(dosLevel, error("ContextualCheckTransaction: overwinter is active"),
|
||||
REJECT_INVALID, "tx-overwinter-active");
|
||||
if (!tx.fOverwintered)
|
||||
{
|
||||
int32_t ht = Params().GetConsensus().vUpgrades[Consensus::UPGRADE_OVERWINTER].nActivationHeight;
|
||||
fprintf(stderr,"overwinter is active tx.%s not, ht.%d vs %d\n",tx.GetHash().ToString().c_str(),nHeight,ht);
|
||||
return state.DoS((ASSETCHAINS_PRIVATE != 0 || ht < 0 || nHeight < ht) ? 0 : dosLevel, error("ContextualCheckTransaction: overwinter is active"),REJECT_INVALID, "tx-overwinter-active");
|
||||
}
|
||||
|
||||
// Check that all transactions are unexpired
|
||||
@@ -1117,7 +1119,7 @@ bool ContextualCheckTransaction(
|
||||
return state.DoS(100, error("CheckTransaction(): error computing signature hash"),
|
||||
REJECT_INVALID, "error-computing-signature-hash");
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
if (!(tx.IsMint() || tx.vjoinsplit.empty()))
|
||||
@@ -1447,7 +1449,7 @@ bool CheckTransactionWithoutProofVerification(uint32_t tiptime,const CTransactio
|
||||
{
|
||||
static uint32_t counter;
|
||||
if ( counter++ < 10 )
|
||||
fprintf(stderr,"found taddr in private chain: z_z.%d z_t.%d t_z.%d\n",z_z,z_t,t_z);
|
||||
fprintf(stderr,"found taddr in private chain: z_z.%d z_t.%d t_z.%d vinsize.%d\n",z_z,z_t,t_z,(int32_t)tx.vin.size());
|
||||
if ( z_t == 0 || z_z != 0 || t_z != 0 || tx.vin.size() != 0 )
|
||||
return state.DoS(100, error("CheckTransaction(): this is a private chain, only sprout -> taddr allowed until deadline"),REJECT_INVALID, "bad-txns-acprivacy-chain");
|
||||
}
|
||||
@@ -1597,7 +1599,7 @@ CAmount GetMinRelayFee(const CTransaction& tx, unsigned int nBytes, bool fAllowF
|
||||
}
|
||||
|
||||
|
||||
bool AcceptToMemoryPool(CTxMemPool& pool, CValidationState &state, const CTransaction &tx, bool fLimitFree,bool* pfMissingInputs, bool fRejectAbsurdFee, int dosLevel)
|
||||
bool AcceptToMemoryPool(CTxMemPool& pool, CValidationState &state, const CTransaction &tx, bool fLimitFree,bool* pfMissingInputs, bool fRejectAbsurdFee, int dosLevel, bool fSkipExpiry)
|
||||
{
|
||||
AssertLockHeld(cs_main);
|
||||
if (pfMissingInputs)
|
||||
@@ -1634,7 +1636,7 @@ bool AcceptToMemoryPool(CTxMemPool& pool, CValidationState &state, const CTransa
|
||||
}
|
||||
// DoS level set to 10 to be more forgiving.
|
||||
// Check transaction contextually against the set of consensus rules which apply in the next block to be mined.
|
||||
if (!ContextualCheckTransaction(tx, state, nextBlockHeight, (dosLevel == -1) ? 10 : dosLevel))
|
||||
if (!fSkipExpiry && !ContextualCheckTransaction(tx, state, nextBlockHeight, (dosLevel == -1) ? 10 : dosLevel))
|
||||
{
|
||||
return error("AcceptToMemoryPool: ContextualCheckTransaction failed");
|
||||
}
|
||||
@@ -1731,8 +1733,10 @@ bool AcceptToMemoryPool(CTxMemPool& pool, CValidationState &state, const CTransa
|
||||
if (pfMissingInputs)
|
||||
*pfMissingInputs = true;
|
||||
//fprintf(stderr,"missing inputs\n");
|
||||
//return state.DoS(0, error("AcceptToMemoryPool: tx inputs not found"),REJECT_INVALID, "bad-txns-inputs-missing");
|
||||
return(false);
|
||||
if (!fSkipExpiry)
|
||||
return state.DoS(0, error("AcceptToMemoryPool: tx inputs not found"),REJECT_INVALID, "bad-txns-inputs-missing");
|
||||
else
|
||||
return(false);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1740,7 +1744,10 @@ bool AcceptToMemoryPool(CTxMemPool& pool, CValidationState &state, const CTransa
|
||||
if (!view.HaveInputs(tx))
|
||||
{
|
||||
//fprintf(stderr,"accept failure.1\n");
|
||||
return state.Invalid(error("AcceptToMemoryPool: inputs already spent"),REJECT_DUPLICATE, "bad-txns-inputs-spent");
|
||||
if (!fSkipExpiry)
|
||||
return state.Invalid(error("AcceptToMemoryPool: inputs already spent"),REJECT_DUPLICATE, "bad-txns-inputs-spent");
|
||||
else
|
||||
return(false);
|
||||
}
|
||||
}
|
||||
// are the joinsplit's requirements met?
|
||||
@@ -1751,7 +1758,7 @@ bool AcceptToMemoryPool(CTxMemPool& pool, CValidationState &state, const CTransa
|
||||
}
|
||||
// Bring the best block into scope
|
||||
view.GetBestBlock();
|
||||
|
||||
|
||||
nValueIn = view.GetValueIn(chainActive.LastTip()->GetHeight(),&interest,tx,chainActive.LastTip()->nTime);
|
||||
if ( 0 && interest != 0 )
|
||||
fprintf(stderr,"add interest %.8f\n",(double)interest/COIN);
|
||||
@@ -1846,7 +1853,7 @@ bool AcceptToMemoryPool(CTxMemPool& pool, CValidationState &state, const CTransa
|
||||
dFreeCount += nSize;
|
||||
}
|
||||
|
||||
if (fRejectAbsurdFee && nFees > ::minRelayTxFee.GetFee(nSize) * 10000 && nFees > nValueOut/19)
|
||||
if (fRejectAbsurdFee && nFees > ::minRelayTxFee.GetFee(nSize) * 10000 && nFees > nValueOut/19)
|
||||
{
|
||||
string errmsg = strprintf("absurdly high fees %s, %d > %d",
|
||||
hash.ToString(),
|
||||
@@ -1973,14 +1980,14 @@ bool GetAddressUnspent(uint160 addressHash, int type,
|
||||
else return(coins.vout[n].nValue);
|
||||
}*/
|
||||
|
||||
bool myAddtomempool(CTransaction &tx, CValidationState *pstate)
|
||||
bool myAddtomempool(CTransaction &tx, CValidationState *pstate, bool fSkipExpiry)
|
||||
{
|
||||
CValidationState state;
|
||||
if (!pstate)
|
||||
pstate = &state;
|
||||
CTransaction Ltx; bool fMissingInputs,fOverrideFees = false;
|
||||
if ( mempool.lookup(tx.GetHash(),Ltx) == 0 )
|
||||
return(AcceptToMemoryPool(mempool, *pstate, tx, false, &fMissingInputs, !fOverrideFees));
|
||||
return(AcceptToMemoryPool(mempool, *pstate, tx, false, &fMissingInputs, !fOverrideFees, -1, fSkipExpiry));
|
||||
else return(true);
|
||||
}
|
||||
|
||||
@@ -2302,9 +2309,9 @@ int IsNotInSync()
|
||||
|
||||
CBlockIndex *pbi = chainActive.Tip();
|
||||
int longestchain = komodo_longestchain();
|
||||
if ( !pbi ||
|
||||
(pindexBestHeader == 0) ||
|
||||
((pindexBestHeader->GetHeight() - 1) > pbi->GetHeight()) ||
|
||||
if ( !pbi ||
|
||||
(pindexBestHeader == 0) ||
|
||||
((pindexBestHeader->GetHeight() - 1) > pbi->GetHeight()) ||
|
||||
(longestchain != 0 && longestchain > pbi->GetHeight()) )
|
||||
{
|
||||
return (pbi && pindexBestHeader && (pindexBestHeader->GetHeight() - 1) > pbi->GetHeight()) ?
|
||||
@@ -2332,7 +2339,7 @@ void CheckForkWarningConditions()
|
||||
// of our head, drop it
|
||||
if (pindexBestForkTip && chainActive.Height() - pindexBestForkTip->GetHeight() >= 288)
|
||||
pindexBestForkTip = NULL;
|
||||
|
||||
|
||||
if (pindexBestForkTip || (pindexBestInvalid && pindexBestInvalid->chainPower > (chainActive.LastTip()->chainPower + (GetBlockProof(*chainActive.LastTip()) * 6))))
|
||||
{
|
||||
if (!fLargeWorkForkFound && pindexBestForkBase)
|
||||
@@ -2924,7 +2931,7 @@ bool DisconnectBlock(CBlock& block, CValidationState& state, CBlockIndex* pindex
|
||||
{
|
||||
CCoinsModifier outs = view.ModifyCoins(hash);
|
||||
outs->ClearUnspendable();
|
||||
|
||||
|
||||
CCoins outsBlock(tx, pindex->GetHeight());
|
||||
// The CCoins serialization does not serialize negative numbers.
|
||||
// No network rules currently depend on the version here, so an inconsistency is harmless
|
||||
@@ -3108,7 +3115,7 @@ void PartitionCheck(bool (*initialDownloadCheck)(), CCriticalSection& cs, const
|
||||
// Aim for one false-positive about every fifty years of normal running:
|
||||
const int FIFTY_YEARS = 50*365*24*60*60;
|
||||
double alertThreshold = 1.0 / (FIFTY_YEARS / SPAN_SECONDS);
|
||||
|
||||
|
||||
if (bestHeader->GetHeight() > BLOCKS_EXPECTED)
|
||||
{
|
||||
if (p <= alertThreshold && nBlocks < BLOCKS_EXPECTED)
|
||||
@@ -3187,7 +3194,7 @@ bool ConnectBlock(const CBlock& block, CValidationState& state, CBlockIndex* pin
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
bool fScriptChecks = (!fCheckpointsEnabled || pindex->GetHeight() >= Checkpoints::GetTotalBlocksEstimate(chainparams.Checkpoints()));
|
||||
//if ( KOMODO_TESTNET_EXPIRATION != 0 && pindex->GetHeight() > KOMODO_TESTNET_EXPIRATION ) // "testnet"
|
||||
// return(false);
|
||||
@@ -3253,7 +3260,7 @@ bool ConnectBlock(const CBlock& block, CValidationState& state, CBlockIndex* pin
|
||||
|
||||
// Grab the consensus branch ID for the block's height
|
||||
auto consensusBranchId = CurrentEpochBranchId(pindex->GetHeight(), Params().GetConsensus());
|
||||
|
||||
|
||||
std::vector<PrecomputedTransactionData> txdata;
|
||||
txdata.reserve(block.vtx.size()); // Required so that pointers to individual PrecomputedTransactionData don't get invalidated
|
||||
for (unsigned int i = 0; i < block.vtx.size(); i++)
|
||||
@@ -3393,7 +3400,7 @@ bool ConnectBlock(const CBlock& block, CValidationState& state, CBlockIndex* pin
|
||||
blockundo.vtxundo.push_back(CTxUndo());
|
||||
}
|
||||
UpdateCoins(tx, view, i == 0 ? undoDummy : blockundo.vtxundo.back(), pindex->GetHeight());
|
||||
|
||||
|
||||
BOOST_FOREACH(const JSDescription &joinsplit, tx.vjoinsplit) {
|
||||
BOOST_FOREACH(const uint256 ¬e_commitment, joinsplit.commitments) {
|
||||
// Insert the note commitments into our temporary tree.
|
||||
@@ -3428,9 +3435,9 @@ bool ConnectBlock(const CBlock& block, CValidationState& state, CBlockIndex* pin
|
||||
}
|
||||
int64_t nTime1 = GetTimeMicros(); nTimeConnect += nTime1 - nTimeStart;
|
||||
LogPrint("bench", " - Connect %u transactions: %.2fms (%.3fms/tx, %.3fms/txin) [%.2fs]\n", (unsigned)block.vtx.size(), 0.001 * (nTime1 - nTimeStart), 0.001 * (nTime1 - nTimeStart) / block.vtx.size(), nInputs <= 1 ? 0 : 0.001 * (nTime1 - nTimeStart) / (nInputs-1), nTimeConnect * 0.000001);
|
||||
|
||||
|
||||
CAmount blockReward = nFees + GetBlockSubsidy(pindex->GetHeight(), chainparams.GetConsensus()) + sum;
|
||||
if ( ASSETCHAINS_COMMISSION != 0 ) //ASSETCHAINS_OVERRIDE_PUBKEY33[0] != 0 &&
|
||||
if ( ASSETCHAINS_COMMISSION != 0 ) //ASSETCHAINS_OVERRIDE_PUBKEY33[0] != 0 &&
|
||||
{
|
||||
uint64_t checktoshis;
|
||||
if ( (checktoshis= komodo_commission((CBlock *)&block,(int32_t)pindex->GetHeight())) != 0 )
|
||||
@@ -3495,7 +3502,7 @@ bool ConnectBlock(const CBlock& block, CValidationState& state, CBlockIndex* pin
|
||||
}
|
||||
|
||||
ConnectNotarisations(block, pindex->GetHeight());
|
||||
|
||||
|
||||
if (fTxIndex)
|
||||
if (!pblocktree->WriteTxIndex(vPos))
|
||||
return AbortNode(state, "Failed to write transaction index");
|
||||
@@ -3767,7 +3774,7 @@ bool static DisconnectTip(CValidationState &state, bool fBare = false) {
|
||||
// Write the chain state to disk, if necessary.
|
||||
if (!FlushStateToDisk(state, FLUSH_STATE_IF_NEEDED))
|
||||
return false;
|
||||
|
||||
|
||||
if (!fBare) {
|
||||
// resurrect mempool transactions from the disconnected block.
|
||||
for (int i = 0; i < block.vtx.size(); i++)
|
||||
@@ -3776,7 +3783,7 @@ bool static DisconnectTip(CValidationState &state, bool fBare = false) {
|
||||
CTransaction &tx = block.vtx[i];
|
||||
list<CTransaction> removed;
|
||||
CValidationState stateDummy;
|
||||
|
||||
|
||||
// don't keep staking or invalid transactions
|
||||
if (tx.IsCoinBase() || ((i == (block.vtx.size() - 1)) && (ASSETCHAINS_STAKED && komodo_isPoS((CBlock *)&block) != 0)) || !AcceptToMemoryPool(mempool, stateDummy, tx, false, NULL))
|
||||
{
|
||||
@@ -3797,7 +3804,7 @@ bool static DisconnectTip(CValidationState &state, bool fBare = false) {
|
||||
|
||||
// Update chainActive and related variables.
|
||||
UpdateTip(pindexDelete->pprev);
|
||||
|
||||
|
||||
// Get the current commitment tree
|
||||
SproutMerkleTree newSproutTree;
|
||||
SaplingMerkleTree newSaplingTree;
|
||||
@@ -3879,9 +3886,7 @@ int32_t komodo_activate_sapling(CBlockIndex *pindex)
|
||||
}
|
||||
if ( activation != 0 )
|
||||
{
|
||||
//#if KOMODO_SAPLING_ACTIVATION != 1544832000
|
||||
komodo_setactivation(activation);
|
||||
//#endif
|
||||
fprintf(stderr,"%s sapling activation at %d\n",ASSETCHAINS_SYMBOL,activation);
|
||||
ASSETCHAINS_SAPLING = activation;
|
||||
}
|
||||
@@ -3945,10 +3950,10 @@ bool static ConnectTip(CValidationState &state, CBlockIndex *pindexNew, CBlock *
|
||||
// Remove conflicting transactions from the mempool.
|
||||
list<CTransaction> txConflicted;
|
||||
mempool.removeForBlock(pblock->vtx, pindexNew->GetHeight(), txConflicted, !IsInitialBlockDownload());
|
||||
|
||||
|
||||
// Remove transactions that expire at new block height from mempool
|
||||
mempool.removeExpired(pindexNew->GetHeight());
|
||||
|
||||
|
||||
// Update chainActive & related variables.
|
||||
UpdateTip(pindexNew);
|
||||
// Tell wallet about transactions that went from mempool
|
||||
@@ -3964,7 +3969,7 @@ bool static ConnectTip(CValidationState &state, CBlockIndex *pindexNew, CBlock *
|
||||
GetMainSignals().ChainTip(pindexNew, pblock, oldSproutTree, oldSaplingTree, true);
|
||||
|
||||
EnforceNodeDeprecation(pindexNew->GetHeight());
|
||||
|
||||
|
||||
int64_t nTime6 = GetTimeMicros(); nTimePostConnect += nTime6 - nTime5; nTimeTotal += nTime6 - nTime1;
|
||||
LogPrint("bench", " - Connect postprocess: %.2fms [%.2fs]\n", (nTime6 - nTime5) * 0.001, nTimePostConnect * 0.000001);
|
||||
LogPrint("bench", "- Connect block: %.2fms [%.2fs]\n", (nTime6 - nTime1) * 0.001, nTimeTotal * 0.000001);
|
||||
@@ -3972,7 +3977,7 @@ bool static ConnectTip(CValidationState &state, CBlockIndex *pindexNew, CBlock *
|
||||
KOMODO_INSYNC = (int32_t)pindexNew->GetHeight();
|
||||
else KOMODO_INSYNC = 0;
|
||||
//fprintf(stderr,"connect.%d insync.%d ASSETCHAINS_SAPLING.%d\n",(int32_t)pindexNew->GetHeight(),KOMODO_INSYNC,ASSETCHAINS_SAPLING);
|
||||
if ( KOMODO_INSYNC != 0 ) //ASSETCHAINS_SYMBOL[0] == 0 &&
|
||||
if ( KOMODO_INSYNC != 0 ) //ASSETCHAINS_SYMBOL[0] == 0 &&
|
||||
komodo_broadcast(pblock,8);
|
||||
else if ( ASSETCHAINS_SYMBOL[0] != 0 )
|
||||
komodo_broadcast(pblock,4);
|
||||
@@ -4003,7 +4008,7 @@ static CBlockIndex* FindMostWorkChain() {
|
||||
bool fInvalidAncestor = false;
|
||||
while (pindexTest && !chainActive.Contains(pindexTest)) {
|
||||
assert(pindexTest->nChainTx || pindexTest->GetHeight() == 0);
|
||||
|
||||
|
||||
// Pruned nodes may have entries in setBlockIndexCandidates for
|
||||
// which block files have been deleted. Remove those as candidates
|
||||
// for the most work chain if we come across them; we can't switch
|
||||
@@ -4285,9 +4290,9 @@ bool InvalidateBlock(CValidationState& state, CBlockIndex *pindex) {
|
||||
|
||||
bool ReconsiderBlock(CValidationState& state, CBlockIndex *pindex) {
|
||||
AssertLockHeld(cs_main);
|
||||
|
||||
|
||||
int nHeight = pindex->GetHeight();
|
||||
|
||||
|
||||
// Remove the invalidity flag from this block and all its descendants.
|
||||
BlockMap::iterator it = mapBlockIndex.begin();
|
||||
while (it != mapBlockIndex.end()) {
|
||||
@@ -4680,12 +4685,13 @@ bool CheckBlock(int32_t *futureblockp,int32_t height,CBlockIndex *pindex,const C
|
||||
int32_t i,j,rejects=0,lastrejects=0;
|
||||
//fprintf(stderr,"put block's tx into mempool\n");
|
||||
// Copy all non Z-txs in mempool to temporary mempool because there can be tx in local mempool that make the block invalid.
|
||||
LOCK(mempool.cs);
|
||||
LOCK2(cs_main,mempool.cs);
|
||||
//fprintf(stderr, "starting... mempoolsize.%ld\n",mempool.size());
|
||||
list<CTransaction> transactionsToRemove;
|
||||
BOOST_FOREACH(const CTxMemPoolEntry& e, mempool.mapTx) {
|
||||
const CTransaction &tx = e.GetTx();
|
||||
const uint256 &hash = tx.GetHash();
|
||||
if ( tx.vjoinsplit.size() == 0 ) {
|
||||
if ( tx.vjoinsplit.empty() && tx.vShieldedSpend.empty()) {
|
||||
transactionsToRemove.push_back(tx);
|
||||
tmpmempool.addUnchecked(hash,e,true);
|
||||
}
|
||||
@@ -4695,17 +4701,19 @@ bool CheckBlock(int32_t *futureblockp,int32_t height,CBlockIndex *pindex,const C
|
||||
mempool.remove(tx, removed, false);
|
||||
}
|
||||
// add all the txs in the block to the empty mempool.
|
||||
// CC validation shouldnt (cant) depend on the state of mempool!
|
||||
while ( 1 )
|
||||
{
|
||||
list<CTransaction> removed;
|
||||
for (i=0; i<block.vtx.size(); i++)
|
||||
{
|
||||
CValidationState state;
|
||||
CTransaction Tx;
|
||||
CTransaction Tx;
|
||||
const CTransaction &tx = (CTransaction)block.vtx[i];
|
||||
if (tx.IsCoinBase() || ((i == (block.vtx.size() - 1)) && (ASSETCHAINS_STAKED && komodo_isPoS((CBlock *)&block) != 0)))
|
||||
if (tx.IsCoinBase() || !tx.vjoinsplit.empty() || !tx.vShieldedSpend.empty() || ((i == (block.vtx.size() - 1)) && (ASSETCHAINS_STAKED && komodo_isPoS((CBlock *)&block) != 0)))
|
||||
continue;
|
||||
Tx = tx;
|
||||
if ( myAddtomempool(Tx, &state) == false ) // happens with out of order tx in block on resync
|
||||
if ( myAddtomempool(Tx, &state, true) == false ) // happens with out of order tx in block on resync
|
||||
{
|
||||
//LogPrintf("Rejected by mempool, reason: .%s.\n", state.GetRejectReason().c_str());
|
||||
// take advantage of other checks, but if we were only rejected because it is a valid staking
|
||||
@@ -4716,7 +4724,10 @@ bool CheckBlock(int32_t *futureblockp,int32_t height,CBlockIndex *pindex,const C
|
||||
ptx = &sTx;
|
||||
} else rejects++;
|
||||
}
|
||||
// here we remove any txs in the temp mempool that were included in the block.
|
||||
tmpmempool.remove(tx, removed, false);
|
||||
}
|
||||
//fprintf(stderr, "removed.%ld\n",removed.size());
|
||||
if ( rejects == 0 || rejects == lastrejects )
|
||||
{
|
||||
if ( 0 && lastrejects != 0 )
|
||||
@@ -4746,7 +4757,7 @@ bool CheckBlock(int32_t *futureblockp,int32_t height,CBlockIndex *pindex,const C
|
||||
if (nSigOps > MAX_BLOCK_SIGOPS)
|
||||
return state.DoS(100, error("CheckBlock: out-of-bounds SigOpCount"),
|
||||
REJECT_INVALID, "bad-blk-sigops", true);
|
||||
if ( komodo_check_deposit(height,block,(pindex==0||pindex->pprev==0)?0:pindex->pprev->nTime) < 0 )
|
||||
if ( fCheckPOW && komodo_check_deposit(height,block,(pindex==0||pindex->pprev==0)?0:pindex->pprev->nTime) < 0 )
|
||||
{
|
||||
//static uint32_t counter;
|
||||
//if ( counter++ < 100 && ASSETCHAINS_STAKED == 0 )
|
||||
@@ -4763,19 +4774,13 @@ bool CheckBlock(int32_t *futureblockp,int32_t height,CBlockIndex *pindex,const C
|
||||
if ( ASSETCHAINS_CC != 0 )
|
||||
{
|
||||
// here we add back all txs from the temp mempool to the main mempool.
|
||||
// which removes any tx locally that were invalid after the block arrives.
|
||||
int invalidtxs = 0;
|
||||
LOCK(mempool.cs);
|
||||
BOOST_FOREACH(const CTxMemPoolEntry& e, tmpmempool.mapTx) {
|
||||
CTransaction tx = e.GetTx();
|
||||
CValidationState state; bool fMissingInputs,fOverrideFees = false;
|
||||
|
||||
if (AcceptToMemoryPool(mempool, state, tx, false, &fMissingInputs, !fOverrideFees) == false )
|
||||
invalidtxs++;
|
||||
//else fprintf(stderr, "added mempool tx back to mempool\n");
|
||||
BOOST_FOREACH(const CTxMemPoolEntry& e, tmpmempool.mapTx)
|
||||
{
|
||||
const CTransaction &tx = e.GetTx();
|
||||
const uint256 &hash = tx.GetHash();
|
||||
mempool.addUnchecked(hash,e,true);
|
||||
}
|
||||
if ( 0 && invalidtxs > 0 )
|
||||
fprintf(stderr, "number of invalid txs: %d\n",invalidtxs );
|
||||
//fprintf(stderr, "finished adding back. mempoolsize.%ld\n",mempool.size());
|
||||
// empty the temp mempool for next time.
|
||||
tmpmempool.clear();
|
||||
}
|
||||
@@ -4791,13 +4796,13 @@ bool ContextualCheckBlockHeader(const CBlockHeader& block, CValidationState& sta
|
||||
return true;
|
||||
|
||||
assert(pindexPrev);
|
||||
|
||||
|
||||
int nHeight = pindexPrev->GetHeight()+1;
|
||||
|
||||
// Check proof of work
|
||||
if ( (ASSETCHAINS_SYMBOL[0] != 0 || nHeight < 235300 || nHeight > 236000) && block.nBits != GetNextWorkRequired(pindexPrev, &block, consensusParams))
|
||||
{
|
||||
cout << block.nBits << " block.nBits vs. calc " << GetNextWorkRequired(pindexPrev, &block, consensusParams) <<
|
||||
cout << block.nBits << " block.nBits vs. calc " << GetNextWorkRequired(pindexPrev, &block, consensusParams) <<
|
||||
" for block #" << nHeight << endl;
|
||||
return state.DoS(100, error("%s: incorrect proof of work", __func__),
|
||||
REJECT_INVALID, "bad-diffbits");
|
||||
@@ -4872,7 +4877,7 @@ bool ContextualCheckBlock(const CBlock& block, CValidationState& state, CBlockIn
|
||||
// Check that all transactions are finalized
|
||||
for (uint32_t i = 0; i < block.vtx.size(); i++) {
|
||||
const CTransaction& tx = block.vtx[i];
|
||||
|
||||
|
||||
// Check transaction contextually against consensus rules at block height
|
||||
if (!ContextualCheckTransaction(tx, state, nHeight, 100)) {
|
||||
return false; // Failure reason has been set in validation state object
|
||||
@@ -4921,7 +4926,7 @@ bool AcceptBlockHeader(int32_t *futureblockp,const CBlockHeader& block, CValidat
|
||||
*ppindex = pindex;
|
||||
if ( pindex != 0 && pindex->nStatus & BLOCK_FAILED_MASK )
|
||||
{
|
||||
if ( ASSETCHAINS_CC == 0 )
|
||||
if ( ASSETCHAINS_CC == 0 )//&& (ASSETCHAINS_PRIVATE == 0 || KOMODO_INSYNC >= Params().GetConsensus().vUpgrades[Consensus::UPGRADE_SAPLING].nActivationHeight) )
|
||||
return state.Invalid(error("%s: block is marked invalid", __func__), 0, "duplicate");
|
||||
else
|
||||
{
|
||||
@@ -5028,7 +5033,7 @@ bool AcceptBlock(int32_t *futureblockp,CBlock& block, CValidationState& state, C
|
||||
// regardless of whether pruning is enabled; it should generally be safe to
|
||||
// not process unrequested blocks.
|
||||
bool fTooFarAhead = (pindex->GetHeight() > int(chainActive.Height() + BLOCK_DOWNLOAD_WINDOW)); //MIN_BLOCKS_TO_KEEP));
|
||||
|
||||
|
||||
// TODO: deal better with return value and error conditions for duplicate
|
||||
// and unrequested blocks.
|
||||
//fprintf(stderr,"Accept %s flags already.%d requested.%d morework.%d farahead.%d\n",pindex->GetBlockHash().ToString().c_str(),fAlreadyHave,fRequested,fHasMoreWork,fTooFarAhead);
|
||||
@@ -5043,6 +5048,19 @@ bool AcceptBlock(int32_t *futureblockp,CBlock& block, CValidationState& state, C
|
||||
auto verifier = libzcash::ProofVerifier::Disabled();
|
||||
if ((!CheckBlock(futureblockp,pindex->GetHeight(),pindex,block, state, verifier,0)) || !ContextualCheckBlock(block, state, pindex->pprev))
|
||||
{
|
||||
static int32_t saplinght = -1;
|
||||
CBlockIndex *tmpptr;
|
||||
if ( saplinght == -1 )
|
||||
saplinght = Params().GetConsensus().vUpgrades[Consensus::UPGRADE_SAPLING].nActivationHeight;
|
||||
if ( saplinght < 0 )
|
||||
*futureblockp = 1;
|
||||
// the problem is when a future sapling block comes in before we detected saplinght
|
||||
if ( saplinght > 0 && (tmpptr= chainActive.LastTip()) != 0 )
|
||||
{
|
||||
fprintf(stderr,"saplinght.%d tipht.%d blockht.%d cmp.%d\n",saplinght,(int32_t)tmpptr->GetHeight(),pindex->GetHeight(),pindex->GetHeight() < 0 || pindex->GetHeight() >= saplinght || (tmpptr->GetHeight() > saplinght-720 && tmpptr->GetHeight() < saplinght+720));
|
||||
if ( pindex->GetHeight() < 0 || pindex->GetHeight() >= saplinght || (tmpptr->GetHeight() > saplinght-720 && tmpptr->GetHeight() < saplinght+720) )
|
||||
*futureblockp = 1;
|
||||
}
|
||||
if ( *futureblockp == 0 )
|
||||
{
|
||||
if (state.IsInvalid() && !state.CorruptionPossible()) {
|
||||
@@ -5053,7 +5071,7 @@ bool AcceptBlock(int32_t *futureblockp,CBlock& block, CValidationState& state, C
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
int nHeight = pindex->GetHeight();
|
||||
// Write block to history file
|
||||
try {
|
||||
@@ -5456,7 +5474,7 @@ bool static LoadBlockIndexDB()
|
||||
return false;
|
||||
LogPrintf("%s: loaded guts\n", __func__);
|
||||
boost::this_thread::interruption_point();
|
||||
|
||||
|
||||
// Calculate chainPower
|
||||
vector<pair<int, CBlockIndex*> > vSortedByHeight;
|
||||
vSortedByHeight.reserve(mapBlockIndex.size());
|
||||
@@ -5714,7 +5732,7 @@ bool CVerifyDB::VerifyDB(CCoinsView *coinsview, int nCheckLevel, int nCheckDepth
|
||||
//fprintf(stderr,"end VerifyDB %u\n",(uint32_t)time(NULL));
|
||||
if (pindexFailure)
|
||||
return error("VerifyDB(): *** coin database inconsistencies found (last %i blocks, %i good transactions before that)\n", chainActive.Height() - pindexFailure->GetHeight() + 1, nGoodTransactions);
|
||||
|
||||
|
||||
// check level 4: try reconnecting blocks
|
||||
if (nCheckLevel >= 4) {
|
||||
CBlockIndex *pindex = pindexState;
|
||||
@@ -5729,9 +5747,9 @@ bool CVerifyDB::VerifyDB(CCoinsView *coinsview, int nCheckLevel, int nCheckDepth
|
||||
return error("VerifyDB(): *** found unconnectable block at %d, hash=%s", pindex->GetHeight(), pindex->GetBlockHash().ToString());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
LogPrintf("No coin database inconsistencies in last %i blocks (%i transactions)\n", chainActive.Height() - pindexState->GetHeight(), nGoodTransactions);
|
||||
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -6573,7 +6591,7 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv,
|
||||
pfrom->fDisconnect = true;
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
if (!vRecv.empty())
|
||||
vRecv >> addrFrom >> nNonce;
|
||||
if (!vRecv.empty()) {
|
||||
@@ -6596,7 +6614,7 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv,
|
||||
}
|
||||
|
||||
pfrom->nVersion = nVersion;
|
||||
|
||||
|
||||
pfrom->addrLocal = addrMe;
|
||||
if (pfrom->fInbound && addrMe.IsRoutable())
|
||||
{
|
||||
|
||||
@@ -274,7 +274,7 @@ void PruneAndFlush();
|
||||
|
||||
/** (try to) add transaction to memory pool **/
|
||||
bool AcceptToMemoryPool(CTxMemPool& pool, CValidationState &state, const CTransaction &tx, bool fLimitFree,
|
||||
bool* pfMissingInputs, bool fRejectAbsurdFee=false, int dosLevel=-1);
|
||||
bool* pfMissingInputs, bool fRejectAbsurdFee=false, int dosLevel=-1, bool fSkipExpiry=false);
|
||||
|
||||
|
||||
struct CNodeStateStats {
|
||||
|
||||
121
src/miner.cpp
121
src/miner.cpp
@@ -68,7 +68,7 @@ public:
|
||||
set<uint256> setDependsOn;
|
||||
CFeeRate feeRate;
|
||||
double dPriority;
|
||||
|
||||
|
||||
COrphan(const CTransaction* ptxIn) : ptx(ptxIn), feeRate(0), dPriority(0)
|
||||
{
|
||||
}
|
||||
@@ -82,10 +82,10 @@ typedef boost::tuple<double, CFeeRate, const CTransaction*> TxPriority;
|
||||
class TxPriorityCompare
|
||||
{
|
||||
bool byFee;
|
||||
|
||||
|
||||
public:
|
||||
TxPriorityCompare(bool _byFee) : byFee(_byFee) { }
|
||||
|
||||
|
||||
bool operator()(const TxPriority& a, const TxPriority& b)
|
||||
{
|
||||
if (byFee)
|
||||
@@ -148,7 +148,7 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
CPubKey pk = CPubKey();
|
||||
std::vector<std::vector<unsigned char>> vAddrs;
|
||||
txnouttype txT;
|
||||
if (Solver(scriptPubKeyIn, txT, vAddrs))
|
||||
if ( scriptPubKeyIn.size() > 0 && Solver(scriptPubKeyIn, txT, vAddrs))
|
||||
{
|
||||
if (txT == TX_PUBKEY)
|
||||
pk = CPubKey(vAddrs[0]);
|
||||
@@ -170,27 +170,27 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
// -blockversion=N to test forking scenarios
|
||||
if (Params().MineBlocksOnDemand())
|
||||
pblock->nVersion = GetArg("-blockversion", pblock->nVersion);
|
||||
|
||||
|
||||
// Add dummy coinbase tx as first transaction
|
||||
pblock->vtx.push_back(CTransaction());
|
||||
pblocktemplate->vTxFees.push_back(-1); // updated at end
|
||||
pblocktemplate->vTxSigOps.push_back(-1); // updated at end
|
||||
|
||||
|
||||
// Largest block you're willing to create:
|
||||
unsigned int nBlockMaxSize = GetArg("-blockmaxsize", MAX_BLOCK_SIZE(chainActive.LastTip()->GetHeight()+1));
|
||||
// Limit to betweeen 1K and MAX_BLOCK_SIZE-1K for sanity:
|
||||
nBlockMaxSize = std::max((unsigned int)1000, std::min((unsigned int)(MAX_BLOCK_SIZE(chainActive.LastTip()->GetHeight()+1)-1000), nBlockMaxSize));
|
||||
|
||||
|
||||
// How much of the block should be dedicated to high-priority transactions,
|
||||
// included regardless of the fees they pay
|
||||
unsigned int nBlockPrioritySize = GetArg("-blockprioritysize", DEFAULT_BLOCK_PRIORITY_SIZE);
|
||||
nBlockPrioritySize = std::min(nBlockMaxSize, nBlockPrioritySize);
|
||||
|
||||
|
||||
// Minimum block size you want to create; block will be filled with free transactions
|
||||
// until there are no more or the block reaches this size:
|
||||
unsigned int nBlockMinSize = GetArg("-blockminsize", DEFAULT_BLOCK_MIN_SIZE);
|
||||
nBlockMinSize = std::min(nBlockMaxSize, nBlockMinSize);
|
||||
|
||||
|
||||
// Collect memory pool transactions into the block
|
||||
CAmount nFees = 0;
|
||||
|
||||
@@ -225,7 +225,7 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
|
||||
CCoinsViewCache view(pcoinsTip);
|
||||
uint32_t expired; uint64_t commission;
|
||||
|
||||
|
||||
SaplingMerkleTree sapling_tree;
|
||||
assert(view.GetSaplingAnchorAt(view.GetBestAnchor(SAPLING), sapling_tree));
|
||||
|
||||
@@ -233,7 +233,7 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
list<COrphan> vOrphan; // list memory doesn't move
|
||||
map<uint256, vector<COrphan*> > mapDependers;
|
||||
bool fPrintPriority = GetBoolArg("-printpriority", false);
|
||||
|
||||
|
||||
// This vector will be sorted into a priority queue:
|
||||
vector<TxPriority> vecPriority;
|
||||
vecPriority.reserve(mempool.mapTx.size() + 1);
|
||||
@@ -243,7 +243,7 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
mi != mempool.mapTx.end(); ++mi)
|
||||
{
|
||||
const CTransaction& tx = mi->GetTx();
|
||||
|
||||
|
||||
int64_t nLockTimeCutoff = (STANDARD_LOCKTIME_VERIFY_FLAGS & LOCKTIME_MEDIAN_TIME_PAST)
|
||||
? nMedianTimePast
|
||||
: pblock->GetBlockTime();
|
||||
@@ -314,16 +314,16 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
}
|
||||
|
||||
if (fMissingInputs) continue;
|
||||
|
||||
|
||||
// Priority is sum(valuein * age) / modified_txsize
|
||||
unsigned int nTxSize = ::GetSerializeSize(tx, SER_NETWORK, PROTOCOL_VERSION);
|
||||
dPriority = tx.ComputePriority(dPriority, nTxSize);
|
||||
|
||||
|
||||
uint256 hash = tx.GetHash();
|
||||
mempool.ApplyDeltas(hash, dPriority, nTotalIn);
|
||||
|
||||
|
||||
CFeeRate feeRate(nTotalIn-tx.GetValueOut(), nTxSize);
|
||||
|
||||
|
||||
if (porphan)
|
||||
{
|
||||
porphan->dPriority = dPriority;
|
||||
@@ -339,20 +339,20 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
int64_t interest;
|
||||
int nBlockSigOps = 100;
|
||||
bool fSortedByFee = (nBlockPrioritySize <= 0);
|
||||
|
||||
|
||||
TxPriorityCompare comparer(fSortedByFee);
|
||||
std::make_heap(vecPriority.begin(), vecPriority.end(), comparer);
|
||||
|
||||
|
||||
while (!vecPriority.empty())
|
||||
{
|
||||
// Take highest priority transaction off the priority queue:
|
||||
double dPriority = vecPriority.front().get<0>();
|
||||
CFeeRate feeRate = vecPriority.front().get<1>();
|
||||
const CTransaction& tx = *(vecPriority.front().get<2>());
|
||||
|
||||
|
||||
std::pop_heap(vecPriority.begin(), vecPriority.end(), comparer);
|
||||
vecPriority.pop_back();
|
||||
|
||||
|
||||
// Size limits
|
||||
unsigned int nTxSize = ::GetSerializeSize(tx, SER_NETWORK, PROTOCOL_VERSION);
|
||||
if (nBlockSize + nTxSize >= nBlockMaxSize-512) // room for extra autotx
|
||||
@@ -360,7 +360,7 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
//fprintf(stderr,"nBlockSize %d + %d nTxSize >= %d nBlockMaxSize\n",(int32_t)nBlockSize,(int32_t)nTxSize,(int32_t)nBlockMaxSize);
|
||||
continue;
|
||||
}
|
||||
|
||||
|
||||
// Legacy limits on sigOps:
|
||||
unsigned int nTxSigOps = GetLegacySigOpCount(tx);
|
||||
if (nBlockSigOps + nTxSigOps >= MAX_BLOCK_SIGOPS-1)
|
||||
@@ -387,14 +387,14 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
comparer = TxPriorityCompare(fSortedByFee);
|
||||
std::make_heap(vecPriority.begin(), vecPriority.end(), comparer);
|
||||
}
|
||||
|
||||
|
||||
if (!view.HaveInputs(tx))
|
||||
{
|
||||
//fprintf(stderr,"dont have inputs\n");
|
||||
continue;
|
||||
}
|
||||
CAmount nTxFees = view.GetValueIn(chainActive.LastTip()->GetHeight(),&interest,tx,chainActive.LastTip()->nTime)-tx.GetValueOut();
|
||||
|
||||
|
||||
nTxSigOps += GetP2SHSigOpCount(tx, view);
|
||||
if (nBlockSigOps + nTxSigOps >= MAX_BLOCK_SIGOPS-1)
|
||||
{
|
||||
@@ -425,12 +425,12 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
++nBlockTx;
|
||||
nBlockSigOps += nTxSigOps;
|
||||
nFees += nTxFees;
|
||||
|
||||
|
||||
if (fPrintPriority)
|
||||
{
|
||||
LogPrintf("priority %.1f fee %s txid %s\n",dPriority, feeRate.ToString(), tx.GetHash().ToString());
|
||||
}
|
||||
|
||||
|
||||
// Add transactions that depend on this one to the priority queue
|
||||
if (mapDependers.count(hash))
|
||||
{
|
||||
@@ -448,7 +448,7 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
nLastBlockTx = nBlockTx;
|
||||
nLastBlockSize = nBlockSize;
|
||||
blocktime = 1 + std::max(pindexPrev->GetMedianTimePast()+1, GetAdjustedTime());
|
||||
@@ -497,7 +497,7 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
//printf("staking PoS ht.%d t%u lag.%u\n",(int32_t)chainActive.LastTip()->GetHeight()+1,blocktime,(uint32_t)(GetAdjustedTime() - (blocktime-13)));
|
||||
} else return(0); //fprintf(stderr,"no utxos eligible for staking\n");
|
||||
}
|
||||
|
||||
|
||||
// Create coinbase tx
|
||||
CMutableTransaction txNew = CreateNewContextualCMutableTransaction(consensusParams, nHeight);
|
||||
txNew.vin.resize(1);
|
||||
@@ -531,7 +531,7 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
fprintf(stderr,"CreateNewBlock: attempt to add timelock to pay2sh or pay2cc\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
opretScript += scriptPubKeyIn;
|
||||
|
||||
txNew.vout[0].scriptPubKey = CScriptExt().PayToScriptHash(CScriptID(opretScript));
|
||||
@@ -578,7 +578,7 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
nonce >>= 16;
|
||||
pblock->nNonce = ArithToUint256(nonce);
|
||||
}
|
||||
|
||||
|
||||
// Fill in header
|
||||
pblock->hashPrevBlock = pindexPrev->GetBlockHash();
|
||||
pblock->hashFinalSaplingRoot = sapling_tree.root();
|
||||
@@ -638,7 +638,7 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
//fprintf(stderr,"done new block\n");
|
||||
return pblocktemplate.release();
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
#ifdef ENABLE_WALLET
|
||||
boost::optional<CScript> GetMinerScriptPubKey(CReserveKey& reservekey)
|
||||
@@ -661,11 +661,11 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
return boost::optional<CScript>();
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
CScript scriptPubKey = CScript() << OP_DUP << OP_HASH160 << ToByteVector(keyID) << OP_EQUALVERIFY << OP_CHECKSIG;
|
||||
return scriptPubKey;
|
||||
}
|
||||
|
||||
|
||||
#ifdef ENABLE_WALLET
|
||||
CBlockTemplate* CreateNewBlockWithKey(CReserveKey& reservekey)
|
||||
{
|
||||
@@ -675,7 +675,7 @@ CBlockTemplate* CreateNewBlock(const CScript& _scriptPubKeyIn, int32_t gpucount,
|
||||
{
|
||||
boost::optional<CScript> scriptPubKey = GetMinerScriptPubKey();
|
||||
#endif
|
||||
|
||||
|
||||
if (!scriptPubKey) {
|
||||
return NULL;
|
||||
}
|
||||
@@ -703,7 +703,7 @@ void IncrementExtraNonce(CBlock* pblock, CBlockIndex* pindexPrev, unsigned int&
|
||||
CMutableTransaction txCoinbase(pblock->vtx[0]);
|
||||
txCoinbase.vin[0].scriptSig = (CScript() << nHeight << CScriptNum(nExtraNonce)) + COINBASE_FLAGS;
|
||||
assert(txCoinbase.vin[0].scriptSig.size() <= 100);
|
||||
|
||||
|
||||
pblock->vtx[0] = txCoinbase;
|
||||
pblock->hashMerkleRoot = pblock->BuildMerkleTree();
|
||||
}
|
||||
@@ -783,7 +783,7 @@ static bool ProcessBlockFound(CBlock* pblock)
|
||||
{
|
||||
LogPrintf("%s\n", pblock->ToString());
|
||||
LogPrintf("generated %s height.%d\n", FormatMoney(pblock->vtx[0].vout[0].nValue),chainActive.LastTip()->GetHeight()+1);
|
||||
|
||||
|
||||
// Found a solution
|
||||
{
|
||||
if (pblock->hashPrevBlock != chainActive.LastTip()->GetBlockHash())
|
||||
@@ -797,11 +797,11 @@ static bool ProcessBlockFound(CBlock* pblock)
|
||||
for (i=31; i>=0; i--)
|
||||
fprintf(stderr,"%02x",((uint8_t *)&hash)[i]);
|
||||
fprintf(stderr," <- chainTip (stale)\n");
|
||||
|
||||
|
||||
return error("KomodoMiner: generated block is stale");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#ifdef ENABLE_WALLET
|
||||
// Remove key from key pool
|
||||
if ( IS_KOMODO_NOTARY == 0 )
|
||||
@@ -825,7 +825,7 @@ static bool ProcessBlockFound(CBlock* pblock)
|
||||
CValidationState state;
|
||||
if (!ProcessNewBlock(1,chainActive.LastTip()->GetHeight()+1,state, NULL, pblock, true, NULL))
|
||||
return error("KomodoMiner: ProcessNewBlock, block not accepted");
|
||||
|
||||
|
||||
TrackMinedBlock(pblock->GetHash());
|
||||
komodo_broadcast(pblock,16);
|
||||
return true;
|
||||
@@ -853,7 +853,7 @@ int32_t waitForPeers(const CChainParams &chainparams)
|
||||
if (fvNodesEmpty || IsNotInSync())
|
||||
{
|
||||
int loops = 0, blockDiff = 0, newDiff = 0;
|
||||
|
||||
|
||||
do {
|
||||
if (fvNodesEmpty)
|
||||
{
|
||||
@@ -1036,7 +1036,7 @@ void static VerusStaker(CWallet *pwallet)
|
||||
post.SetCompact(pblock->GetVerusPOSTarget());
|
||||
pindexPrev = get_chainactive(Mining_height - 100);
|
||||
CTransaction &sTx = pblock->vtx[pblock->vtx.size()-1];
|
||||
printf("POS hash: %s \ntarget: %s\n",
|
||||
printf("POS hash: %s \ntarget: %s\n",
|
||||
CTransaction::_GetVerusPOSHash(&(pblock->nNonce), sTx.vin[0].prevout.hash, sTx.vin[0].prevout.n, Mining_height, pindexPrev->GetBlockHeader().GetVerusEntropyHash(Mining_height - 100), sTx.vout[0].nValue).GetHex().c_str(), ArithToUint256(post).GetHex().c_str());
|
||||
if (unlockTime > Mining_height && subsidy >= ASSETCHAINS_TIMELOCKGTE)
|
||||
printf("- timelocked until block %i\n", unlockTime);
|
||||
@@ -1356,15 +1356,15 @@ void static BitcoinMiner()
|
||||
SetThreadPriority(THREAD_PRIORITY_LOWEST);
|
||||
RenameThread("komodo-miner");
|
||||
const CChainParams& chainparams = Params();
|
||||
|
||||
|
||||
#ifdef ENABLE_WALLET
|
||||
// Each thread has its own key
|
||||
CReserveKey reservekey(pwallet);
|
||||
#endif
|
||||
|
||||
|
||||
// Each thread has its own counter
|
||||
unsigned int nExtraNonce = 0;
|
||||
|
||||
|
||||
unsigned int n = chainparams.EquihashN();
|
||||
unsigned int k = chainparams.EquihashK();
|
||||
uint8_t *script; uint64_t total; int32_t i,j,gpucount=KOMODO_MAXGPUCOUNT,notaryid = -1;
|
||||
@@ -1395,7 +1395,7 @@ void static BitcoinMiner()
|
||||
}
|
||||
);
|
||||
miningTimer.start();
|
||||
|
||||
|
||||
try {
|
||||
if ( ASSETCHAINS_SYMBOL[0] != 0 )
|
||||
fprintf(stderr,"try %s Mining with %s\n",ASSETCHAINS_SYMBOL,solver.c_str());
|
||||
@@ -1418,7 +1418,7 @@ void static BitcoinMiner()
|
||||
break;
|
||||
MilliSleep(15000);
|
||||
//fprintf(stderr,"fvNodesEmpty %d IsInitialBlockDownload(%s) %d\n",(int32_t)fvNodesEmpty,ASSETCHAINS_SYMBOL,(int32_t)IsInitialBlockDownload());
|
||||
|
||||
|
||||
} while (true);
|
||||
//fprintf(stderr,"%s Found peers\n",ASSETCHAINS_SYMBOL);
|
||||
miningTimer.start();
|
||||
@@ -1441,7 +1441,7 @@ void static BitcoinMiner()
|
||||
|
||||
#ifdef ENABLE_WALLET
|
||||
// notaries always default to staking
|
||||
CBlockTemplate *ptr = CreateNewBlockWithKey(reservekey, pindexPrev->GetHeight()+1, gpucount, ASSETCHAINS_STAKED != 0 && GetArg("-genproclimit", 0) == 0);
|
||||
CBlockTemplate *ptr = CreateNewBlockWithKey(reservekey, pindexPrev->GetHeight()+1, gpucount, ASSETCHAINS_STAKED != 0 && GetArg("-genproclimit", -1) == 0);
|
||||
#else
|
||||
CBlockTemplate *ptr = CreateNewBlockWithKey();
|
||||
#endif
|
||||
@@ -1567,7 +1567,7 @@ void static BitcoinMiner()
|
||||
komodo_longestchain();
|
||||
// Hash state
|
||||
KOMODO_CHOSEN_ONE = 0;
|
||||
|
||||
|
||||
crypto_generichash_blake2b_state state;
|
||||
EhInitialiseState(n, k, state);
|
||||
// I = the block header minus nonce and solution.
|
||||
@@ -1687,13 +1687,13 @@ void static BitcoinMiner()
|
||||
std::lock_guard<std::mutex> lock{m_cs};
|
||||
return cancelSolver;
|
||||
};
|
||||
|
||||
|
||||
// TODO: factor this out into a function with the same API for each solver.
|
||||
if (solver == "tromp" ) { //&& notaryid >= 0 ) {
|
||||
// Create solver and initialize it.
|
||||
equi eq(1);
|
||||
eq.setstate(&curr_state);
|
||||
|
||||
|
||||
// Initialization done, start algo driver.
|
||||
eq.digit0(0);
|
||||
eq.xfull = eq.bfull = eq.hfull = 0;
|
||||
@@ -1705,7 +1705,7 @@ void static BitcoinMiner()
|
||||
}
|
||||
eq.digitK(0);
|
||||
ehSolverRuns.increment();
|
||||
|
||||
|
||||
// Convert solution indices to byte array (decompress) and pass it to validBlock method.
|
||||
for (size_t s = 0; s < eq.nsols; s++) {
|
||||
LogPrint("pow", "Checking solution %d\n", s+1);
|
||||
@@ -1714,7 +1714,7 @@ void static BitcoinMiner()
|
||||
index_vector[i] = eq.sols[s][i];
|
||||
}
|
||||
std::vector<unsigned char> sol_char = GetMinimalFromIndices(index_vector, DIGITBITS);
|
||||
|
||||
|
||||
if (validBlock(sol_char)) {
|
||||
// If we find a POW solution, do not try other solutions
|
||||
// because they become invalid as we created a new block in blockchain.
|
||||
@@ -1741,7 +1741,7 @@ void static BitcoinMiner()
|
||||
cancelSolver = false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Check for stop or if block needs to be rebuilt
|
||||
boost::this_thread::interruption_point();
|
||||
// Regtest mode doesn't require peers
|
||||
@@ -1811,7 +1811,7 @@ void static BitcoinMiner()
|
||||
miningTimer.stop();
|
||||
c.disconnect();
|
||||
}
|
||||
|
||||
|
||||
#ifdef ENABLE_WALLET
|
||||
void GenerateBitcoins(bool fGenerate, CWallet* pwallet, int nThreads)
|
||||
#else
|
||||
@@ -1819,10 +1819,10 @@ void static BitcoinMiner()
|
||||
#endif
|
||||
{
|
||||
static boost::thread_group* minerThreads = NULL;
|
||||
|
||||
|
||||
if (nThreads < 0)
|
||||
nThreads = GetNumCores();
|
||||
|
||||
|
||||
if (minerThreads != NULL)
|
||||
{
|
||||
minerThreads->interrupt_all();
|
||||
@@ -1831,8 +1831,13 @@ void static BitcoinMiner()
|
||||
}
|
||||
|
||||
//fprintf(stderr,"nThreads.%d fGenerate.%d\n",(int32_t)nThreads,fGenerate);
|
||||
if ( nThreads == 0 && ASSETCHAINS_STAKED )
|
||||
nThreads = 1;
|
||||
if ( ASSETCHAINS_STAKED > 0 && nThreads == 0 && fGenerate )
|
||||
{
|
||||
if ( pwallet != NULL )
|
||||
nThreads = 1;
|
||||
else
|
||||
return;
|
||||
}
|
||||
|
||||
if ((nThreads == 0 || !fGenerate) && (VERUS_MINTBLOCKS == 0 || pwallet == NULL))
|
||||
return;
|
||||
@@ -1861,5 +1866,5 @@ void static BitcoinMiner()
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#endif // ENABLE_MINING
|
||||
|
||||
@@ -1492,13 +1492,18 @@ void ThreadOpenAddedConnections()
|
||||
LOCK(cs_vNodes);
|
||||
BOOST_FOREACH(CNode* pnode, vNodes)
|
||||
for (list<vector<CService> >::iterator it = lservAddressesToAdd.begin(); it != lservAddressesToAdd.end(); it++)
|
||||
{
|
||||
BOOST_FOREACH(const CService& addrNode, *(it))
|
||||
if (pnode->addr == addrNode)
|
||||
{
|
||||
it = lservAddressesToAdd.erase(it);
|
||||
it--;
|
||||
if ( it != lservAddressesToAdd.begin() )
|
||||
it--;
|
||||
break;
|
||||
}
|
||||
if (it == lservAddressesToAdd.end())
|
||||
break;
|
||||
}
|
||||
}
|
||||
BOOST_FOREACH(vector<CService>& vserv, lservAddressesToAdd)
|
||||
{
|
||||
|
||||
@@ -339,19 +339,25 @@ UniValue setgenerate(const UniValue& params, bool fHelp)
|
||||
//if (nGenProcLimit == 0)
|
||||
// fGenerate = false;
|
||||
}
|
||||
|
||||
if (fGenerate && !nGenProcLimit)
|
||||
if ( ASSETCHAINS_LWMAPOS != 0 )
|
||||
{
|
||||
VERUS_MINTBLOCKS = 1;
|
||||
fGenerate = GetBoolArg("-gen", false);
|
||||
nGenProcLimit = KOMODO_MININGTHREADS;
|
||||
if (fGenerate && !nGenProcLimit)
|
||||
{
|
||||
VERUS_MINTBLOCKS = 1;
|
||||
fGenerate = GetBoolArg("-gen", false);
|
||||
KOMODO_MININGTHREADS = nGenProcLimit;
|
||||
}
|
||||
else if (!fGenerate)
|
||||
{
|
||||
VERUS_MINTBLOCKS = 0;
|
||||
KOMODO_MININGTHREADS = 0;
|
||||
}
|
||||
else KOMODO_MININGTHREADS = (int32_t)nGenProcLimit;
|
||||
}
|
||||
else if (!fGenerate)
|
||||
else
|
||||
{
|
||||
VERUS_MINTBLOCKS = 0;
|
||||
KOMODO_MININGTHREADS = 0;
|
||||
KOMODO_MININGTHREADS = (int32_t)nGenProcLimit;
|
||||
}
|
||||
else KOMODO_MININGTHREADS = (int32_t)nGenProcLimit;
|
||||
|
||||
mapArgs["-gen"] = (fGenerate ? "1" : "0");
|
||||
mapArgs ["-genproclimit"] = itostr(KOMODO_MININGTHREADS);
|
||||
|
||||
@@ -54,7 +54,7 @@ extern uint64_t KOMODO_INTERESTSUM,KOMODO_WALLETBALANCE;
|
||||
extern int32_t KOMODO_LASTMINED,JUMBLR_PAUSE,KOMODO_LONGESTCHAIN;
|
||||
extern char ASSETCHAINS_SYMBOL[KOMODO_ASSETCHAIN_MAXLEN];
|
||||
uint32_t komodo_segid32(char *coinaddr);
|
||||
int64_t komodo_coinsupply(int64_t *zfundsp,int32_t height);
|
||||
int64_t komodo_coinsupply(int64_t *zfundsp,int64_t *sproutfundsp,int32_t height);
|
||||
int32_t notarizedtxid_height(char *dest,char *txidstr,int32_t *kmdnotarized_heightp);
|
||||
#define KOMODO_VERSION "0.3.1"
|
||||
#define VERUS_VERSION "0.4.0g"
|
||||
@@ -282,7 +282,7 @@ public:
|
||||
|
||||
UniValue coinsupply(const UniValue& params, bool fHelp)
|
||||
{
|
||||
int32_t height = 0; int32_t currentHeight; int64_t zfunds,supply = 0; UniValue result(UniValue::VOBJ);
|
||||
int32_t height = 0; int32_t currentHeight; int64_t sproutfunds,zfunds,supply = 0; UniValue result(UniValue::VOBJ);
|
||||
if (fHelp || params.size() > 1)
|
||||
throw runtime_error("coinsupply <height>\n"
|
||||
"\nReturn coin supply information at a given block height. If no height is given, the current height is used.\n"
|
||||
@@ -295,7 +295,8 @@ UniValue coinsupply(const UniValue& params, bool fHelp)
|
||||
" \"height\" : 420, (integer) The height of this coin supply data\n"
|
||||
" \"supply\" : \"777.0\", (float) The transparent coin supply\n"
|
||||
" \"zfunds\" : \"0.777\", (float) The shielded coin supply (in zaddrs)\n"
|
||||
" \"total\" : \"777.777\", (float) The total coin supply, i.e. sum of supply + zfunds\n"
|
||||
" \"sprout\" : \"0.077\", (float) The sprout coin supply (in zcaddrs)\n"
|
||||
" \"total\" : \"777.777\", (float) The total coin supply, i.e. sum of supply + zfunds\n"
|
||||
"}\n"
|
||||
"\nExamples:\n"
|
||||
+ HelpExampleCli("coinsupply", "420")
|
||||
@@ -307,13 +308,14 @@ UniValue coinsupply(const UniValue& params, bool fHelp)
|
||||
currentHeight = chainActive.Height();
|
||||
|
||||
if (height >= 0 && height <= currentHeight) {
|
||||
if ( (supply= komodo_coinsupply(&zfunds,height)) > 0 )
|
||||
if ( (supply= komodo_coinsupply(&zfunds,&sproutfunds,height)) > 0 )
|
||||
{
|
||||
result.push_back(Pair("result", "success"));
|
||||
result.push_back(Pair("coin", ASSETCHAINS_SYMBOL[0] == 0 ? "KMD" : ASSETCHAINS_SYMBOL));
|
||||
result.push_back(Pair("height", (int)height));
|
||||
result.push_back(Pair("supply", ValueFromAmount(supply)));
|
||||
result.push_back(Pair("zfunds", ValueFromAmount(zfunds)));
|
||||
result.push_back(Pair("sprout", ValueFromAmount(sproutfunds)));
|
||||
result.push_back(Pair("total", ValueFromAmount(zfunds + supply)));
|
||||
} else result.push_back(Pair("error", "couldnt calculate supply"));
|
||||
} else {
|
||||
|
||||
@@ -394,6 +394,7 @@ static const CRPCCommand vRPCCommands[] =
|
||||
|
||||
// Channels
|
||||
{ "channels", "channelsaddress", &channelsaddress, true },
|
||||
{ "channels", "channelslist", &channelslist, true },
|
||||
{ "channels", "channelsinfo", &channelsinfo, true },
|
||||
{ "channels", "channelsopen", &channelsopen, true },
|
||||
{ "channels", "channelspayment", &channelspayment, true },
|
||||
|
||||
@@ -271,6 +271,7 @@ extern UniValue gatewaysmarkdone(const UniValue& params, bool fHelp);
|
||||
extern UniValue gatewayspending(const UniValue& params, bool fHelp);
|
||||
extern UniValue gatewaysprocessed(const UniValue& params, bool fHelp);
|
||||
extern UniValue gatewaysmultisig(const UniValue& params, bool fHelp);
|
||||
extern UniValue channelslist(const UniValue& params, bool fHelp);
|
||||
extern UniValue channelsinfo(const UniValue& params, bool fHelp);
|
||||
extern UniValue channelsopen(const UniValue& params, bool fHelp);
|
||||
extern UniValue channelspayment(const UniValue& params, bool fHelp);
|
||||
|
||||
@@ -42,7 +42,7 @@ int mta_find_output(UniValue obj, int n)
|
||||
if (!outputMapValue.isArray()) {
|
||||
throw JSONRPCError(RPC_WALLET_ERROR, "Missing outputmap for JoinSplit operation");
|
||||
}
|
||||
|
||||
|
||||
UniValue outputMap = outputMapValue.get_array();
|
||||
assert(outputMap.size() == ZC_NUM_JS_OUTPUTS);
|
||||
for (size_t i = 0; i < outputMap.size(); i++) {
|
||||
@@ -50,7 +50,7 @@ int mta_find_output(UniValue obj, int n)
|
||||
return i;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
throw std::logic_error("n is not present in outputmap");
|
||||
}
|
||||
|
||||
@@ -69,33 +69,33 @@ saplingNoteInputs_(saplingNoteInputs), recipient_(recipient), fee_(fee), context
|
||||
if (fee < 0 || fee > MAX_MONEY) {
|
||||
throw JSONRPCError(RPC_INVALID_PARAMETER, "Fee is out of range");
|
||||
}
|
||||
|
||||
|
||||
if (utxoInputs.empty() && sproutNoteInputs.empty() && saplingNoteInputs.empty()) {
|
||||
throw JSONRPCError(RPC_INVALID_PARAMETER, "No inputs");
|
||||
}
|
||||
|
||||
|
||||
if (std::get<0>(recipient).size() == 0) {
|
||||
throw JSONRPCError(RPC_INVALID_PARAMETER, "Recipient parameter missing");
|
||||
}
|
||||
|
||||
|
||||
if (sproutNoteInputs.size() > 0 && saplingNoteInputs.size() > 0) {
|
||||
throw JSONRPCError(RPC_INVALID_PARAMETER, "Cannot send from both Sprout and Sapling addresses using z_mergetoaddress");
|
||||
}
|
||||
|
||||
|
||||
if (sproutNoteInputs.size() > 0 && builder) {
|
||||
throw JSONRPCError(RPC_INVALID_PARAMETER, "Sprout notes are not supported by the TransactionBuilder");
|
||||
}
|
||||
|
||||
|
||||
isUsingBuilder_ = false;
|
||||
if (builder) {
|
||||
isUsingBuilder_ = true;
|
||||
builder_ = builder.get();
|
||||
}
|
||||
|
||||
|
||||
toTaddr_ = DecodeDestination(std::get<0>(recipient));
|
||||
isToTaddr_ = IsValidDestination(toTaddr_);
|
||||
isToZaddr_ = false;
|
||||
|
||||
|
||||
if (!isToTaddr_) {
|
||||
auto address = DecodePaymentAddress(std::get<0>(recipient));
|
||||
if (IsValidPaymentAddress(address)) {
|
||||
@@ -105,18 +105,18 @@ saplingNoteInputs_(saplingNoteInputs), recipient_(recipient), fee_(fee), context
|
||||
throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid recipient address");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Log the context info i.e. the call parameters to z_mergetoaddress
|
||||
if (LogAcceptCategory("zrpcunsafe")) {
|
||||
LogPrint("zrpcunsafe", "%s: z_mergetoaddress initialized (params=%s)\n", getId(), contextInfo.write());
|
||||
} else {
|
||||
LogPrint("zrpc", "%s: z_mergetoaddress initialized\n", getId());
|
||||
}
|
||||
|
||||
|
||||
// Lock UTXOs
|
||||
lock_utxos();
|
||||
lock_notes();
|
||||
|
||||
|
||||
// Enable payment disclosure if requested
|
||||
paymentDisclosureMode = fExperimentalMode && GetBoolArg("-paymentdisclosure", true);
|
||||
}
|
||||
@@ -132,12 +132,12 @@ void AsyncRPCOperation_mergetoaddress::main()
|
||||
unlock_notes();
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
set_state(OperationStatus::EXECUTING);
|
||||
start_execution_clock();
|
||||
|
||||
|
||||
bool success = false;
|
||||
|
||||
|
||||
#ifdef ENABLE_MINING
|
||||
#ifdef ENABLE_WALLET
|
||||
GenerateBitcoins(false, NULL, 0);
|
||||
@@ -145,7 +145,7 @@ void AsyncRPCOperation_mergetoaddress::main()
|
||||
GenerateBitcoins(false, 0);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
try {
|
||||
success = main_impl();
|
||||
} catch (const UniValue& objError) {
|
||||
@@ -166,7 +166,7 @@ void AsyncRPCOperation_mergetoaddress::main()
|
||||
set_error_code(-2);
|
||||
set_error_message("unknown error");
|
||||
}
|
||||
|
||||
|
||||
#ifdef ENABLE_MINING
|
||||
#ifdef ENABLE_WALLET
|
||||
GenerateBitcoins(GetBoolArg("-gen", false), pwalletMain, GetArg("-genproclimit", 1));
|
||||
@@ -174,15 +174,15 @@ void AsyncRPCOperation_mergetoaddress::main()
|
||||
GenerateBitcoins(GetBoolArg("-gen", false), GetArg("-genproclimit", 1));
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
stop_execution_clock();
|
||||
|
||||
|
||||
if (success) {
|
||||
set_state(OperationStatus::SUCCESS);
|
||||
} else {
|
||||
set_state(OperationStatus::FAILED);
|
||||
}
|
||||
|
||||
|
||||
std::string s = strprintf("%s: z_mergetoaddress finished (status=%s", getId(), getStateAsString());
|
||||
if (success) {
|
||||
s += strprintf(", txid=%s)\n", tx_.GetHash().ToString());
|
||||
@@ -190,10 +190,10 @@ void AsyncRPCOperation_mergetoaddress::main()
|
||||
s += strprintf(", error=%s)\n", getErrorMessage());
|
||||
}
|
||||
LogPrintf("%s", s);
|
||||
|
||||
|
||||
unlock_utxos(); // clean up
|
||||
unlock_notes(); // clean up
|
||||
|
||||
|
||||
// !!! Payment disclosure START
|
||||
if (success && paymentDisclosureMode && paymentDisclosureData_.size() > 0) {
|
||||
uint256 txidhash = tx_.GetHash();
|
||||
@@ -216,12 +216,12 @@ void AsyncRPCOperation_mergetoaddress::main()
|
||||
bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
{
|
||||
assert(isToTaddr_ != isToZaddr_);
|
||||
|
||||
|
||||
bool isPureTaddrOnlyTx = (sproutNoteInputs_.empty() && saplingNoteInputs_.empty() && isToTaddr_);
|
||||
CAmount minersFee = fee_;
|
||||
|
||||
|
||||
size_t numInputs = utxoInputs_.size();
|
||||
|
||||
|
||||
// Check mempooltxinputlimit to avoid creating a transaction which the local mempool rejects
|
||||
size_t limit = (size_t)GetArg("-mempooltxinputlimit", 0);
|
||||
{
|
||||
@@ -235,31 +235,31 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
strprintf("Number of transparent inputs %d is greater than mempooltxinputlimit of %d",
|
||||
numInputs, limit));
|
||||
}
|
||||
|
||||
|
||||
CAmount t_inputs_total = 0;
|
||||
for (MergeToAddressInputUTXO& t : utxoInputs_) {
|
||||
t_inputs_total += std::get<1>(t);
|
||||
}
|
||||
|
||||
|
||||
CAmount z_inputs_total = 0;
|
||||
for (const MergeToAddressInputSproutNote& t : sproutNoteInputs_) {
|
||||
z_inputs_total += std::get<2>(t);
|
||||
}
|
||||
|
||||
|
||||
for (const MergeToAddressInputSaplingNote& t : saplingNoteInputs_) {
|
||||
z_inputs_total += std::get<2>(t);
|
||||
}
|
||||
|
||||
|
||||
CAmount targetAmount = z_inputs_total + t_inputs_total;
|
||||
|
||||
|
||||
if (targetAmount <= minersFee) {
|
||||
throw JSONRPCError(RPC_WALLET_INSUFFICIENT_FUNDS,
|
||||
strprintf("Insufficient funds, have %s and miners fee is %s",
|
||||
FormatMoney(targetAmount), FormatMoney(minersFee)));
|
||||
}
|
||||
|
||||
|
||||
CAmount sendAmount = targetAmount - minersFee;
|
||||
|
||||
|
||||
// update the transaction with the UTXO inputs and output (if any)
|
||||
if (!isUsingBuilder_) {
|
||||
CMutableTransaction rawTx(tx_);
|
||||
@@ -274,7 +274,7 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
}
|
||||
tx_ = CTransaction(rawTx);
|
||||
}
|
||||
|
||||
|
||||
LogPrint(isPureTaddrOnlyTx ? "zrpc" : "zrpcunsafe", "%s: spending %s to send %s with fee %s\n",
|
||||
getId(), FormatMoney(targetAmount), FormatMoney(sendAmount), FormatMoney(minersFee));
|
||||
LogPrint("zrpc", "%s: transparent input: %s\n", getId(), FormatMoney(t_inputs_total));
|
||||
@@ -285,13 +285,13 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
LogPrint("zrpcunsafe", "%s: private output: %s\n", getId(), FormatMoney(sendAmount));
|
||||
}
|
||||
LogPrint("zrpc", "%s: fee: %s\n", getId(), FormatMoney(minersFee));
|
||||
|
||||
|
||||
// Grab the current consensus branch ID
|
||||
{
|
||||
LOCK(cs_main);
|
||||
consensusBranchId_ = CurrentEpochBranchId(chainActive.Height() + 1, Params().GetConsensus());
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* SCENARIO #0
|
||||
*
|
||||
@@ -301,15 +301,15 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
*/
|
||||
if (isUsingBuilder_) {
|
||||
builder_.SetFee(minersFee);
|
||||
|
||||
|
||||
|
||||
|
||||
for (const MergeToAddressInputUTXO& t : utxoInputs_) {
|
||||
COutPoint outPoint = std::get<0>(t);
|
||||
CAmount amount = std::get<1>(t);
|
||||
CScript scriptPubKey = std::get<2>(t);
|
||||
builder_.AddTransparentInput(outPoint, scriptPubKey, amount);
|
||||
}
|
||||
|
||||
|
||||
boost::optional<uint256> ovk;
|
||||
// Select Sapling notes
|
||||
std::vector<SaplingOutPoint> saplingOPs;
|
||||
@@ -324,7 +324,7 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
ovk = expsk.full_viewing_key().ovk;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Fetch Sapling anchor and witnesses
|
||||
uint256 anchor;
|
||||
std::vector<boost::optional<SaplingWitness>> witnesses;
|
||||
@@ -332,7 +332,7 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
LOCK2(cs_main, pwalletMain->cs_wallet);
|
||||
pwalletMain->GetSaplingNoteWitnesses(saplingOPs, witnesses, anchor);
|
||||
}
|
||||
|
||||
|
||||
// Add Sapling spends
|
||||
for (size_t i = 0; i < saplingNotes.size(); i++) {
|
||||
if (!witnesses[i]) {
|
||||
@@ -340,7 +340,7 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
}
|
||||
assert(builder_.AddSaplingSpend(expsks[i], saplingNotes[i], anchor, witnesses[i].get()));
|
||||
}
|
||||
|
||||
|
||||
if (isToTaddr_) {
|
||||
if (!builder_.AddTransparentOutput(toTaddr_, sendAmount)) {
|
||||
throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Invalid output address, not a valid taddr.");
|
||||
@@ -372,15 +372,15 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
}
|
||||
builder_.AddSaplingOutput(ovk.get(), *saplingPaymentAddress, sendAmount, hexMemo);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
// Build the transaction
|
||||
auto maybe_tx = builder_.Build();
|
||||
if (!maybe_tx) {
|
||||
throw JSONRPCError(RPC_WALLET_ERROR, "Failed to build transaction.");
|
||||
}
|
||||
tx_ = maybe_tx.get();
|
||||
|
||||
|
||||
// Send the transaction
|
||||
// TODO: Use CWallet::CommitTransaction instead of sendrawtransaction
|
||||
auto signedtxn = EncodeHexTx(tx_);
|
||||
@@ -391,9 +391,9 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
if (sendResultValue.isNull()) {
|
||||
throw JSONRPCError(RPC_WALLET_ERROR, "sendrawtransaction did not return an error or a txid.");
|
||||
}
|
||||
|
||||
|
||||
auto txid = sendResultValue.get_str();
|
||||
|
||||
|
||||
UniValue o(UniValue::VOBJ);
|
||||
o.push_back(Pair("txid", txid));
|
||||
set_result(o);
|
||||
@@ -405,14 +405,14 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
o.push_back(Pair("hex", signedtxn));
|
||||
set_result(o);
|
||||
}
|
||||
|
||||
|
||||
return true;
|
||||
}
|
||||
/**
|
||||
* END SCENARIO #0
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* SCENARIO #1
|
||||
*
|
||||
@@ -429,16 +429,16 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
/**
|
||||
* END SCENARIO #1
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
// Prepare raw transaction to handle JoinSplits
|
||||
CMutableTransaction mtx(tx_);
|
||||
crypto_sign_keypair(joinSplitPubKey_.begin(), joinSplitPrivKey_);
|
||||
mtx.joinSplitPubKey = joinSplitPubKey_;
|
||||
tx_ = CTransaction(mtx);
|
||||
std::string hexMemo = std::get<1>(recipient_);
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* SCENARIO #2
|
||||
*
|
||||
@@ -451,13 +451,13 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
MergeToAddressJSInfo info;
|
||||
info.vpub_old = sendAmount;
|
||||
info.vpub_new = 0;
|
||||
|
||||
|
||||
JSOutput jso = JSOutput(boost::get<libzcash::SproutPaymentAddress>(toPaymentAddress_), sendAmount);
|
||||
if (hexMemo.size() > 0) {
|
||||
jso.memo = get_memo_from_hex_string(hexMemo);
|
||||
}
|
||||
info.vjsout.push_back(jso);
|
||||
|
||||
|
||||
UniValue obj(UniValue::VOBJ);
|
||||
obj = perform_joinsplit(info);
|
||||
sign_send_raw_transaction(obj);
|
||||
@@ -466,14 +466,14 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
/**
|
||||
* END SCENARIO #2
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
// Copy zinputs to more flexible containers
|
||||
std::deque<MergeToAddressInputSproutNote> zInputsDeque;
|
||||
for (const auto& o : sproutNoteInputs_) {
|
||||
zInputsDeque.push_back(o);
|
||||
}
|
||||
|
||||
|
||||
// When spending notes, take a snapshot of note witnesses and anchors as the treestate will
|
||||
// change upon arrival of new blocks which contain joinsplit transactions. This is likely
|
||||
// to happen as creating a chained joinsplit transaction can take longer than the block interval.
|
||||
@@ -488,7 +488,7 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
jsopWitnessAnchorMap[jso.ToString()] = MergeToAddressWitnessAnchorData{vInputWitnesses[0], inputAnchor};
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* SCENARIO #3
|
||||
*
|
||||
@@ -507,12 +507,12 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
int changeOutputIndex = -1; // this is updated after each joinsplit if jsChange > 0
|
||||
bool vpubOldProcessed = false; // updated when vpub_old for taddr inputs is set in first joinsplit
|
||||
bool vpubNewProcessed = false; // updated when vpub_new for miner fee and taddr outputs is set in last joinsplit
|
||||
|
||||
|
||||
// At this point, we are guaranteed to have at least one input note.
|
||||
// Use address of first input note as the temporary change address.
|
||||
SproutSpendingKey changeKey = std::get<3>(zInputsDeque.front());
|
||||
SproutPaymentAddress changeAddress = changeKey.address();
|
||||
|
||||
|
||||
CAmount vpubOldTarget = 0;
|
||||
CAmount vpubNewTarget = 0;
|
||||
if (isToTaddr_) {
|
||||
@@ -524,16 +524,16 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
vpubOldTarget = t_inputs_total - minersFee;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Keep track of treestate within this transaction
|
||||
boost::unordered_map<uint256, SproutMerkleTree, CCoinsKeyHasher> intermediates;
|
||||
std::vector<uint256> previousCommitments;
|
||||
|
||||
|
||||
while (!vpubNewProcessed) {
|
||||
MergeToAddressJSInfo info;
|
||||
info.vpub_old = 0;
|
||||
info.vpub_new = 0;
|
||||
|
||||
|
||||
// Set vpub_old in the first joinsplit
|
||||
if (!vpubOldProcessed) {
|
||||
if (t_inputs_total < vpubOldTarget) {
|
||||
@@ -544,30 +544,30 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
info.vpub_old += vpubOldTarget; // funds flowing from public pool
|
||||
vpubOldProcessed = true;
|
||||
}
|
||||
|
||||
|
||||
CAmount jsInputValue = 0;
|
||||
uint256 jsAnchor;
|
||||
std::vector<boost::optional<SproutWitness>> witnesses;
|
||||
|
||||
|
||||
JSDescription prevJoinSplit;
|
||||
|
||||
|
||||
// Keep track of previous JoinSplit and its commitments
|
||||
if (tx_.vjoinsplit.size() > 0) {
|
||||
prevJoinSplit = tx_.vjoinsplit.back();
|
||||
}
|
||||
|
||||
|
||||
// If there is no change, the chain has terminated so we can reset the tracked treestate.
|
||||
if (jsChange == 0 && tx_.vjoinsplit.size() > 0) {
|
||||
intermediates.clear();
|
||||
previousCommitments.clear();
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Consume change as the first input of the JoinSplit.
|
||||
//
|
||||
if (jsChange > 0) {
|
||||
LOCK2(cs_main, pwalletMain->cs_wallet);
|
||||
|
||||
|
||||
// Update tree state with previous joinsplit
|
||||
SproutMerkleTree tree;
|
||||
auto it = intermediates.find(prevJoinSplit.anchor);
|
||||
@@ -576,7 +576,7 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
} else if (!pcoinsTip->GetSproutAnchorAt(prevJoinSplit.anchor, tree)) {
|
||||
throw JSONRPCError(RPC_WALLET_ERROR, "Could not find previous JoinSplit anchor");
|
||||
}
|
||||
|
||||
|
||||
assert(changeOutputIndex != -1);
|
||||
boost::optional<SproutWitness> changeWitness;
|
||||
int n = 0;
|
||||
@@ -594,7 +594,7 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
}
|
||||
jsAnchor = tree.root();
|
||||
intermediates.insert(std::make_pair(tree.root(), tree)); // chained js are interstitial (found in between block boundaries)
|
||||
|
||||
|
||||
// Decrypt the change note's ciphertext to retrieve some data we need
|
||||
ZCNoteDecryption decryptor(changeKey.receiving_key());
|
||||
auto hSig = prevJoinSplit.h_sig(*pzcashParams, tx_.joinSplitPubKey);
|
||||
@@ -605,23 +605,23 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
prevJoinSplit.ephemeralKey,
|
||||
hSig,
|
||||
(unsigned char)changeOutputIndex);
|
||||
|
||||
|
||||
SproutNote note = plaintext.note(changeAddress);
|
||||
info.notes.push_back(note);
|
||||
info.zkeys.push_back(changeKey);
|
||||
|
||||
|
||||
jsInputValue += plaintext.value();
|
||||
|
||||
|
||||
LogPrint("zrpcunsafe", "%s: spending change (amount=%s)\n",
|
||||
getId(),
|
||||
FormatMoney(plaintext.value()));
|
||||
|
||||
|
||||
} catch (const std::exception& e) {
|
||||
throw JSONRPCError(RPC_WALLET_ERROR, strprintf("Error decrypting output note of previous JoinSplit: %s", e.what()));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
//
|
||||
// Consume spendable non-change notes
|
||||
//
|
||||
@@ -638,7 +638,7 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
CAmount noteFunds = std::get<2>(t);
|
||||
SproutSpendingKey zkey = std::get<3>(t);
|
||||
zInputsDeque.pop_front();
|
||||
|
||||
|
||||
MergeToAddressWitnessAnchorData wad = jsopWitnessAnchorMap[jso.ToString()];
|
||||
vInputWitnesses.push_back(wad.witness);
|
||||
if (inputAnchor.IsNull()) {
|
||||
@@ -646,13 +646,13 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
} else if (inputAnchor != wad.anchor) {
|
||||
throw JSONRPCError(RPC_WALLET_ERROR, "Selected input notes do not share the same anchor");
|
||||
}
|
||||
|
||||
|
||||
vOutPoints.push_back(jso);
|
||||
vInputNotes.push_back(note);
|
||||
vInputZKeys.push_back(zkey);
|
||||
|
||||
|
||||
jsInputValue += noteFunds;
|
||||
|
||||
|
||||
int wtxHeight = -1;
|
||||
int wtxDepth = -1;
|
||||
{
|
||||
@@ -674,13 +674,13 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
wtxHeight,
|
||||
wtxDepth);
|
||||
}
|
||||
|
||||
|
||||
// Add history of previous commitments to witness
|
||||
if (vInputNotes.size() > 0) {
|
||||
if (vInputWitnesses.size() == 0) {
|
||||
throw JSONRPCError(RPC_WALLET_ERROR, "Could not find witness for note commitment");
|
||||
}
|
||||
|
||||
|
||||
for (auto& optionalWitness : vInputWitnesses) {
|
||||
if (!optionalWitness) {
|
||||
throw JSONRPCError(RPC_WALLET_ERROR, "Witness for note commitment is null");
|
||||
@@ -696,20 +696,20 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
}
|
||||
witnesses.push_back(w);
|
||||
}
|
||||
|
||||
|
||||
// The jsAnchor is null if this JoinSplit is at the start of a new chain
|
||||
if (jsAnchor.IsNull()) {
|
||||
jsAnchor = inputAnchor;
|
||||
}
|
||||
|
||||
|
||||
// Add spendable notes as inputs
|
||||
std::copy(vInputNotes.begin(), vInputNotes.end(), std::back_inserter(info.notes));
|
||||
std::copy(vInputZKeys.begin(), vInputZKeys.end(), std::back_inserter(info.zkeys));
|
||||
}
|
||||
|
||||
|
||||
// Accumulate change
|
||||
jsChange = jsInputValue + info.vpub_old;
|
||||
|
||||
|
||||
// Set vpub_new in the last joinsplit (when there are no more notes to spend)
|
||||
if (zInputsDeque.empty()) {
|
||||
assert(!vpubNewProcessed);
|
||||
@@ -724,10 +724,10 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
// If we are merging to a t-addr, there should be no change
|
||||
if (isToTaddr_) assert(jsChange == 0);
|
||||
}
|
||||
|
||||
|
||||
// create dummy output
|
||||
info.vjsout.push_back(JSOutput()); // dummy output while we accumulate funds into a change note for vpub_new
|
||||
|
||||
|
||||
// create output for any change
|
||||
if (jsChange > 0) {
|
||||
std::string outputType = "change";
|
||||
@@ -741,24 +741,24 @@ bool AsyncRPCOperation_mergetoaddress::main_impl()
|
||||
}
|
||||
}
|
||||
info.vjsout.push_back(jso);
|
||||
|
||||
|
||||
LogPrint("zrpcunsafe", "%s: generating note for %s (amount=%s)\n",
|
||||
getId(),
|
||||
outputType,
|
||||
FormatMoney(jsChange));
|
||||
}
|
||||
|
||||
|
||||
obj = perform_joinsplit(info, witnesses, jsAnchor);
|
||||
|
||||
|
||||
if (jsChange > 0) {
|
||||
changeOutputIndex = mta_find_output(obj, 1);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Sanity check in case changes to code block above exits loop by invoking 'break'
|
||||
assert(zInputsDeque.size() == 0);
|
||||
assert(vpubNewProcessed);
|
||||
|
||||
|
||||
sign_send_raw_transaction(obj);
|
||||
return true;
|
||||
}
|
||||
@@ -778,7 +778,7 @@ void AsyncRPCOperation_mergetoaddress::sign_send_raw_transaction(UniValue obj)
|
||||
throw JSONRPCError(RPC_WALLET_ERROR, "Missing hex data for raw transaction");
|
||||
}
|
||||
std::string rawtxn = rawtxnValue.get_str();
|
||||
|
||||
|
||||
UniValue params = UniValue(UniValue::VARR);
|
||||
params.push_back(rawtxn);
|
||||
UniValue signResultValue = signrawtransaction(params, false);
|
||||
@@ -789,13 +789,13 @@ void AsyncRPCOperation_mergetoaddress::sign_send_raw_transaction(UniValue obj)
|
||||
// TODO: #1366 Maybe get "errors" and print array vErrors into a string
|
||||
throw JSONRPCError(RPC_WALLET_ENCRYPTION_FAILED, "Failed to sign transaction");
|
||||
}
|
||||
|
||||
|
||||
UniValue hexValue = find_value(signResultObject, "hex");
|
||||
if (hexValue.isNull()) {
|
||||
throw JSONRPCError(RPC_WALLET_ERROR, "Missing hex data for signed transaction");
|
||||
}
|
||||
std::string signedtxn = hexValue.get_str();
|
||||
|
||||
|
||||
// Send the signed transaction
|
||||
if (!testmode) {
|
||||
params.clear();
|
||||
@@ -805,26 +805,26 @@ void AsyncRPCOperation_mergetoaddress::sign_send_raw_transaction(UniValue obj)
|
||||
if (sendResultValue.isNull()) {
|
||||
throw JSONRPCError(RPC_WALLET_ERROR, "Send raw transaction did not return an error or a txid.");
|
||||
}
|
||||
|
||||
|
||||
std::string txid = sendResultValue.get_str();
|
||||
|
||||
|
||||
UniValue o(UniValue::VOBJ);
|
||||
o.push_back(Pair("txid", txid));
|
||||
set_result(o);
|
||||
} else {
|
||||
// Test mode does not send the transaction to the network.
|
||||
|
||||
|
||||
CDataStream stream(ParseHex(signedtxn), SER_NETWORK, PROTOCOL_VERSION);
|
||||
CTransaction tx;
|
||||
stream >> tx;
|
||||
|
||||
|
||||
UniValue o(UniValue::VOBJ);
|
||||
o.push_back(Pair("test", 1));
|
||||
o.push_back(Pair("txid", tx.GetHash().ToString()));
|
||||
o.push_back(Pair("hex", signedtxn));
|
||||
set_result(o);
|
||||
}
|
||||
|
||||
|
||||
// Keep the signed transaction so we can hash to the same txid
|
||||
CDataStream stream(ParseHex(signedtxn), SER_NETWORK, PROTOCOL_VERSION);
|
||||
CTransaction tx;
|
||||
@@ -864,52 +864,52 @@ UniValue AsyncRPCOperation_mergetoaddress::perform_joinsplit(
|
||||
if (anchor.IsNull()) {
|
||||
throw std::runtime_error("anchor is null");
|
||||
}
|
||||
|
||||
|
||||
if (witnesses.size() != info.notes.size()) {
|
||||
throw runtime_error("number of notes and witnesses do not match");
|
||||
}
|
||||
|
||||
|
||||
if (info.notes.size() != info.zkeys.size()) {
|
||||
throw runtime_error("number of notes and spending keys do not match");
|
||||
}
|
||||
|
||||
|
||||
for (size_t i = 0; i < witnesses.size(); i++) {
|
||||
if (!witnesses[i]) {
|
||||
throw runtime_error("joinsplit input could not be found in tree");
|
||||
}
|
||||
info.vjsin.push_back(JSInput(*witnesses[i], info.notes[i], info.zkeys[i]));
|
||||
}
|
||||
|
||||
|
||||
// Make sure there are two inputs and two outputs
|
||||
while (info.vjsin.size() < ZC_NUM_JS_INPUTS) {
|
||||
info.vjsin.push_back(JSInput());
|
||||
}
|
||||
|
||||
|
||||
while (info.vjsout.size() < ZC_NUM_JS_OUTPUTS) {
|
||||
info.vjsout.push_back(JSOutput());
|
||||
}
|
||||
|
||||
|
||||
if (info.vjsout.size() != ZC_NUM_JS_INPUTS || info.vjsin.size() != ZC_NUM_JS_OUTPUTS) {
|
||||
throw runtime_error("unsupported joinsplit input/output counts");
|
||||
}
|
||||
|
||||
|
||||
CMutableTransaction mtx(tx_);
|
||||
|
||||
|
||||
LogPrint("zrpcunsafe", "%s: creating joinsplit at index %d (vpub_old=%s, vpub_new=%s, in[0]=%s, in[1]=%s, out[0]=%s, out[1]=%s)\n",
|
||||
getId(),
|
||||
tx_.vjoinsplit.size(),
|
||||
FormatMoney(info.vpub_old), FormatMoney(info.vpub_new),
|
||||
FormatMoney(info.vjsin[0].note.value()), FormatMoney(info.vjsin[1].note.value()),
|
||||
FormatMoney(info.vjsout[0].value), FormatMoney(info.vjsout[1].value));
|
||||
|
||||
|
||||
// Generate the proof, this can take over a minute.
|
||||
std::array<libzcash::JSInput, ZC_NUM_JS_INPUTS> inputs{info.vjsin[0], info.vjsin[1]};
|
||||
std::array<libzcash::JSOutput, ZC_NUM_JS_OUTPUTS> outputs{info.vjsout[0], info.vjsout[1]};
|
||||
std::array<size_t, ZC_NUM_JS_INPUTS> inputMap;
|
||||
std::array<size_t, ZC_NUM_JS_OUTPUTS> outputMap;
|
||||
|
||||
|
||||
uint256 esk; // payment disclosure - secret
|
||||
|
||||
|
||||
JSDescription jsdesc = JSDescription::Randomized(
|
||||
mtx.fOverwintered && (mtx.nVersion >= SAPLING_TX_VERSION),
|
||||
*pzcashParams,
|
||||
@@ -929,34 +929,34 @@ UniValue AsyncRPCOperation_mergetoaddress::perform_joinsplit(
|
||||
throw std::runtime_error("error verifying joinsplit");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
mtx.vjoinsplit.push_back(jsdesc);
|
||||
|
||||
|
||||
// Empty output script.
|
||||
CScript scriptCode;
|
||||
CTransaction signTx(mtx);
|
||||
uint256 dataToBeSigned = SignatureHash(scriptCode, signTx, NOT_AN_INPUT, SIGHASH_ALL, 0, consensusBranchId_);
|
||||
|
||||
|
||||
// Add the signature
|
||||
if (!(crypto_sign_detached(&mtx.joinSplitSig[0], NULL,
|
||||
dataToBeSigned.begin(), 32,
|
||||
joinSplitPrivKey_) == 0)) {
|
||||
throw std::runtime_error("crypto_sign_detached failed");
|
||||
}
|
||||
|
||||
|
||||
// Sanity check
|
||||
if (!(crypto_sign_verify_detached(&mtx.joinSplitSig[0],
|
||||
dataToBeSigned.begin(), 32,
|
||||
mtx.joinSplitPubKey.begin()) == 0)) {
|
||||
throw std::runtime_error("crypto_sign_verify_detached failed");
|
||||
}
|
||||
|
||||
|
||||
CTransaction rawTx(mtx);
|
||||
tx_ = rawTx;
|
||||
|
||||
|
||||
CDataStream ss(SER_NETWORK, PROTOCOL_VERSION);
|
||||
ss << rawTx;
|
||||
|
||||
|
||||
std::string encryptedNote1;
|
||||
std::string encryptedNote2;
|
||||
{
|
||||
@@ -965,7 +965,7 @@ UniValue AsyncRPCOperation_mergetoaddress::perform_joinsplit(
|
||||
ss2 << jsdesc.ephemeralKey;
|
||||
ss2 << jsdesc.ciphertexts[0];
|
||||
ss2 << jsdesc.h_sig(*pzcashParams, joinSplitPubKey_);
|
||||
|
||||
|
||||
encryptedNote1 = HexStr(ss2.begin(), ss2.end());
|
||||
}
|
||||
{
|
||||
@@ -974,10 +974,10 @@ UniValue AsyncRPCOperation_mergetoaddress::perform_joinsplit(
|
||||
ss2 << jsdesc.ephemeralKey;
|
||||
ss2 << jsdesc.ciphertexts[1];
|
||||
ss2 << jsdesc.h_sig(*pzcashParams, joinSplitPubKey_);
|
||||
|
||||
|
||||
encryptedNote2 = HexStr(ss2.begin(), ss2.end());
|
||||
}
|
||||
|
||||
|
||||
UniValue arrInputMap(UniValue::VARR);
|
||||
UniValue arrOutputMap(UniValue::VARR);
|
||||
for (size_t i = 0; i < ZC_NUM_JS_INPUTS; i++) {
|
||||
@@ -986,8 +986,8 @@ UniValue AsyncRPCOperation_mergetoaddress::perform_joinsplit(
|
||||
for (size_t i = 0; i < ZC_NUM_JS_OUTPUTS; i++) {
|
||||
arrOutputMap.push_back(static_cast<uint64_t>(outputMap[i]));
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
// !!! Payment disclosure START
|
||||
unsigned char buffer[32] = {0};
|
||||
memcpy(&buffer[0], &joinSplitPrivKey_[0], 32); // private key in first half of 64 byte buffer
|
||||
@@ -1003,11 +1003,11 @@ UniValue AsyncRPCOperation_mergetoaddress::perform_joinsplit(
|
||||
libzcash::SproutPaymentAddress zaddr = output.addr; // randomized output
|
||||
PaymentDisclosureInfo pdInfo = {PAYMENT_DISCLOSURE_VERSION_EXPERIMENTAL, esk, joinSplitPrivKey, zaddr};
|
||||
paymentDisclosureData_.push_back(PaymentDisclosureKeyInfo(pdKey, pdInfo));
|
||||
|
||||
|
||||
LogPrint("paymentdisclosure", "%s: Payment Disclosure: js=%d, n=%d, zaddr=%s\n", getId(), js_index, int(mapped_index), EncodePaymentAddress(zaddr));
|
||||
}
|
||||
// !!! Payment disclosure END
|
||||
|
||||
|
||||
UniValue obj(UniValue::VOBJ);
|
||||
obj.push_back(Pair("encryptednote1", encryptedNote1));
|
||||
obj.push_back(Pair("encryptednote2", encryptedNote2));
|
||||
@@ -1020,19 +1020,19 @@ UniValue AsyncRPCOperation_mergetoaddress::perform_joinsplit(
|
||||
std::array<unsigned char, ZC_MEMO_SIZE> AsyncRPCOperation_mergetoaddress::get_memo_from_hex_string(std::string s)
|
||||
{
|
||||
std::array<unsigned char, ZC_MEMO_SIZE> memo = {{0x00}};
|
||||
|
||||
|
||||
std::vector<unsigned char> rawMemo = ParseHex(s.c_str());
|
||||
|
||||
|
||||
// If ParseHex comes across a non-hex char, it will stop but still return results so far.
|
||||
size_t slen = s.length();
|
||||
if (slen % 2 != 0 || (slen > 0 && rawMemo.size() != slen / 2)) {
|
||||
throw JSONRPCError(RPC_INVALID_PARAMETER, "Memo must be in hexadecimal format");
|
||||
}
|
||||
|
||||
|
||||
if (rawMemo.size() > ZC_MEMO_SIZE) {
|
||||
throw JSONRPCError(RPC_INVALID_PARAMETER, strprintf("Memo size of %d is too big, maximum allowed is %d", rawMemo.size(), ZC_MEMO_SIZE));
|
||||
}
|
||||
|
||||
|
||||
// copy vector into boost array
|
||||
int lenMemo = rawMemo.size();
|
||||
for (int i = 0; i < ZC_MEMO_SIZE && i < lenMemo; i++) {
|
||||
@@ -1050,7 +1050,7 @@ UniValue AsyncRPCOperation_mergetoaddress::getStatus() const
|
||||
if (contextinfo_.isNull()) {
|
||||
return v;
|
||||
}
|
||||
|
||||
|
||||
UniValue obj = v.get_obj();
|
||||
obj.push_back(Pair("method", "z_mergetoaddress"));
|
||||
obj.push_back(Pair("params", contextinfo_));
|
||||
|
||||
@@ -169,9 +169,9 @@ void AsyncRPCOperation_sendmany::main() {
|
||||
|
||||
#ifdef ENABLE_MINING
|
||||
#ifdef ENABLE_WALLET
|
||||
GenerateBitcoins(GetBoolArg("-gen",false), pwalletMain, GetArg("-genproclimit", 0));
|
||||
GenerateBitcoins(GetBoolArg("-gen",false), pwalletMain, GetArg("-genproclimit", 1));
|
||||
#else
|
||||
GenerateBitcoins(GetBoolArg("-gen",false), GetArg("-genproclimit", 0));
|
||||
GenerateBitcoins(GetBoolArg("-gen",false), GetArg("-genproclimit", 1));
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@@ -807,9 +807,9 @@ bool AsyncRPCOperation_sendmany::main_impl() {
|
||||
|
||||
vOutPoints.push_back(jso);
|
||||
vInputNotes.push_back(note);
|
||||
|
||||
|
||||
jsInputValue += noteFunds;
|
||||
|
||||
|
||||
int wtxHeight = -1;
|
||||
int wtxDepth = -1;
|
||||
{
|
||||
@@ -832,14 +832,14 @@ bool AsyncRPCOperation_sendmany::main_impl() {
|
||||
wtxDepth
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
// Add history of previous commitments to witness
|
||||
if (vInputNotes.size() > 0) {
|
||||
|
||||
if (vInputWitnesses.size()==0) {
|
||||
throw JSONRPCError(RPC_WALLET_ERROR, "Could not find witness for note commitment");
|
||||
}
|
||||
|
||||
|
||||
for (auto & optionalWitness : vInputWitnesses) {
|
||||
if (!optionalWitness) {
|
||||
throw JSONRPCError(RPC_WALLET_ERROR, "Witness for note commitment is null");
|
||||
@@ -1061,7 +1061,7 @@ bool AsyncRPCOperation_sendmany::find_utxos(bool fAcceptCoinbase=false) {
|
||||
continue;
|
||||
|
||||
CAmount nValue = out.tx->vout[out.i].nValue;
|
||||
|
||||
|
||||
SendManyInputUTXO utxo(out.tx->GetHash(), out.i, nValue, isCoinbase, dest);
|
||||
t_inputs_.push_back(utxo);
|
||||
}
|
||||
@@ -1368,7 +1368,7 @@ void AsyncRPCOperation_sendmany::add_taddr_change_output_to_tx(CBitcoinAddress *
|
||||
std::array<unsigned char, ZC_MEMO_SIZE> AsyncRPCOperation_sendmany::get_memo_from_hex_string(std::string s) {
|
||||
// initialize to default memo (no_memo), see section 5.5 of the protocol spec
|
||||
std::array<unsigned char, ZC_MEMO_SIZE> memo = {{0xF6}};
|
||||
|
||||
|
||||
std::vector<unsigned char> rawMemo = ParseHex(s.c_str());
|
||||
|
||||
// If ParseHex comes across a non-hex char, it will stop but still return results so far.
|
||||
|
||||
@@ -141,9 +141,9 @@ void AsyncRPCOperation_shieldcoinbase::main() {
|
||||
|
||||
#ifdef ENABLE_MINING
|
||||
#ifdef ENABLE_WALLET
|
||||
GenerateBitcoins(GetBoolArg("-gen",false), pwalletMain, GetArg("-genproclimit", 0));
|
||||
GenerateBitcoins(GetBoolArg("-gen",false), pwalletMain, GetArg("-genproclimit", 1));
|
||||
#else
|
||||
GenerateBitcoins(GetBoolArg("-gen",false), GetArg("-genproclimit", 0));
|
||||
GenerateBitcoins(GetBoolArg("-gen",false), GetArg("-genproclimit", 1));
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
@@ -4113,6 +4113,9 @@ UniValue z_sendmany(const UniValue& params, bool fHelp)
|
||||
if ( fromSprout || toSprout )
|
||||
throw JSONRPCError(RPC_INVALID_PARAMETER,"Sprout usage has expired");
|
||||
}
|
||||
if ( toSapling && ASSETCHAINS_SYMBOL[0] == 0 )
|
||||
throw JSONRPCError(RPC_INVALID_PARAMETER,"Sprout usage will expire soon");
|
||||
|
||||
// If we are sending from a shielded address, all recipient
|
||||
// shielded addresses must be of the same type.
|
||||
if ((fromSprout && toSapling) || (fromSapling && toSprout)) {
|
||||
@@ -4785,9 +4788,9 @@ UniValue z_mergetoaddress(const UniValue& params, bool fHelp)
|
||||
|
||||
if (useAnySprout || useAnySapling || zaddrs.size() > 0) {
|
||||
// Get available notes
|
||||
std::vector<CSproutNotePlaintextEntry> sproutEntries;
|
||||
std::vector<SaplingNoteEntry> saplingEntries;
|
||||
pwalletMain->GetFilteredNotes(sproutEntries, saplingEntries, zaddrs);
|
||||
std::vector<CSproutNotePlaintextEntry> sproutEntries,skipsprout;
|
||||
std::vector<SaplingNoteEntry> saplingEntries,skipsapling;
|
||||
pwalletMain->GetFilteredNotes(sproutEntries, useAnySprout == 0 ? saplingEntries : skipsapling, zaddrs);
|
||||
|
||||
// If Sapling is not active, do not allow sending from a sapling addresses.
|
||||
if (!saplingActive && saplingEntries.size() > 0) {
|
||||
@@ -5669,6 +5672,15 @@ UniValue tokenaddress(const UniValue& params, bool fHelp)
|
||||
return(CCaddress(cp,(char *)"Assets",pubkey));
|
||||
}
|
||||
|
||||
UniValue channelslist(const UniValue& params, bool fHelp)
|
||||
{
|
||||
if ( fHelp || params.size() > 0 )
|
||||
throw runtime_error("channelsinfo\n");
|
||||
if ( ensure_CCrequirements() < 0 )
|
||||
throw runtime_error("to use CC contracts, you need to launch daemon with valid -pubkey= for an address in your wallet\n");
|
||||
return(ChannelsList());
|
||||
}
|
||||
|
||||
UniValue channelsinfo(const UniValue& params, bool fHelp)
|
||||
{
|
||||
uint256 opentxid;
|
||||
|
||||
@@ -63,8 +63,8 @@ void post_wallet_load(){
|
||||
#ifdef ENABLE_MINING
|
||||
// Generate coins in the background
|
||||
if (pwalletMain || !GetArg("-mineraddress", "").empty())
|
||||
GenerateBitcoins(GetBoolArg("-gen", false), pwalletMain, GetArg("-genproclimit", 0));
|
||||
#endif
|
||||
GenerateBitcoins(GetBoolArg("-gen", false), pwalletMain, GetArg("-genproclimit", 1));
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user