How to Obtain Bitcoin Gold Without Using Coinomi I had some bitcoin on Electrum and some on Coinbase before the October fork. I assume I won't be able to claim Bitcoin gold for the amount that was on Coinbase.

Since the fork, I've moved all my Bitcoin to a Ledger Nano S. When I try to use their Split Tool, it doesn't show a balance. I've seen a number of how-tos that entail using a Coinomi which only works on an Android device (of which I do not own).

So my question it, how do I obtain my Bitcoin Gold now that my Bitcoin is on my Ledger Nano S?

Regarding Coinbase, they do not support Bitcoin Gold right now, but there is a possibility they will in the future.

The Nano Ledger split procedure is for if you had Bitcoin in their wallet during the fork.
You can't use it to claim Bitcoin Gold from an external private key.
So for the time being you can't claim Bitcoin Gold with your Ledger Nano.

However, you can use one of the wallets listed under Bitcoin Gold official webpage if you trust them.
Honestly, I wouldn't trust all the wallets they endorse since after the two major incidents that happened a while ago.

Incident 1 - One of the wallet provider they endorsed turned out to be malicious.
Incident 2 - Their official wallet got compromised.

As of now I only deem Coinomi, Ledger and Trezor as the trustworthy wallets for BTG.


How to verify Ripple is working? isup.me is a cool page that checks whether another page is "down for everyone, or just me". Today I found my access to https://ripple.com/client/ and https://ripple.com/graph/ didn't work at all, due to "network errors".

Ripple is p2p, so theoretically it should always be up ... however it's a young project so there might be bugs, and the server code isn't yet open sourced. What's a good way to verify the Ripple network is up, or rather "is Ripple down for everyone, or just me"?

There really isn't one yet. Currently there is only one access point into the Ripple system open to the public and there's no system monitoring on it that has public access.


The representation of data is from site to site different. The hexcode "01" is a SIGHASH ALL Opcode, defined here.

I show here all the opcodes and their definition of your example. Basically sigscript of this example consists of . The signature is an ASN1 DER structure, followed by the public key as hex chars. Drilling deeper, it gets this:

49: OP_DATA_0x49:        push hex 49 (decimal 73) bytes on stack
30: OP_SEQUENCE_0x30:    type tag indicating SEQUENCE, begin sigscript
46: OP_LENGTH_0x46:      length of R + S
02: OP_INT_0x02:         type tag INTEGER indicating length
21: OP_LENGTH_0x21:      this is SIG R (33 Bytes)
02: OP_INT_0x02:         type tag INTEGER indicating length
21: OP_LENGTH_0x21:      this is SIG S (33 Bytes)
01: OP_SIGHASHALL:       this terminates the ECDSA signature (ASN1-DER structure)
21: OP_DATA_0x21:        length compressed Public Key (X9.63 form, 33 Bytes)

So [ALL] and "01" indicate the same. One format is showing the OpCodes (see also in the scriptPubKey section), one is plain hex representation, to make cut&paste easy. All opcodes are here.


bitcoind: How to generate new address and broadcast? I have my own server running bitcoind. Could you tell me how to generate new bitcoin address, sign and broadcast? My goal is that I can see the generated address's balance on Blockchain.info. As for you, my question may be very easy but I am looking for the way for a long time...

bitcoind's version is 0.9.2.

$ bitcoind getinfo
{
    "version" : 90200,
    "protocolversion" : 70002,
    "walletversion" : 60000,
    "balance" : 0.00000000,
    "blocks" : 335538,
    "timeoffset" : -1,
    "connections" : 21,
    "proxy" : "",
    "difficulty" : 39457671307.13873291,
    "testnet" : false,
    "keypoololdest" : 1418654127,
    "keypoolsize" : 101,
    "paytxfee" : 0.00000000,
    "relayfee" : 0.00001000,
    "errors" : ""
}

You don't have any bitcoins, so you can't create, sign, and broadcast a transaction.

As for generating a new address, use the getnewaddress RPC.  It will give you an address you can give someone else to send you bitcoins.  Once you have bitcoins, you can create and broadcast a transaction in one step using either the sendtoaddress RPC or the sendmany RPC.

Use help getnewaddress, help sendtoaddress, and help sendmany to learn more about each RPC.


Bitcoin Exchange Api I need an bitcoin exchange api implemented in my website.

Basically there will be one way transactions money->bitcoin and it needs to support major credit cards (visa,mastercard) as well as paypal and google wallet.

Could you recomend me a such api which works with php/js?

Thanks!

You will not be able to find an API that supports Paypal, credit cards and Google wallet since there's a chargeback issue with paying for Bitcoins in these methods. More on this here.
Each major exchange usually has their own api. Just Google "BTC-E API" for example. There is no "one stop shop" solution for this.


If nonce can change the hash then it should be changing the next block's previous hash? I am studing blockhain and i know that a block hash is linked to the next block in previous hash and it cant be changed for valid reason.
Reason is : because if someone have changed hash then then he/she would have to change in hundreds or millions of nodes/system also otherwise it wont be valid.
My question is :
If nonce will be changed by some miner then the hash will also get changed and it should be changing the next block's previous hash.
correct me if i am wrong. I mean if a miner can change the hash of a block then how he can replicate that hash in all the nodes or system for that block? this is confusing.

Miners don't change the hash of a published block, they change the nonce of a block template until the resulting hash is less than the target and only then publish the block.
So until then, there are no other copies that need changing and there are no other blocks that refer to the older failed versions of the published block.


Ardor Lightweight Contracts: (Almost) trustless way with new Phased Transaction type? I asked that question on Bitcointalk, but got no response so far. As Lior has proposed to make Stackexchange the main medium of exchange about Ardor I'm asking here.

As I read in the FAQ, the main drawback of Lightweight Contracts is that they are not totally trustless, because you cannot guarantee the "contract owner" really runs the contract.

So for example, if the contract is an "exchange contract" that should give you some token for ARDR (e.g. this IGNIS/ARDR exchange), then if the contract owner doesn't run the contract, you won't get the tokens (and the contract owner could steal your ARDR).

You can run the contract yourself, but AFAIK you can't achieve that the "contract owner" signs the exchange transaction without himself running it - you can only validate that the contract does what he should do according to the source code. (Correct me if I'm wrong here.)

But perhaps you could do the following:

You first run the contract yourself and calculate the "expected transaction" that should result from it, based on the input from your planned transaction (in this case, the transaction that rewards you with tokens from your ARDR).
You now issue a phased transaction ("conditional transaction") with the condition of the "expected transaction" - in the exchange case, that you receive the calculated token amount from the contract account.
If the contract doesn't run or doesn't give you the expected token amount, the transaction expires at some block in the future.

This way, the contract owner can only spend the resulting coins when the contract owner runs the contract. So you are safe from "selective scammers" that run contracts once and then never again.

The contract owner is also safe: The contract should be possible to be constructed in a way to check first that it really is able to produce the desired transaction. If not, then he simply doesn't issue the "expected transaction". So nothing happens (only that we have an useless phased transaction recorded on the blockchain, but I think that is a minor issue, and it creates the incentive to only trigger the contract with possible conditions).

Is this scenario possible? I haven't read it in the discussions about Lightweight contracts. If not, I think it would be a nice addition, as then Lighweight Contracts would be as trustless (or almost as trustless) as Ethereum Smart Contracts (or even more, as Ethereum contracts can run out of gas).

AFAIK it would need a new type of Phased Transaction - one similar to the one requiring a linked transaction, but with the ability to not  require the complete transaction hash (which is impossible to calculate in this situation) but the "unsigned" transaction or the amount of a token/coin to receive.

Cheers, d5000

One idea how to solve it works like this:

The sender submits the contract trigger transaction as phased with a reveal secret approval model based on the hash of a secret it generates.
The contract activated by this trigger transaction, submits the response transaction(s) with a composite approval model composed of the same hash of the secret used by the trigger transaction and the trigger transaction full hash.

What happens next is the following:

If the sender approves the trigger transaction, it can also approve the contract transaction since they rely on the same secret.

If the sender does not approve the trigger transaction both the trigger transaction and the transaction submitted by the contract expire.

If the sender tries to approve the contract transaction but not approve his own transaction, the the contract transaction won't be approved since it also relies on the trigger transaction full hash which is not approved in the blockchain.

To implement this we need at least two changes to the existing design:
1. Trigger a contract by a phased transaction which is not approved yet, which is currently not supported.
2. Enhance the by transaction full hash approval model so it has an option to only become approved if the full hash represents a phased approved transaction and not just a transaction stored in the blockchain like it is now.


Server requirements & optimal configuration for Testnet My friend and I are interested in running some experiments using a blockchain and accordingly we're interested in setting up our own Testnet.

We're a bit light on experience, i.e. we've never set up or configured a Testnet environment before, so we're looking for any advice or recommendations on the proper procedure or important implementation details that anyone might be able to offer.

From our university we have the ability to have allocated to our project a server, and we've been asked what are the requirements that our project would need- does anyone know what are the necessary specifications?

We're a bit light on experience, i.e. we've never set up or configured a Testnet environment before, so we're looking for any advice or recommendations on the proper procedure or important implementation details that anyone might be able to offer.

There's Testnet3 (the current public testnet) and Regtest (a private, locally generated, proof-of-work-less network. If you want to experiment with consensus changes you can't be using the public network because those changes will be rejected. Regtest is good for quickly testing things, and Testnet3 is more real world and has a small number of other network participants.

  From our university we have the ability to have allocated to our project a server, and we've been asked what are the requirements that our project would need- does anyone know what are the necessary specifications?

Ideally you'll have as much capacity as you can, but you'll get away with any modern Intel CPU and a few gigabytes of memory. The more memory you have the more you can allocate to caching (dbcache defaults to 100MB, but can be set far higher for performance). Testnet is not a great reflection of how the real network operates, the requirements for the full network to run with good performance are higher.


Account Addresses after moving wallet.dat to new computer I reinstalled bitcoin on a new computer, and took my old wallet.dat file from an old pc that had v.0.3 of the bitcoin software.

I had 2 receiving addresses when I started.
When I typed getaddressesbyaccount ""
it listed the 2 addresses.

I then did the command getnewaddress
then noticed that my wallet.backup file had assigned new reserved addresses.

I did a test spend between my 2 old addresses.  I sent 0.0001 for the 1st address to 2nd address, expecting change to come back to the first, but it
seems that the unspent got sent to the 3rd.

It looks like account name is set by the label.  Everything seems to still belong to the wallet but I have 2 accounts, 1 with 2 addresses.

Here is the transaction:
https://blockchain.info/address/1FsmCgxrrKFPgLxrMgTWUAintbtLeeDf2S

It appears that when I use Bitcoin-qt it thinks that the main account is 18ffH16dzkg64nh8rj8JtSL7K6QYzBBwV2 even though 1FsmCgxrrKFPgLxrMgTWUAintbtLeeDf2S was originally the 1st receiving address.

There doesn't appear to be an obvious intuitive way to determine which account recieves the unspent part of the transaction back.

Not that is should matter as I own them all, but I am trying to understand how this works.

For this transaction it's 12mjN8ZX8nLNLw9KqTEWoR32J1hsKptEh5 that is the change address.

When you transfer from core it creates a new change address to recieve the balance.

If you do listtransactions you can see them all. listreceivedbyaccount may also be helpful.

Something that is helpful to keep in mind when looking at transactions is there there is no from address, something that sites like blockchain.info show and can be confusing.


What is the btc.to address shortening algorithm? How does the btc.to address shortening algorithm work? Is is a deterministic algorithm, that is, it can be reproduced on other websites with the same results, or are the results specific to the website and the order in which the addresses were inputted?

The results are specific to the website and the order in which the addresses were input.

This can be easily determined by experiment. I took a random address from BE and it gave me http://btc.to/2z7. I took another address and it gave me http://btc.to/2z8.

So clearly, it stores all given addresses in a database, and the URL is the address ID encoded in base 36 (experiment also shows that it's case insensitive).

Also, it only accepts valid Bitcoin addresses.

More generally, it's impossible for any algorithm to take an arbitrary long, high-entropy string and give a short string which can be uniquely mapped back to the input.


Where's my Bitcoin Cash? We followed Coinbase's advice and moved our BTC into a Jaxx wallet- No Bitcoin Cash anywhere to be found We followed Coinbase's advice and moved our BTC into a Jaxx wallet-until the fork happened, then moved it back into Coinbase, then Gdax.
We never saw any evidence of Bitcoin Cash on either our Jaxx wallet or on Coinbase/Gdax. How do we find it?  And retrieve it?

Bitcoin Cash is an altcoin. You must have a wallet that supports Bitcoin Cash in order to see your Bitcoin Cash.


How to keep track on new cryptocurrencies Here is a situation: new cryptocurrencies appears with a huge speed and also most of them are just useless clones, there might be some interesting one with new ideas. I would like be know when they appears to read about the differences from previous one. Right now my only place to go is a bitcointalk site to and hopelessly search in alternative currencies branch.

But this is not effective, and requires a lot of time. So the question: is there an easy way to get notified (something like subscribe to news and get email) when a new crypto was introduced?

I recently found a resource that seems to be very comprehensive. At the moment indexes 156 different cryptocurrencies and it seems to be updated quite often.

The main page has a sidebar titled "Latest Coins" that might be useful for what you need.

Each currency has a page with info and relevant links like a block explorer, homepage, etc... (See for example the page for Protoshares)


If I send BTC from Jaxx will it give me both BTC and BCC Just want to know if Bittrex supports both blockchains, Bitcoin and Bitcoin cash, when importing from a Wallet like Jaxx

Bitcoin and bitcoin cash are two separate networks, if you send a tx on one network, it will not affect what happens on the other network. If you are using Jaxx, your wallet will show separate btc and bch balances in the app.

To deposit both btc and bch to Bittrex, you will not to get a btc deposit address from Bittrex and send btc to it. And then get a bch deposit address from Bittrex and send bch to it.

That said, I am unsure if Bittrex supports bch right now. If they do support it, the above will work. If they do not support bch, then obviously you cannot deposit a coin they do not support.


What is the command for primecoind and bitcoind to see my address? i just installed primecoind and bitcoind and datacoind and i want to know how i can get my address. what is the command options for it? I dont see it in the help list.

With bitcoind up and running, you can use this command to check your addresses:

bitcoind listreceivedbyaddress 0 true

if you want to add a new address, you can use:

bitcoind getnewaddress

I don't have primecoind or datacoind installed, so I can't confirm if these commands work for them as well, but the source for both appears to be forked from bitcoind so it should work. The documentation for datacoind and primecoind seems a bit sparse on the net, but you can also try running

primecoind help

or

datacoind help

to check what options are available for them.


Bitcoin mobile phone wallet What would happen to my mobile bitcoin wallet if something happens to my phone? If it breaks, or I want to replace it or it gets stolen?

You lose your money.

To mitigate this encrypt your wallet and do regular backups to several other places. I think wallets will have the backup functionality built-in soon, but it is not here yet.


Whats a site or app where I can extract a public key just by typing in a private key? I read that you are able to extract the public key address from a private key address. Is there a website or app that can do such a thing? I just want to be able to see if I can make up my own private key.


Where can I get testnet Bitcoins in the year 2017-March? I doing some development and want to test out some stuff on testnet. Where can I get testnet coins in bitcoin? Last I read I might be able to mine with the Bitcoin core software? Or is that not worth it anymore? What are some places to get testnet coins in 2017-March?

https://testnet.manu.backend.hamburg/faucet
Try to give them back when you are done with them. Also a simple google search "testnet faucet" would have found you that site and similar ones.


Mnemonic Phrase (BIP39) with Existing Seed Generating Library The standard BIP39 does three things:

1) Generate 256+8 entropy

2) Generate sentence

3) Derive seed from sentence (using PBKDF2 with HMAC-SHA512).

I wonder what would be the security implication of doing things the reverse way:

1) Generate entropy and use it as seed

2) Derive 256 bit array from entropy (using PBKDF2 with HMAC-SHA256/HMAC-SHA512). + 8 bit checksum

3) Use above bit array to construct sentence

Essentially, instead of creating the seed from the sentence, I create the sentence from the seed. In the last step, if HMAC-SHA512 is used, it would generate a bit array of length 512 which is too long for the sentence. To solve that I would XOR the two halves of the array. Alternately, I could just use HMAC-SHA256.

The company I work for has a library that does seed generation and this is what we are mandated to use.

You probably know that HMAC-SHA256/HMAC-SHA512 and thus PBKDF2 are one-way functions. There would be no way how to reconstruct the seed from the generated sentence in your setup, which is the only purpose of such sentence.


How are blocks accepted in bitcoin? These are steps to run the network quoted from the Bitcoin white paper (https://bitcoin.org/bitcoin.pdf):

New transactions are broadcast to all nodes.
Each node collects new transactions into a block.
Each node works on finding a difficult proof-of-work for its block.
When a node finds a proof-of-work, it broadcasts the block to all nodes.
Nodes accept the block only if all transactions in it are valid and not already spent.
Nodes express their acceptance of the block by working on creating the
next block in the chain, using the hash of the accepted block as the
previous hash.

I am wondering weather there will be a scenario where the miners do not accept a valid block or accept a malicious block. Can anyone explain how steps 5 and 6 are executed?

I am wondering weather there will be a scenario where the miners do not accept a valid block or accept a malicious block

The only scenario in which this would happen is if someone on the network is running a malicious version of code with different consensus rules. In this event, anyone running that code will accept an invalid block (that is valid according to their incorrect rules), causing a fork in the chain.

However, everyone on the network using valid consensus rules would deem each block of the forked chain as invalid, and continue extending the real chain as expected.


Change port 8333 to other. (Running multiple docker instances) My question is:

can I change port 8333 on the network connection to any other port (8334 f.e.) without making my node "blind" to the other peers in the network? Will it still sync/push transaction data?

The core of this question is that I want to run multiple docker node instances on a single VM, with docker ports mapped to local ports.

node1 (:8333 -> :8333)

node2 (:8334 -> :8334)

...

Yes you can and the node will still sync and push transaction data.

Most of the nodes are behind NAT and not reachable anyway from the internet.
These nodes are initiating connection against random nodes and then the communication become bidirectional, allowing to receive blocks.

Nodes that are exposed to the internet are important, to bootstrap nodes behind NAT and for SPV clients.


How do I sort the output of listtransactions "*"? I am testing some new code, and need to sort the output of listtransactions. Ultimately I need to verify that there are no duplicate txids.

How do I output  ./bitcoind -datadir=1 listtransactions "*" to a logfile, or sort it directly in the terminal window?

You can run the listtransaction JSON output through this little python script (save it as jsonTOCSV.py). That will produce csv (comma separated value) output that Excel or Google Spreadsheets can import, both of which can sort by columns (if I recall correctly).

So:

  bitcoind listtransactions | jsonTOCSV.py > transactions.csv

#!/usr/bin/env python
#
# Reads an array of JSON objects and writes out CSV-format,
# with key names in first row.
# Columns will be union of all keys in the objects.
#

import csv
import json
import sys

json_string = sys.stdin.read()
json_array = json.loads(json_string)

columns = set()
for item in json_array:
  columns.update(set(item))

writer = csv.writer(sys.stdout)
writer.writerow(list(columns))
for item in json_array:
  row = []
  for c in columns:
    if c in item: row.append(str(item[c]))
    else: row.append('')
  writer.writerow(row)


What is the meaning of "Position in mempool" for a transaction? I am using Electrum as my wallet and when I am receiving a transaction, I see an attribute with the name "Position in mempool" and the value is "8.61 MB from tip". Since the transaction is still unconfirmed, I understand that this value gives information of how close this transaction is to being included in a block but I am not sure how to read it and did not find answers in the documentation or other sources.
Does anyone know how to understand/read that value?

To illustrate this let's imagine the mempool as big vertical list of transactions.

Let this list be ordered by the feerate each transaction is paying, the higher the feerate the higher the transaction in the list.

Miners will under normal circonstances take the highest virtual MB of transaction in this list/queue.

This website is a good visualizer of this concept.

NB: The tip in this context is the transaction in the mempool paying the highest feerate.


How do I know that a node provides the accurate blockchain When I connect with a wallet to the bitcoin network, how is the balance actually retrieved? One node? Or more? I understand it is a sum of all transactions. But when I load my wallet I assume I connect to certain node. How do I know that that particular (malicious) node has the most recent or valid blockchain? In other words: can it be possible for a node to cheat by adjusting the blockchain which I could connect to with a wallet and get a faulty balance?

I read some articles about this and they state that this will be rejected by the network. But I have no idea how this works. Can somebody help?

Edit: this answer is written assuming you are asking about ‘SPV’ or ‘light wallet’ implementations, not a full node implementation

  How do I know that that particular (malicious) node has the most recent or valid blockchain?

This is two separate questions: are you up to date? And is the info valid?

Up to date: it is possible for light wallets to query data from multiple network peers, though not every implementation will do so. This helps ensure no single node is ‘lying by omission’, which means they are withholding information from you (Interesting related info: ‘fraud proofs’ are apparently very, very difficult to craft. It is an ongoing area of research in the field). If you are only connected to malicious nodes, this may become an issue, though in practice it is not a difficult issue to overcome (see: Sybil attacks / eclipse attacks).

Some light wallets will connect to a server run by the developers of that wallet, while others will connect directly to a node(s) in the bitcoin network. Using a service that does not hardcode their own server into the wallet is probably better, though if they follow a standard HD wallet scheme it should be no problem importing your seed phrase to a different wallet in case that service goes down.

I think the best advice is to run your own node. Many light wallets allow you to point your wallet at your own node as a manual setup option. This gives you sovereignty, and greatly increased privacy as well.

Validity: light wallets work by downloading the chain of block headers, and then requesting info related to the wallet’s address’ from connected nodes. By only downloading the blockheaders, resource usage stays low enough for the wallet to work on mobile (less than 100mb for the entire bitcoin history, currently).

The header contains the transaction merkle root, which can be used to locally verify that a valid transaction is included in a certain block, without having all of that block’s data. A node will serve the transaction in question to the wallet, along with the intermediate hashes in the merkle tree. This allows the node to recalculate the merkle root locally, giving proof that the transaction is confirmed on the bitcoin network (and thus valid according to the network’s rules). If even one bit of information is changed, the merkle root will be calculated differently, and the wallet will know the transaction served is invalid.


How many BTC addresses have balance in them? Of all the possible BTC addresses, how many have balance in them?
And what percentage of the total possible addresses is that?

There are approximately 800,000 unique addresses on the blockchain with some Bitcoin held at those addresses at the present time according to blockchain.com.
Let's assume these addresses are all bech32 (to simplify the calculation, in reality these are the minority).
The witness program in a bech32 SegWit v0 P2WSH address is 32 bytes. In theory this means there could be approximately 8^32 = 7.9 x 10^28 different witness programs.
The percentage of unique addresses on the blockchain then works out to be:
800,000 / 7.9 x 10^28 = 1.0 x 10 ^(-23)
This is 0.00000000000000000000001 percent of the total bech32 SegWit v0 addresses.


creating address in wallet and sending how it works I'm a bit of noob so I will apologize in advance.
I'm reading people suggesting using different address every time I send an bitcoin. If I were to say send a 1BTC to someone I'd need to create a new address underneath my wallet and need to transfer 1 BTC from my other addresses and then send it to that address right? Wouldn't that kind of defeat the purpose of securing and also costly by paying extra fees?
Thank you

Address are similar in a way to your bank account number, it just says where your wallet is. It differs in the way that a bitcoin wallet can have more than 1 address. Personally, I am receiving bitcoin on 4 to 5 different addresses.

But I don't actually understand what you mean by creating new addresses to send bitcoin from, you only create a new address (or use an old one) when receiving bitcoin not sending one.


How do you stake / forge in nxt / ardor using a public node without having to login publicly? I have a public nxt / ardor node, but how do I set it to stake / forge with my account? I'm planning to create a separate account and just lease my balance to it to forge.

What settings do I need set to make this work?

You should lease the balance of your main account to a second account which has only a small balance. Submit this leasing transaction on your local workstation.
See: https://nxtwiki.org/wiki/Account_Leasing

Now setup a public node and start forging using your second account.

By doing so, you never have to expose the passphrase of your main account to the public node, only the passphrase of your second account which has a small balance is exposed.


Synchronizing with network – What does it mean? The messages:

synchronizing with network
xxx blocks remaining

what does that mean?

It's most likely you're using the client from bitcoin.org.

Synchronizing with the network refers to the download and verification of the blocks in the block chain, which is the transaction history of Bitcoin. The block chain is the record of who spent what and when they spent it, and who owns what now.

Currently, the bitcoin.org client downloads the entire block chain on installation, which is somewhere around 3GB of data. As it downloads each block, it confirms each transaction, which is a disk-intensive activity. Unless you have high spec hardware, expect it to take many hours, possibly even days.

Version 0.8 of the bitcoin.org client alters the synchronization process, which heavily reduces the time required to get the client functional. The process is faster through being less disk intensive.

Alternative clients are also available, such as Armory or Electrum, which don't use the same synchronization process. Electrum doesn't download the block chain, and the features list for Armory says it doesn't need the block chain.


How to invest bitcoins? Are there any websites where bitcoin holders can invest their money? Such as by buying shares or giving out loans. For example there is a ShareHolder service for WebMoney. Is there something similar for Bitcoin?

A list of Bitcoin-related financial investment services:

http://en.bitcoin.it/wiki/Trade#Financial


Can Ripple gateways operate as fully transparent fractional reserve banks? Any Ripple gateway that establishes a solid reputation will be tempted to switch to fractional reserve issuance of its own IOUs to increase leverage (which is exactly what the existing comercial banks do).

Question:

Can Ripple gateways' accounting be fully transparent since presumably all their transactions are stored in the distributed public ledger ? (This is similar to how SatoshiDice operates currently).

However it's not clear if external deposits and distributions can be represented in the ledger.

For currency in the form of Ripple IOUs, yes. Anyone can tell at any time the total outstanding value of all IOUs in a given currency for a given issuer. So a gateway could, if it wished to, provide provable reserves relative to its outstanding IOUs.

However, gateways typically also hold fiat that's not in the form of IOUs. Gateways currently use a two-step deposit scheme -- you deposit currency in your gateway account and then you tell them to "withdraw" these funds as Ripple IOUs. The funds in the gateway account that haven't been withdrawn as IOUs are not visible. So there's no way to know what obligations a gateway has that aren't in the form of IOUs.

A gateway that wanted to operate in this form would probably wind up supporting only a one-step deposit and withdraw system. With this scheme, you specify the Ripple account the IOUs are to go to before you give them any currency and they issue IOUs as soon as the deposit clears. And for withdrawals, you specify where the currency is to go prior to returning the IOUs to the gateway.

I don't believe these one-step mechanisms are supported by any gateways yet.


What is a good place to ask for bitcoin to fund a scientific project? I have a great idea for an invention, but I am currently limited to purchasing parts for building a prototype of it with bitcoins. Unfortunately, I do not have that many bitcoins and need a way to ask the bitcoin community for donations. Yes, I have an address, I am not a newbie to bitcoin. I would like to know where I can ask for bitcoin for a scientific project that could benefit the world. If anyone is interested I will disclose some information about my project.

You could look into posting about your project in the Einsteinium community. The coin is designed specifically to help fund science projects and research.

http://einsteinium.org/

https://bitcointalk.org/index.php?topic=494708.0


In the basic Wallet based in QT, How can i get by RPC the stored addresses and labels? this question is for you to ask about the QT wallet, in the section to send coins, there is an address window, and it has the list of the stored addresses we save along the time. So using RPC, do you know if there is a way to obtain this data from inside? i am not refering myself on creating a new address or getaddresses by account command, i mean all the addresses we save, independently if they are ours or not.

The closest I know of is

listreceivedbyaddress 0 true

https://en.bitcoin.it/wiki/Original_Bitcoin_client/API_calls_list says:

  Listing the bitcoin addresses in your wallet is easily done via listreceivedbyaddress. It normally lists only addresses which already have received transactions, however you can list all the addresses by setting the first argument to 0, and the second one to true.

Similar questions (different answers)

How to get all addresses - including the "change" addresses - from bitcoind?


What is Open Transactions? I discovered that there are some questions that discuss finer points of the Open Transactions Software, however the project itself could use a proper definition.

Please explain concisely what the Open Transactions is:
How does Open Transactions work, what problems does it solve and how does money get into the open transactions network?

Open-Transactions is a free software library of financial cryptography primitives, used for implementing cryptographically secure financial transactions.

Open-Transactions also includes a server and client API.

Open-Transactions can be used for issuing currencies/stock, paying dividends, creating asset accounts, sending/receiving digital cash, writing/depositing cheques, cashier's cheques, creating basket currencies, trading on markets, scripting custom agreements, recurring payments, escrow, etc.

Open-Transactions uses strong crypto. The balances are unchangeable (even by a malicious server.) The receipts are destructible and redundant. The transactions are unforgeable. The cash is untraceable. The cheques are non-repudiable. Etc.

Open-Transactions is able to prove all balances, as well as which instruments are still valid, and which transactions are closed, without storing any transaction history (other than the last signed receipt.)

OT can be used to build wallets, market exchanges, and many other things. Basically anywhere you want to build secure transactions, you can use OT.

  how does money get into the open transactions network?

Any user choosing to act as an issuer can issue his currency onto OT servers by uploading a signed currency contract and then issuing a number of units. Then any other user can use the same currency contract to open asset accounts denominated in that same currency. (In practice, most users will not issue their own currencies, but simply use existing ones.)

Upcoming additions will enable currency units based on blockchain-based currencies to be issued on OT without an issuer, since the backing reserves will be stored in a multisig voting pool on the blockchain itself. For details on how this will work, see: https://bitcoin.stackexchange.com/a/834/6473

You may also be interested in this: How can Open Transactions benefit Bitcoin?


How to get the general population to pay more in transaction fees? When mining becomes less profitable* what options are there for miners and mining pools to persuade or insist that end users pay more in transaction fees?

I'm interested in

Specific code changes that need to be done in miners (to exclude low fee Tx)
Business plans (or description thereof)
Incentives of various types (..free Namecoins if pool X processes your Tx)

Sure there will probably always be miners who accept zero fee Tx but I am thinking that this might become the minority over time.  As a result these zero fee miners will finish fewer blocks and will cause zero fee Tx to be delayed before being added to a block.

*Mining can become less profitable for a number of reasons: increased difficulty, poor conversion rates, decreased reward, higher costs (hardware, electricity), or government regulation & taxation on mining income.

I don't think that it is definitely a good idea to increase the transaction fee.  One of bitcoins biggest selling points is the ability for micro-payments and very low transaction fees.  While I do agree with others that micro-transactions will eventually move off the blockchain.  For now even with the block-reward halving, transactions fees still won't benefit miners financially much for a very long time.  As again as I said the ability to make bitcoin transactions much cheaper than traditional means is one of bitcoins main selling points and will be for a long time.  Until such a date that the majority of bitcoin transactions are made off the blockchain.  Instead in house by larger bitcoin payment and services provider outlets.


Are blocks sent only after finding nonce? One of the concerns with increasing the block size is that it may get orphaned more often due to network latency in sending the big block. Why can't miners send the block without the nonce as soon as they start working on them. When they find the nonce, they can just send the nonce with block headers which will be quick. It will be also fast for other nodes to validate as they have to just check one hash with the nonce to know if the block is valid or not. They would have already validated the transactions before and merkleroot much before.

This effectively already happens on several levels, though without direct miner interaction. Both Bitcoin Core and the Bitcoin Relay Network have their own implementation of forward preparation for the validation of blocks with the intent of speeding up block propagation as much as possible. One focused on validation latency, one on bandwidth and latency.

Bitcoin Core has a validation cache of transactions it sees unconfirmed on the network, this allows the most expensive operations (executing the script, and validating signatures) to happen long before they are included in any block. Very often a node which has been active on the network for even a few minutes has already validated a large portion of any new blocks that arrive. When a new block is seen the uncached transactions are validated, inputs are checked, and the block is connected without having to do extensive, expensive validation of the contents.
The Bitcoin Relay Network takes this concept even further, it keeps track of transactions a node has already validated and transmits blocks excluding those transactions in order to save time on the wire. For many blocks this means the network only needs to push around the header (80 bytes), and a 2 byte integer referencing all the included transactions. An entire block might only be a few hundred bytes total and can be shuffled around the network quickly, then reassembled by the client using the transactions they already have in their mempool. A large portion of miners and services use this to drastically reduce network latency and subsequently their stale block rate over just using the P2P network to relay blocks around.

Miners do not transmit unsolved blocks purely because it would be a massive denial of service problem, and there might be hundreds of thousands of candidate blocks that don't get solved every hour. Ultimately the Relay Network achieves the same result as what you proposed (just transmit a nonce) and actually uses substantially less bandwidth than the normal P2P network.


Using the blockchain for providing other services, besides bitcoin transactions What I have in mind are proof of existence software, than are a kind a non-centralized and virtual notary service. They time-stamp digital information submitting a hash to the blockchain.

I know already that technically, the blockchain can be used for that. After all, it's basically a time-stamping system.

However, is this kind of service disruptive to the bitcoin community? Can it become disruptive when it reaches a certain level and be curtailed?

I also wonder whether the messages are prunable. Important are the transactions, not the associated messages. If the blockchain grow and grow, would the messages be still be kept?

There are already tons of services doing this, so probably worth focusing your creative efforts elsewhere. Here are the ones we know about on Coin Secrets:

Proof of Existence
BlockSign
Stampd
La Preuve
Bitproof
Stampery
ProveBit

As for pruning, assuming you use the same OP_RETURN mechanism as these tools, then they may be pruned by some nodes. But I imagine there will always be plenty of full archives of the blockchain available (even if this is eventually a paid-for service) so I doubt that your timestamped hashes will ever be truly lost.


ValueError: need more than 1 value to unpack I am giving this a try to see if I can do bitcoin mining. I took a Windows laptop and installed GUIMiner on it. I then connected to bitminter pool on http://mint.bitminter.com:8332 using my ID. When I click to start Mining, I get this message "ValueError: need more than 1 value to unpack". The summary then says "connection problems".

What am I doing wrong?

I was getting this error. Like the above answer states, I checked my password, saw that it was longer than it should have been and changed it, then quit getting the error. At least for me, it was a wrong username/password.


Is the potential number of blocks in the Bitcoin blockchain limited? i.e. Is there a finite number of transactions that will ever take place using Bitcoin?

I have Googled this somewhat and found discussions about Bitcoin's limited, finite supply, but it's unclear to me whether the blockchain itself is a finite resource.

No, there is no limit on the number of blocks in blockchain. The transaction can go on for ever.

The limit is only on the bitcoin that will ever be produced in the environment (Why was 21 million picked as the number of bitcoins to be created?) , but no limit on the number of times it can be exchanged.


How can one download the bitcoin client securely? What is the correct procedure to download the official bitcoin client, and validate it was signed by the developers, and not infected with any malware by a man in the middle?

Jeff Garzik signs every release with his GPG key (also here). You can find release announcements (such as this one) on the SourceForge.net Bitcoin development list.

To verify the signature on a release, obtain the key from the link above. Obtain the release announcement from the link above. Obtain the download from any source. Then point GPG at the release annoucement (or the signature block from it, including the BEGIN and END lines). GPG will ask what file you want to verify, pick any of the ones listed in the signature certificate. It will then tell you if the release is identical to the release Jeff Garzik signed.


Does anyone have a formula for adaptive blocksize? I want to implement this, so does anyone have a formula for adaptive blocksize?

I only found this:

if(average size of last 4096 blocks*4>maxblocksize &&
   median size of last 4096 blocks *8>maxblocksize)
        maxblocksize = (average size of last 4096 blocks*4)

You must have read this article and are looking to implement dynamic block size limits. You should know that it's not just a simple formula though that only affects one piece of code, it's more complicated than that.

I know of a few coins that have done this. Monero, Cryptonote, and ziftrCOIN. The latter is the one I am the most familiar with, so I'll explain how the solution works.

First, the block size and chain size is added to the block index. Then, whenever the tip of the chain is updated, the code checks, once every 3 months, to see if both:

The average block size is greater than 2/3 of the current limit.
The median block size is greater than 1/2 of the current limit.

If both are true, then it allows the maximum block size to increase by 10%. If this happened regularly for 2 years, the maximum block size would approximately double.


Cgminer not working with AMD APP SDK 2.8 Before I install AMD APP SDK 2.8, I get this error from cgminer 3.7.2:

  [2014-01-06 22:44:56] Error -1001: clGetPlatformsIDs failed (no OpenCL SDK installed?)
  [2014-01-06 22:44:56] clDevicesNum returned error, no GPUs usable
  [2014-01-06 22:44:58] No devices detected!

After I install APP SDK 2.8, I get this window:

  cgminer.exe has stopped working

My graphics card is ATI Radeon HD 545v. I have tried both Catalyst 13.4 and 12.10. The software versions are all 64 bit (except miners).

After installing SDK 2.8, guiminer exits when I run it. Before installation it shows a window:

  No OpenCL devices were found.
  If you only want to mine using CPU or CUDA, you can ignore this message.
  If you want to mine on ATI graphics cards, you may need to install the ATI Stream SDK, or your GPU may not support OpenCL.

Question: How do I get to mining?

Assuming you are using windows:

uninstall all AMD drivers

Do not install (uninstall) APP SDK.

download 3.11 beta version of catalyst drivers
http://www.guru3d.com/files_get/amd_catalyst_13_11_beta_9_2_(13_250_18_november_7)_download,1.html

Make sure you're cgminer settings are modeset and try again. If you are never on modest cgminer settings, you may never know if your software/driver config will work.


API Bitfinex question: "key amount should be a decimal string"? I started writing code for the Bitfinex api yesterday and I've been struggling quite a lot with this.
I am using jndok's python implementation.

I added my pyblic and secret keys and wrote this line of code at the end with python 2.7 on Windows 8:

rep = place_order(0.001, 589.0, 'sell', 'limit', exchange='bitfinex')

And I thought that would do it but the reply I get 'Key amount should be a decimal string' and the order is not placed.
I also tried to print the reply code I get from the server and it is 400.

How can this be resolved?

You are submitting a float value. Float values are not totaly accurate:

>>> 0.9
0.90000000000000002

Thats why the specification requires a Decimal datatype:

>>> from decimal import Decimal
>>> Decimal("0.001")


What is the simplest crypto-currency? I am looking for the most basic blockchain technology implementation. What is the simplest crypto-currency?

Crypto-currencies are not simple things.  They are a combination of various cryptographic primitives constructed in such a way as to create decentralized trust in a shared ledger.  The trust in the system depends on aligning the incentives of the participants so that game theory can predict their actions as rational actors.  If you are looking for simplicity...look elsewhere.

Most crytpo-currencies out there have been forked from Bitcoin.  From a technical perspective, it's probably best to think "Bitcoin" whenever you hear "blockchain technology", at least so far as the source code is concerned.  Most likely, you are dealing with a codebase that was originally forked from Bitcoin, but with changes made on top of it.  With that in mind, you could argue that Bitcoin is the simplest.

There are exceptions (like Ripple and CryptoNote) which have not been forked from Bitcoin, but I find it hard to say that any of these systems are simpler than Bitcoin.  They are different, less used, and therefore often considered less trustworthy.  There are probably some university projects out there which re-implement a blockchain with the minimal required complexity (such as with transaction scripts stripped out, which contribute a great deal to the complexity), but I am unaware of any.


Is BTC and Crypto Currency Illegal in USA My close friend who is the biggest currency rebellion I know. He introduced me to Bitcoin. Earlier he told me about some guy called Nothaus who created currency, in HI. However he got arrested for it.

Honestly he turned me onto BTC by advertising it as no banks, decentrized currency out of government control. Sounded great but is it legal, and is there something that is different in Nothaus's case as to why he was arrested?

The United States government has specifically stated that Bitcoins are not inherently illegal and have legal uses. You can find this both in the new FinCEN guidance and in the legal documents submitted in the Ross Ulbricht case.

See, for example, pages 12 and 13 of this complaint: "Bitcoins are not illegal in and of themselves and have known legitimate uses."


What does the label field in Bitcoin-Qt mean? I tried to get involved with Bitcoin on iPad, couldn't download a wallet and thought a paper wallet was an alternative; I generated said paper wallet and used the address to buy coins.

I realized I couldn't access the coins, so I bought a macbook to download a wallet. Assumed I could just add the address from the paper wallet, but its asking for a "label."

The label is just a short, memorable name for your client to refer to that address.

It can be anything, or nothing.


Possible better peer-to-peer protocols for Bitcoin? As we know, bitcoin uses flooding in order to propagate blocks and transactions across all the nodes in the network. As it was launched in 2009, it's been almost 10 years since it's launch and I was wondering if it was launched today, would it be able to use a more efficient P2P protocol/algorithm then the flooding mechanism employed today? As flooding can cause multiple transactions, albeit inv transactions, to be sent to the same node multiple times which is information that the node does not need and is unnecessary. Are there any better state-of-the-art p2p protocols that could be a better fit for bitcoin today?

The network used today isn't actually the same as the original design, which did not have an inventory system at all, every transaction and every block was sent to every peer indiscriminately. Compact Blocks was also added to remove redundancy in block transmission and reduce latency, as blocks predominantly contain transactions which have already been forwarded around the network previously. Fee based filtering was added to allow nodes to request that peers to not send transactions which will be rejected regardless, which saves bandwidth.

The P2P protocol, while not ideal, is relatively functional in its current state. It is an unusual set of requirements (flooding, censorship resistance, sybil avoidance) which doesn't have much simularity to many other systems.


Can I use lightning for ERC-20 (Ethereum coins) Just finished setting up my lightnig node. It is awesome!! Does anybody knows an implementation or documentation that explains how to make it work on rinkeby or ethereum mainnet?

Short answer there is non.

The Ethereum people have tried to create the Raiden Network which is supposed to be their offchain solution. As far as I know (thought not 100% certain) They use ERC-20 tokens to create payment channels but the network cannot transfer ERC-20 tokens. The Lightning Network Protocol itself is currently only designed to transfer an amount of currency.

One of the reasons is that the onions of the transport layer are limited in size.

If you are interested in transfering smart contracts or tokens you might want to look at the RGB Project by BHB Networks. This group tries to create colored coins (which are basically tokens) on top of bitcoin in a way that this is compatible with the Lightning Network. However this is work in progress and will - according to one of the main developers - take probably years before it is ready to use.


Can bitcoin-qt use imported address as a change address? If I import a private key into a bitcoin-qt wallet, is it possible that some day some transaction I send from the wallet will use its pair address (the bitcoin address created from this private key ) as a change address target in the outputs ?

On Bitcoin-QT can use whatever change address you want. Go to Settings->Options->Wallet and check "Enable Coin Control Features". Now when you go to send you can check "custom change address" and enter whatever you want, even if you don't have the privkeys.


How to know btc wallet name/website ? Is there any way to know bitcoins wallet name using these details

pubkey publicaddress rsz signatures sha-256 ripemd160 script signature ( asm & hex )

None of the values mentioned are linkable in any way to the software that generated the address. Bitcoin Addresses are standardized, and all wallets follow identical rules for generating them.

Your only option to determine which software an address originated from is to have some backup of the wallet file, or some other indicator, such as an email confirmation.


LND describegraph and getnetworkinfo RPC response The LND API documentation is here, but doesn't contain much information about what the responses to various calls mean. Can anyone explain what these responses are describing?

describegraph['edges']

I understand this to be channel data, but not sure exactly what it's describing.

"time_lock_delta": 14,
"min_htlc": "0",
"fee_base_msat": "546000"
"fee_rate_milli_msat": "10"

getnetworkinfo

"avg_out_degree": 2.841628959276018
"max_out_degree": 102

After looking into the code and running some tests I think I've found the answers:

avg_out_degree is the average channels per node. In other words, total channels / total nodes = avg_out_degree. source
max_out_degree is the maximum channels (sum of incoming and outgoing) found on a node in the network. This can be found by iterating through every node and summing their incoming/outgoing channels to find the maximum. source
time_lock_delta: the required timelock delta for HTLCs forwarded over the channel. source
min_htlc: the minimum value in millisatoshi required for incoming HTLCs on the channel. source
fee_base_msat: the base fee charged regardless of the number of milli-satoshis sent. source
fee_rate_milli_msat: the effective fee rate in milli-satoshis. The precision of this value goes up to 6 decimal places, so 1e-6. source


How proof of work prevents double spend One article I am reading said that proof of work system is used in Bitcoin to prevent double spending. More particularly:

Imagine we are protecting against double spending in following way. When Bob receives transaction from Alice saying that "Alice transfers some 1234 BTC to Bob", bob would broadcast this to entire network to ask them to verify whether this is a legitimate transaction. In the mean time say if Alice had sent also same message to Charlie (saying that she is transfering same 1234 BTC to Charlie), Charlie would have also broadcast this message and other nodes on the network would spot that Alice is trying to spend same 1234 BTC with two persons, and they would let Bob (or Charlie) know that this is invalid transaction. Or if all is ok Bob or Charlie would wait till some nodes send acknowledgment that this is valid transaction.

SOCK PUPPET ATTACK: Above scheme would work but Alice could cheat in the following way. She could create say one million fake identities on network, and they would lie to Bob and Charlie that the transactions was valid- making them accept payment.

Now comes my question. It seems proof of work was introduced in Bitcoin to prevent exactly the above kind of sock poppet attack. But I fail to see how proof of work helps protect against above sock puppet attack. Why would Alice not be able to introduce those fake 100000 identities on the network anymore?

Can someone ealaborate and explain?

ps. I know what proof of work is, this question is more related how and why it prevents above mentioned sock puppet attack.

It is not really the Proof of Work which prevents double spends but rather the blockchain itself which prevents double spends. The Proof of Work is just one aspect of the blockchain.

For a transaction to be considered final, it must be in the blockchain. Otherwise it could disappear forever and everyone forgets about it. For a transaction to be added to the blockchain, it must be included in a block, and miners will do a Proof of Work for the block. In order for the transaction to be included in a block, the outputs that it spends from must have not been spent by any other transaction in the blockchain nor by any other transaction in the block. If such an other transaction exists in the blockchain, then the block will be invalid.

It is this process of including transactions in blocks which avoids double spends. It essentially establishes an order and says "this transaction is the real transaction, all others which spends any of the outputs which this transaction spends are fake".

The proof of work mechanism exists in Bitcoin because that is what makes the blockchain immutable. A valid proof of work means that a miner is proving that they did a certain amount of work, on average, in order to produce a block. In order to replace that block, someone else must also do about the same amount of work for that block. If someone wanted to modify a block in the blockchain and have everyone accept it, that person must perform the same amount of work that went into creating the block, then do the same for every single block that follows it because those blocks would be invalid since a block in their history has changed. This makes the blockchain immutable; the amount of work required to rewrite history is considered to be infeasible and much too costly to do practically. That is what the Proof of Work is for.


Is it possible to create a system for 'shared wallets' on top of bitcoin? Is it possible to build a system on top of bitcoin, where:

Random people will deposit money in a wallet X.
Nobody has access to that wallet.
After a few months, those users will vote in other wallets for the money in wallet X to go.
The money in wallet X is distributed between those wallets.

Is it possible on top of bitcoin, or would it need the design of a new system?

Yes, it's called a Distributed Contract or a Smart Contract.

Projects like Ethereum are aiming to make this much more of a reality. Currently they're a bit of a pain to write.


Can a regtest bitcoind node use SignRawTransactionWithKey + prevtxs for a mainnet raw transaction? I want to know if a regtest nnode can sign a raw mainnet transaction with the signrawtransactionwithkey rpc provided that I pass the correct keys and prevtxs as the regtest node will not be aware of them?

No, you will get an Invalid private key error. Note that if you use a correct-network private key but it is the wrong key to sign the input you provide you get a different error: Unable to sign input, invalid stack size (possibly missing key)
The base58 prefix is checked against a constant value that is different for each network (main, regtest, etc)
const std::vector<unsigned char>& privkey_prefix =
    Params().Base58Prefix(CChainParams::SECRET_KEY);

https://github.com/bitcoin/bitcoin/blob/master/src/key_io.cpp#L132-L148


What is the story behind MtGox and their French bank? MtGox has their French bank account closed last year, as the bank stated they aren't legally allowed to undertake the activities they were doing in regards to trading Bitcoins. There have been a few decisions in this regard as well as a few appeals. What is the full story behind the whole issue and have any conclusions been reached?

The important answer is on https://support.mtgox.com/entries/20568322-all-eur-transactions-will-be-temporarily-suspended-within-europe-with-immediate-effect

quote :

  "While Bitcoin at a European level is so far not directly impacted by
  this decision, the Bank de France (France's central bank) has
  confirmed that because of European banking rules, monetary transfers
  (deposits and withdrawals) through a single entity are subject to
  financial regulation and therefore can only be performed by licensed
  financial institutions such as banks or Payment Service companies (the
  European Equivalent to a Money Service Business). This decision has
  forced us to find other payment processing partners within Europe that
  will allow us to quickly resume all EUR transactions for our European
  customers soon."

To be allowed to accept deposits, keep your funds, and allow withdrawals, mtgox ( and any other European based exchange, like virwox for example ) have to be registered as a Payment Service Company (the European Equivalent to a Money Service Business).
 Since virwox is in Europe, they are probably illegal if they dont have this Payment Service Company license

This is true for any website or company wanting to accept deposits, keep your funds, and allow withdrawals, bitcoin related or not
 This decision is not related with bitcoin, it applies to anyone.

Registering as a Payment Service company takes time and is very expensive.

more details for :
Money Services Business  : http://en.wikipedia.org/wiki/Money_services_business
Payment Service provider : http://en.wikipedia.org/wiki/Payment_service_provider


Can i compose a multisig address where one of the signatories is a multisig address? Can i compose a multisig address where one of the signatories is a multisig address?
In order to create a multisig address we need the pubkey of the signatories.

bitcoincli addmultisigaddress 2
'["pubkey1", "pubkey2",..."pubkey(n)"]'

Is anything stopping me from using a multisig address as one of the signatories?

Essentially: can one of the signatories be a multisig address (one that currently starts with a 3).

No this is not supported behavior. You can manually add the public keys from one multisig script into another, but a multisignature script can not be nested within another.


Can Ripple Unique Node Lists (of validators) be weighted? My understanding is that in order to limit / remove the risk of collusion in the Ripple system the consensus mechanism relies on local Unique Node Lists (UNLs) specific to each node in the network (but potentially provided to the node by a gateway or other third party).

My question is whether these UNLs can be assigned discretionary weights by the user (e.g. if the list comprises A,B,C nodes, can they be weighted 4/6, 1/6, 1/6 respectively)?

If not, would it be possible to include a node several times on the list to achieve such weighting, or do they have to be 'unique' as 'Unique NL' seems to suggest..

(Weighting might be interesting if a large amount of trust is ascribed to one or more particular nodes..)

I have information from the #ripple IRC channel that 'unique' nodes are weighted equally in the current implementation.


What is the current Status of major proposed BTC upgrades like Taproot, MAST, Submarine Swaps? I have read during the last year about some very interesting BIPs or initiatives. I am not asking for their explanations, just would be great if anyone would know about their simple status as of now, whether they are still considered to be implemented at some point (do you know when?), or whether they have been removed from consideration...

1)  MAST

2)  TAPROOT

3)  SCHNORR

4)  Submarine Swaps

5)  Consumer Lightning-based applications (desktop+mobile by Jack Mallers)

6)  Drivechain Sidechain, by Paul Sztorc

7)  Lightning over NFC, by Igor Cota

I just dont know where to track those initiatives .

Thanks!!

1) MAST: Essentially folded into Taproot

2) Taproot: Planned to be part of the upcoming SegWit V1 softfork. A formal proposal for that has been about two weeks away for half a year, so could appear any day now. ;)

3) Schnorr: All SegWit V1 transactions will only allow Schnorr signatures and no ECDSA signatures. I am not sure whether the first release of Schnorr signatures will include any form of signature aggregation beyond the one used in correspondence with public key aggregation, i.e. making multisig look like singlesig.

4) AFAIU, Submarine Swaps have been implemented in both directions. The variant from chain to Lightning has been live for a while and Lightning Lab's Lightning Loop has greatly simplified offering Lightning to on-chain transition.

5) Lightning Network is mostly for masochists, enthusiasts, and experts still. If you're attempting to dive-in at this time, I would suggest to bring a good amount of frustration tolerance. ;)

6) I talked to Paul about that a bit a few weeks ago. He's making progress. There are some disagreements on whether or not he has been able to solve the challenges that caused other sidechain projects to be severely delayed. I am not sure whether deployment requires a softfork, but the drivechain doesn't appear to have achieved broad interest at this time.

7) I know nothing about Lightning over NFC.

All of the above from the top of my head and probably in dire need of corrections and/or substantiation. Will edit as people tell me where I'm wrong. :)


Java: way to convert a 256-bit private key to WIF? I have a question concerning Java and sha-256.

I try to do these steps discribed here to create a WIF key:
https://en.bitcoin.it/wiki/Wallet_import_format

step:

  String string
  = "0C28FCA386C7A227600B2FE50B7CAE11EC86D3BF1FBE471BE89827E19D72AA1D";

step (ad 80 in front):

  string = "80" + string;

perform sha-256:

here is my mistake. I can perform sha-256 on step 2 but the result is wrong. The reason seems to be perform the hash on a String and not on binary.
I get:

  e2e4146a36e9c455cf95a4f259f162c353cd419cc3fd0e69ae36d7d1b6cd2c09

But I should get:

  8147786C4D15106333BF278D71DADAF1079EF2D2440A4DDE37D747DED5403592

I dont get how to convert it to binary. Can someone help me?

Its the same problem as here (Correct way to convert a 256-bit private key to WIF?) but I dont understand the answer. I also cant reply to the thread because I dont have enough reputation.

Thank you :)

You should convert hex representation of bytes to byte array (not String to byte array). Then make hash. Then convert the byte array back to hex representation of bytes in String.

The whole solution will look like:

import java.security.*;

class HashExample {
    public static void main(String[] args) throws NoSuchAlgorithmException {
        String string = "0C28FCA386C7A227600B2FE50B7CAE11EC86D3BF1FBE471BE89827E19D72AA1D";
        string = "80" + string;
        byte[] data = hexStringToByteArray(string);
        byte[] digest = MessageDigest.getInstance("SHA-256").digest(hexStringToByteArray(string));
        String result = bytesToHex(digest);
        System.out.println(result);
        //prints: 8147786c4d15106333bf278d71dadaf1079ef2d2440a4dde37d747ded5403592
    }

    public static byte[] hexStringToByteArray(String s) {
        int len = s.length();
        byte[] data = new byte[len / 2];
        for (int i = 0; i < len; i += 2) {
            data[i / 2] = (byte) ((Character.digit(s.charAt(i), 16) << 4)
                    + Character.digit(s.charAt(i+1), 16));
        }
        return data;
    }

    private static String bytesToHex(byte[] bytes) {
        StringBuffer result = new StringBuffer();
        for (byte b : bytes) result.append(Integer.toString((b & 0xff) + 0x100, 16).substring(1));
        return result.toString();
    }
}

Of course this is just example. In production code I recommend to use one of the available libraries which can perform this task.


How can one blockchain with the same block heigth as another, have more Proof-of-Work I am reading Andreas M. Antonopoulos's book and In chapter 10 - Assembling and Selecting Chains of Block he writes:

  Under most circumstances this is also the chain [main chain] with the most block
  in it, unless there are two equal-length chains and one has more
  Proof-of-Work.

Can somebody explain how this is possible? How can 2 chains with the same length have different cummulative Proof-of-Work? Is it because they might include block that were mined with different difficulty targets? Not sure how this could happen, but this is my only hypothesis.

How can 2 chains with the same length have different cummulative Proof-of-Work? Is it because they might include block that were mined with different difficulty targets?

That is correct. The bitcoin protocol actually follows the chain with the highest accumulated proof-of-work, not the largest block height.

I believe the original implementation followed the largest block height, but that left the network open to certain attacks, so it was soon changed to largest accumulated proof of work.


Bitcoin public key pre-0.6 length before hashing As I understand, since bitcoin 0.6.x, compressed and uncompressed public keys are supported. And the process from the public key to the address has the step that puts a byte in front of the public key before hashing, like:

0x04<256bit x><256bit y> = buffer before hashing the uncompressed public key

or

[0x02|0x03]<256bit x> = buffer before hashing the compressed public key

That implies that the buffer before the hashing is either 33bytes long or 65 bytes long.

My question: pre-0.6, all the way back to the first public version of bitcoin, is the buffer pre-hashing always 65 bytes long, since compressed keys were not supported? Or was it 64 bytes long (just <256bit x><256bit y>) and there was no byte for the version prepended before hashing?

If it was just the 64bytes of the public key on clients pre-0.6, that means that for the same public key, if I ran that public key through the code path of both pre-0.6 bitcoin client and current bitcoin client (uncompressed fomat), the final bitcoin address would still be different, since the modern client would prepend the version byte?

is the buffer pre-hashing always 65 bytes long,

yes

  since compressed keys were not supported?

they were not used by anybody. but there were no changes in client to "implement/support" them

  Or was it 64 bytes long (just <256bit x><256bit y>) and there was no byte for the version prepended before hashing?

no. the client was written with openSSL library. This library always appends prefix to public key bytes (this is standard encoding defined somewhere)


How can I pull the "Candles" argument from the Huobi websocket data? I've a problem with Huobi Websocket, I know my ways in REST API but new to asyncio and websockets, and Huobi only gives resonable amount of history through websocket request so I'm stuck with it. I'm using their [sdk](https://github.com/HuobiRDCenter/huobi_Python. I managed to figure this out:
from huobi.client.market import MarketClient
from huobi.client.market import CandlestickInterval
import pandas as pd
from pandas import DataFrame as df

def callback(candlestick_req: "CandlestickReq"):
    Candles = candlestick_req.data

Market_client = MarketClient()
Market_client.req_candlestick("btcusdt", CandlestickInterval.MIN60, callback, from_ts_second = 1611788400, end_ts_second = 1614812400)

History_dataframe_new["Date"] = [Candles[f].id for f in range(len(Candles))]
History_dataframe_new["Open"] = [Candles[f].open for f in range(len(Candles))]
History_dataframe_new["High"] = [Candles[f].high for f in range(len(Candles))]
History_dataframe_new["Low"] = [Candles[f].low for f in range(len(Candles))]
History_dataframe_new["Close"] = [Candles[f].close for f in range(len(Candles))]
History_dataframe_new["Volume"] = [Candles[f].vol for f in range(len(Candles))]

The problem is, how can I get this Candles argument out of the callback to use below? I'm not calling callback directly, only in the req_candlestick so return won't work. And it's a callback so I propably have to wait for the response somehow. And tips how to do that? Or if what I'm trying here is the correct way?

I will just throw it out here, there is a better way to do it, here above I was using Huobi SDK but I find using websocket without any external libraries better. A great template for websocket connection below:
import gzip
import json
import pprint
import threading

import time
import websocket

def send_message(ws, message_dict):
    data = json.dumps(message_dict).encode()
    print("Sending Message:")
    pprint.pprint(message_dict)
    ws.send(data)

def on_message(ws, message):
    unzipped_data = gzip.decompress(message).decode()
    msg_dict = json.loads(unzipped_data)
    print("Recieved Message: ")
    pprint.pprint(msg_dict)
    if 'ping' in msg_dict:
        data = {
            "pong": msg_dict['ping']
        }
        send_message(ws, data)

def on_error(ws, error):
    print("Error: " + str(error))
    error = gzip.decompress(error).decode()
    print(error)

def on_close(ws):
    print("### closed ###")

def on_open(ws):
    def run(*args):
        data = {
            "req": "market.btcusdt.kline.1min",
            "id": "id1"
            "from": int("fromtimestamp")
            "to": int("to timestamp")
        }

        for i in range(5):
            time.sleep(2)
            send_message(ws, data)
        ws.close()
        print("thread terminating...")

    t = threading.Thread(target=run, args=())
    t.start()

if __name__ == "__main__":
    # websocket.enableTrace(True)
    ws = websocket.WebSocketApp(
        "wss://api.huobi.pro/ws",
        on_open=on_open,
        on_message=on_message,
        on_error=on_error,
        on_close=on_close
    )
    ws.run_forever()


How to change the wallet on the fly with bitcoin-qt A friend and I want to create a simple webservice for ourselves, that can do transactions from our wallets. We want to keep our wallets separate. So how can we exchange the wallet that bitcoin-qt uses without restarting the application? Is that possible? Or is there another bitcoin client with a JSON-RPC or similar that we can use for that?

EDIT:
The plan is that we have a simple webinterface (PHP-based) where we enter the receiver, the amount, the username (will correspond to the name of the wallet file) and the wallet password. The script would then send the data to bitcoin-qt (or whatever we use) which will then execute the transaction. Also, it should be possible to view the amount of BTC that each wallet has (After entering the password of course).

We have a dedicated server, everything will run on that.

First thing: encrypt that Dedicated server's entire hard drive.
Secondly: encrypt that wallet.dat file
Thirdly: use EVERY possible method of attack defense you can. Use googleauth for 2 step log in. disable root access. If you must run SSH, run it under a random port. NOT port 22. use tripwire mod_sec/mod_evasive, if you think it might be good... add it. use UFW firewall. Use insane settings. If you only plan to sell to one country: block ALL IP's that are not within that country
Disable ALL error notifications and disable any information that may allow the attacker to gain any information about what the server is run on (no "this server run on apache centos" etc). I do assume you do know this, but im just giving fair warning.
Host as few applications beyond the bare minimum. (so no minecraft servers).
I personally recommend not keeping funds in a hot wallet because ~/.bitcoin/wallet.dat is the most searched for thing by hackers

Now... How can you have two different wallets on the same machine? well. there's a few ways to do it... If you want to keep generating infinite new addresses (using infinite seeds) all the time and have a good contingency plan in place for your wallet.dat file (like hourly back up etc), you could run 2 instances of bitcoind. (commandline version is what you want for this) Two instances can be run by changing the listening ports on one of the two bitcoind instances and running each instance on its own user account. you can then (depending on which user you are paying to) have php connect to the respective bitcoin client and request an address for payment.
Another idea i would propose could be using one bitcoin client and having accounts. If you are okay sharing one wallet and one daemon, but need your own account for accounting balances, its a breeze

Side note
there are a few projects that actually are pretty good. I started writing a basic bitcoin escrow system based off of my own coding and using  "The Bitcoin Shopping Cart Interface package" and "The Bitcoin Shopping Cart Interface package"

http://sourceforge.net/projects/bitscrow/
I use to have a much more advance version i built for FreiCoin but the wonderful people over at FDCServers destroyed my development server on me (thanks guys). So I am pretty far behind again. However you should at least have an idea of maybe a general direction to start
This version requires no  bitcoind at all which is pretty unique. But if you want a wallet, then you may need to integrate that yourself.

you could also consider installing drupal and modifying the source to have a two different plug ins going to the two different daemons.

there are many options.
you can even start from scratch, good documentation is available here.
https://en.bitcoin.it/wiki/PHP_developer_intro

Please let me know if this was useful or not, and let me know if there is further clarification needed. If you want to truly have your own page it's a lot of work...

Also, check out https://github.com/Bit-Wasp/BitWasp

I have been playing around with it and its been pretty cool so far.

thanks for giving me the information i needed to try and respond as best i can


Add wallet feature to bitcoind (full node) after installation with --disable-wallet I installed bitcoind with this configuration:
`./configure --without-gui --disable-wallet`

However, after it finished downloading the blockchain for a week, now I realize I actually do need the wallet feature. Is there a way to add it back (without another week of verifying the blockchain)?

The data directory is independent of the installation. Just recompile with the wallet enabled, install the binary over your existing one, and it'll use the same data directory and all of the data inside of it.


Exporting secure seed using bitcoin core I am trying to secure my own bitcoin.

I want to generate a bunch of addresses from a HD Seed, however I am paranoid about the security of any seed generated from any website and so only trust in the bitcoin core client.

I have downloaded and compiled the bitcoin-core client, but am struggling to understand how to export the seed and or seed + my password.

Is this feature not available on bitcoin-core and if not is there something else people use to secure large amounts or bitcoin using a HD seed +  custom password.

My ultimate plan was to then get one of the addresses generated from this seed, plus 2 other addresses from other seeds on other remote machines to then create a multi sig address for securing my bitcoin.

Any help/input appreciated.

Bitcoin Core uses BIP32, but does not implement BIP39 - As such, you cannot export a set of seed words, since the seed to BIP32 master key conversions is one way only, and it is not possible to obtain seed words if you only have the master key.

You should simply back up the master key itself, and import it into another instance of bitcoin core when needed. The dumpwallet command will help you with that.


How can I track assets in Bitcoin? I heard that in the future Bitcoin has the ability to track physical assets.

Can someone explain how this would be done? (generally speaking)

Any assets can be represented on the blockchain using marked or colored coins. Therefore it's also possible to transfer the ownership of any asset using colored coins. Since the blockchain is public, assets being represented on the blockchain can also be tracked.

Colored or marked coins are basically bitcoins representing -other than their face value- ownership or access right to some other asset assigned to them by the original owner.

Very simple example: I'm a gold merchant and I'm announcing that I just transferred 0.0001 btc from my address A to address B and that transfer also represents 1kg of gold at my merchant store. Whoever B sends that 0.0001 btc to can transfer it back to me and claim ownership of 1kg of gold.

Now everyone can trade that 1kg of gold using the blockchain. I can track which address owns it. The owner can trade it with other assets as well.

It actually does not need to be the same amount. It works using inputs and outpus of bitcoin transactions.

It's pretty cool stuff but the Bitcoin protocol might not be able to carry the extra load this type of transactions can bring.

Here is a paper discussing the idea: https://docs.google.com/document/d/1AnkP_cVZTCMLIzw4DvsW6M8Q2JC0lIzrTLuoWu2z1BE/edit#


Atomicity on HTLC payment chain I have a doubt about HTLC on a lightning network payment. I have this scenario:
Alice wants to pay 100 sats to David using a route she found with Bob and Chad, this would be:
Alice -> Bob -> Chad -> David

Alices sends the HTLC to Bob, Bob to Chad and Chad to David, everything goes as expected, David wants to reveal the secret to Chad and they update their channel state, now David have +100 sats on his channel balance and Chad have -100 sats.
Chad do the same with Bob and now Chad have +100 sats on his side of the channel and Bob have -100 sats on his side.
At the moment Bob wants to do the same with Alice his node crash and go offline (for days), Alice can wait for the timeout and get her funds back, Bob would lose the funds.
I read before that an HTLC chain was atomic, all payments are successful or none of them, is this true? in this case David and Chad got their payments updating the channel state but not Alice so this case is not atomic.
What I am missing here?

It is atomic
If a node goes offline the htlc will not be settled off chain but onchain. of course that is more expensive with respect to fees but that is true for channel closes in any case


what should I do when CDF is really high? I noticed today on Bitminter that the CDF is over 99% and the block session has been running for almost 12 hours now. what causes such a high CDF and is there anything that can be done about it?

CDF is a measure of the pool's (bad) luck in the near past. By the nature of randomness (and how it applies to the process of mining), every pool will have times of good and bad luck, and nothing can be done to fix that.

If you are mining at a pool using a hopping-proof method such as PPLNS or DGM, you don't need to do anything when the CDF is high. The CDF represents the pool's luck in the past, but your reward for continued mining depends only on the pool's luck in the future, and thus the CDF has no effect.


blockcypher amount transacted larger than amount transferred When transferring some bitcoin from coinbase to my hardware wallet, I see on coinbase and on my hardware wallet that the amounts sent and received are about the same (minus a transaction fee), as expected.  But when I look up the transaction on live.blockcypher.com, the Amount Transacted and the Input Consumed is much larger than the amount I transferred.  There are two outputs, one unspent amount matching the amount I transferred minus the fee (and using my hardware wallet address) and one spent amount equal to the difference between the amount transacted and the amount I transferred (using a wallet address I don't recognize).  Why is the Amount Transferred larger than the amount I actually transferred?  Thank you.

When you create a transaction, you have to specify where the bitcoins you are spending have come from, as well as prove you are allowed to spend them. That is known as an input to the transaction. Inputs refer to outputs of previous transactions, which have not yet been spent, called UTXOs (unspent transaction outputs). Each UTXO must be spent all at once, you cannot partially spend one, when it is used as input to a transaction. Thus you will generally need to choose a UTXO which is larger than the amount you are trying to spend, and then send yourself back some change to make up the difference. That is what the second output you see is, it is the change being sent back to your wallet. See also:

If bitcoin is indivisible, where does change come from?
How does change work in a bitcoin transaction?
Why does Bitcoin send the "change" to a different address?
How is it possible to say that a bitcoin was fully spent?


Why will a miner verify the digital signature, instead of directly adding a transaction to the Merkle tree? I am a complete noob to Bitcoin, and this question might seem obvious to some. But I can't seem to get my head around it. I read how the process of mining works - they select transactions, verify them, create a merkle tree, and then start creating nonces. I want to ask whether a miner can skip the part of verifying a transaction, and just take the transactions as they come, just add them and be done with it? That is, what part of the protocol prevents him from defuncting, in some sense?

Sorry if this is obvious.

If a miner would do so, and the transaction they include is invalid, they would produce a block with invalid transactions in them. As all full nodes on the network (not just miners) verify all transactions in blocks, they would reject this block, and the miner would lose their reward.

By extension, other miners will avoid building on top of such a block, as they too do not want to lose their reward.


Why can addresses be shorter than 34 bytes? The wiki entry on Address says:

  Some Bitcoin addresses can be shorter than 34 characters (as few as 27 in theory) and still be valid. [...] These shorter addresses are valid simply because they stand for numbers that happen to start with zeroes, and when the zeroes are omitted, the encoded address gets shorter.

Alright, but according to this diagram, a main-network address is:

Base58Check(00 ++ RIPEMD160(SHA256(04 ++ pubkeyX ++ pubkeyY)) ++ checksum)

Next we look at the entry for Base58Check and we see step 4 is:

  4) Treating the results of step 3 - a series of bytes - as a single big-endian bignumber, convert to base-58 using normal mathematical steps (bignumber division) and the base-58 alphabet described below. The result should be normalized to not have any leading base-58 zeroes (character '1').

First strange thing - if it's treated as a single big-endian number, shouldn't prepending the main network byte of 00 not have any effect? Since that is the most significant byte it'd be like writing 00123 instead of 123 in regular notation, no?

Second strange thing - if the result should be normalized to have no leading zeroes, doesn't that mean that the output should never have any 1s in it? Step 5 seems contradictory to this

  5) The leading character '1', which has a value of zero in base58, is reserved for representing an entire leading zero byte, as when it is in a leading position, has no value as a base-58 symbol. There can be one or more leading '1's when necessary to represent one or more leading zero bytes. Count the number of leading zero bytes that were the result of step 3 (for old Bitcoin addresses, there will always be at least one for the version/application byte; for new addresses, there will never be any). Each leading zero byte shall be represented by its own character '1' in the final result.

It seems step 4 would have stripped out any possible leading bytes. However, in the case that it didn't, and for some reason it didn't with the prepended 00 byte, shouldn't an address have multiple leading 1s, e.g. 11175tWpb... instead of simply being shorter, e.g. 175tWpb...?

EDIT: Ok, it seems that what it is saying is that given payload X, base58(X) is normalized to remove the zeroes, and then you prepend a 1 for each leading byte of X, not base58(X). It still raises the question of why addresses are shorter instead of having multiple 1s. Is it that the RIPEMD160(SHA256(04 ++ pubkeyX ++ pubkeyY)) happens never to have too many leading 0s (which would be prepended as 1s) while base58(RIPEMD160(SHA256(04 ++ pubkeyX ++ pubkeyY))) does (and they are cut out of the final result)?

Yes there can be multiple leading '1' characters, and each '1' represents one leading zero byte. This leads to a shorter address because normally each base58 character represents slightly less than 6 bits of information, but a leading zero byte contains exactly 8 bits of information.

For example the shortest address you can have is 1111111111111111111114oLvT2 (representing 160-bit hash of 0000000000000000000000000000000000000000). It has 21 leading "1" characters representing exactly 21 leading zero bytes (the hash prepended by another 00).


Brother died and I am sole survivor..just found out he has a wallet. How do I go about getting his bit coins I have no info Brother died I am the sole survivor. I have no info..How do I retreive ..I have death certificate. Thank You
LJF

I have no info..

Without information, you cannot get control of any Bitcoin your brother possessed.
You need some details of his wallet or of his account with a Bitcoin exchange.

How do I retreive

If he looked after his own money in a Bitcoin wallet on a computer or phone, you need to be able to log in to that device and run the wallet program and enter any password he set on the wallet. He may have kept a note of his wallet's "private key" or its 12, 18 or 24-word "recovery phrase" written down somewhere safe. E.g. on paper or stamped metal in a safe. If so, you can use this information on a different computer to create a new wallet that controls the same money.
If he had an account with a business that looked after his money for him, you'll need to find out the name of that business and his login details. It is possible you would find some details in his old email messages.

I have death certificate.

That might be of use if his money was in an exchange and you know his account name but not his account password. You or the executor of his estate would need to contact the exchange  directly about this.

You will be contacted by people offering to help you. 99% of these will be scammers intending to trick you into trusting them with any details you find, or who will trick you into paying invented recovery fees but who will never give you access to your brother's money. Be very very careful.


When joining the bitcoin network, why aren't we connected to the most geographically closest nodes? Is this a safety/security reason or is it just convenience?

There isn't any reason that I'm aware of to think that this would be desirable. I'm not aware of any way that it would improve things and it would make the network highly prone to partitioning. E.g. why would the nodes in north america ever have any connectivity to the nodes in europe?

Making some number of additional connections to nodes on your LAN would probably be useful, but it isn't that often that there are multiple nodes on a LAN.


Account extended private key vs BIP32 extended private key I would like to know which is the difference between Account extended private key and BIP32 extended private key. I was creating Mnemonic seeds (https://iancoleman.io/bip39/) and I stopped because I could not find out the difference

BIP 32 extended private key is a more generic term that refers to any private key that is derived and serialized according to BIP 32.

Account extended private key is the BIP 32 extended private key at a specific derivation path. This is described in BIP 44. For P2PKH Bitcoin addresses, this derivation path is m/44'/0'/0'.


Is there a simple method of tracking number of transactions sent to an address? I want to create a counter in my store displaying the number of units sold.

I'm not using a shopping cart, but simply placing a bitpay button.  I'm wondering if there is a way to query the blockchain, that will return the number of transactions sent to an address, over a given time period.

You can see the number of transactions for a Bitcoin address. That's easy. Either through a desktop wallet(Like Bitcoin QT) or using services like blockchain.info. Just search for an address there.

You can't do this for your site thought because you're using Bitpay and they provide a unique address for each payment to your site.

Even if you weren't using Bitpay, you would need to generate a unique address for each purchase on your site to be able to figure out which customer paid how much and when.

You could take an aggregate of the transactions and display them along with each unique address you used but I would strongly advise against it. Because then people could easily trace where you spend the Bitcoins that your customers paid you.

Try getting the number from your accounting records instead of trying to get it from Bitcoin payments ;)


Multibit notification I have  a blockchain.info account and I would like to move my wallet from the web interface to the multibit client.
However, I need that once an incoming transaction have been confirmed I need to call  web service to update a remote database.
Is this possible to do this without modify the multibit code?
I have some experience in Java but this seems beyhon my current skill.
In case I can evaluate other client.

Thanks in advance for any help

As MultiBit HD is targeted for end users it does not have any external API.

Have a look at the WalletTool in the bitcoinj examples module (the Bitcoin network code MultiBit uses).

It gives you a command line interface into bitcoin confirmations.
It's much simpler than the MultiBit HD code so will be much easier to tweak to do what you want.


Please help with Bitcoin Core. Password All kind time of day. From the Internet I learned about Bitcoin. Decided to support this movement. Downloaded Bitcoin Core put 0.5 BTC to buy two S9. At the beginning of the habit to put password and when the time came to transfer the BTC realised that a password is forgotten. Attempts to recall were not successful. Waiting for the wise advice how to be and what to do to restore the wallet. Thanks in advance if you have understanding and support.

I am afraid, you can not recover your wallet without the password. That is the idea of the password: if someone steals your wallet, she can do nothing without the password.

So, try hard and do recall the password.


How could the protocol or client be altered to mitigate a timejacking attack? I've read about the proposed Timejacking attack:

http://culubas.blogspot.com/2011/05/timejacking-bitcoin_802.html

There are a number of solutions proposed, but it seems like there might be a simpler solution to make the selection of peers more random.

As I understand it, the attack relies on an attacker being able to connect to a specific target node.

Wouldn't either of the following two solutions work?

Differentiate between input and output peers. Allow anyone to connect to you to receive information from you but only take information from peers that you connect to. This would make it very difficult for an attacker to have a large number of connections to a specific node because the node is randomly choosing which nodes to receive data from.
Continuously change connected nodes. i.e. every minute or so, disconnect from one connected node and find a new one to connect to. This would create a constant rotation of nodes that would make it much harder for an attacker to keep his/her connections to your node.

Solution number 1 would mitigate this problem, but the attacker could try creating enough nodes to flood the network anyway (see cancer nodes). It would not be likely that the attack would be performed, but it would still be possible.

Solution number 2 would help with this problem, although it would cause a lot more problems with everything else. Imagine the excess traffic caused by tens of thousands of Bitcoin clients dropping all of their connections each minute and reestablishing them with new peers. You would need to exchange a lot of information this way you wouldn't normally have to (version, verack and inv messages during each such reconnection at the very least). As the attack does not appear a likely threat for the Bitcoin network, such overhead would be unjustifiable.


Earliest bitcoin forex & product purchases How did bitcoin trade for conventional currency in the earliest days?

Was there much demand to exchange it for conventional currencies, or were those who sold goods & services content with holding the currency in the hopes of using it to buy goods & services from someone else?

The same way gold or any commodity did, the person buying bitcoins valued the idea or thought it had potential and payed someone money for their bitcoins. Price is what people are willing to pay anyways. Mining is the same concept, miners are paying with their hashing power (it isn't worthless!) to the bitcoin network.

It was as shabby and undocumented as possible I'd assume, see the infamous btc pizza, some guy posted a thread on bitcointalk (you can get records of this transaction and others by going through histories) saying he wanted to pay for pizza with btc. A guy in England agreed and paid with CC for the pizza to be delivered while the other guy sent btc in exchange.