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
0
votes
1 answer

How can I sign bitcoin transaction offline use bitcoinj and some other c programs

We are want to do a device like trezor or ledger , and we try to sign transaction in the offline device which use c program like trezor , first our online app get utxos and get the TansactionInput , but we do not know how to change the inputs to the…
Eric
  • 330
  • 2
  • 9
0
votes
0 answers

Who receive fee when developing bitcoin wallet using bitcoinJ

Hey I am new developer on android development. I have a question I searched the web and did not find answer. I wish someone can make it clear to me. who receive fee while creating new wallet app using bitcoinJ library ? Can I put my developer wallet…
0
votes
0 answers

base58 cannot get 34 chars results (as Bitcoin address does) but 68 chars

I am trying to convert public key hex to Bitcoin address. From this website http://gobittest.appspot.com/Address, I can do some test. For example, I have this public…
fluency03
  • 2,637
  • 7
  • 32
  • 62
0
votes
1 answer

Bitcoinj getting estimate balance of wallet

Simple question, i am simply trying to get the estimated balance. When i send money id like to get the estimated balance while that transaction is pending. NOT BALANCE but ESTIMATED BALANCE. Please check link…
BTCDude
  • 31
  • 7
0
votes
1 answer

Deriving BIP32/BIP44 addresses for LTC to match Jaxx

I'm using https://github.com/bitcoinjs/bitcoinjs-lib to derive LTC wallet addresses from a private key so I can track transactions of the Jaxx LTC wallet. The first few addresses generated match what Jaxx has (first 9 to be precise), but other…
Muxa
  • 5,563
  • 6
  • 46
  • 56
0
votes
1 answer

How to generate deterministic keys for Ethereum using Java?

I'm trying to create a deterministic wallet for Ethereum mixing BitcoinJ and Web3j. The deterministic key is generated using BitcoinJ and the Ethereum credentials using Web3j. But the address generated with the Web3j credential is not as…
Italo Borssatto
  • 15,044
  • 7
  • 62
  • 88
0
votes
1 answer

Bitcoin Protocol GetAddr returns Alert Message

I am implementing the bitcoin protocol in Android/Java. When I send a getaddr message, the peer responds with an alert message The flow of messages are: Send a version message. Receive a version message. Send a verack message. Receive a verack…
iamanyone
  • 429
  • 2
  • 10
0
votes
1 answer

How to get currentReceiveAddress from Bitcoinj wallet without network connection?

We are using bitcoinj to work with bitcoin wallets. Protobuf serialized Wallet body is stored in database as byte array. As far as I'm concerned, there is no need to connect to bitcoin network to get receive address, because it is calculated somehow…
aalekseyev
  • 133
  • 1
  • 10
0
votes
0 answers

Spring webpage with bitcoin payment

I'm trying to write simple program that will be web client for bitcoin payment. I use bitcoinj as a library; But getting errors. 2017-04-12 15:07:35.099 ERROR 14507 --- [inj user thread] org.bitcoinj.core.Context : Performing thread…
0
votes
1 answer

Get raw block with bitcoinj

I'm trying to get the raw blocks with bitcoinj. I use Block.bitcoinSerialize() to get the bytes of each block when it is downloaded, but does not include transactions. How can I get the full raw block?
Ander Acosta
  • 1,060
  • 1
  • 12
  • 25
0
votes
1 answer

How to event when BitcoinJ instance shut down before the transaction is confirmed?

I'm developing an application which uses bitcoin payment method. And it is using bitcoinj java library. But i have a problem: I am sending btc to the wallet. It says transaction recieved, but it has no confirmation of course. I am creating future…
0
votes
1 answer

Is it possible to sell apps on a cryptocurrency exchange?

I heard that some cryptocurrencies have their own decentralised exchanges. Is it possible to sell our own apps there and how should that work? Maybe we should implement the cryptocurrency in the app? Otherwise somebody may buy it and sell it again?…
0
votes
1 answer

bitcoinJ with createP2SHOutputScript

I am trying to create multi-signature address for the each transaction. Transaction tx = new Transaction(kit.params()); Script script = ScriptBuilder.createP2SHOutputScript(2, keysList); Adress created and I can send coins to this address please…
mmm mmm
  • 37
  • 2
0
votes
1 answer

Can I open bitcoin-qt wallet with bitcoinj

I am trying to open my bitcoin-qt wallet with bitcoinj. I have this simple code: private static final File WALLET_FILE = new File("__PATH__"); public static void main(String[] args) { Wallet wallet; try { wallet =…
Baptiste Pernet
  • 3,318
  • 22
  • 47
-1
votes
1 answer

How to generate positive private key from negrative private key for bitcoin in bitcoinj java or kotlin

I used -13 as private key in bitcoin but the private key is not valid. How can I get the positive private key from -13 or any other negative numbers using Bitcoinj or java and generate the same address? val params = MainNetParams.get() val b =…
Mehranjp73
  • 341
  • 6
  • 20