Questions tagged [bitcoinj]

Bitcoinj is a Java implementation of the Bitcoin protocol, which allows it to maintain a wallet and send/receive transactions without needing a local copy of Bitcoin Core.

bitcoinj is a implementation of the protocol, which allows it to maintain a wallet and send/receive transactions without needing a local copy of Bitcoin Core. It comes with full documentation and some example apps showing how to use the library.

Features:

  • Connect to the P2P network and download/parse/verify the block chain.
  • Highly optimised lightweight simplified payment verification (SPV) mode. In this mode, only a small part of the block chain is downloaded and verified, making bitcoinj suitable for usage on constrained devices like laptops, smartphones or cheap virtual private servers.
  • SPV wallets can sync with the blockchain in seconds, even from a cold start.
  • Experimental full verification mode, which does the same verification work as Bitcoin Core. In this mode, the unspent transaction output set (UTXO set) is calculated and, thanks to a PostgreSQL store, can be indexed into a database allowing for fast lookup of balance by address.
  • A wallet class with encryption, fee calculation, pluggable coin selection/coin control policies, extensions support and event listeners that let you stay up to date with changes in your balance.
  • Easily implement apps that use Bitcoin's contracts features.
  • Support for micropayment channels that let you set up a multi-signature contract between client and server, and then negotiate over how much value is sent on the channel, allowing rapid and fast micropayments that avoid miner fees.
  • Provides both async and thread-per-connection for network IO, allowing you to choose between scalability and blocking-only features like / proxying.
  • Strong BitcoinStandards support.
  • Command line tool for working with wallet and chain files.
  • Example apps, thorough API documentation and articles explaining the design and layout of the library.

Home Page: https://code.google.com/p/bitcoinj/

GitHub: https://github.com/bitcoinj/bitcoinj

86 questions
1
vote
1 answer

Android: Bitcoin J INSTALL_FAILED_NO_MATCHING_ABIS: Failed to extract native libraries, res=-113

I am facing an issue with my Project Everything was working fine before I Integrated BitcoinJ Library, Once I add that library to my Gradle file it stops installing the APK on Real Device with the error: INSTALL_FAILED_NO_MATCHING_ABIS: Failed to…
Umer Kiani
  • 3,783
  • 5
  • 36
  • 63
1
vote
1 answer

How to create Replace-By-Fee TX with BitcoinJ

First was faced with endless pending Transaction in BitcoinJ FrameWork The main documentation says that it can be made by Replace-By-Fee. So you need to take the old transaction and create a new one but based on previous. Sounds good, but how…
Vladimir
  • 214
  • 2
  • 12
1
vote
0 answers

APK Fails to install when library with native components(`bitcoinj`) is included

I have two projects, A and B. Both projects rely on org.bitcoinj:bitcoinj-core:0.14.7. A is an older project from 2016, compiles fine and launches a debug-apk to my device or emulator. B on the other hand, is a new project. B has a library module,…
Elli White
  • 1,440
  • 1
  • 12
  • 21
1
vote
0 answers

BitcoinJ wallet shows wrong balance

I'm getting familiar with BitcoinJ. So now there is a function for user that registers for the first time and there should be created address for him. But it doesn't work. It says there is already some money. // USER HAS NEVER USED COIN_ATLAS ( IT…
1
vote
1 answer

How to generate multiple Bitcoin addresses from 1 public key?

I'm facing an issue regarding generation of Bitcoin addresses. I've public key: String xpub"xpub661MyMwAqRbcGJxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" I want to generate multiple addresses from xpub. I'm using bitcoinJ library. ECKey…
Muhammad Saad
  • 713
  • 1
  • 9
  • 31
1
vote
0 answers

How secure is BitcoinJ in production environment?

I am completely new to the Bitcoin scene. and have been researching a lot about it. I have also read the original white paper on it. I was looking into making an Andorid wallet where I could send and receive bitcoin. I successfully made that…
UOLUGGG
  • 19
  • 1
1
vote
0 answers

Get the balance of a wallet by a private key

I want to get the balance of a bitcoin wallet based on a private key. My wallet contains 0.0000155 BTC. But the following code always returns "You have 0 bitcoins". What is wrong with my code? final WalletAppKit kit = new…
eztam
  • 3,443
  • 7
  • 36
  • 54
1
vote
0 answers

Not able to run bitcoinj wallettemplate example using testnet3

When I run the bitcoinj example with MainNetParams it works fine but when I try to run with testnet3 I get the following error in the console.Please guide me. 11:06:55 21 DRMWorkaround.maybeDisableExportControls: Failed to deactivate AES-256 barrier…
SSSS
  • 33
  • 1
  • 6
1
vote
1 answer

How to receive bitcoin payments using bitcoinjs-lib in node js

Basically I've been trying to figure out how to use bitcoinjs-lib to have a quick and easy wallet (in node js). This program isn't gonna be a full fledged wallet, it just needs to be able to tell when a bitcoin address receives payment and how much…
Lucas A.
  • 99
  • 2
  • 7
1
vote
0 answers

How to get transactions from H2FullPrunedBlockStore

I have the following code: H2FullPrunedBlockStore h2BlockStore = new H2FullPrunedBlockStore(params, "path", 1000); BlockChain chain = new BlockChain(params, h2BlockStore); PeerGroup peerGroup = new PeerGroup(params, chain); DnsDiscovery dnsDiscovery…
Mix74rus
  • 11
  • 2
1
vote
1 answer

How to find senders Bitcoin Address in BitcoinJ after receiving a transaction

So in my app I have the following functionality for receiving bitcoins kit.wallet().addCoinsReceivedEventListener(new WalletCoinsReceivedEventListener() { @Override public void onCoinsReceived(Wallet wallet, Transaction tx,…
tantonj
  • 434
  • 5
  • 18
1
vote
0 answers

How to create a pem key in string format from base64 encoded key

I'm trying to create a pem key from a ecdsa private key, I have to use a pem string in another function to create a JWT but when I'm trying var base64key =…
Actung
  • 1,438
  • 1
  • 13
  • 18
1
vote
2 answers

BitcoinJ and message verifying

Given three pieces of information: message (string), signature (string), and public address (string), I want to verify the signature. In libraries for Javascript, Python and PHP this is a simple method call. However in BitcoinJ (Java), I cannot come…
mohrt
  • 464
  • 5
  • 3
1
vote
1 answer

Android: No Matching ABI's

Problem: I cannot install my app on my HTC One M7 or any emulators while using Android Studio. Before the upgrade to 5.0.2 (from 4.4.?) it worked fine. Error message that I am receiving is INSTALL_FAILED_NO_MATCHING_ABIS. Attempts: I have tried…
rdadkins
  • 343
  • 4
  • 17
1
vote
0 answers

How to authenticate with challenge and private keys?

I'd like to translate the following JS code into Java code: var key = new Bitcoin.ECKey(Crypto.util.hexToBytes(SHA256(password))); var signed_challenge = Crypto.util.bytesToHex(key.sign(Crypto.util.hexToBytes(SHA256(challenge_key)))); The…
membersound
  • 81,582
  • 193
  • 585
  • 1,120