Questions tagged [java]

Java is a programming language.

32 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
5
votes
1answer
351 views

How to build Merkle root from merkle branches?

Is there any help/tutorial on how to build the Merkle root from stratum data? The Slushpool's stratum protocol has an example of a mining job but it does not contain any Merkle branches and I don't ...
5
votes
1answer
539 views

Test Network Genesis Block

I am using BitcoinJ for my java application which fetches the test network's genesis block. I referred to the basics mentioned at JavaWorld and BitcoinJ's Google Code wiki. I am able to get it ...
3
votes
1answer
1k views

Building Signed Bitcoin Transaction in Java

I have been attempting to build my own raw transaction generator in Java which I can then broadcast on the testnet network. The problem is when I attempt to broadcast the transaction it says there is ...
2
votes
0answers
268 views

Broadcasting signed transaction from Watching wallet using bitcoinj

I am working with watching wallet and Offline wallet using bitcoinj, I created Watching Wallet using tpub key of Offline Wallet I am receiving payment on watching wallet Fine, now I want to ...
2
votes
1answer
613 views

How to sign a transaction using BitcoinJ

I am having problem signing the transaction using BitcoinJ library without the Wallet instance, I only have the Transaction class instance and the ECKey in order to sign the transaction. Is there a ...
1
vote
1answer
19 views

Fail to sign the Segwit Transaction's input in bitcoinj

I want to spend from a segwit address and it has a P2WPH script, I created this transaction just like creating a normal P2PKH transaction, but just changed the address of the input to the segwit ...
1
vote
0answers
30 views

How to sign a 2-of-2 multisig address?

I want to implement 2-of-2 multisig in bitcoinj, and I implement the methods which are used to sign the first time and the second time. But there is a bug that using the same key for the first signing ...
1
vote
0answers
74 views

How to sign an Altcoin transaction manually with 2 inputs and 2 outputs

So i'm working with the altcoin denarius which has the following raw TX structure. This is a transaction I am try to sign: Original: ...
1
vote
0answers
52 views

Bitcoinj Spend from a address directly without wallet

I am stuck trying to send coins from arbitary privateKey in bitcoinj. How can I make the following function work without using the Kit or Wallet classes? @Override public String transferCoin( ECKey ...
1
vote
0answers
270 views

List of crypto currencies built with java?

Is there a list of crypto currencies that was built with Java?
1
vote
1answer
551 views

can i use one Mnemonic Code to create both(TestNet and MainNet) wallets

currently i am using bitcoinj library to create wallet for both Main-net and Test-net using Mnemonic code(Mnemonic Code is different for both), my question is can i create both Wallets(Test-net and ...
1
vote
1answer
271 views

Is there anything I can do to speed up the synchronization of litecoinj?

I am using litecoinj which is forked from bitcoinj but compared to bitcoinj, the wallet creation and block synching is slow when using litecoinj. So, I searched for a solution and found a post that ...
1
vote
0answers
375 views

Block chain receive payment api not working

I am building a little online app to accept bitcoin payments in my website. I have a blockchain.info wallet and I am following their Receive Payments Api, which can be visited here: http://blockchain....
1
vote
0answers
120 views

How return transaction hash from wallet to android app after payment?

Scenario: I have my android app where customers can pay by bitcoins. For this I created intent with uri like: bitcoin:[address]?amount=.. and using startActivityForResult it opens wallet with ...
1
vote
0answers
38 views

Is there a java library which could extract the first seen date and the last seen date of an address over a bitcoin network?

Apparently the bitcoinj does not provide such feature.
1
vote
0answers
137 views

API request of blockchain.info over Java stops spontaneously

In my java class, I extract the hash of transactions from the files of blk...dat, then obtain the data of the corresponding transactions via reading from the URL: https://blockchain.info/rawtx/+ hash. ...
1
vote
0answers
123 views

Payment Transaction Validation

I want to build a app which takes transaction id, source and destination address as input and need to validate the transaction (the specified amount is sent from address1 to address2. What is the ...
1
vote
0answers
46 views

Verification exception : Unexpected

i have cloned litecoin wallet and edit it connect to the network we have created. I disabled checkoints, changed params and the block syncs for 32 blocks. Then i get the following error 05-26 13:07:...
1
vote
0answers
224 views

Why I can't see the balance increasing in my wallet?

I wrote this function using bitcoinJ public Wallet getWallet(ECKey ecKey) { Wallet wallet = walletAppKit.wallet(); wallet.importKey(ecKey); wallet.addEventListener(new ...
1
vote
0answers
204 views

bitcoinj, unknown confidence level

I've got a bitcoin address A with its relative encrypted key K stored in a persistence storage. I am launching bitcoinj through the WalletAppKit class and calling awaitRunning to wait for the ...
1
vote
0answers
167 views

How to use Bitcoinj to authenticate signed messages?

I'd like to authenticate from java code on a website that makes use of javascript/ajax authentication like below: var key = new Bitcoin.ECKey(Crypto.util.hexToBytes(SHA256(password))); var ...
1
vote
0answers
109 views

BitcoinJ without PeerNetwork

I am writing a system which generates wallets on a per user basis. It must be capable to receive and send payments. So I have to keep the private keys encrypted on the system. Generating the ...
0
votes
0answers
22 views

How to get transaction info by hash using bitcoinj?

I have a transaction hash (transaction does not belong to my wallet). How can I get information about this transaction through bitcoinj API? I need information like: number of confirmations sender &...
0
votes
1answer
46 views

How can Server-less communication take place between clients?

I was thinking to design a application which is not dependent on server and can directly send and receive data to and from other clients.I learned it is possible with UDP but how can new users join in ...
0
votes
2answers
130 views

Verify Bitcoin Transaction

Following the great post [Redeeming a raw transaction step by step example required, I came up with code below but the verification failed. // pubkeyBytes, len: 65 // ...
0
votes
0answers
230 views

How can I generate public address from an xpub key in Java?

I have an xpub key with which I want to generate all addresses which have been used or will be used and then find out the keys which have balance. Here's a sample xpubkey with balance- ...
0
votes
1answer
264 views

GDAX Java Limit Order (HTTP Post)

Trying to send HTTP Post request to GDAX with auth. The 'GET' requests work fine and I'm unsure if I am passing the json params correctly as I keep getting Bad Request. private static JsonObject ...
0
votes
0answers
111 views

blockChainDownloadLocked ignoring the duplicate request error

I work with a bitcoin wallet app using the Java/BitcoinJ. The app has custom features such as showing balance, transactions, address and sending option. It was running fine and suddenly, I get the ...
0
votes
0answers
195 views

Library ZMQ to Java does not work

I am trying to connect to a bitcoin node using the ZMQ library for Java. the problem is that when I try to receive a response the code remains frozen. Returns nothing. This is my code: public class ...
0
votes
0answers
2k views

blockchain.info websocket: Error code = 1006, Unexpected end of stream

I am using javax.websockets to have a webSocket connection with Blockchain.info, except that it closes down after random intervals, and I can see the close reason as: 'Unexpected end of stream', ...
0
votes
0answers
211 views

Verifying mrkl_root from two children nodes in JAVA

Let's use the following block for a reference: http://blockexplorer.com/rawblock/00000000000000001e8d6829a8a21adc5d38d0a473b144b6765798e61f98bd1d According to my understanding (correct if wrong), I ...
-1
votes
1answer
95 views

Standalone Java Bitcoin Miner - Does it Exist?

I am a java developer, and currently am looking to create a standalone java class that will let people mine Bitcoin using CPU, but I have no idea if such already exists. I have found one for LiteCoin, ...