mirror of
https://github.com/LORDBABUINO/stealth.git
synced 2026-05-04 19:29:08 -07:00
feat: add vuln reproduction and detection scripts
This commit is contained in:
committed by
LORDBABUINO
parent
1f7ecf321c
commit
fb5381d7b1
28
backend/script/mine_blocks.sh
Executable file
28
backend/script/mine_blocks.sh
Executable file
@@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env bash
|
||||
# mine_blocks.sh — Mine N blocks on the custom Signet
|
||||
set -euo pipefail
|
||||
|
||||
N="${1:-1}"
|
||||
source "$HOME/.bitcoin/signet_keys.env"
|
||||
|
||||
MINER="/home/renato/Desktop/bitcoin/bitcoin/contrib/signet/miner"
|
||||
GRIND="bitcoin-util grind"
|
||||
CLI="bitcoin-cli -signet"
|
||||
|
||||
CURRENT=$($CLI getblockcount)
|
||||
TARGET=$((CURRENT + N))
|
||||
echo "Mining $N blocks (from $CURRENT to $TARGET)..."
|
||||
|
||||
BLOCK_TIME=$(date +%s)
|
||||
for i in $(seq 1 $N); do
|
||||
BLOCK_TIME=$((BLOCK_TIME + 1))
|
||||
$MINER \
|
||||
--cli="bitcoin-cli -rpcwallet=miner" \
|
||||
generate \
|
||||
--grind-cmd="$GRIND" \
|
||||
--address="$MINER_ADDR" \
|
||||
--min-nbits \
|
||||
--set-block-time="$BLOCK_TIME" \
|
||||
2>&1 >/dev/null
|
||||
done
|
||||
echo "Done. Block height: $($CLI getblockcount)"
|
||||
Reference in New Issue
Block a user