I mostly detailed the various encryption schemes used in version 1 wallets over here: https://bitcointalk.org/index.php?topic=1012475.msg11105755#msg11105755

Incidentally, it's not trivial to create such a wallet any longer, now that the default is version 2. It is easy to convert a version 1 wallet into version 2: just change the iteration count under security settings.

(edited to include the referenced content here, on request)

That's a version 1 (what the code refers to as version 0 IIRC) encrypted wallet. There have been several different encryption schemes used for this wallet version—the only way to differentiate them is to try them all, and see which one works.

The schemes have some shared attributes: the payload is stored base-64 encoded, the first 16 bytes is used as both the KDF's salt and the encryption mode's IV (and the rest is the ciphertext), the password is UTF-8 encoded (it's not normalized), and the KDF is PBKDF2-SHA1. The scheme differences, in most recent to oldest order, are:

the KDF iteration count is 10, encryption is AES-256 in CBC mode with ISO 10126 padding (same as version 2 wallets, but with a hard-coded iteration count)
same as the above, but the iteration count is 1
the iteration count is 1, encryption is AES-256 in OFB mode with ISO 7816-4 padding

Likewise, the second-password encryption has gone through a number of schemes; I think they parallel the ones above, but I'm not sure and don't have the details readily available.

The second password is also stored hashed inside the wallet file, and I do have the details of the various hashing schemes (again, password is UTF-8 encoded, most recent to oldest):

the salt is the sharedKey field (the literal string, not the underlying UUID bytes), the hash is PBKDF1-SHA256 with an iteration count of 10 (same as version 2 wallets, but with a hard-coded iteration count)
same as the above, but the iteration count is 1
the hash is SHA256(password) (unsalted)


Is it possible to interact with the blockchain through bitcoin-core without a wallet?

I don't see a way of doing this through bitcoin-core. How could I accomplish this? Is there a library I could use? Should I create my own methods? Can you think of a workaround?

You can disable the wallet by passing --disable-wallet at compile time. I don't think that's what you're asking, though.

I'm guessing you want to be able to query the balance of an address, where the address unknown at the time of synchronization. Bitcoin Core can't do this efficiently, because it doesn't index transactions by address unless the address is in the wallet.

There are patches to Bitcoin Core that create an address index, but none are officially supported.

https://github.com/satoshilabs/bitcoin
https://github.com/btcdrak/bitcoin

You could also try one of these non Bitcoin Core solutions.

(Another approach would be to import the public key as watch-only, which would let you do this with Bitcoin Core. I don't know if that satisfies your security requirements, though.)


2 bitcoinqt - getrawmempool returns different results

Why do you expect them to be identical?

There are no guarantees about synchronization between mempool contents. In fact, if there was, we wouldn't need a blockchain at all. We'd just use "time of entering mempool" to order transactions.

Transactions are relayed across the network, but under various conditions, and usually the mempool contents reflects what a node decided to relay.

Reasons for variations between nodes:

Only the first of two double spends will typically enter the mempool (but some nodes use different policies, such a replace by fee).
There are various versions of nodes out there, with different relay fee requirements.
In some cases, relay is subjected to rate limiting, which means arbitrary dropping of transactions.
Standardness rules have changed over time, changing which types of transactions are accepted into the mempool.


What is the current maximum Bitcoin block size in MB?

Effectively, the theoretical maximum size is 3999997B although in practice this limit cannot be reached. In Bitcoin Core v0.15.1 the default value for blockmaxweight in block creation is 3996000B.

Using the following formula with a limit of block weight = 4000000 (yes, decimal MB):

Block weight = Base size * 3 + (Total size = Base Size + Extra size)

The limits are 4000000 = 1000000B * 3 + (1000000B + 0B) through 4000000 = 1B * 3 + (1B + 3999996B)

In practice, the Base size cannot be as low as 1B, for a single transaction we would expect the Base size to be at least several hundred Bytes and the associated Extra size to then be far below it's theoretical limit, however the theoretical maximum block size using the weight calculation extend from 1MB through to just short of 4MB in size, allowing for a traditional 1MB block with no Extra size through to a larger block containing solely Segwit transactions. The practical maximum size for a block containing solely Segwit transactions can only be estimated.


Private Key in HD Account Bither Watch Only

If you don’t have the private key, you cannot spend the bitcoin in a watch-only wallet. There is no way to find, calculate, or recover a private key for a given address.

After all, if you were able to do that, Bitcoin, and many other systems that use public key cryptography, would be broken.

Beware: some scams involve a scammer telling you to pay for access to a private key for an address that was set up as a watch-only address. If this sounds like the situation you are in, so not send the scammer any money, you will likely receive nothing in return.


Is there a service that shows up used addresses containing a substring?

https://goochain.net had an option to search bitcoin addresses in the explorer with a string that has few initial characters according to this link: https://bitcointalk.org/index.php?topic=808066.msg9179505#msg9179505
The block explorer is dead and I have not seen this option in any other explorer used right now.


Just wait, it will eventually confirm. When I process large transactions they usually take hours to confirm. Smaller transactions usually go through quicker. There is a lot of randomness involved in the confirmation process and it might also have to do with the wallet you are using.

So don't worry, your transaction will eventually be confirmed.


Could something like proof of work be provided in the form of human creativity voted on by other humans?

These are not the only requirements.

The most fundamental requirement is that the PoW actually verifies something. It's not enough to do work and prove that you've done it - the work actually has to express acceptance of a specific branch of the block tree. Otherwise, it's useless in preventing double spending.

It follows that the problem to be solved must be generated from the details of a specific branch/block, and the proof must show that work was done with this specific block in mind. The work cannot be reused to signal acceptance of a different block. The block is baked into the work in the most fundamental level.

How would you do that for creative work? How do you generate creative assignments that are tied exclusively to some specific block? That's completely far-fetched. If the work is, say, a painting - once the work is done and the painting is drawn, it can just as easily be assigned to block A as it can to block B. It therefore verifies nothing.

Another requirement is that the work is not only verified easily, but also in a digital and decentralized way. Your software can, without any additional knowledge, computationally verify that some amount of hashing was put into a block. It cannot verify that someone who voted is indeed a human - it needs to rely on external trusted sources for that.

Which leads to the final point, which virtually everyone who proposes alternative PoW mechanisms miss - if there was a way to verify the identity of humans and collect their votes, there would not be a need to have proof of work at all. Instead of voting on works of art, they can just vote on which branch they think is right. This way they can synchronize transactions and prevent double spending. The whole reason we don't do that in Bitcoin, is that there is no way to verify identities in a decentralized, digital way, with the standards sufficient to reliably administer the voting. This is why we rely on independently verifiable proof of computational work.


Why don't cryptocurrencies create inflation if there are so many of them?

Other crypto currencies are their own entities, like each country contains their own currency each crypto currency is self contained. While others (fiat currency) depend on the rise and fall of the US backed dollar. Other coins aren't hinged inherently on the rise and fall of bitcoin, these coins depend on their own usage, efficiency, or adoption.

More reading here.
https://www.coindesk.com/bitcoin-explained-global-currency-wall-street-veteran/


If bitcoin algorithm was broken and some one started spitting out blocks one after the other through their other worldly space computer, could it be detected that the same miner was busting all the blocks?

Not necessarily. There's not enough data recorded to conclusively show that the same person is behind the new blocks, but people would figure it out: The block generation rate and network difficulty would shoot up without anyone knowing why. People could try to trace where the mined bitcoins are first seen and where they go. And you could trace the first IPs known to report the blocks: if your interplanetary computer always communicates over one IP, it might get noticed as something that has a lot of power behind it (be that a pool, supercomputer, etc.).

If that happened, the value of Bitcoin would probably drop as people realize that we'd be vulnerable to a 51% attack at the hands of an unknown party.

  Follow up question: How does the network strength or hashing power get computed? By just assuming the required H/s for the current technology?

The difficulty is known (since it's calculated based on all the previous blocks), and the block generation rate is known (since you can look at how often blocks are coming in). From these, it's easy to estimate the network's total hashing power.

It's like having a lot of people throwing weighted coins (such that 1 millionth of the time it comes up heads) and telling you when they hit a heads. If one such "heads" is reported every 10 minutes (600 seconds), you can make a very accurate estimation of how many times per second the coins are being flipped. In this example:

(1,000,000 flips/heads) / (600 seconds/heads) ~=
1,667 flips/second

The network difficulty is how you adjust this 1,000,000 figure so that the 600 figure stays consistent as the network's total hash power (1,667) changes.


Why am I getting only about 3k to 300k hashes per second?

You are limited by your machine clock speed and hashing library performance.
Scripting langs are not a good choice for CPU intensive operations.

Also, you are doing hashes sequentially, try multiprocessing: https://docs.python.org/2/library/multiprocessing.html


the private key is only a (very big) integer-number. this number used as private key is all you need to generate a public key with some more or less complex mathematical operations and this private key is also the only thing which must be your secret. anyone can know your address and your public key, no problem. with the public key you can generate the address of the public key. (=>public key and address are not the same.)

a common used format to store a private key is the WIF-format. you can convert a private key to the wif-format and vice versa.

many people call a keypair (containing private- and public key) a "wallet". but technically you don't need any software to have a wallet. you can have a paper wallet for example as long as you do not want so send your funds to have full access to your funds.


When importing private keys, will compressed or uncompressed format be used?

From a cryptographic point of view, there is just one type of private keys and one type of public keys. A private key is an integer in the range 1 to 115792089210356248762697446949407573529996955224135760342422259061068512044368, a public key is a point on the elliptic curve secp256k1. No magic here.

The problem is that Bitcoin uses addresses, and addresses are derived from the hash of a public key. As you cannot take a hash of the mathematical concept of a "point", it needs to be converted to a byte sequence first. The standard Bitcoin follows, however defines two ways of converting a public key to a byte sequence: a normal one (resulting in 65 bytes) or a compressed one (resulting in 33 bytes). There is no reason to use the normal one, except of course compatibility. As the resulting byte sequence is different in both encodings, the address will be different as well. If coins were sent to one address, the public key encoding that exactly matches it needs to be used to spend them.

Thus, in order to support both, we must remember for each public/private keypair whether the normal or compressed encoding is to be used. As you point out, we also need this information when importing a private key. To do so, the "Wallet Import Format" for private keys (the base58 form, typically starting with a '5'), was extended. If the public key/address for a particular private key are to be derived from the compressed encoding of the public key, the private key gets an extra 0x01 byte at the end, resulting in a base58 form that starts with 'K' or 'L'.

So to answer your question: when importing a private key into the reference client, it will use the normal encoding for public keys if the '5' format was used for the private key, and the compressed encoding if the 'K'/'L' format was used. It doesn't make sense to try to convert one to the other: the client must use the same encoding as was used when generating the address, or the address won't match. Unfortunately, quite a lot of software doesn't support compressed public keys yet (which is a pity, as they save block chain space).


Update: These instructions or similar are included in the bitcoin source as of 19 February 2013. See doc/build-osx.md for details. As such, the below instructions may fall out of date. Alternatively, make it easy on yourself an use WyseNynja's homebrew tap with brew tap wysenynja/bitcoin && brew install bitcoind.

Building bitcoind on OSX 10.8 with homebrew

I got bitcoind working using these instructions. For reference, I'm on OSX 10.8.2 with homebrew 0.9.3. I've made an assumption throughout that homebrew is installed in /usr/local. I've also assumed that you've installed the Xcode command line utilities and any other packages that are essential to building code. If you build any code regularly, e.g. you have RVM installed to build ruby occasionally, you're probably OK!

Install some necessary libraries from homebrew.

brew install boost miniupnpc openssl

Revert berkeley-db formula to an older version

cd /usr/local
git checkout e6a374d Library/Formula/berkeley-db.rb

You may have to unlink it if you've already installed the latest version.

brew unlink berkeley-db

Install berkeley-db 4.8 now that you've got the right formula in place.

brew install berkeley-db

Checkout from Github.

git clone https://github.com/bitcoin/bitcoin.git

Edit the makefile.osx to change it a bit. Here's a diff that shows what you need to change, or you can just use this as a patch by doing echo '$patch-text' | patch, where $patch-text is the patch text below.

diff --git a/src/makefile.osx b/src/makefile.osx
index 9629545..ffac9a3 100644
--- a/src/makefile.osx
+++ b/src/makefile.osx
@@ -7,17 +7,19 @@
 # Originally by Laszlo Hanyecz (solar@heliacal.net)

 CXX=llvm-g++
-DEPSDIR=/opt/local
+DEPSDIR?=/opt/local

 INCLUDEPATHS= \
  -I"$(CURDIR)" \
  -I"$(CURDIR)"/obj \
  -I"$(DEPSDIR)/include" \
- -I"$(DEPSDIR)/include/db48"
+ -I"$(DEPSDIR)/include/db48" \
+ -I"/usr/local/Cellar/openssl/1.0.1c/include"

 LIBPATHS= \
  -L"$(DEPSDIR)/lib" \
- -L"$(DEPSDIR)/lib/db48"
+ -L"$(DEPSDIR)/lib/db48" \
+ -L"/usr/local/Cellar/openssl/1.0.1c/lib"

 USE_UPNP:=1
 USE_IPV6:=1

Start the build.

cd bitcoin/src
make -f makefile.osx DEPSDIR=/usr/local

It's now available at ./bitcoind. We have to first create the rpc configuration file, though. Run ./bitcoind to get the filename where it should be put, or just try the below text.

echo "rpcuser=bitcoinrpc
rpcpassword=HdAseQSRkirfoNuUSzqzixyL9sM1T6ABfzV1nyNmbuwg" > "/Users/${USER}/Library/Application Support/Bitcoin/bitcoin.conf"
chmod 600 "/Users/${USER}/Library/Application Support/Bitcoin/bitcoin.conf"

When next you run it, it will start downloading the blockchain, but it won't output anything while it's doing this. This process may take several hours.

Mine appears to be working fine, but it's still downloading the blockchain. I'll be able to tell after some testing if it's working normally or not, but I suspect that it is!

Inspirations:

https://github.com/WyseNynja/homebrew-bitcoin/blob/master/bitcoind.rb
What are the steps in building bitcoind on Mac OS X 10.6?
Trouble compiling bitcoind on OSX with homebrew


How many transactions will be created in a Lightning Network channel

The number of transaction per Lightning Network channel may change depending on two main
factors:

The type of channel used.
As a protocol in development, the Lightning Network specifications may change. This
includes the specification of the transactions used for each channel state. For instance,
the "Anchor Outputs" proposal which was merged in 2020 included a complete rewrite of the
transaction tree.
The number of payments being currently routed through the channel (HTLCs in flight).

The following description is for a non-"anchor outputs" channel.
Without any in-flight HTLC
The channel begins with:

The funding transaction (onchain)
Two commitment transactions (one for each participant)

So we are at 3 transactions. But there is a quirk (there is always a quirk!), each of
the transaction pays to:

The remote party
The local party after a delay OR the remote party with the revocation key.

Since i want the count to showcase the complexity of the client implementation, i'm going
to include the special transactions in the counter.
Note that the specifications call the "simple outputs" (basic P2WPKH, as an onchain
payment) as being resolved, and the "contract outputs"[*] to not be resolved until a
"special transaction" spending it is confirmed.
It therefore brings us to 7 transactions:

1 revocation transaction per party
1 delayed transaction per party

Now, let's add some real complexity.
Adding the HTLCs
Lightning Network channels are bi-directional, therefore both parties can offer or
receive an HTLC. Intuitively.. HTLCs are translated into outputs than can be in both
these states (offered or received) in both the commitment transactions.
So you can have:

An HTLC offered by the local party
An HTLC received by the local party
An HTLC offered by the remote party
An HTLC received by the remote party

As well as any combination of the above.
For an HTLC offered by the local party, an "offered-htlc" output is added to the local
party's commitment transaction and a "received-htlc" output is added to the remote party's
commitment transaction.
Each of these outputs are the first stage of the onchain HTLC resolution, they are later
finalized in a second-stage pre-signed "HTLC transaction", and finally sweeped by a
"special transaction" (the same kind as those in the first section: delayed or revocation).
An offered HTLC output in the local party's commitment transaction may be spent by:

A "preimage transaction" (to the remote party -- ie "successful-but-quite-long payment")
A revocation transaction (to the remote party -- you need to prevent cheating at each step of the process)
A pre-signed "timeout transaction" which may then be spent by either:

A delayed transaction (to the local party -- ie "cancelled payment")
A revocation transaction (to the remote party -- we can still cheat at this point!)

A received HTLC output in the local party's commitment transaction may be spent by:

A timeout transaction (to the local party -- that's the cltv_delta configuration on your node)
A revocation transaction (to the remote party -- as usual)
A pre-signed "success transaction", which may then be spent by either:

A delayed transaction (to the local party -- ie "successful-but-quite-long payment")
A revocation transaction (to the remote party, -- still to decincentivize cheating)

This brings us to 10 new transactions per commitment transaction for two HTLCs in flight
(one in both direction).
Summing it up
For the example i've showcased above it brings us to:
7 # Nuked channel
+ 10 # htlc offered on one side, received on the other one
+ 10 # htlc received on one side, offered on the other one
= 27

That's for one channel state (the next one will use new keys!) for the common scenario of
being currently forwarding a payment in both directions.
To answer your question precisely, the number of transactions per state may vary between
7 (no HTLC) and 7 + 483 * 5 * 2 = 4837 (maximum number of HTLCs in both directions).
Note that the latter is unrealistic as the maximum number of in-flight HTLCs is currently
bounded on implementations in order to avoid DOS.

More resources:

The BOLTs if you want all the nitty-gritty details:
#5
(onchain) and
#3
(transactions) cover this.
This post by Rusty Russell -- outdated but still
gives the intuition. Touchs also the challenge of managing the keys.

[*] Terminology mine on this one


How Do I create a Mining Pool for an Altcoin?

Check out MPOS, here is a guide to setting up an MPOS pool:

https://github.com/MPOS/php-mpos/wiki/Quick-Start-Guide

And, to answer your last question, it is impossible to solo mine standard coins on a single computer that does not have the alt coin wallet in question installed.


Algorithm of checking whether an element is present in a merkle tree

I've read and watch about merkle trees but can't figure out how to implement is_present(element) method.

Put the entire contents of the merkle tree in an array.
Check that the result of hashing all of the elements equals the root of the merkle tree. (If not, this is not the correct merkle tree.)
Check if the element is in the array.

This takes O(n) time and space, where n is the number of elements in the merkle tree.
Proving that to another node
You can create a proof that a particular element is in a tree. This proof takes O(log n) space to store, and O(log n) time to verify, but still takes O(n) time to construct.
Construction:

Run through steps 1-3 above.
Start with the element you want to prove the presence of. Add it to the result list.
Find its buddy. In other words, find the hash that it would be hashed with to form the merkle branch containing both. Add it to the result list.
Repeat 2 through 3 until you get to the merkle root, which has no buddy.
The resulting list is your proof.

Verification:

Start with the first item in the list. Verify that it's the one you're trying to prove the presence of. Set A to this.
Hash it with the second item, with it either first or second depending on where the original item is in the merkle tree. Set A to this hash.
Repeat 2 with the next item until you run out of items.
Verify that A equals the merkle root.

If the merkle tree is in sorted order, you can also create a proof that an element is not in the merkle tree. It works in a similar way, except that you find the two elements that would have been the neighboring elements. Then, you prove that both are in the tree, and that they are next to each other.


Figure out your blockhash with index=0
(normally in your coind debug window,s you can: do a

getblockhash 0
(0 = genesis block number)

With the return value from that, you do a
getblock xxxx

eg:

￼
getblockhash 0
 ￼
5597f25c062a3038c7fd815fe46c67dedfcb3c839fbc8e01ed4044540d08fe48

￼
getblock 5597f25c062a3038c7fd815fe46c67dedfcb3c839fbc8e01ed4044540d08fe48

{
"hash" : "5597f25c062a3038c7fd815fe46c67dedfcb3c839fbc8e01ed4044540d08fe48",
"confirmations" : 4142183,
"size" : 240,
"height" : 0,
"version" : 1,
"merkleroot" : "2bad42ac6e0ccc4808d8df0fd50ac8634eea335b1412b1ef52864b430a87b262",
"tx" : [
"2bad42ac6e0ccc4808d8df0fd50ac8634eea335b1412b1ef52864b430a87b262"
],
"time" : 1394102925,
"nonce" : 2482334,
"bits" : "1e0ffff0",
"difficulty" : 0.00024414,
"nextblockhash" : "df34593a55b7ed0ff076766805023c8262fe26c84ba8624b77abae446c402dea"
}


Why does some transaction returned in the result of Blocktrail api call contain a field called "raw"?

It looks like a hex encoding of the binary encoding that Bitcoin uses. You could also get this through the getrawtransaction Bitcoin RPC call, if you have txindex=1 enabled.


Found my Multibit.key wallet back up, but I do not remember the password, what next?

You can try using btcrecover to attempt to brute force your password. However, if you have no idea what the password could be, then it isn't going to be able to help much.


Is there a way to link a bitcoin user's transaction to entering a lightning network channel?

Is there a way for companies like chainalysis to see if your on the lightning network?

Not really. Funding a channel will look just like sending coins to a P2WSH address. Closing a channel cooperatively also just looks like that P2WSH address sending to two addresses. This does not tell any outside observer that you are actually using the Lightning Network.

  And then from there track your coin movements there?

Coin movements over LN are not easily trackable since not all LN nodes see all LN transactions.


Does the 256-bit integer secret exponent define the X, Y pair?

I usually use the following analogy to oversimplify things: The secret key is how far you walk along a known curve starting from a known point and the public point is where on the curve you wind up when you finish. If you repeat the same walk, you will always wind up at the same place. The operation is irreversible because the curve is complex, you can only figure out where you wind up by taking steps. Given a destination, you cannot figure out how to get there because you must walk in integer steps.


There are some fundamental legal problems with this, as the Post Office is a creature of the Constitution and thus a creation of the United States government. It's not at all clear that the Post Office has authority to engage in brokering financial transactions. It's even doubtful that Congress has the power to allow the Post Office to do that.

That said, for the sake of argument, let's assume the Post Office starts brokering Bitcoin transactions. What then? Well, the point of Bitcoin (oversimplification ahead) is that it is not controlled by a government, is anonymous, and is secure. How many Bitcoin users are going to transact Bitcoin with a government agency whose job it is to route documents to people all over the planet, but is notorious for losing, mishandling, or misdelivering its cargo? I don't see it.

For that matter, how many American citizens or politicians will support inserting the Post Office into the volatile and rapidly evolving crypto-currency world? The two things the Post Office has done predictably over the last few years, other than deliver other people's mail to me, are lose money and ask for taxpayer bailouts. Add in the complexity of a major financial institution and the possibility of a market crash, and you have the makings of a major disaster (think something like LTCM + national debt horror rolled into one).

This doesn't mean I see some nefarious scheme here to "take over" Bitcoin or something. It just means this sounds like a hairbrained idea thought up by a bureaucrat who doesn't really know what Bitcoin actually is.


Buying bitcoin is easy, but how do you get it back?

Sell bitcoins in an third party exchange. (First you need to send the bitcoins to address specified in exchange)
For example checkout a trade ad on localbitcoins.com


Start Bitcoin-qt,
click help,
click debug window,
click show below command-line options,
click show details


I am clueless as well but I think that it requires a consensus of people on the network for this to function properly through one accepted BTC address. When we create our own orders no one else can see it unless you are in their trust circle or ripple neighbourhood. So we would have to all use your posted address to trade in BTC. Maybe MtGox sets up a ripple wallet inside the ripple network then we would all flock to their address and use it as a trusted source for the exchange. I could be totally wrong but that is how I poorly understand it. Someone with more technical know how can explain it better I am sure.

Ripple FAQ - Limited Description of Distribute Exchange


What are the three values in the csv graph of price history?

Unix Time, Price, Amount of Value in the Order Book at Corresponding price.

So the first line in your example translates to Thursday, April 23, 2015 GMT time, there was an order for 0.01 bitcoins at the price of $300.


Transaction was rejected - Bitcoin QT, recovered wallet.dat

So I had to fire up the OS on the old HD and run an older version of Bitcoin code - lo and behold, no problems with the wallet at all. Transferred balance to another address, installed new Bitcoin core and generated a new wallet.dat.

None of this fills me with confidence for long term storage of my coins!!


Any privacy considerations regarding allowing inbound connections for a Tor full node?

If you are running -onlynet=onion, there is no need to open any router ports. Perhaps I misunderstand your question.

If your chain state is caught up, and bitcoind+Tor is properly configured, you should be serving data to other nodes, even behind an otherwise locked-down home router.

What result do you get when running

$ bitcoin-cli getpeerinfo | grep true


API where i can get min and max price daily, going back months/years

Yes, but they are paid. Take a look at https://bitcoinaverage.com/ and https://coinmarketcap.com/ which are the big 2 services for this.


What distinguishes a miner from another?

You can't find out whether 2 blocks have been mined by the same entity (e.g. person) for sure. Guessing is possible. If you go to http://blockchain.info, you'll see a "Relayed By" column in the table right on the start page. You can be reasonably sure that that mining pool mined the block. Some mining pools always send their money to the same address. In that case, you can be even more sure that all the blocks whose coinbase transaction went to that address have been mined by the same entity because else they'd be giving a lot of money to a different entity.

The proof that a transaction has been incorporated into the blockchain is that there is a valid blockchain which contains a block which contains that transaction. You can't simply take a blockchain and swap a transaction in it out for a different one because that'd make the blockchain invalid as the hashes wouldn't check out.

Furthermore, if you want to be entirely certain that the transaction isn't just in any blockchain but also in the longest one, you need to be connected to the Bitcoin network so you know the longest blockchain. The longest one is the one which counts.


Hashrate

The number of hashes a miner can do per second. What you seem to be referring to is Network Hashpower: the amount of computational power of all the miners on the network. This was not assumed to be constant, but the block time was intended to be close to constant, hence the reason the difficulty is adjusted based on how often blocks are mined.

Estimating network hashpower

How would you estimate the hashpower of the entire network without knowing all of the miners and details about their hardware, and how long they are running? You could potentially see the rate that shares are submitted to pools (and their difficulty) if you have access to that data. But, more likely you'll have to estimate it based on the current difficulty, and rate that blocks are solved. This can calculated based on the probability of finding a hash at the current target by guessing randomly, and then how many guesses per second (hashrate) it would take to get one every 10 minutes:

Hashrate = (1/P)/Blocktime, where

P is the probability of guessing a hash that solves the block at the current target
Blocktime is blocktime in seconds (600 seconds for bitcoin)

  what distribution does the hashrate follow?

Here are some charts:
https://bitinfocharts.com/comparison/hashrate-btc-bch.html
https://bitinfocharts.com/comparison/difficulty-btc-bch.html

You can see that the difficulty follows the network hashrate. As the hashrate increases over time with more user adoption (miners coming), the difficulty increases to maintain a 10 minute block time.


Retrieve number of OP-RETURN transaction

For statistics you’re best using bitcoin-iterate which will let you extract information very quickly. Here you want to be searching for scripts beginning with the op return byte, it takes only tens of minutes to search the whole chain from disk.


What is the difference between the two transaction headers on the Bitcoin Liquid sidechain network?

Tx: 802dc4c4a08fcf4f50e4320bdb5eb596afc01c95dd0ff6afb83304aeb989be15
Inputs:
38V6gLL6kVCWhfXPo4t5x1gMfg5BKe3Rv
H18z1ifzs184pzwTABag5gv47AAxZSi1qg
Outputs:
H38V6gLL6kVCWhfXPo4t5x1gMfg5BKe3Rv
H4UWQS836njW4QJ6WfkGAPjaYtK2twLnZE
GnHogGZpDCwmskKFJoVhuvgUg6gKhWQjy6
Tx: 81efc96bea93fcb5992831d8311dec63a0b1d17072ec2e6f1263901b1bd26000
Inputs:
Gm5rw7zmqdMV1ajbT6zTEEDJhSHK1Ymdfq
H38V6gLL6kVCWhfXPo4t5x1gMfg5BKe3Rv
Outputs:
H38V6gLL6kVCWhfXPo4t5x1gMfg5BKe3Rv
H4UWQS836njW4QJ6WfkGAPjaYtK2twLnZE
GisytKX4AhQ8B1aH4p9fHsNuRbpzSr1VdF


I want to create a P2TR (pay-to-taproot) address but I just need a key path spend, not a script path spend. How do I create the P2TR address?

BIP 341 (BIP-Taproot) discusses this example where you don't require the script path.

If the spending conditions do not require a script path, the output key should commit to an unspendable script path instead of having no script path.

The BIP also explains here the rationale for this.

If the taproot output key is an aggregate of keys, there is the possibility for a malicious party to add a script path without being noticed by the other parties. This allows to bypass the multiparty policy and to steal the coins.

The Bitcoin Optech workshop on Taproot explains that you calculate the tweaked public key using:
Q = P + H(P|c)G

where
Q is the tweaked public key
P is the initial public key (P = xG where x is the private key)
H is the hash function
| is concatenation
c is the commitment to the script path spend
G is the generator point

If you don't need the script path spend you can calculate the tweaked public key using:
Q = P + H(bytes(P))G

where bytes(P) is the serialization of P as defined in BIP 340 (BIP-Schnorr).
This tweaked public key Q will be your Taproot (P2TR) address. Remember we don't hash (tweaked) public keys with Taproot (SegWit v1) like we do with P2PKH, P2SH, P2WSH (SegWit v0).


No, you were not defrauded because you did not lose anything real.

You did not lose 10 BTC.
You did not lose $1,556.76.
You lost potential, yet unrealized gain as a result of the delay in processing your order.

You may have not had access to either amount for a period of time because of the flag thrown on your transaction.

AFAIK, Coinbase does not publish its criteria for flagging transactions. Doing so would likely make it more difficult to detect transactions that would defraud them.

One way to look at it is that this is not Coinbase's fault. Coinbase has to protect itself from both financial and legal liability. It can refuse to do business with anyone it so desires if it feels the transaction may not be made with legally obtained funds by people with whom it can legally conduct business.

If you are unhappy with the delay, and that's enough of a transgression for you not to use Coinbase again, then that's your decision to make. However, this can happen with anyone as automated and needfully paranoid as Coinbase.


Transaction unconfirmed after almost 2 day,please help

Your transaction's fee is pretty high and its size is small. It usually should get confirmed right in the next block.

The reason it's still unconfirmed is that there currently is a very big number of unconfirmed transactions. Around 57'000. Usually, it's somewhere around 1'000 to 3'000.

This already happened a few months ago. The mempool back then was 8 MB big. Right now, it's 35 to 43 MB big (depending on who you ask) and a block being mined (which statistically happens every 10 minutes) can only reduce it by about 1 MB.

Inconveniently for you, the size of the mempool has skyrocketed since you made the transaction due increased frequency of transactions.

(Source)

If it continues like this, the blocksize limit will likely be increased so a block can decrease the mempool by more than 1 MB.

Your fee (0.5907 mBTC/kB) is above the current mempool average (0.2871 mBTC/kB) but there are a lot of transactions with higher fees than yours. Because of this, the miners will pick other transactions instead of yours.

The only thing you can do if you really need the transaction to go through fast is to send it again with a higher fee, this time.


Depending on what you want to do there are several answers.

Top 2:

https://longhorn.bullpay.com - Up to 2,000 Tx's returned per call
https://live.blockcypher.com/btc/ - Up to 2,000 Tx's returned per call

These may work for you but have reduced thru put:

https://blockexplorer.com - Up to 50 Tx's returned per call
https://blockchain.info - Up to 50 Tx's returned per call

All these services act like a full node (at least bullpay and blockcypher have the ability to send transactions, i'm unsure about the other two in this regard). They all have free versions. Some have paid versions to increase the number of requests you can make per second for increased scalability. The links are to their explorers. API documentation can be found on each site.

So again, it depends on what you're trying to accomplish. If you're working heavily with historical data for things like auditing, you'll want to obtain more data faster. Focus on the first two. If you're just messing around then any of them would work with varying degree's of effort.


Bitcoin price drop in the past few days (25/10/12 to 27/10/12)

All you'll ever get is speculation. Nobody knows why prices change.

It's just like when you listen to the news and they tell you that stocks dropped because of "profit taking". Clearly, people were selling if stock prices dropped. But nobody really knows if people were taking profits, cutting losses, or something else entirely.

These are emergent behaviors of complex systems and only in rare cases can you explain price movements. The most popular theory I've heard is that at least one significant factor is BitInstant downtime.


Does Ripple allow one to issue their own currency?

Currently, only three-letter currencies that exist as IOUs can be created as a custom currency. And if someone else uses that same three-letter identifier for something else, each account can only transact in one of those conflicting currencies. So you could use "XBR" to mean people owe each other beers and you could use the ripple system to track how many beers you owe people or they owe you. You could accept payment in beers.

There are plans to introduce more customized currencies. There are some things you can't do without some specialization. For example, charging a storage fee as some gold storage agents would like to do. This is still in the design stages.

You can, of course, create IOUs denominated in any currency, subject only the what other people are willing to take. But if you want to create two accounts and have one owe the other $1,000,000, you can.


There are multiple exchanges each with its own BTC/USD (or other currency pair) , so arbitrage between exchanges is what keeps prices among exchange inline.

There are short term disruptions when those providing arbitrage are out of cash (for buying) and a lesser disruption for moving bitcoins (for selling).  The selling limitation is smaller because bitcoin transactions confirm in about an hour.

There are permanent price deltas between exchanges due to the cost of moving funds and trading fees.  For instance, it is hard to get USDs to BTC-e, and therefore the selling there can be relatively far below the exchange rate at Mt. Gox -- a difference as much as 10%.  But the direction up and down are generally in sync thanks to arbitrage.


Can I "duplicate" a wallet using a backup phrase (12 words)?

Can I “duplicate” a wallet using a backup phrase (12 words)?

Yes

Where is my balance stored?

Both wallets will scan the relevant parts of the public  transaction-journal ("blockchain") to add up the amount of money controlled by the keys derived from your backup phrase - this total is your balance.
Wallets are very likely to store this total locally, as a convenience, so they don't have to re-scan the blockchain and add up the total all over again every time the wallet is opened. Exactly where and how this number is stored is likely to vary depending on the software used. The storage of this total is of no real consequence.

if I send from (A) to a friend's wallet (Z), would my reduced balance also show on (B)?

Yes, both wallets will learn about new confirmed transactions that affect your balance.
Wallet A might show the transaction amount as pending until it receives a confirmation, a confirmation is just a new block appearing in the public transaction journal that either contains the transaction in question or which builds on top of such a block. Wallet B learns about the confirmation in the same way and will similarly notice that the block contains a transaction that affects an amount associated with an address derived from your backup phrase. The mechanism is the same for both wallets, Wallet A has no special privileges.
To elaborate a little:
As Murch noted in a comment, wallet A might have some additional information that doesnt get transmitted to wallet B. This is information which isn't transmitted to the rest of the Bitcoin network and which has no effect on validation of a transaction or on the mining process by which payments are considered to be confirmed. One example is if you choose to add a memo "payment for new trinket" to the transaction, this memo is not transmitted to anyone else and so is not known to Wallet B (or anyone else). It is also lost if you destroy wallet A and re-create it (e.g. by deleting an app and associated data and then reinstalling the app and using the old backup phrase). If your wallet A allows you to organise transactions into accounts, wallet B wouldn't automatically know about those accounts. Similarly, if wallet A is a Lightning-capable wallet, Wallet B wouldn't normally know about the lightning transactions that Wallet A made, only about the final on-chain settlements made e.g. when a lightning channel is closed.
However Wallet B should still normally show that same total as Wallet A for total amount of Bitcoins that the basic Bitcoin network and it's public replicated transaction-journal ("blockchain") consider to be controlled by private keys which are in your wallets A and B.


Why can't mining pools provide fake transactions within the generated blocks?

Suppose Alice wants to add a fake transaction where she receives X ammount of BTC. I understand that in order to add that transaction to the blockchain she would have to compete against all the other miners to generate the next block, which makes it improbable to happen as an individual against them.

No, that isn't correct.  No matter how much mining power she has, or how many miners she cooperates with, she can't add a fake transaction to the blockchain.

It's a common misconception that miners are solely responsible for determining whether or not a transaction is valid, and if they say it is, then everyone else accepts it.  In fact, anyone who runs a Bitcoin full node (e.g. Bitcoin Core) is automatically checking whether each transaction is valid (spends money from a previous valid and unspent transaction, properly signed, etc).  If a miner attempts to include an invalid transaction in a block, this will be detected and their entire block will be ignored by everybody, effectively meaning that they don't get their mining reward.

With enough mining power, or the cooperation of a pool, Alice could create a block with her fake transaction.  But nobody in the world will consider it as valid or accept it as part of the blockchain.  If she tries to spend the proceeds of that transaction, say by sending those coins to Bob in exchange for some goods, Bob's software will simply ignore it.  He'll think that Alice just hasn't paid at all, and won't send her any goods.  So the whole exercise would be a giant waste of Alice's time and resources, without gaining her anything or harming anyone else.

The only special authority that miners have is this: if there are two or more otherwise valid transactions which are in conflict with one another, then miners get to decide which one (or none) goes into the blockchain, thus confirming it.  But they can't confirm a transaction that was never valid in the first place.

A large amount of mining power, or a pool, could help Alice perform a double spend attack, where a valid and confirmed transaction is later replaced in the blockchain with a different valid transaction.  The first one might have gone to Bob, who would have sent some goods, and the second one could effectively take the money back from Bob and return it from Alice, who now has the money and the goods.  But the second transaction is one that Alice could have created all along (of course she can send her own money to herself); it isn't "fake".


How can you share a plaintext bitcoin address private key with a friend and ensure they won’t spend your bitcoin?

That's not possible. If your friend has the private key, he has everything he needs to spend all the bitcoins of that address.

What you could do: Use the private key (before he uses it) and send the coins to a new wallet and don't give him the new private key, seed...


BTC confirmed however funds not received

You have to wait within 1 working day when you sell bitcoins on Zebpay.
After Zebpay gets everything clear up, your wallet will show you the amount of Bitcoin, which is 0.01627139 btc in this case. Here is the FAQ from Zebpay.

Zepbay is online wallet service which means even if you see confirmations on blockchain.info, your online wallet might not show you the exact same transaction history because of some reasons that the company has to deal with. But I am pretty sure your wallet will show you the amount of BTC you see on blockchain.info within 1 working day unless the company gets bankrupt.

If there are confirmations then the transaction is confirmed but, it is best to wait for 6 confirmations. Unspent means that there is no additional transaction yet created to spend the bitcoins.


All parts directly involved with the wallet service are open source. On the github project page the repositories My-Wallet, My-Wallet-Integrity-Checker and MyWallet-RPC-Communicator is BSD licensed.

The repositories My-Wallet-iPhone, My-Wallet-Android are GPLv3.

However the database backend and some other parts of the site are not open source. This will change at some point in time, but there are some things I want to finish first.


Why is my Antminer S9 only using one Chain

Also posting as an answer: the issue is that the GH/S (RT) on board 6 and 7 is 0--it is because the power quality coming into that dedicated power supply is too low.

The board has an ideal measurement (~4TH/s), no busted ASICS. After doing about 3 days of testing, it appears that the power quality upstream of the ASIC boards is pretty important. Even if the power supply is powered on (and reads the appropriate voltage), it is sensitive to the amperage rating of its circuit (I use 2 PS's, one for the main board + 1 ASIC board and a second one for the 2 other ASIC boards).

By moving the 2nd power supply (the one powering the 2 ASIC boards) to a high capacity 20 AMP circuit, everything works. (although now I have a huge power cable running to my miners from a separate circuit). I had to have an electrician come and pull that separate circuit from my main.


Should I use getwork or getblocktemplate

The advantage of getblocktemplate is that work units from it last longer, because you can change the extraNonce field. That's nice if you're writing an fpga miner, because it saves bandwidth.

getwork will probably never go away. It's useful and not very hard to maintain. Note that that's a personal opinion; I'm not one of the Bitcoin developers.

Edit: getwork has been removed in v0.10.0, so you have to use getblocktemplate.


I'm here to provide some more information to put your mind at ease. You most likely used a faucet to receive free bitcoin, and to do this you would need a public address. This would have been copied and pasted into the faucet's website. Now even if you still have this computer, not only would you have to have the public address, but also the private key to access the funds.

But in the past, 90% of the population had their private key stored on an exchange called Mt. Gox ... and this exchange went bankrupt 4 or so years ago.


I have a Bitcoin ABC full node. How do I split off Bitcoin SV?

I made a tool (linked by user MCCCS) but you can actually do the splitting in regular Electron Cash too. Electron Cash is great for this because unlike most wallets, you can connect to both BCH and BSV servers. Just get some free BCH-only 'split dust' from free.bitcoin.com or from forkfaucet.cash, and mix that with your coins. Then switch to BSV and make a distinct transaction there.

The key points are:

During splitting, only send amongst your own addresses. That way if you screw up, you haven't lost anything.
After splitting, wait then verify that your coins are split (have different transaction IDs)

Some guides:

https://www.reddit.com/r/btc/comments/9yefov/if_you_want_to_dump_bsv_some_tips_on_splitting/
https://news.bitcoin.com/follow-this-branch-a-guide-to-splitting-bch-and-bsv/
https://cdn.discordapp.com/attachments/412369923541565463/514774626849521672/bsvbch-2.pdf


How to buy bitcoin to my local harddrive?

I'd suggest you to:

Look into hosting your own bitcoin node.
Try using P2P non-custodial non-kyc exchange, you can find the list here.
You may want not to store your wallet on a hard drive. The suggested
solution is to own a hardware wallet


i don't know if there is an error in the scriptsig generation method of input in p2psh

ECDSA signatures are not deterministic unless you are using a deterministic signature scheme. Meaning that signing the same data with the same key produce different (valid) signatures.

I don't know if Bitcoinj uses such a scheme so If only the signature bytes in the transaction are different it is probably  fine.


To look up the transaction go to blockchain.info or blockexplorer.com and type the transaction number in the search box. You will see the sender address, the destination address, the block number where the transaction was included, among other info.

Please confirm that your bitcoin client has downloaded all the blocks. You can see a number in the bottom right corner, which should match the most recent block (the current number is 153881, you can find this information in the websites I mentioned). See this question for more information.


What is the smallest possible size of a bid/ask on Mt.Gox?

From the (unofficial) MtGox API documentation:

The minimum trade size to buy OR sell is 0.01 BTC


Getting or Building coinbasetxn to create the Merkle Root

The coinbasetxn is a field that results from a request from a pool. Have you seen this link here? How to compute merkle root without coinbasetxn?

You are hitting your local block chain node which will give you the actual individual transactions in the transactions field. You can then use all the fields to create the coinbasetxn yourself.

To build it yourself, I recommend reading example/actual code in another language in conjunction with the docs. Check out this link: https://www.anintegratedworld.com/whats-in-a-block/ where you can read the wikipedia links and also see graphically the internals of a block.


How should one manage the Bitcoin blockchain on a Linux laptop with limited storage?

Starting with Bitcoin Core 0.12.0, due out in Jan/Feb 2016, you'll be able to add the prune option to your configuration file to only store the most recent blocks.  For example, if you specify prune=5000, you'll only store as many of the recent blocks as fit into 5,000 MiB of disk space.

On top of that, you'll also have to store the UTXO database, which is currently about 1.2 GiB and growing, plus maybe a few megabytes of other things like the binaries themselves and your wallet.  On Bitcoin.org, we're saying that 5 GiB is a reasonable minimum for now.

Note that Bitcoin Core 0.11.* includes a prune feature, but in those versions it disables the wallet.  (This feature was initially targeted at miners who use mining software to manage payout addresses, and it was considered unwise to have regular users use the feature until it got more testing.)

If I were you, I would consider the feature somewhat experimental and make sure to maintain backups of the wallet (which is good policy anyway, of course).


First show what Algorithm it is built on. Second look where you can see Mining Pools for it (Google can help). Third download Mining Tool.

Pro tip: Mining with CPU is less rentable than with GPU and it makes no sensen anymore.


How to create a deterministic wallet using bitcoinjs-lib

See Blockchain.info wallet source code
https://github.com/blockchain/My-Wallet-V3

Also check the bitcoinjs-lib's list of projects


Bitcoin i have been asked to send money for a private key

This is most likely a scam! there have been a similar question recently Why do I have to deposit BTC as missing turnover

There is no need to send bitcoin or money to receive a private key or unlock a bitcoin wallet, be careful.


How to link a bitcoin address to a wallet address?

The wallet is simply a logical separation (or group, in this case). It simply means that multiple keys are kept in the same wallet.

As far as the blockchain is concerned, there is no wallet, just a set of output scripts, controlled by private keys.


Where can I find how much one XRP (Ripple unit) is worth?

Update 2: There are now more traditional price / volume charts:

BTC:Bitstamp/XRP at RippleCharts.com
USD:Bitstamp/XRP at RippleCharts.com

Update: Ripple Live Orderbook and Charts by webr3 provides various bitstamp style charts and orderbooks for various XRP/xxx pairs.

Update: The Ripple Ledger Explorer by melvster shows a graph of Ripple vs Bitcoin prices.  It also shows recent ledger activity.

Early on there was also a manually-updated list at:

Ripple: XRP Price Tracker

The discussion there had a nice example of what an order book snapshot from the ripple client looks like, with headers.

The #ripple-market irc channel at freenode.net also shows real-time trades via a "Streaming exchange feed for notable #ripple gateways" all trades.  You can see it via

freenode Web IRC

A trade example looks like this:

< ripplebot> TRD bitstamp 730.698114 @ 48,713.2076 BTC rwdLV79WzXmFuzP2cBwTG6mtXcfSnCjtoF #142

I assume that means that the price for that transaction was 48,713 XRD per BTC, and I'm guessing that 730 XRD were traded at that price via bitstamp, but I haven't seen good documentation yet.

Here is an example ASK report:

ASK bitstamp 347.152555 @ 41,854.251463 BTC rwdLV79WzXmFuzP2cBwTG6mtXcfSnCjtoF #143

The code for ripplebot can be found at

rippleFoundation/ripple-watch · GitHub


The only two that I know of are cgminer and bfgminer. Unless you have specialized mining equipment (read: ASICs) or mining on testnet, mining is not going to be a good idea.


Button generating code altering addresses

Looks like scam yeah. It looks like they are asking for one normal bitcoin address, so any address they generate will NOT be yours.

However it would be possible to do such a thing if they would ask for the xpub seed of your HD wallet. Even then though it wouldn't make sense to trust a service like that.

Stay away!


Is it a threat if top mining player merges?

You are speaking of 51% attack or Majority Attack

You can read more about it in here

If they join, yes they can double spend or so.

But they can't change the price though, as that purely depends on the market demand.

Till now, there has been no Majority Attack on BTC, though it has been demonstrated on small altcoins.


I try to explain it, that no coding is required :-) Taking more of a process view...
Assembly and sending of a tx:
the wallet software of A looks up it's internal database, if there is a transaction with required amount of 1 BTC on it. If yes, it then looks up this transaction's details in the blockchain, and finds in this transaction the pk script (spending condition), and assembles a new transaction, which shall move the funds to B's address. The wallet software then signs a hash of this transaction. The signature of this hash and the public key are placed in the [scriptsig] field of the transaction. So the final transaction contains the previous tx hash, signature and pubkey, and also an output section, with a pub key script (for B's  target address) and the amount. That's what the picture shows.
The transaction is then sent to the network.
Transaction Verification:
In the network are verifying nodes, that check for validity of the tx. Amongst others, these nodes check that you have the right to spend the funds. They take the current tx' sigscript (<signature> and <public key>), and from the previous tx the output script (pubkey script). Then basically two comparisons take place:

1.) can the public key of the previous tx' sigscript be hashed to the same value as the presented hash in the current tx' pubkey script?
2.) is the signature a valid signature for the public key

With the first check, it is assured, that the current transaction moves the funds to the previously defined target address. And with the second check it is verified, if the signature aligns to the presented public key.
For the second test: the wallet software creates a signature, which requires the private key of the owner of the public address. The private key is used to sign the hash of the current transaction.
The picture you provided has a presentation of the parts to create the spending tx. Not the verifying part. That makes it a bit more complex to derive functionality... I had a very good reading with Ken Shirrif's article here:
http://www.righto.com/2014/02/bitcoins-hard-way-using-raw-bitcoin.html
and also (of course) Andreas' book "Mastering Bitcoin" (Second Edition), which is also online available.


Why do I get: Error:  has no matching Script

you need to be  passing the  network parameter as the tuple and thus you forgot to put the {} on them . the link on github repo (https://github.com/bitcoinjs/bip174) explains the proposition in correct way.


Cryptocurrency with support for a shared wallet

Is there a cryptocurrency which could fit the above scenario?

yes, bitcoin: https://en.bitcoin.it/wiki/Multisignature


When I have a problem running the bitcoin client, where can I go to get help?

I think you have mentioned them all:

bitcointalk,

bitcoin.stackexchange,

github issues page,

bitcoin-dev.

For commercial companies offering bitcoin client support see Stephen Gornick's answer.


What would be an example for an insertion into the blockchain?

An insertion occurs when, given a chain C with two consecutive
blocks B and B, a block B* created after B′
is such that B , B*, B′ form three consecutive
blocks of a valid chain.

For an insertion to occur in the Bitcoin blockchain, block B* would need to be a valid child of B:

a valid block at the corresponding height
commit to B as its prevBlock

B* would also need to be a valid predecessor of B':

The prevBlock in block B' would need to match the hash of B*

Finally, the block B' would need to be a valid block at a height one greater than the one it was previously found at.

These requirements are not just improbable but actually impossible to fulfill. Condition 1. is costly in that it requires expending sufficient work to fulfill the proof-of-work requirement of a valid block. Condition 2. would require finding a block that hashes to an exact value. This means breaking second pre-image resistance of SHA-256 which is considered infeasible. The good news is that if we can break second pre-image resistance, we can also find valid blocks more easily; the assumption that partial pre-images are hard to find are the core assumption of Bitcoin's proof-of-work algorithm. Finally, fulfilling condition 3. is impossible: each block commits to a specific block height in their coinbase transaction as required by BIP34. A block therefore can only be valid at exactly one height in a chain, and inserting another block in front of it invalidates the block.
Looking at the paper, it seems to me that that Definition 8 is chiefly used to prepare Definition 9 (emphasis added.):

Definition 9 (Typical execution). An execution is (ϵ, λ)-typical (or
just typical), for ϵ ∈ (0, 1) and integer λ ≥ 2/f, if, for any set S
of at least λ consecutive rounds, the following hold.
(a) (1 − ϵ)[X(S)] < X(S) < (1 + ϵ)[X(S)] and (1 − ϵ)[Y (S)] < Y (S).
(b) Z(S) < [Z(S)] + ϵ[X(S)].
(c) No insertions, no copies, and no predictions occurred.

I.e. the authors are trying to describe the three defined occurrences as atypical execution.


Cryptsy, Mintpal, Bittrex API - how many requests can I do?

Mintpal has a limit of 10 requests/second

MintPal API v1 offers a simple REST API to retrieve information about our markets. The API responses are JSON encoded arrays. Please be aware that calls to the API are rate limited to 10 requests per second, any requests exceeding this rate will be met with a HTTP 503 response.

I know Kraken has different rules. You can 'burst', instead of a flat limit. Source

The basic API rate limit is 1 call every 5 seconds. You can do faster bursts up to 10 calls, but then you'd need to follow that by a 50 second pause before you could resume the 1 call very 5 second rate. If you get locked out, it's for 15 minutes.
For really active traders (including those who want to market make with us), we can offer much higher limits. Anyone interested in this should contact us with a support ticket.

I know Kraken isn't on your wishlist of things to know, but I cannot find information about Cryptsy or Bittrex. But it gives you a insight at real limits, so you can maybe assume those two have similar limits.


All the BIPs that have been written up are listed on the BIPs Github project along with their status:

https://github.com/bitcoin/bips/blob/master/README.mediawiki

There's rarely a clear plan as to when they're going to incorporated into bitcoin-core and the corresponding schedule. In open source projects, features get incorporated when someone gets around implementing them and the review process is done.

The best way to follow implementation is to follow the development mailing list and Github pull requests (https://github.com/bitcoin/bitcoin/pulls).


Creating my own script for proof of reserves

A proof of reserve via invalid input is not necessarily constructable by regular means, due to a few reasons.

Proving you own all utxos in a single tx may result in a tx that is too large - while this isn't a problem for the proof, any sane wallet will refuse to construct such a tx
Using invalid inputs by definition requires you to sign an invalid tx - any sane wallet will also disallow this.
In trivial cases, a proof via invalid inputs is unnecessary - if all your coins reside in p2pkh addresses or simple multisig addresses, a single signed message signed with all the keys involved (along with appropriate redeemscripts) is sufficient.

That said, if you really do want to use a proof of reserve with invalid inputs, you can construct a raw transaction consuming all the inputs, add an invalid inputs (a utxo that doesn't exist, or has already been spent), and then sign it with any bitcoin signing tool or library - any tool that supports offline signing should have little trouble signing it (although you may still get hit by validation issues if the resulting tx is too large).


is it available to pay for my multiple inputs at one time?

Within a bitcoin transaction, there is no specification for 'which address (input) is paying the fee'.

The fee is simply calculated by subtracting the sum of all outputs, from the sum of all inputs. The inputs are consumed entirely, and the newly formed UTXOs specify the exact amount paying each address. Whatever is left over is the fee that miners can claim.


How to implement a game like SatoshiDice?

Creating a SatoshiDice-like game is rather easy.  Below are the high level steps involved in making such a game.

For each incoming transaction...

Get the customer amount and payment address

Call bitcoind getrawtransaction [The incoming transaction ID] 1.  The 1 at the end will return the data in "verbose mode", which essentially the raw data in JSON format.
From the raw transaction details, take the txid and vout from the vin object.  With this transaction, again call bitcoind getrawtransaction on the txid.
From these raw transaction details find the vout object, referenced by the vout index from step #2.  Within this vout object, there should be a list of payment recipient addresses.  Take and store the first address.

Determine the Win/Loss state of the round and return the results

Hash the txid+vout index of the transaction.  Seed your hash function with a secret key.  As an aside note, you will need to provide your secret key on a periodic basis.  Without updating and providing your secret keys, there is no way for your players to verify your fairness.
Compare the last four bytes of your hash to determine the win/loss condition.

In case of a loss...

Call bitcoind createrawtransaction.  You must pass in the originating txid and vout of your customers payment.  With the customers address, include a small, fractional value to send back to the customer.  This informs them that they've lost the round.  Also, include a second payment address that will receive the remaining portion of bitcoins from the customers originating payment.  This should be an address within your wallet.
Call bitcoind signrawtransaction to sign the transaction.  If it returns a value of complete=true, your transaction is valid.
Call bitcoind sendrawtransaction and include the above constructed raw transaction.

In case of a win

Calculate the customers winning amount.
Call bitcoind listunspent.  This will return a list of inputted transactions that have not been spent by your wallet.
Create a list of transactions to process as payments.  First, include the customer's originating txid and vout index of their payment.  Next, append to the list any number of unspent transactions (from step #1) that are necessary to pay your customer their winnings.

Remember to include an additional payment address that will receive the remaining portion of bitcoins from the final unspent transaction that may contain overages above the player's winnings.
Call bitcoind createrawtransaction, passing in all of the transactions accumulated in step #3.
Call bitcoind signrawtransaction to sign the transaction.
Call bitcoind sendrawtransaction and include the above constructed raw transaction.

That's it!  That's a very simplistic, SatoshiDice processor.  You may want to add more validation, cache your transactions, monitor orphaned blocks and just integrate some other administrative routines.

It is worth mentioning that you always include a portion of the customers original payment with all of your return transactions.  This is because if their payment is orphaned, or is marked as invalid, you want to be sure that your transaction is also removed from the block-chain.

Using this method you can actually respond near-instantaneously and there is no need for confirmations.  If their transaction is malformed and rejected by the network, your transaction will also be thrown out by the network since it is a child of their original transaction.


Spreading reward of a block over the miners proceeding it

Can one create a cryptocurrency like this by adjusting the generation tx and ensure no one can steal others reward?

You can implement whatever consensus rules you like if you create your own altcoin :)

Unfortunately the thing which makes this difficult / impossible in bitcoin is the fact that coinbase transactions only mature after 100 blocks are mined on top. So while it would be nice in theory to include an extra 5 BTC output from your coinbase transaction that the miner of the next block could spend, it would not be valid, because the coinbase would not be mature. From what I can think, it would only be possible to do this safely to let the miner 100 blocks later claim the coins. That would still provide an incentive, especially if most/all blocks did this, then each new block would usually get 5 BTC from the block 100 blocks behind it.


Is it computationally feasible to find two transaction IDs with the same first 20 bytes?

20 bytes is still 160 bits of security, which is considered very secure. If you are sure that you only need the IDs to check for existence, 20 bytes of the hashes should be fine.

Hard drive space is pretty cheap, though, and you might need the full TXID someday just for interoperability between other systems. So make sure 20 bytes really does satisfy your use cases. A 20 byte hash is sufficiently secure, though.


How can I get more than 1 BTC on testnet?

There are no exchanges or services which sell testnet which I know of.
Instead of purchasing directly, mining hardware can be borrowed or rented to directly mine testnet coins. CPU mining is no longer a real possibility for generating over 1 tBTC.
The steps for mining testnet coins would be the following.

Setup Bitcoin testnet full node
Setup pool interface for mining testnet with a SHA256 miner (such as CoiniumServ or P2Pool)
Rent or borrow a SHA256 mining device to generate the coins
Get a testnet address for collecting mining rewards

Ironically, this will probably cost you time, effort and MONEY, but you should be able to get as much tBTC as is needed. Hopefully, there will be an open market for testnet BTC someday.
I also created step-by-step details on how I mined testnet coins which might be helpful.


You should not store your private keys on a webserver, unless you actually need to spend the bitcoins from that very same server.

Remember, to receive money on an address, check its balance, etc, you only need the address. This is much safer because that way nobody could steal your money, even if they get full access to your server.

One way to do it is to import all private keys in a new, separate wallet (default Bitcoin Core install would do), password-protect the wallet with a long, random, gibberish password and then discard the password (of course make sure you also still have the private keys in the original wallet). This essentially creates a "read only" wallet, which would be safe to put on your webserver, and allows for all functionality on your addresses, except spending the money.

To actually spend the money, you use the original wallet that doesn't need to be on your webserver.


Can I recover my own wallet from the public key?

This is impossible.

The whole point of public key cryptography is that the public key can be shared with anybody, without compromising the private key.  If there were a way to recover the private key using the public key, this would all fall apart, and in particular Bitcoin would be horribly insecure.  This hasn't happened.

The public key could be used to determine how much Bitcoin is associated with that key, but it is no help at all in actually accessing those coins.  Sorry.


When using a paper wallet and doing partial spends via blockchain.info. Where does the change go?

If you use a paper wallet with just one address. The most common way to make transactions that do not spent a complete unspent output (UTXO) is to send the change back to the wallet address itself.

Note that using only a single address implies that you have no privacy whatsoever. Everyone that Evers comes to know your address can see your balance and every transaction you receive or send.

Paper wallets are useful to safely and conveniently store some bitcoins, but when you want to make payments on a more frequent basis, you should use a more sophisticated wallet that can contain multiple addresses.

Note that HD wallets (Hierarchical Deterministic wallets) make it possible to have a paper wallet that can consist of many addresses. However I don't know of a wallet app that already supports this type of wallets today.


How does the sender know the receiver's public keys in a m-of-n transaction?

Any address that a spender will send to is provided by the receiver. As the owner of the address, the receiver knows these details and will be able to provide the correct sending instructions to the spender. This holds true even for the outdated original multisig construction that required the spender to know the pubkeys, but today most multisig transactions actually make use of pay-to-script-hash (p2sh), so the receiver would simply provide a standard p2sh address to the spender.


where can I find a chart or data showing total Multibit dowloads?


What is the maximum idle time for a node to be considered active?

If there is no traffic on a connection, nodes will periodically send a message to maintain the connection. If a node has not communicated on a connection for more than 90 minutes, it is assumed to be disconnected and a new peer will be found.
A more detailed explanation is given in the book Mastering Bitcoin by O'Reilly Chimera. The specific explanation is given here


what is the incentive for the other miners to actually validate that it is correct?

The incentive is to not mine a block on top of something that is invalid. If they do end up mining on top of an invalid block, then they waste effort (and thus money) on something that will never be accepted by the rest of the network.

  It seems that they might save time by just starting to work in the next block instead of validating.

They do save time, and in fact, many miners actually do not validate the previous block before they start mining on it. While there is an incentive to validate blocks, no one can force anyone else to validate a block and the incentive is not high enough for miners to always validate a block before mining on it. Since invalid blocks happen rarely, many miners have found it unnecessary to validate blocks before beginning to mine on top of the block.

Many miners will still validate the block, just after they have begun mining on it. They instead will validate a block whilst they are already mining on it and only stop mining on it if it turns out to be invalid. Although they can lost money by doing this, the risk is not that great because blocks are rarely invalid but the reward is great due to the extra mining time.


GLBSE is a website where companies and individuals can issue and sell stocks, bonds, and options via Bitcoin. Anyone can create an account and issue any contracts he wants - a contract is just some text, signed by him (For example I created this bond as a proof of concept where I promised I will pay X amount of Bitcoin in the future for a loan of Y amount of Bitcoin today).

You can use GLBSE as an investor, transferring Bitcoins there and placing BUY and SELL orders on the various assets, or you can use it to sell parts of your company. It is a small scale version of a stock exchange (e.g. Nasdaq), with much lower fees and (almost?) no regulation. To create an IPO at an official stock exchange would probablly cost you at least a few thousand dollars, on GLBSE you can do it for half a bitcoin.

Although GLBSE has a command line client and an API, the easiest way to use it would be the javascript client. You can see a list of assets here, and follow this blog for posts about new assets. An updated list of transactions is available via Twitter, and you can find graphs of the assets prices here.


I would like to explain a bit the smart contract situation in bitcoin, as a "smart contract platform" is not a fixed wording in bitcoin world.  As such your question is not clear. Bitcoin already has smart contracts. A good summary was provided by Andrew Poelstra here.

When you mention Ethereum, then usually solidity is used, which is "turing complete". People tend to state, that only turing complete machines are "real smart contracts". This is opinion based... Bitcoin has no plans to implement turing complete language, at least not directly. There is the concept of "Bitcoin Simplicity", and it's worthwhile to read the discussion thread in bitcointalk. There is also a link to the Simplicity white paper.

Another development is going into side chains, like this.

A whitepaper for descreet log contracts is presented here.

  Will projects build on top of Ethereum's blockchain be able to transit
  to Bitcoin's blockchain when the smart contract platform is up and
  running?

At the current point in time, it is not visible, that people are working on making bitcoin compatible with ethereum smart contracts. It looks more like bitcoin devs are heading in a different direction, to avoid the problems of smart contracts with turing complete machines. When reading through the threads, you'll see how deep the politics are involved on this...


Error: Non-canonical DER signature when attempting to broadcast signed Segwit Transactions

You're missing the sighash flag byte at the end of the signature.
"Signature" objects in Bitcoin Script consist of the actual DER-encoded ECDSA signature, plus the sighash type byte (in your case, 0x01 for SIGHASH_ALL).


Help with very old wallet.dat file and keys, next steps?

You don't need to import the keys to see if they have a balance or not. Just copy the content of "addr" and use a Bitcoin blockchain explorer such as https://blockchain.info/ to check if there is any BTC on the address.

And i guess you could just import the wallet.dat on Bitcoin Core directly if there is any BTC on any of your addresses.


what must do to sent money from bitcoin to my bank account

Simple answer:
You can not send bitcoins to your bank account.
...except is some special cases when your bank accepts bitcoins. I do not believe your bank do that.
Long answer:
You need to exchange the bitcoins for money, say EUR or USD or your local currency. Lots of bitcoin exchanges can do this, but you need to have trust in the exchange, because they can stole your bitcoins and never send you the money.
I use two exchanges, but I am not sure if it is OK to recommend them here.


Various questions regarding wallet and mining

1) yes, "out of sync" means that it hasn't downloaded the whole blockchain yet.

2) to mine ("make") them, you need special hardware and software.

3) it is much easier, yes. There are many exchanges where you can buy bitcoins, such as Mt. Gox or Bitcoin Central


Check if you have a relevant setting in one of these

Start up app at System Preferences / Users & Groups / Login Items
Config file at ~/Library/Application Support/Bitcoin/
A bitcoind -daemon in ~/.bash_profile

You could run ps aux | grep bitcoind to check where it is executing from and then delete that folder.


TLDR: Rough estimate of electricity cost needed to produce one bitcoin on a laptop with 5 Mhash/s equals to 61 dollar, and would take 339 days with current difficulty.

A standard laptop CPU provides around 2-8 Mhash/sec and consumes 25 to 75 watts, which on average gives us 1 Mhash/sec per 10 watts of power.

An ATI 5870 video card, which has one the best efficiency/cost ratios, mines at about 400 Mhash/sec and consumes about 216 watts. Which gives us about 2 Mhash/sec per 1 watt of power. In other words mining with ATI video card about 20 times more cost effective then mining with CPU.

According to pi.uk.com/bitcoin, mining with ATI video cards at 1000 Mhash/sec will cost 650 watts or 9.75 cents (15 cent per kilowatt hour), and the operation profit margin would be 19.07%. Therefore I doubt it would be cost effective to mine on laptop considering that power consumption changes dramatically from computing intensive task.

You can get better estimate yourself by using Bitcoin mining profitability calculator and Electricity Prices by State.


Yes, these tasks are normally taken care of by Bitcoin Core or equivalent mining software.

I suppose in principle some miner could patch their software so that it asked a human operator to approve each transaction before adding to a block, or to participate in some other way.  But I can't imagine why anybody would want to, or what a human would look for in a transaction that wouldn't be easier to script.

For more general information about mining, see What exactly is Mining? The main source of technical information about Bitcoin is the wiki at https://en.bitcoin.it/wiki/Mining (or a mirror).


Will Bitcoin copy Best Features of Litecoin, Ripple, if its Open Source?

Proponents of Bitcoin always mention that Bitcoin is Open Source, so if any better cryptocurrency comes along, Bitcoin can just copy those features in their open source.

Bitcoin can of course adapt to whatever its community agrees to. This isn't so much a result of the fact that it is open source, but of the fact that its use is entirely opt-in: it works because people want to use it with the properties it has. Any group at any point can decide to create their own modified network/software, possibly creating their own coin in the process. This has happened in the past, but only with very limited success.

Both Litecoin and Ripple have faster transaction speeds and more transaction capacity.

They do, but those come with significant costs too. Litecoin is fairly similar to Bitcoin, but has higher upper bounds on certain resource costs like bandwidth usage, processing time for nodes, block propagation guarantees... all metrics that influence how realistic it is to keep Bitcoin's full node network decentralized. Ripple is a completely different design that relies on wildly different security assumptions.
Note that I'm not trying to say the different choices those systems make are necessarily bad - they're just different trade-offs, and those are things to be decided by the network's ecosystem. It is highly unlikely you'll convince a sufficiently large and important subset of the ecosystem that such changes are desirable. Sure, some people will feel they are - but others won't, and unless it is clearly better in (almost) all regards, the Bitcoin ecosystem will likely prefer being conservative about such choices as it has been in the past.

So why hasn't Bitcoin just copied those features, to improve itself?

TL;DR: because not everyone considers those changes to be improvements, when taking the costs into account.


Ripple paper wallet: is "ripplepaperwallet.com" safe?

Considering the fact it has iframes (e.g ads) in it and they might have access to the parent (e.g http://ripplepaperwallet.com) DOM, I would say that even if it was an open source project (which I have not found any references to) I would say it relies on a third party that is not open source therefore theoretically can be not safe.

As well, I did not see an offline version of it, which in my opinion is a good practice to verify integrity of paper wallets.


What are the chances that Nick Szabo is Satoshi?

He is one of the most likely candidates but for me his interest in Ethereum makes him less likely (than before) to be Satoshi

This article discusses some of the known plausible candidates:

http://www.coindesk.com/information/who-is-satoshi-nakamoto/


Why mark a transaction as RBF (Replace-by-Fee) explicitly?

I could broadcast a second transaction that has the same inputs but a higher fee, without marking the original transaction as replaceable.

Default node behaviour is to accept the first-seen transaction into the node's mempool. So your second transaction that spends the same inputs would likely be dropped by most nodes, and thus it would be less reliably broadcast across the network, and therefore be less likely to be included in a block.

Of course, the second transaction could still be included in a block, but this 'first-seen' preference makes it less likely. Even though a miner may prefer the transaction that pays higher fees, if they do not hear about that transaction in the first place then there is no chance of it confirming. An explicit RBF marking allows the user to more reliably broadcast a modified transaction spending the same inputs later.


Silly me. I figured it out right after I posted the question.

Ledger Live shows the sum of the following:

Actual spent amount
The transaction fee

In my case, this is:

0.3878 BTC
0.00031680 BTC

Which is indeed equal to 0.3881168 BTC. I first got confused by this value because I subtracted 0.00065121 BTC (my newly created  UTXO) from 0.38876801 BTC (total input), but this is just a natural mathematical equivalence.


Can transaction data be altered before creating a block?

You can modify it, but in doing so, you will invalidate the signature on the transaction, since the data is no longer the same as what was signed.

You could do so on transactions that don't involve signatures, but they are generally non-standard on the mainnet.

Note that even after modification, you can only update it within the bounds of the input(s) sum. You can never modify a transaction to have an output greater than the sum of the inputs.


It seems that the fee provided by you is too low and it's total amount is lower than relay fee (==the minimum fee amount that can guarantee that your transaction would be retranslated to the net). You can find this amount by calling getinfo function and taking "relayfee". Currently "relayfee" is 0.00001000 at BTC Mainnet.


Is Bitcoin PoW actually SHA256 + Merkle generation? Or have I misunderstood coinbase/append?

You are correct that effectively Bitcoin PoW involves computing the Merkle root every now and then in addition to the hash grinding.

However, this is negligable. Even ignoring nTime rolling, the Merkke root computation is just a dozen or so hashes every 232. It's so little because not the entire Merkle tree needs recomputation; just the coinbase transaction is modified, along with n Merkle nodes above it (assuming up to 2n transactions).

As far as I know, the burden of Merkle root computation is so low that it is generally done in the miner controller rather than in the ASIC itself.


Bitcoin core v0.19.0.1 automatically prunes. I keep loosing the blockchain. How can I stop this?

Start bitcoin-qt with the -choosedatadir option. You'll get first startup dialog again. Uncheck pruning there if it is checked and make sure the datadir is pointed to where you want it to point to. Once you click OK, double check the settings that pruning is disabled. Then check for a bitcoin.conf file in your datadir. If it is not there, you are fine. If it is, make sure it does not have have a prune= line.

Bitcoin Core does not prune by default, but recent changes to the Choose a Data Directory dialog may automatically enable pruning.


What purpose does XRP serve in the ripple protocol?

It's not clear how you're imagining doing what Ripple does with Bitcoins, so it's hard to say whether you're correct or not.

If you mean with the Bitcoins still being transferred on the blockchain and being used directly to pay transaction fees for Ripple transactions, that wouldn't work. Bitcoin transactions take time to confirm, and slowing Ripple down to Bitcoin's speed wouldn't make sense.

If you mean with the Bitcoins being virtualized somehow onto Ripple's ledger, it's hard to see how you can do that reliably without a central authority. Also, what do you do with the Bitcoins that pay transaction fees? Destroy them?

You haven't really set out your proposed alternative in much detail. It's possible that you do have some good way to do it. But I don't know of one.

One of the main points of Ripple is to solve the double spend problem without relying on proof of work and without being vulnerable to 51% attacks that have no clear solution. Building on top of Bitcoin would make a system that was at best no stronger.

There are significant benefits to having a native currency on the same ledger.


Why do the Bitcoin RPC Calls use decimals for coin amounts?

I would say the RPC interface is intended mainly as an application interface, but it's also meant to be simple enough for a human to use.  And the computer cares less than you think.

For human users, using decimal bitcoins (rather than integer satoshis) makes life significantly easier.  For people writing software to interface with it, it makes their life only infinitesimally more complicated (you have to write maybe one extra line of code to insert and parse the decimal point).  The computer running it takes maybe a few more nanoseconds to run the code, which nobody will notice.  So on balance, it seems like more good is achieved by including the decimal point than not.


Firstly

Read

Help
I am new to Bitcoin, how can I get started?
How do you obtain bitcoins?
Can bitcoins be traced to scammers
scam with blockchain

Bitcoin "ATM"/BTM

Scrutinise "ATM" for fees etc to determine exactly how much BTC you will receive.

Open your wallet. Click the Receive button. Enter appropriate details (all aptional). Click the Request Payment button. Carefully write down or otherwise record the generated address. Details depend on exact wallet used.

Follow the "ATM" instructions and make sure you tell it to pay to the address generated by the wallet. You may need to type in the address or will be able to scan the QR-code.

Fiat ATM

Use a service like "local bitcoins" to find someone willing to swap your local currency for BTC.

Consider what you will do if the BTC don't show up for a few days (or never).

Meet them. See above re generated address. Give them your money and the generated bitcoin-address.

Hope they are honest.

Either

Take a careful note of the Transaction Id

After the transaction, wait half an hour and see if your wallet shows the amount of BTC you expected. If not, check your wallet is synchronised and/or wait a couple of hours.

Try doing a web-search for "blockchain explorer" and type in either your receiving address or the Transaction Id.


Working of crypto currency swaping (Exchanging) in Crypto exchange

Any service or exchange allowing conversion of one asset into another (whether it is decentralized or centralized), is eventually executing the trade on an orderbook with a large exchange or liquidity provider.

Larger exchanges like Coinbase, Binance, Bitstamp etc. operate their own orderbooks, which have liquidity from users and market makers.

Second tier services like Shapeshift, Changelly etc. maintain balances in all the coins they support on larger services, and when a user wishes to convert an asset, they will execute a corresponding trade on these services.


Here is the explanation: https://support.exodus.io/article/81-how-do-i-generate-a-new-bitcoin-address

  Your bitcoin addresses are reusable, however, some users may want to
  generate new bitcoin addresses for privacy purposes. If you would like
  to generate a new address, click on the arrow to the right of the QR
  code in your bitcoin receive window.

  You start out with two bitcoin addresses. As each address is used, a
  new one will generate. This way, you always have an unused address
  available to you.


I created a ripple account ... what next? (how do I start?)

To see an active Bitstamp BTC IOUs vs. XRP market do the following:

Advanced -> Trade -> change issuer

Enter rvYAfWj5gh67oV6fW32ZzP3Aw4Eubs59B which should then fill in BTC Bitstamp.net

Click on "Order Book" to see BTC/XRP offers.


Is there any evidence that the Litecoin network is significantly affected by botnet mining?

I have the privilege of answering your question a year later, where GPUs have taken over Litecoin and all of its derivatives. Currently, botnets would be better off mining a CPU coin like Primecoin.

That said, there is evidence of botnet mining for both Litecoin and Primecoin.


Essentially, there is no such thing as a "suspicous transaction" and bitcoin is already set up to work in the way that you want.

Double spending is handled like this -- if two transactions spending the same input(s) happen in the same block, both will be rejected. If one transaction makes it into a block before the other, the first one will be accepted and the second will be rejected.

Now, if two transactions entered the network simultaneously, but at different endpoint, by the time the next block is mined it's likely that they would have made it into the same block and thus be simultaneously rejected. It's also possible that a block is mined containing one transaction, and all subsequent blocks containing the other transaction will simply be rejected. The third and least likely scenario is that two blocks are mined simultaneously -- each containing one of the competing transactions -- and this would cause a fork in the blockchain. However, this is the purpose of having confirmations, and by the time you reach 6, it's extremely likely that the forks have been reconciled and that one of these transactions will be rejected along with the rejected fork.

So, if double spending occurs exactly one of three things will have happened :

1. You will have the bitcoins (even though they were promised to someone else)
2. Someone else will have the bitcoins (even though they were promised to you)
3. The original owner keeps the bitcoins.

Since you're not dealing with transactions that occur in real time, you only need to worry about whether or not you receive your bitcoins. After a number of confirmation, you can be confident that there was no double spend detected.

You noted that you wanted to identify suspicious transactions using the bitcoind API, but as mentioned before, there no way to identify a transaction as being inherently suspicious. If money shows up at your bitcoin address from a sender and you want to be confident that the transactions won't somehow disappear from the blockchain later, you could check the for forks in the block chain that might contain transactions with the same inputs, but simply waiting 6 confirmations, as you're already doing, is more than enough. If you don't get your coins, just let the customer know, and if the customer didn't double spend, he or she can just resend the payment. Essentially @Nate-Eldredge is right.


Which alternative currencies might experience a sharp rise in popularity like bitcoin recently did?

there is no real way to predict where the market goes. Therefore it is a question without an answer.

The part about bitcoin surge is just a question of supply and demand. bitcoin doesn't really have a value. the value lies in the demand from people hoarding or spending them and the supply from miners and/or brokers. It is now in high demand so it's high in price.If by popularity you mean a hyper deflation. Well then yes. bitcoin will probably always dominate the others.


How does blockchain.info access my wallet in MyWallet

Your wallet is only used to send coins. To receive coins you don't need access to the wallet.


How easy is finding related vanity addresses?

Zero. They are completely unrelated.

And if you think about that, it is quite obvious... otherwise it would be very easy to steal known addresses: you would just have to find a similar one.


The process actually goes like this:

Alice sends 1BTC to Bob's address. A new transaction gets created with:

As many inputs as necessary (unspent outputs from Alice's previously received transactions) formed by:

Previous transaction ID (txid, the transaction which sent Alice the coins she's going to spend) and output index (vout, which output of the transaction is being spent)
Alice's public key (whose hash(publicKey) must match the hash included in the previous transaction)
A signature over the whole transaction, signed with Alice's private key and verifiable with the included public key

As many outputs as necessary/wanted pointing to Bob's addresses (remember each address is just a hash, not public key!)

This is the hash Bob will have to match with his public key to spend the coins!

The raw transaction is broadcast
Miners receive this transaction, verify and validate it (check signatures, check that inputs are valid and unspent, check that hash included in unspent outputs equals hash of the provided public key)

Up til here you got it more or less. Now here's what you didn't get:

Miners add this transaction to their current block, which holds even more unconfirmed transactions
The miner keeps hashing the block with an incrementing nonce

In each nonce incrementation, the hash is different
If hash(block+nonce) < target (target varies with difficulty), the block has been mined and is considered valid

When block is mined, it's broadcast to the rest of the network, which in turn update their blockchain and start mining from this block (if it's the head of the longest known chain)

Getting a block and nonce whose H(block+nonce) < target is a probabilistic process and you can only get a mined block via trial and error. If you mine a block, you've spent lots of trials and errors (proof of work) but verifying that the block is correct is very cheap.

These mined blocks form a chain. Miners compete to form the longest chain. This is what makes Bitcoin secure: to change the chain you have to mine as many blocks as you'd like to change plus one, before anyone else finds a single block.


How to detect a race attack and re-spend the already-spent outputs?

As Doug said in the question comments (posted here as an answer by his request):

  If there is at least 1 conf by the network, a race-based double-spending attack is not possible.

Therefore the attack he describes is a fork-based double spend similar to his questions here and here.