Categories
Bitcoin Cryptocurrency Development

How to install bitcoin core on Ubuntu?

I want to install a command line-only full node bitcoind on a mini PC with 4GB RAM and Ubuntu. What are the steps to do it and how can I check if it works? (I will post an answer myself, also as a reminder on how to set it up. I will refine the answer.)

Categories
Bitcoin Cryptocurrency Development

Create hashes with at least a user-selected number of leading zeroes

The main program consists of a simple menu with two options: • Try to find nonces that can create hashes with at least a user-selected number of leading zeroes • Quit When the user chooses to start generating hashes, those calculations will continue until the user presses ctrl+c. • Once the user does press ctrl+c, […]

Categories
Bitcoin Cryptocurrency Development

Wallet validation methods (centralized, SPV, etc.) – please clarify for Ledger and in general

1) ledger: https://bitcoin.org/en/wallets/hardware/ledgernanos/ Variable validation – Payment validation features are provided by the software wallet you use with this device. 2) wasabi: https://bitcoin.org/en/wallets/desktop/windows/wasabi/ Centralized validation – This wallet relies on a centralized service by default. This means a third party must be trusted to not hide or simulate payments. 3) Simplified validation (SPV) – This […]

Categories
Bitcoin Cryptocurrency Development

How to install Berkeley DB 4.8 on Linux?

The Unix build notes do not show how to install version 4.8 apart from saying BerkeleyDB is required for the wallet. Ubuntu and Debian have their own libdb-dev and libdb++-dev packages, but these will install BerkeleyDB 5.1 or later. This will break binary wallet compatibility with the distributed executables, which are based on BerkeleyDB 4.8.If […]

Categories
Bitcoin Cryptocurrency Development

UnhandledPromiseRejectionWarning: RpcError: Requested wallet does not exist or is not loaded

I run bitcoind default wallet path.but ı request getballance from nodejs api return; UnhandledPromiseRejectionWarning: RpcError: Requested wallet does not exist or is not loaded I use createwallet rpc method, I created testwallet after I use loadwallet “testwallet” rpc method after that I use listwallets rpc method return json; [ “”, “testwallet” ] but when I […]

Categories
Bitcoin Cryptocurrency Development

Updating Bitcoin Core Wallet

I am currently running a Bitcoin Core wallet 0.18.1. What do I need to do to update it to 0.19.0.1 version? Would be very grateful for instructions as I am relatively new to this.

Categories
Bitcoin Cryptocurrency Development

How should I handle cases like this where the documentation for Bitcoin Core states one thing, and the actual program does something else?

Bitcoin Core’s RPC API call “getnewaddress” is documented here: https://bitcoincore.org/en/doc/0.18.0/rpc/wallet/getnewaddress/ It claims: Result: “address” (string) The new bitcoin address In other words, it is supposed to return an associative array containing only the element ‘address’ which is a string representing the new Bitcoin receive address. However, it actually returns just an “untitled” string without an […]

Categories
Bitcoin Cryptocurrency Development

How to get block header hex?

I am trying to research hash functions and I want to be able to use bitcoin’s mining outputs as hashes. I am curious about where the actual hex value of the data that generates that hash with a lot of zeroes is. So, this is what I want: the 80 byte input that gives a […]

Categories
Bitcoin Cryptocurrency CSV Development

Problem using op_checksequenceverify (op_csv) with relative time flag

i have trouble in using op_csv. The spending condition is not match to my expectation. FUNDING Redeem Script Hex: 03010040b27576a91451d2a5e04d25ceaa86e600a6ec34bd24431c675d88ac Redeem Script Asm: 03<010040> OP_CHECKSEQUENCEVERIFY OP_DROP OP_DUP OP_HASH160 14<51d2a5e04d25ceaa86e600a6ec34bd24431c675d> OP_EQUALVERIFY OP_CHECKSIG P2SH base85 address: 2NFRizqW8XpNQm7nxYvFpYTvYsy3BqgsEx2 (bitcoin testnet3) Based on my mentioned redeem script, i set time parameter as 1 along with OP_CHECKSEQUENCEVERIFY. Now my expectation […]

Categories
Bitcoin Cryptocurrency Development

Usage of PkScript as a part of Inputs of a Transaction

I’ve seen transactions with PkScripts as part of Inputs eg : Example of such a transaction Could anyone please explain how this PkScript is used ?