From eb97a1ba3ad412114386650fc51bb783d7a0851d Mon Sep 17 00:00:00 2001
From: lateminer <9951982+lateminer@users.noreply.github.com>
Date: Mon, 5 Feb 2024 18:54:24 +0100
Subject: [PATCH] build, contrib: Generate example blackmore.conf

---
 contrib/devtools/README.md                    |   8 +-
 ...-bitcoin-conf.sh => gen-blackmore-conf.sh} |  12 +-
 .../examples/{bitcoin.conf => blackmore.conf} | 117 ++++++++++--------
 share/setup.nsi.in                            |   4 +-
 4 files changed, 74 insertions(+), 67 deletions(-)
 rename contrib/devtools/{gen-bitcoin-conf.sh => gen-blackmore-conf.sh} (84%)
 rename share/examples/{bitcoin.conf => blackmore.conf} (88%)

diff --git a/contrib/devtools/README.md b/contrib/devtools/README.md
index 56eaeef815..12aa0569a7 100644
--- a/contrib/devtools/README.md
+++ b/contrib/devtools/README.md
@@ -100,11 +100,11 @@ options, as all its configuration is set at the top of the file. It runs many ti
 pypy3 contrib/devtools/headerssync-params.py
 ```
 
-gen-bitcoin-conf.sh
+gen-blackmore-conf.sh
 ===================
 
-Generates a bitcoin.conf file in `share/examples/` by parsing the output from `bitcoind --help`. This script is run during the
-release process to include a bitcoin.conf with the release binaries and can also be run by users to generate a file locally.
+Generates a bitcoin.conf file in `share/examples/` by parsing the output from `blackmored --help`. This script is run during the
+release process to include a blackmore.conf with the release binaries and can also be run by users to generate a file locally.
 When generating a file as part of the release process, make sure to commit the changes after running the script.
 
 With in-tree builds this tool can be run from any directory within the
@@ -112,7 +112,7 @@ repository. To use this tool with out-of-tree builds set `BUILDDIR`. For
 example:
 
 ```bash
-BUILDDIR=$PWD/build contrib/devtools/gen-bitcoin-conf.sh
+BUILDDIR=$PWD/build contrib/devtools/gen-blackmore-conf.sh
 ```
 
 security-check.py and test-security-check.py
diff --git a/contrib/devtools/gen-bitcoin-conf.sh b/contrib/devtools/gen-blackmore-conf.sh
similarity index 84%
rename from contrib/devtools/gen-bitcoin-conf.sh
rename to contrib/devtools/gen-blackmore-conf.sh
index 2ebbd42022..4be822f593 100755
--- a/contrib/devtools/gen-bitcoin-conf.sh
+++ b/contrib/devtools/gen-blackmore-conf.sh
@@ -7,9 +7,9 @@ export LC_ALL=C
 TOPDIR=${TOPDIR:-$(git rev-parse --show-toplevel)}
 BUILDDIR=${BUILDDIR:-$TOPDIR}
 BINDIR=${BINDIR:-$BUILDDIR/src}
-BITCOIND=${BITCOIND:-$BINDIR/bitcoind}
+BITCOIND=${BITCOIND:-$BINDIR/blackmored}
 SHARE_EXAMPLES_DIR=${SHARE_EXAMPLES_DIR:-$TOPDIR/share/examples}
-EXAMPLE_CONF_FILE=${EXAMPLE_CONF_FILE:-$SHARE_EXAMPLES_DIR/bitcoin.conf}
+EXAMPLE_CONF_FILE=${EXAMPLE_CONF_FILE:-$SHARE_EXAMPLES_DIR/blackmore.conf}
 
 [ ! -x "$BITCOIND" ] && echo "$BITCOIND not found or not executable." && exit 1
 
@@ -22,10 +22,10 @@ fi
 if [ -n "$DIRTY" ]
 then
   echo -e "WARNING: $BITCOIND was built from a dirty tree.\n"
-  echo -e "To safely generate a bitcoin.conf file, please commit your changes to $BITCOIND, rebuild, then run this script again.\n"
+  echo -e "To safely generate a blackmore.conf file, please commit your changes to $BITCOIND, rebuild, then run this script again.\n"
 fi
 
-echo 'Generating example bitcoin.conf file in share/examples/'
+echo 'Generating example blackmore.conf file in share/examples/'
 
 # create the directory, if it doesn't exist
 mkdir -p "${SHARE_EXAMPLES_DIR}"
@@ -33,7 +33,7 @@ mkdir -p "${SHARE_EXAMPLES_DIR}"
 # create the header text
 cat > "${EXAMPLE_CONF_FILE}" << 'EOF'
 ##
-## bitcoin.conf configuration file.
+## blackmore.conf configuration file.
 ## Generated by contrib/devtools/gen-bitcoin-conf.sh.
 ##
 ## Lines beginning with # are comments.
@@ -46,7 +46,7 @@ cat > "${EXAMPLE_CONF_FILE}" << 'EOF'
 ### Options
 EOF
 
-# parse the output from bitcoind --help
+# parse the output from blackmored --help
 # adding newlines is a bit funky to ensure portability for BSD
 # see here for more details: https://stackoverflow.com/a/24575385
 ${BITCOIND} --help \
diff --git a/share/examples/bitcoin.conf b/share/examples/blackmore.conf
similarity index 88%
rename from share/examples/bitcoin.conf
rename to share/examples/blackmore.conf
index 0470acd300..4944c7fd3a 100644
--- a/share/examples/bitcoin.conf
+++ b/share/examples/blackmore.conf
@@ -1,5 +1,5 @@
 ##
-## bitcoin.conf configuration file.
+## blackmore.conf configuration file.
 ## Generated by contrib/devtools/gen-bitcoin-conf.sh.
 ##
 ## Lines beginning with # are comments.
@@ -16,18 +16,18 @@
 # message)
 #alertnotify=<cmd>
 
-# For backwards compatibility, treat an unused bitcoin.conf file in the
+# For backwards compatibility, treat an unused blackmore.conf file in the
 # datadir as a warning, not an error.
 #allowignoredconf=1
 
 # If this block is in the chain assume that it and its ancestors are valid
 # and potentially skip their script verification (0 to verify all,
 # default:
-# 00000000000000000001a0a448d6cf2546b06801389cc030b2b18c6491266815,
+# ae0c2a9bd13746e2887ca57bf1046b3c787a5ed1068fd1633a3575f08ee291fc,
 # testnet:
-# 0000000000000093bcb68c03a9a168ae252572d348a2eaeba2cdf9231d73206f,
+# 5d5c42500cc6057533e249ba9eeb9b5e998aff30468c904bc267ec9bccbc8b39,
 # signet:
-# 0000013d778ba3f914530f11f6b69869c9fab54acff85acd7b8201d111f19b7f)
+# 0000000000000000000000000000000000000000000000000000000000000000)
 #assumevalid=<hex>
 
 # Maintain an index of compact filters by block (default: 0, values:
@@ -58,7 +58,7 @@
 
 # Specify path to read-only configuration file. Relative paths will be
 # prefixed by datadir location (only useable from command line, not
-# configuration file) (default: bitcoin.conf)
+# configuration file) (default: blackmore.conf)
 #conf=<file>
 
 # Run in the background as a daemon and accept commands (default: 0)
@@ -81,6 +81,25 @@
 # -nodebuglogfile to disable writing the log to a file.
 #debuglogfile=<file>
 
+# Use header spam filter (default: 1)
+#headerspamfilter=<n>
+
+# Enable header spam filter during IBD (default: 0)
+#headerspamfilterduringibd=<n>
+
+# Ignore the port in the ip address when looking for header spam,
+# determine whether or not multiple nodes can be on the same IP
+# (default: 1)
+#headerspamfilterignoreport=<n>
+
+# Maximum average size of an index occurrence in the header spam filter
+# (default: 10)
+#headerspamfiltermaxavg=<n>
+
+# Maximum size of the list of indexes in the header spam filter (default:
+# 500)
+#headerspamfiltermaxsize=<n>
+
 # Specify additional configuration file, relative to the -datadir path
 # (only useable from configuration file, not command line)
 #includeconf=<file>
@@ -106,20 +125,9 @@
 #persistmempool=1
 
 # Specify pid file. Relative paths will be prefixed by a net-specific
-# datadir location. (default: bitcoind.pid)
+# datadir location. (default: blackmored.pid)
 #pid=<file>
 
-# Reduce storage requirements by enabling pruning (deleting) of old
-# blocks. This allows the pruneblockchain RPC to be called to
-# delete specific blocks and enables automatic pruning of old
-# blocks if a target size in MiB is provided. This mode is
-# incompatible with -txindex. Warning: Reverting this setting
-# requires re-downloading the entire blockchain. (default: 0 =
-# disable pruning blocks, 1 = allow manual pruning via RPC, >=550 =
-# automatically prune block files to stay under the specified
-# target size in MiB)
-#prune=<n>
-
 # If enabled, wipe chain state and block index, and rebuild them from
 # blk*.dat files on disk. Also wipe and rebuild other optional
 # indexes that are active. If an assumeutxo snapshot was loaded,
@@ -134,7 +142,7 @@
 
 # Specify path to dynamic settings data file. Can be disabled with
 # -nosettings. File is written at runtime and not meant to be
-# edited by users (use bitcoin.conf instead for custom settings).
+# edited by users (use blackmore.conf instead for custom settings).
 # Relative paths will be prefixed by datadir location. (default:
 # settings.json)
 #settings=<file>
@@ -149,7 +157,7 @@
 #startupnotify=<cmd>
 
 # Maintain a full transaction index, used by the getrawtransaction rpc
-# call (default: 0)
+# call (default: 1)
 #txindex=1
 
 # Print version and exit
@@ -162,7 +170,7 @@
 # Add a node to connect to and attempt to keep the connection open (see
 # the addnode RPC help for more info). This option can be specified
 # multiple times to add multiple nodes; connections are limited to
-# 8 at a time and are counted separately from the -maxconnections
+# 16 at a time and are counted separately from the -maxconnections
 # limit.
 #addnode=<ip>
 
@@ -178,8 +186,8 @@
 # Bind to given address and always listen on it (default: 0.0.0.0). Use
 # [host]:port notation for IPv6. Append =onion to tag any incoming
 # connections to that address and port as incoming Tor connections
-# (default: 127.0.0.1:8334=onion, testnet: 127.0.0.1:18334=onion,
-# signet: 127.0.0.1:38334=onion, regtest: 127.0.0.1:18445=onion)
+# (default: 127.0.0.1:15717=onion, testnet: 127.0.0.1:25717=onion,
+# signet: 127.0.0.1:45717=onion, regtest: 127.0.0.1:35717=onion)
 #bind=<addr>[:<port>][=onion]
 
 # If set, then this host is configured for CJDNS (connecting to fc00::/8
@@ -232,7 +240,7 @@
 
 # Maintain at most <n> connections to peers (default: 125). This limit
 # does not apply to connections manually added via -addnode or the
-# addnode RPC, which have a separate limit of 8.
+# addnode RPC, which have a separate limit of 16.
 #maxconnections=<n>
 
 # Maximum per-connection receive buffer, <n>*1000 bytes (default: 5000)
@@ -279,7 +287,7 @@
 #peerbloomfilters=1
 
 # Listen for connections on <port>. Nodes not using the default ports
-# (default: 8333, testnet: 18333, signet: 38333, regtest: 18444)
+# (default: 15714, testnet: 25714, signet: 38333, regtest: 35714)
 # are unlikely to get incoming connections. Not relevant for I2P
 # (see doc/i2p.md).
 #port=<port>
@@ -343,7 +351,7 @@
 
 
 # What type of addresses to use ("legacy", "p2sh-segwit", "bech32", or
-# "bech32m", default: "bech32")
+# "bech32m", default: "legacy")
 #addresstype=1
 
 # Group outputs by address, selecting many (possibly all) or none, instead
@@ -376,10 +384,9 @@
 # limited by the fee estimate for the longest target
 #discardfee=<amt>
 
-# A fee rate (in BTC/kvB) that will be used when fee estimation has
-# insufficient data. 0 to entirely disable the fallbackfee feature.
-# (default: 0.00)
-#fallbackfee=<amt>
+# Donate the specified percentage of staking rewards to the dev fund (0 to
+# 95, default: 20)
+#donatetodevfund=<n>
 
 # Set key pool size to <n> (default: 1000). Warning: Smaller sizes may
 # increase the risk of losing funds when restoring from an old
@@ -391,22 +398,30 @@
 # allows the use of partial spend avoidance (default: 0.00)
 #maxapsfee=<n>
 
-# Fee rates (in BTC/kvB) smaller than this are considered zero fee for
-# transaction creation (default: 0.00001)
-#mintxfee=<amt>
-
 # Fee rate (in BTC/kvB) to add to transactions you send (default: 0.00)
 #paytxfee=<amt>
 
+# Reserved balance not used for staking (default: 0)
+#reservebalance=<amt>
+
 # External signing tool, see doc/external-signer.md
 #signer=<cmd>
 
 # Spend unconfirmed change when sending transactions (default: 1)
 #spendzeroconfchange=1
 
-# If paytxfee is not set, include enough fee so transactions begin
-# confirmation on average within n blocks (default: 6)
-#txconfirmtarget=<n>
+# Enables or disables the staking cache; significantly improves staking
+# performance, but can use a lot of memory (default: 0)
+#stakecache=<true/false>
+
+# Proof of stake timeout. (default: 500)
+#staketimio=<n>
+
+# Enables or disables staking (default: 1)
+#staking=<true/false>
+
+# Set transaction version to <n> (default: 1)
+#txversion=<n>
 
 # Specify wallet path to load at startup. Can be used multiple times to
 # load multiple wallets. Path is to a directory containing wallet
@@ -434,9 +449,6 @@
 # to invoke the command.
 #walletnotify=<cmd>
 
-# Send transactions with full-RBF opt-in enabled (RPC only, default: 1)
-#walletrbf=1
-
 
 ### ZeroMQ notification options
 
@@ -480,9 +492,9 @@
 # Output debug and trace logging (default: -nodebug, supplying <category>
 # is optional). If <category> is not supplied or if <category> = 1,
 # output all debug and trace logging. <category> can be: addrman,
-# bench, blockstorage, cmpctblock, coindb, estimatefee, http, i2p,
-# ipc, leveldb, libevent, mempool, mempoolrej, net, proxy, prune,
-# qt, rand, reindex, rpc, scan, selectcoins, tor, txpackages,
+# bench, blockstorage, cmpctblock, coindb, coinstake, http, i2p,
+# ipc, leveldb, libevent, mempool, mempoolrej, net, proxy, qt,
+# rand, reindex, rpc, scan, selectcoins, tor, txpackages,
 # txreconciliation, util, validation, walletdb, zmq. This option
 # can be specified multiple times to output multiple categories.
 #debug=<category>
@@ -511,7 +523,7 @@
 #logtimestamps=1
 
 # Maximum total fees (in BTC) to use in a single wallet transaction;
-# setting this too low may abort large transactions (default: 0.10)
+# setting this too low may abort large transactions (default: 1.00)
 #maxtxfee=<amt>
 
 # Send trace/debug info to console (default: 1 when no -daemon. To disable
@@ -562,15 +574,11 @@
 #datacarrier=1
 
 # Relay and mine transactions whose data-carrying raw scriptPubKey is of
-# this size or less (default: 83)
+# this size or less (default: 223)
 #datacarriersize=1
 
-# Accept transaction replace-by-fee without requiring replaceability
-# signaling (default: 0)
-#mempoolfullrbf=1
-
 # Fees (in BTC/kvB) smaller than this are considered zero fee for
-# relaying, mining and transaction creation (default: 0.00001)
+# relaying, mining and transaction creation (default: 0.0001)
 #minrelaytxfee=<amt>
 
 # Relay non-P2SH multisig (default: 1)
@@ -594,7 +602,7 @@
 #blockmaxweight=<n>
 
 # Set lowest fee rate (in BTC/kvB) for transactions to be included in
-# block creation. (default: 0.00001)
+# block creation. (default: 0.0001)
 #blockmintxfee=<amt>
 
 
@@ -634,13 +642,12 @@
 # Password for JSON-RPC connections
 #rpcpassword=<pw>
 
-# Listen for JSON-RPC connections on <port> (default: 8332, testnet:
-# 18332, signet: 38332, regtest: 18443)
+# Listen for JSON-RPC connections on <port> (default: 15715, testnet:
+# 25715, signet: 45715, regtest: 35715)
 #rpcport=<port>
 
 # Sets the serialization of raw transaction or block hex returned in
-# non-verbose mode, non-segwit(0) (DEPRECATED) or segwit(1)
-# (default: 1)
+# non-verbose mode, non-segwit(0) or segwit(1) (default: 0)
 #rpcserialversion=1
 
 # Set the number of threads to service RPC calls (default: 4)
diff --git a/share/setup.nsi.in b/share/setup.nsi.in
index cff8a9a109..eed5b5eea5 100644
--- a/share/setup.nsi.in
+++ b/share/setup.nsi.in
@@ -75,7 +75,7 @@ Section -Main SEC0000
     File @abs_top_builddir@/release/@BITCOIN_GUI_NAME@@EXEEXT@
     File /oname=COPYING.txt @abs_top_srcdir@/COPYING
     File /oname=readme.txt @abs_top_srcdir@/doc/README_windows.txt
-    File @abs_top_srcdir@/share/examples/bitcoin.conf
+    File @abs_top_srcdir@/share/examples/blackmore.conf
     SetOutPath $INSTDIR\share\rpcauth
     File @abs_top_srcdir@/share/rpcauth/*.*
     SetOutPath $INSTDIR\daemon
@@ -130,7 +130,7 @@ Section /o -un.Main UNSEC0000
     Delete /REBOOTOK $INSTDIR\@BITCOIN_GUI_NAME@@EXEEXT@
     Delete /REBOOTOK $INSTDIR\COPYING.txt
     Delete /REBOOTOK $INSTDIR\readme.txt
-    Delete /REBOOTOK $INSTDIR\bitcoin.conf
+    Delete /REBOOTOK $INSTDIR\blackmore.conf
     RMDir /r /REBOOTOK $INSTDIR\share
     RMDir /r /REBOOTOK $INSTDIR\daemon
     DeleteRegValue HKCU "${REGKEY}\Components" Main