Multiple public keys - Total received funds If I create a new public key (Bitcoin Address) for every transaction I'm receiving, is there some way to find my total balances of my wallet/private key?

And are there any downsides with creating unique addresses for every transaction?

Just to make it clear. I'm not talking about total balances in the wallet's GUI. I'm asking if there is some way for thirdpart who is watching transactions on blockchain.info to calculate my total balances in the wallet.

If you're running Bitcoin Core as your wallet, then the graphical interface is handling your wallet's total balance already, which includes the balance of every address within your wallet.

If you prefer the command line method, use bitcoin-cli getbalance to get the total sum of all transactions in your wallet. That command basically balances your wallet transaction history like a checkbook, so including deposits and debits, and delivers you the final balance.

The balance shown in the Bitcoin Core GUI is the same as the balance displayed with bitcoin-cli getbalance.

To answer your second question, as far as I can tell there is no downside to creating unique addresses for every transaction, and in fact it is highly recommended in order to aid in anonymity. The fact that you own all of the Bitcoin associated with a particular wallet is harder to determine when more than 1 address is used to receive funds.

However, spending the entire balance of multiple addresses in a single transaction could negate any protection you were hoping to have by using multiple addresses in the first place, since an attacker could then determine, using that single transaction ID, that the total balance of the multiple addresses was associated with the same wallet.

Hope this helps

EDIT

One important note when creating many unique addresses is, if using the Bitcoin Core wallet, backups would need to be created more frequently because new private/public keypairs are generated when creating a new address, and previous backups will not contain the new keypairs. Therefore, if you create a backup of your wallet, then create a new address and receive 1BTC at that address, then your wallet backup will not contain the address that received 1BTC.


I tried to withdraw coins from Binance but they were lost on the blockchain. I need help from an expert I really need some help from someone with a lot of knowledge and experience with crypto trading.

I tried to withdraw LTC from my Binance account recently, but I mistakenly used a BTC "receive address" from my Green Address desktop wallet, and the transaction didn't go through. I've contacted Binance and Green Address customer support several times and neither company is willing to help me recover my lost coins. Binance won't own the fact that they allowed a transfer that had an invalid receive address (the address started with a "3", not an "L"), and they said my coins are now lost on the blockchain.

Green Address says they don't have access to my private keys in order to help. I don't know how to access my private keys or even if they exist. I do have 2-factor authentication enabled on Green Address wallet. I've been told by members of this forum that I may be able to recover my coins if I'm able to convert my Green Address wallet to a cold wallet, and I have emailed Green Address with that question and am waiting for their reply.

Someone also posted that I try calculating an address from my wallet seed. I have no idea how to go about doing that and that's one of the things I need help with. I'm a total newbie to crypto trading and trying to understand all the technical steps is overwhelming and hard to comprehend.

I would be eternally grateful, if someone would be willing to walk me through the steps of how to recover my LTC coins?

It's a lot of money to me. I'm attaching a screenshot of the original transaction from Binance website, including the Green receive address and the Txid.

transfer that had an invalid receive address (the address started with a "3", not an "L")

An address starting with 3 is a valid LTC address, so Binance could not have known this is not where you want them sent.

In your particular case, recovery may not be possible without cooperation from Green Address. Green Addresses are 2of2 or 20f3 multisig addresses and require two keys to spend coins from. One key is from your seed words, and the other is held by Green Address, in the case of 2of2.

Unless you are able to convince Green Address to share that key with you, or sign a tx using it that moves your LTC, you will not be able to access the coins.

If you have a 2of3 multisig, you hold 2 of the keys, and should be able to use an Electrum-LTC client to generate the multisig address and use it on the Litecoin chain.


Month into crypto and have some questions I've been invested in btc, eth, and ltc for about a month on Coinbase. I'm still working to learn about this expansive realm. I don't totally understand the need for a wallet and how that works. Somehow I can keep my money growing in the exchange and keep them secure in a wallet? How do I do that and what should I use? I've also heard things about protecting your "keys". What are keys and what is the best way to protect them? Thank you for your answers!

Private key: Your wallet stores the private key. With the private key, you can don transactions. Never give someone your private key or this person has controll over your coins. And: There are no bitcoins in your wallet. They are all saved as transactions in the decentalized blockchain!!

If you let your coins on the exchange, it means automaticly that you trust the exchange. If there is a security issue and all coin on the exchange are stolen, it's your problem. If you send them to an adress generated by the public key (also stored in your wallet), you only need to trust yourself.
If there is a hardfork (Bitcoin-Cash-hardfork for example) and the coins are on the exchange, you don't have access until the exchange allows you to trade the BCH.
So you should think wheather it's maybe usefull to store the BTC in your wallet instead of your exchange. But you could also wait a few months until the transaction fees are maybe lower.

The best way to protect your keys is letting them in your wallet and (of course) don't publish your private key.


Is there a newer Bitcoin blockchain download available? The SourceForge project page for Bitcoin provides a blockchain download at http://sourceforge.net/projects/bitcoin/files/Bitcoin/blockchain/ but this file is old/dated.

How and where can I download an up to date copy of the Bitcoin block chain?

Since v0.10, the parallel block download in Bitcoin Core is often comparable in speed to torrent downloading, does not require temporary double storage, and validates while downloading instead of sequentially.

Original answer:

Please use the bootstrap.dat torrent download. It is more frequently updated and much safer to use.

You can find the .torrent download at http://sourceforge.net/projects/bitcoin/files/Bitcoin/blockchain/bootstrap.dat.torrent/download


Can somebody really tell how many BTC I have from a receive address? I bought a small number of BTC in 2013.
Although it's not true, let's say for simplicity that I never moved them from my wallet.dat where I first received them.
Now, in 2020, I generate a new receive address in Bitcoin Core, loaded with that same wallet.dat.
Then I put this receive address in public.
Can anyone now somehow determine how many Bitcoin I own, based on that receive address?
Or is that receive address now as "opaque" and "pristine" as any receive address which has not received any coins yet?
I've been trying to understand exactly HOW Bitcoin is "not anonymous" for over a decade, but it's very difficult for me to grasp. For all practical purposes, it seems to be anonymous if actually used correctly. That is, never reuse receive addresses.
But I'm probably missing something.

Can anyone now somehow determine how many Bitcoin I own, based on that receive address?

There is no way to look at an address on the blockchain (or a block explorer) and identify which other addresses were generated from the same wallet that generated that address. Obviously anyone can look at the blockchain and identify the number of Bitcoin held at a single address.

Or is that receive address now as "opaque" and "pristine" as any receive address which has not received any coins yet?

If the receive address hasn't received any Bitcoin it is as opaque and pristine as any other address that hasn't received any Bitcoin.

I've been trying to understand exactly HOW Bitcoin is "not anonymous" for over a decade, but it's very difficult for me to grasp. For all practical purposes, it seems to be anonymous if actually used correctly. That is, never reuse receive addresses.

Privacy (like security) is not boolean. It is a continuum. Bitcoin is pseudonymous rather than anonymous. The number of Bitcoin held at addresses is public but it is not obvious which individual owns a particular address. However, there are ways external to the blockchain where this information can leak in addition to address reuse. For example, if you buy a good from a merchant using the Bitcoin held at that address that merchant now knows you own that address and can track when you spend your funds in future.
Other altcoins like Monero, Zcash, Grin, Beam etc try to provide stronger anonymity guarantees than Bitcoin by not making transactions and effective balances held at addresses public. However they do that at the expense of weaker scalability, more experimental cryptography and/or greater computational burden. Alternatively Lightning (on top of Bitcoin) doesn't make transactions within a channel public but the opening and closing of the channel on the blockchain are still public.


How many connections do I have on bitcoind? How do I find out how many connections bitcoind has made? From terminal.

I figured it out:

bitcoin-cli getnetworkinfo

It will tell you, among other things, how many connections you have at the moment.


Retrieve number of OP-RETURN transaction Is there a possible way to extract the bitcoin transaction protocoll with Python and extract specifically OP RETURN transaction?
I want to plot the number of those over the course of time to derive some statistics from it.

Best regards
Nils

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 source of bitcoin value? From what I understood, the economic intrinsic value of Bitcoin as a currency is based on the "CPU-work" required to produce them. That is what makes Bitcoin rare enough to qualify as a currency. Is that it?

Now the thing is CPU-work doesn't come free of social costs. Doesn't it have some incidence on things like:
- market prices of fuels (we all end up paying our electricity higher as a consequence of bitcoin, i.e. we bare the burden)
- climate change (future generations will have to pay more to survive in a less stable climate)
- no legal-compliance checks (i.e. bitcoin activity like all business takes advantage of the security of the State but doesn't fulfill the function of checking legal compliance of transactions as the banking system does - or should I say: is legally required to do)

Welcome to Bitcoin.SE! Some interesting points that you raise.

Bitcoin is more analogues to gold than more recent traditional banking.

Yes, since power is used in bitcoin mining there are some additional distribution costs certainly. The distribution infrastructure exists anyway and in most cases is not being used to capacity ex-bitcoin, however, the more additional power that a wire carries the more losses there are. If power is in limited supply because generation capacity is being reached then there are certainly additional generation costs, otherwise, the generation cost, in most commercial scale generation projects, is in most cases nothing or close to it.

I heard somewhere recently I think that the total power usage in bitcoin mining is equivalent to the full output of three large nuclear reactors. I wondered what effect that may have on climate myself at the time but rationalised that regardless of Bitcoin, practices in generation need to globally improve. In most countries people either pay for the full cost of their power or, pay the cost of generating it themselves.

It is true that the security of the state is to the advantage of all and is why people are free to engage in things like transacting with Bitcoin. As stated, Bitcoin is more analogues to gold than it is to the banking system. So, Bitcoin currently seems to be about as regulated as transacting in cash, but without the tyranny of distance, and without the value ties of fiat currency and, without centralisation. No central bank can decide to print 21 million more Bitcoin and halve the value of everybody's holdings, much like gold.

With exchanges and Bitcoin Debit Cards, Bitcoin is linked to the local banking system much like any other offshore currency.

In Australia, Bitcoin is legally just like cash. GST and other taxes are payable.


Namecoin name_new fee for already taken I'm very new to Namecoin and tried to to register a domain with name_new d/<name>. I received the tx and rand response which seemed normal. Later (after 12+ blocks) when I did firstupdate and it responded with an error (using windows and I think I had escape issues):

error: {"code":-1,"message":"name_firstupdate <name> <rand> [<tx>] <value>\nPerf
orm a first update after a name_new reservation.\nNote that the first update wil
l go into a block 12 blocks after the name_new, at the soonest."}

So I corrected the escape issues and reissued firstupdate:

error: {"code":-1,"message":"this name is already active"}

And then thinking maybe the original firstupdate took, escape issues and all, I tried an update:

error: {"code":-1,"message":"this coin is not in your wallet"}

I then did what I should have done first and looked up the domain name and found it exists and will expire in 188 days.

So... my questions are:

1) Why did the name_new not inform me it was taken? The Wiki implies using name_new checks for existance:

  Or check if your domain if free with the command line (the command
  line don't do the conversion) :

./namecoind name_new d/<name>

2) Does the .01 fee for name_new just disappear?

Maybe a little bit late, but for everybody who is interested, the easy command to check if a name exists is simply:

> ./namecoind name_show d/<name>

It will return some informations should the name already be registered, or it will return

error: {"code":-4,"message":"failed to read from name DB"}

if the name doesn't exist.


P2Pool crashes the Bitcoin client I wanted to try out P2Pool mining, so I installed the newest Bitcoin (0.5.2, also tried it with 0.5.1).

Unfortunately when I start run_p2pool.exe it immediately crashes my Bitcoin!

My OS: Win7 x64

Any ideas?

I wrote a solution to this problem two days ago:

How to use p2pool with an accompanying standalone bitcoind

(since the windows gui version of bitcoin 0.5.1 crashes frequently when used with p2pool)

Assumptions:

OS: Windows 7

Bitcoin: Latest stable release installed and working - http://sourceforge.net/projects/bitcoin/files/Bitcoin/bitcoin-0.5.1/bitcoin-0.5.1-win32-setup.exe/download

p2pool: you'll be slightly off the beaten path with this
   configuration as you're specifying the bitcoin address to send
   generated bitcoins and not using the second bitcoin processes wallet

Download latest current p2pool code and extract to
"%programfiles%\p2pool" -
https://github.com/forrestv/p2pool/zipball/master
Download and install latest Python 2.7 (if you get 64bit, you'll need
64bit versions of the packages below) -
http://www.python.org/download/
Download and install python extension package twisted -
http://www.lfd.uci.edu/~gohlke/pythonlibs/#twisted
Download and install python extension package zope.interface -
http://www.lfd.uci.edu/~gohlke/pythonlibs/#zope.interface
Download and install python extension package pil -
http://www.lfd.uci.edu/~gohlke/pythonlibs/#pil
Download and install python extension package pygame -
http://www.lfd.uci.edu/~gohlke/pythonlibs/#pil
Open your Bitcoin GUI client if it is not running and generate a new
address, take note of the generated address and close your Bitcoin
GUI client
Edit your existing "%appdata%\bitcoin\bitcoin.conf" and unless you
know what you're doing, change what ever is there to this and if the
file does not exist - create it:

logtimestamps=1

Create the folder "%programfiles%\p2pool\bitcoind-data"
Create "%programfiles%\p2pool\bitcoind-data\bitcoin.conf" with your
 favorite text editor and populate it with this:

server=1
logtimestamps=1
port=18333
rpcport=18332
rpcuser=bitcoinusername
rpcpassword=bitcoinpassword
rpcallowip=*

Take note of the folder name of the latest current p2pool code - it
 is in "%programfiles%\p2pool"
Create "%programfiles%\p2pool\p2pool.cmd" with your favorite text
 editor and populate it with this:

@echo off
title p2pool
echo.
echo running p2pool ...
echo.
C:\Python27\python.exe "%programfiles%\p2pool\folder-name-of-the-latest-current-p2pool-code\run_p2pool.py" --net bitcoin --address yourbitcoinaddresshere --bitcoind-address 127.0.0.1 --bitcoind-rpc-port 18332 --bitcoind-p2p-port 18333 bitcoinusername bitcoinpassword
echo.
echo p2pool stopped.
echo.
pause

eg.

@echo off
title p2pool
echo.
echo running p2pool ...
echo.
C:\Python27\python.exe "%programfiles%\p2pool\forrestv-p2pool-4f6c2e2\run_p2pool.py" --net bitcoin --address 12uN6G1uAtn7G29qfTdLD9des4y63Whr61 --bitcoind-address 127.0.0.1 --bitcoind-rpc-port 18332 --bitcoind-p2p-port 18333 bitcoinusername bitcoinpassword
echo.
echo p2pool stopped.
echo.
pause

Create "%programfiles%\p2pool\bitcoind.cmd" with your favorite text
editor and populate it with this:

@echo off
title bitcoind
echo.
if exist "%programfiles%\bitcoin\daemon\bitcoind.exe" (set programfilesx86=0)
if exist "%programfiles(x86)%\bitcoin\daemon\bitcoind.exe" (set programfilesx86=1)
if %programfilesx86%==0 (goto :programfiles)
if %programfilesx86%==1 (goto :programfilesx86)
echo ERROR! bitcoind.exe not found in either "%programfiles%\bitcoin\daemon\" or "%programfiles(x86)%\bitcoin\daemon\" - giving up!
echo.
pause
goto:eof
:programfiles
echo running bitcoind.exe from "%programfiles%\Bitcoin\daemon\" ...
"%programfiles%\Bitcoin\daemon\bitcoind.exe" -datadir="%programfiles%\p2pool\bitcoind-data"
echo.
echo bitcoind stopped.
echo.
pause
goto:eof
:programfilesx86
echo running bitcoind.exe from "%programfiles(x86)%\Bitcoin\daemon\" ...
"%programfiles(x86)%\Bitcoin\daemon\bitcoind.exe" -datadir="%programfiles%\p2pool\bitcoind-data"
echo.
echo bitcoind stopped.
echo.
pause

List item
Copy blk*.dat from %appdata%\bitcoin to
 %programfiles%\p2pool\bitcoind-data

Run "%programfiles%\p2pool\bitcoind.cmd"
Run "%programfiles%\p2pool\p2pool.cmd"

You should now be able to mine on your machine to 127.0.0.1:9332 or to your machines IP on port 9332 on your LAN :)


what is a miner's main source of income the name miner might come from the fact that it earns profits from block rewards; but a miner also earns profits from transaction fees, and it can choose which transactions to include into a block or not; usually, a miner also offers wallets as an integrated customer service; all of these remind me of a typical stock broker rather than someone working in a mining field;

i am wondering, which types of revenues, block rewards, tx fees or other paid services, provide the most income for a miner during these days;

Any service a miner offers which is not related to or benefited by their being a miner should be ignored, because this is external and unrelated to mining: anyone can run such a service, and likewise a miner could choose to; or not.

There are some services that a miner could run that are miner-specific, but note that since such services are economic transactions which generally occur in private (ie between the miner and the customer), it is difficult to say how much revenue they may bring in. As an example, a miner could offer a service to mine transactions that are not broadcast to the network before they are included in a block. It would be difficult, if not impossible, to prove that any transaction in a block was such included via such a paid service, unless you were the miner or the customer.

So anyways, the thing we can be most sure about, is the block reward and the transaction fees. This is because that information is necessarily public: the first transaction in each block is called the coinbase transaction, and it includes all of that information.

So you can find this information for yourself, just by looking at the reward and transaction fees included in each block through history.

The block reward is halved every 210,000 blocks, currently it is 12.5 BTC. The transaction fees vary depending on how much users are paying to have their transactions included in new blocks (generally, more transactions means high fees), but right now (and for a good portion of bitcoin's history) transaction fees are a small part of the total mining reward.

As an example of a busy time on the network: in block 500,439 the transaction fees (~13.01 BTC) exceeded the block reward (12.5 BTC), and many blocks in that range have very high fees as well. To my knowledge that block is the only time the block reward has been less than the transaction fees, but maybe somebody else here knows better (I'm excluding blocks with 'erroneous' transactions which included unnecessarily large amounts of BTC as their transaction fee, at least).


How to perform a double spend attack in websites that accept transactions with 0 confirmations? To perform a Finney attack or a 51% attack I need to have lots of computational power, but in this case (a website that accepts transactions with 0 confirmations) it seems to me that I only need to issue two transactions almost simultaneously. Depending on what the miner chooses to include in the next block, I might get lucky.

Is it that easy or am I forgetting something?

If you are attempting a 0-confirm double spend then which transactions (if any) are included in the next block is irrelevant.  Your goal is to simply complete both transaction prior to either merchant getting notification of the other one.

The "problem" is that the network is fairly quick at passing transactions from one node to the next.  Unless you have located an inefficiency in the network, a bottleneck, or actively degrading network performnce is unlikely you will complete both transactions before the merchant sees both halves of the double spend.

An effective countermeasure would be for the merchant to introduce a short delay between the time they detect your 0-confirm transaction and when they give you access to the purchased item or service.   Say you execute a perfectly timed double spend.  The merchant sees their transaction and waits 60 seconds.  60 seconds is a long time for transactions to not propagate the network.  If at any point in that 60 seconds the merchant sees the "other" transaction you have failed.   Unlike other forms of fraud you will lose the funds as your double spend is irrevocable.  It will just be luck on which merchant gets paid.

Also many transactions are not irreversible.  Software which has a license key can have the license key revoked.  Many giftcards can be reported as stolen to freeze the funds.  Any subscription based site would grant you at most a few seconds of service before cutting you off.  Product which require physical deliver are never going to be shipped fast enough to execute a double spend.

The risk of a 0-confirm double sped is low but security can be improved by designing ultra fast low latency "super nodes".  A service provider could setup a network of Bitcoin nodes around the world with low latency links between them.  Each of these nodes would be running modified version of bitcoind to maximize the number of connections, establishing thousands or even tens of thousands of connections to peers.  No matter where the two halves of the double spend originate it would be only a few hops to a super node.

If a merchant only accepts transactions from the super node network then you would be unable to complete the double spend.  Either the network has seen both transactions and the double spend is detected or they haven't in which case one of the merchants won't give access to the item purchased.


Is bitcoin node and bitcoin client the same thing? What is the difference between btc node and btc client?

Which one is bitcoin-core and which bitcoind?

The Bitcoin system runs on a peer-to-peer network.
Each device participating on this network is called a "node" (of the network).
This node is actually a device running a Bitcoin client program.
Technically speaking node and client coincide. However they are different concepts in my opinion. One refers to the role of being part of the network, while the other refers to having a Bitcoin client program running.

Bitcoin-Core is a client program; namely, the reference implementation.
Bitcoind is just the "daemon" of Bitcoin-Core, that is the client core, running in the background, and can be controlled by bitcoin-cli (the command-line interface) via RPC.


What happens if a P2SH redeem script is lost? Assume Bob creates a complicated Bitcoin Script and asks Alice to make a payment to a hash of this script. (Using a P2SH transaction)
If Bob loses the script (i.e. the source code of the script), is the payment transaction going to be locked forever?

Yes, if you lose the redeemscript, the funds are going to be locked forever. In order to spend a p2sh output, you need to both reveal the redeemscript that hashed to the address and then satisfy the conditions of that redeemscript. If the script cannot be recovered, it cannot be satisfied and the funds will not be spendable.


Can I get an overdraft? Hypothetically...

A uses a desktop bitcoin client, who would like an overdraft facility.

B has lots of bitcoins and would like to offer that overdraft and charge interest on the overdrawn amount.

Can A just go into a negative balance with B's backing? If not, what would A and B need to change to achieve an overdraft or an aproximation of an overdraft?

(Note, an overdraft is different from a loan, but a loan might be used to approximate an overdraft if its automatic.)

Bitcoins are like tangible cash in a sense that you can't overdraft. If you want to spend more Bitcoins than you have, you have to get more Bitcoins first. To achieve that either B has to send A some Bitcoins, or A and B have to create a transaction together (A created one input, signs it, B creates another input, signs it, and then someone needs to do some balancing of how much Bitcoins go where).

Alternatively, one can expect to see some Bitcoin banks in the future that allow you to overdraft from their shared address, and later charge you for it. This solution is not hard to implement, but I don't know if something like this is available anywhere currently (maybe through IBB). The main problem with this solution is trust between parties and how effective debt collecting would be.


Transaction stuck in the Omni layer A friend of mine accidentally transferred USDT from Binance to GDAX ... and apparently it's stuck in the Omni layer which handles these types of transactions.  However GDAX is not looking for them and is not able to help retrieve or map the funds to one of it's currencies.  Anyone know of a service that can retrieve the funds from the Omni Layer blockchain?

The omni layer is not a separate network or blockchain. It is simply a standardized format of transaction on the Bitcoin blockchain that uses the OP RETURN feature to move non-bitcoin assets.

In the event that your friend is able to convince GDAX to sign an Omni-format transaction using the private key for the deposit address the funds can be recovered.  Otherwise there is nothing anyone can do to recover the coins. Anyone else who claims they can and asks you for private information is trying to scam you, beware.


Does Bitcoin mining reward halving have documentation? Or is it just in the code? I can't seem to find actual documentation about the reward halving process.
This is not addressed in Bitcoin's Whitepaper, although Satoshi Nakamoto briefly mentions the decrease of the reward, but never explicitly talks about the amount of the reward.
I've also looked in the references of Bitcoin's Wikipedia page, but nothing there either. The couple of crypto books I own do not mention it either.
Is it possible that the amount is explicitly described only in the source code? (To be honest I haven't looked at the source code.)

This is not addressed in Bitcoin's Whitepaper, although Satoshi
Nakamoto briefly mentions the decrease of the reward, but never
explicitly talks about the amount of the reward.

Satoshi speak about the halving process since the release notes for Bitcoin v0.1 Alpha:
Total circulation will be 21,000,000 coins.  It'll be distributed
to network nodes when they make blocks, with the amount cut in half
every 4 years.

first 4 years: 10,500,000 coins
next 4 years: 5,250,000 coins
next 4 years: 2,625,000 coins
next 4 years: 1,312,500 coins
etc...

When that runs out, the system can support transaction fees if
needed.  It's based on open market competition, and there will
probably always be nodes willing to process transactions for free.

Satoshi Nakamoto

On the Bitcoin wiki ( https://en.bitcoin.it/wiki/Controlled_supply )  you find this table that tell you when and how each of the 33 halving process will happen:

If you need a technical explanation of how the halving work in the code here you find a dissemination about it: https://ma.ttias.be/dissecting-code-bitcoin-halving/
Keep in mind that the halving are programmed by block height, so there are only estimates on which date these blocks will be reached (and the block subsidy will cut in half), but all other info on this topic are exact and well documented.


Who store seed phrases data Seed phrases seem to be pretty secure, approximately as strong as bitcoin private key according to this site https://en.bitcoin.it/wiki/Seed_phrase.

But who store the private key adresses of these seed phrases, I suppose it is the wallet software provider, so each one of these provider have to save this data somewhere, and what prevent them from storing it in clear text and just acting like it didnt know our private key.

who store the private key adresses of these seed phrases,

The private-keys are generated from the seed-phrase by a mathematical function. There is no need to store a list of seed-phrases and corresponding private-keys.

  I suppose it is the wallet software provider

No, you should be the only person to know or store your seed-phrase. Ideally it should not be stored on a computer of any sort. Best practise is probably something like punch it onto metal plates - you can buy letter punch kits to help with this. Ideally you'd provide a few trusted relatives with overlapping subsets so that any two of them working together can retrieve your legacy if an airplane lands on you in five seconds from now.


What can you do with the private key? I am trying to understand all security regarding blockchain and bitcoins.

Let's say you have a bitcoin wallet which is secured, only you know the private key. This bitcoin address was created on one of the bitcoins wallet provided by bitcoin.org
What if a person has your private key? I know it's difficult but let's say he knows the 54 letters private key from hacking a database. How can that person interact with your wallet?
Does he have to know which wallet you use as well or can he use just the private key to 'log in'?

Anyone who knows the private key will have full access and control of any coins stored at the corresponding address.

When you put a password on a wallet or login account, that password is only for unlocking that instance of the wallet (it is possible to create another instance, that is not locked by your password). Once unlocked, the wallet will use the private key to sign transactions that move the coins, etc. But without the password an attacker can not unlock the wallet if it the wallet alone is found.

However, having the private key itself means you don’t need to unlock the wallet, because you already have the key. You can import the key into just about any other wallet software, and then use that wallet instance to move the coins, etc.

There is BIP38, which allows you to password protect a private key itself, but this is different, and a less common set up.


How to get the "BTC" abbreviation via command line? I'm writing a module that connects to multiple wallets at once and I would like to have a way I can simply query the coin daemon for its coins abbreviation (not the "microcoins" as asked in a comment below, just the 3 character currency identifier).

Since my module also reads the coins config file, my only solution thus far is to add a parameter in the coins config file:

abbr=BTC

But I was wondering if there was a cleaner way to do this. A simple rpc command that I can pull the abbr from?

I will post my solution, but I still think there should be a cleaner way of doing this.

You would first need to open up (or create) the conf file for the coin which you wish to connect with then add abbr=BTC (or replace 'BTC' with whatever coin abbr you want).

You would then need to open up and read that conf file with your script/module. Since I am working with Python, here a function that does that:

def readCfg(location):
    cfg ={}
    with open(location) as f:
        for line in f:
            line = line.strip()
            if line and not line.startswith("#") and '=' in line: cfg[line.split('=', 1)[0]] = line.split('=', 1)[1]
        return cfg

cfg = readCfg('/home/username/.bitcoin/bitcoin.conf')
print(cfg['abbr'])

I think maybe having a documentation of this method done in other languages would be beneficial to the Bitcoin community. Feel free to expand on my answer until Bitcoin devs decide to add 'BTC' to the output of an rpc call.


Transactions used to form a block I've read the Developers Guide ( bitcoin.org/en/developer-guide ), asked a few peers and I still don't understand how the transactions are used to form the block.

I did get that the transactions are used to form the Merkle tree. Do all people mining the next block use the same transactions to form the Merkle tree?

Let's say that the Bitcoin network has the transactions A, B, C, X, Y, and Z. All of them are unconfirmed.

I'm mining the transactions ABC and you are mining XYZ. If so, if I find a block that contains ABC, will I then mine the XYZ transactions?

If I find a block, you will have to check which transactions were included in the block by me, before forming the next merkle tree, right? If not, you might use, for example, the B transaction again, which was already confirmed by me.

Do all people mining the next block use the same transactions to form the Merkle tree?

No. This can arise because miners choose transactions differently (I say there shouldn't be free transactions!) or because a transaction is only known about by 90% of the network.

  I'm mining the transactions ABC and you are mining XYZ. If so, if I find a block that contains ABC, will I then mine the XYZ transactions?

That depends on why you didn't include XYZ in your first block.

If you didn't include them because you don't know about them, then you won't.
If you didn't include them because they didn't pay enough fees, then you might.
If you didn't include them because there wasn't enough space in the block, then you probably would.

  If I find a block, you will have to check which transactions were included in the block by me, before forming the next merkle tree, right? If not, you might use, for example, the B transaction again, which was already confirmed by me.

Yes. Mining clients download and fully validate blocks before mining on top of them.


Spreading reward of a block over the miners proceeding it Say I want to implement a rewarding scheme that spreads the reward of a block over its own miner and the miners that build on top of it. Is it possible?

More concretely, say each of my blocks bring 10 BTC(Coinbase+Tx fee). Let's say a miner mines a block. I'd like him to receive only 5 BTC. Whenever someone else mines on top of his block, I'd like him to receive the remaining 5 BTC.

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

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 there a legal way and free way to open a Bitcoin exchange in the United States? I've been doing some reading on the state of starting a Bitcoin exchange in the United States, and I have a couple of unanswered questions.

1) What are the legal fees and process for starting a regular exchange?

2) When are the legalities surrounding exchanges like coinffeine, where two anonymous users exchange and coinffeine acts as the intermediary?

3) How can I connect with a partner in a developing country like Panama, where it is much easy to start an exchange?

There is a free way. There is a legal way. There is not a free, legal way.
Free way
Get a DynDNS account, and a Raspberry Pi. Host the exchange on your home internet connection.
I can't think of any reason why someone would trust their money to my_exchange.dyndns.biz, but I suppose you could do this.
Legal way
Money service businesses are generally regulated state-by-state, so it's difficult to give you general advice. I would suggest that you find a lawyer that practices law in that state and who specializes in banking law; they can tell you what you need to comply with. If you do not know a lawyer like this, I suggest going to a lawyer you do know and asking for a recommendation.

When are the legalities surrounding exchanges like coinffeine, where two anonymous users exchange and coinffeine acts as the intermediary?

Those two users are breaking the law. Operating an unlicensed money service business is against the law, and people have been arrested for exchanging Bitcoins. (Also, if you operate an unlicensed MSB, you're automatically also committing a federal crime.)
Whether Coinffeine is also breaking the law is a very interesting question that I am totally unqualified to answer.


Can I use the same seed words for two wallets? I like the security of a local wallet, but at the same time I don't like the limited access. So I'm thinking I'll install the same wallet software on a second computer at my office and use the same seed words. This should get me access to the same private keys both at home and the office. I'll be the only person using the wallets, so accidental double sending won't happen. I don't know if transactions created on one wallet will show on the other, however, but I don't care to much about that.

Are there any potential issues with this that I'm not seeing?

I'll be using Electrum and Coinomi through Bluestacks, both on Windows 7.

I'm not too familiar with how Electrum handles duplicate seeds. Personally, I start a multi-signature wallet and require only one signer but add two signers (my mobile device & my laptop). You can do this on Copay, Electrum, and most other bitcoin wallets.


Why MultiBit replays transactions from internet on every startup? I've installed MultiBit version 0.5.14 and every time i start it, there is a synchronization happening with network:

Replaying blockchain from date "Aug 3, 2013"
Stopping Bitcoin network connection...
Synchronising with network...
Synchronising with network, 15,253 block(s) to download. Block date : "Aug 4, 2013".
...

My assumption is that it holds on to a block generated on 2013-08-03 as a genesis block, in order to save space. But then, it updates. Why not hold on to the updated block instead of initial one? Alternatively, if keeping transaction history is important, why not cache downloaded data locally and replay it from disk instead? I have a pretty fast connection, but there's so much internet traffic happening, that even for me it takes minutes to start.

EDIT: Apparently, I was wrong. It does not replay transactions anymore on startup. I don't know what am I doing differently this time.

MultiBit remembers the last blockheight that it saw in the wallet.

There are various times where, if it sees discrepancies across the wallets (or compared to the Bitcoin network) it goes back in time to get the transactions again. This is is to prevent inconsistencies and to deal with forks etc.

It goes back in time using a checkpoints file, which is included in the installer. As 0.5.14 is a couple of months old now it goes back a bit further in time than is ideal. I update the checkpoints file in every build.


Electrum Gap Limit from CLI Is there any way to change wallet gap limit in Electrum from command line? If yes, how? If not, could it be bypassed using some kind of external script? I really need to avoid GUI. Thank you in advance.

The only way is to edit the json code in the wallet file and add the gap limit into it. You can do that using the command line tool jq:

jq ". + {gap_limit:100}" wallet_file


IoT to Hyperledger Fabric, and Tracing / Certifying data I'm thinking about IoT and Blockchain to certifying data.

My blockchain is not public, and it has 3 nodes. I use Hyperledger

So, I have a sensor, that is a light blockchain client, not powerful enough to be a full node. I want to send data to a Blockchain, but I have several issues.

My IoT object should not have Internet, so maybe I should send it to a local gateway connected to internet, and then send the data to the blockchain.

If my IoT object has internet, I would hide my Blockchain behing an API so that Blockchain is not publicly available like any other private DB.

My question about tracability / certification is about code I use:

To extract data from sensor
To code an API that would write into the BC
All the smart contracts

I can certify that the ledger has not been altered by the administrator of my company, but how can I certify that my admin has not altered code listed on those 3 points ?

If I can't guaranty that code has not been altered, how should I certify my data ?

I can certify that the ledger has not been altered by the administrator of my company, but how can I certify that my admin has not altered code listed on those 3 points ?
If I can't guaranty that code has not been altered, how should I certify my data ?

You can’t, and this is the problem with ‘supply chain tracking’ and other such ‘blockchain’ scams.
A blockchain cannot trustlessly certify data from the real world. A user would need to trust that the sensors (or some other oracle) have truthfully uploaded data to the chain.
After all, what is to stop someone from uploading false data? You could only allow ‘certified sensors’ to upload data, but now everyone needs to wholly trust the manufacturers of those sensors. Obviously this is an issue, since the goal of ‘supply chain tracking’ is to apparently reduce potential for abuse / provide more reliable data.
And so in the case where we need to trust some authority to upload truthful data, why not just let that authority provide us with a ~centralized database of that data? This would be an immense cost savings, considering how slow and expensive a blockchain is to run.


What is the precise nonce finding protocol? There are many descriptions of what mining is, but none of them describe it exactly. From what I gather:

  Mining means finding a nonce c such that for some information s the hash value h(s||c) begins with a certain number of zeros (h is sha-256, || concatenation).

The "information" is given here. The nonce is an integer that is incremented in the mining process. But it seems that it's not s||c that is hashed, but rather there is some double hashing going on, but of what, h(s)||c, h(s||c), h(s)||h(c)? I can't deduce it from the Python code in the previous link (NB: I'm code illiterate).

Also the nonce isn't just initialized at zero and then incremented until there's success:

  To avoid risking wasting work in this way, there needs to be a random starting point, and so the work becomes to find H(s,x,c)/2^(n-k) = 0 where x is random (eg 128-bits to make it statistically infeasible for two users to maliciously or accidentally start at the same point), and c is the counter being varied, and s is the service string. (source)

But that's the article describing hashcash, and who knows bitcoin might not have implemented the hashcash protocol as it was proposed.

So my question is, what is the exact protocol? I'd go and read the source code if I could but like I said I'm not code literate. Surely the answer must be possible to formulate concisely, something like:

  Compute h(s||c) where c runs over 0,1,... until value begins with 15 zeros.

or

  Hash s and obtain x in manner X, then compute h(h(s)||c) where c runs over x,x+1,..., until value begins with 17 zeros.

Sorry if this has been asked before, if so clearly I'm googling the wrong words, thanks.

This mining simulator is a good visual of what is being hashed.

http://www.yogh.io/#mine:last

People are correct you don't have to change the Nonce it's just the fastest way to get a different hash output.  You could very well keep the nonce at 1 and change the timestamp, or the list of included transactions, which would change the merkelroot.

What's being hashed is version + previous block hash + merkel root + time + bits (target) + nonce.  This gets hashed twice sha256(sha256(blockheader))

The code and description here is pre
https://en.bitcoin.it/wiki/Block_hashing_algorithm


Private Key leakage due to reusing same address, how to prevent? 1 What precisely is the meaning of "reusing"? Is it receiving multiple times coins to the same btc address? Or is it also about sending coins?
2 How can people avoid this leaking of information when using a wallet, best practices?
3 How many times of reusing could be enough to seriously allow leakage/reingeneering of the key? Just one time is enough ? Possible to make any estimations?
4 Is this reusing problem only inherent to bitcoin? Or which other blockchains would you know of with same issues?

No, reusing address won't succeed in private key leakage (assuming quantum resistance).

Yeah, reusing has two meanings - if you use static address it may succeed in lack of privacy. Imagining the situation when you share single address with police department for some contract work, and also you use the same address in your darknet market store (hypothetically).
But reusing is also related to spending from an address, during which you share your public key (it's needed to be shared publicly to confirm transaction signature).

Use BIP44 scheme, don't share one address to more than one person. Use invoices (btcpay server) rather than static addresses. If you want to be even more private, use P2E or Paynym's protocol.

As in example in point 1, once is enough in some case

Address reusal is a problem in utxo-based blockchains. Ethereum, being account-based is much less affected by it, as the privacy on this front is non-existent by default in account-based model blockchains. With bitcoin, utxo model is at least preventing users from obvious mistakes.


Can bitcoin purchase be tracked? Can a bitcoin transaction be tracked? I'm planning on buying bitcoin from coinmama.com and I'd like to ask if I can be tracked down for using my credit card? Will someone know my location or my bitcoin address if I buy it using a credit card.

Can a bitcoin transaction be tracked?

Mostly yes, all bitcoin transactions are recorded in the blockchain. There are techniques to try to cover up the trail -see Bitcoin mixers.

  I can be tracked down for using my credit card?

Obviously the credit-card company (& some of their employees) know you bought something from a Bitcoin exchange, likely Bitcoin. They know exactly who you are.

Obviously the Bitcoin exchange (& some of their employees) you used also know your identity and that you purchased Bitcoin with a credit card.

  Will someone know my location or my bitcoin address if I buy it using a credit card.

The credit card company will not know your Bitcoin address.

The Exchange (& some of their employees) know your Bitcoin-address.

They don't know your physical location unless you buy the Bitcoin in-person.

Many exchanges are required by Know Your Customer (KYC) laws to know who you are sufficiently for law-enforcement to track you down. Some of the employees of such exchanges will have access to this information.


Environment for building Bitcoin core in Windows I'd like to try building the Bitcoin core source in Windows. The instructive materials I've found take too much for granted. What environment needs to be installed before building? Can it be built in Visual Studio, or is it one of those cross-compilers like MingGW that compiles code originally written for Linux so it can be executed in Windows?

In the past, the standard method of building for Windows has been to use MinGW. Either have MinGW on Windows and compile from within it (may be more difficult) or cross compile it from a Linux environment.

However, fairly recently, support for using MSVC has been added. Although the official binaries do not use MSVC, you can self compile using it. We even have CI that makes sure that everything builds under MSVC.

Instructions and the necessary project files can be found at https://github.com/bitcoin/bitcoin/tree/master/build_msvc


How prevalent are coin attacks with botique altcoins? I have deployed several altcoins using various PoW algorithms on my LAN for my buddies and I to mine/learn from. We ultimately want to go the distance of deploying an altcoin to the world, writing the white paper, doing the leg work of maintaining it and getting it listed on an exchange.

I have a fear that since our incredibly slim budget has limited us to a very small amount of computational power with which to develop these altcoins (at least initially) that if/when we go the distance of releasing a fully functioning altcoin we will be swiftly crashed by someone with a cabinet full of ASICs and a love of trolling.

I guess my question(s) are how common is this and what is the least expensive but effective way of preventing it. Please don't destroy my dreams, I understand making a coin that ever ends up worth anything is highly unlikely, I am asking for technical advice relative to the issue at hand, not to be told that having a coin of value with a small development team and little capital investment is impossible.

Thanks!

Schwifty

If you'd like to be absolutely sure that some malicious miner won't attack your coin, you could hard-code in a set of 'approved' miners (ie, your miners). Doing so greatly undermines some of the core concepts of a cryptocurrency though (open, permissionless system, etc), so that probably isn't a good option by most measures.

So then, what is the best option?

Many coins choose to employ an 'ASIC-resistant' algorithm, with the goal of preventing ASIC-wielding miners controlling their network. Instead, the idea is that GPU (and perhaps CPU) miners will be the ones securing the network, and many people argue that the the distribution and economies of scale involved in GPU mining are better-suited to create a decentralized network.

However, in practice we've seen that perhaps no algorithm is ASIC-proof. In fact, an algorithm that is extremely difficult to build an ASIC for may just concentrate mining power even further, as very few people will have the skills and resources to create an ASIC for such an algorithm. Such people could thus easily control the majority of hashpower on a network, once they have built some ASIC miners.

For a more in-depth look at this issue, check out this article written by David Vorick (a SiaCoin dev).

It is worth noting though: nobody is going to invest the resources to invent an ASIC that attacks a very small coin. There would be no economic incentive to do so, this problem only becomes apparent once the network has grown and is storing a worthwhile amount of value. (Keep in mind though, if you choose an algorithm also employed by a larger chain, then such ASICs might already exist).

Trolling aside, it is also worth noting that it is not necessarily in a miner's economic interest to attack your coin. If a miner owns some ASICs, and can make money by mining with them, then there is perhaps a substantial opportunity cost involved in instead using the ASICs to attack your chain. This incentive helps keep miners 'honest', in that they will benefit more by using their hashpower to secure a chain, rather than attack a chain.


NBitcoin: Get address out of raw block stream OK, I am sure that this is a really dumb, rookie question, so sorry in advance...
I am trying to read through the blockchain and display the receiving address(es) for all transactions in the chain. (Just like Blockchain-Explorer would do.) My library is NBitCoin in C#, so I am not really working through the raw data here. My starting point is the the Hash that is in the output transaction part (TxOut.ScriptPubKey.PaymentScript.Hash). I read in another post that in order to convert that Base160 encoded hash to a BitCoin address I would have to add 00 in front and then do a Base58 encode of the resulting array. So I did that:

Base58Encoding.Encode(ArrayHelpers.ConcatArrays(DoubleZero,TO.ScriptPubKey.PaymentScript.Hash.ToBytes()))

Then I took a sample and compared it with the output blockexplorer.com had for the same transaction, and unfortunately it didn't match. (And yes, I checked the comment made in this question (Deriving the Bitcoin address from the raw block script), my test transaction has a Base160 encoding, so according to my understanding it was sent to an address.
The hash is: caf74d35ff967c946f99588cb03b774350d83331
My generated output is: 13q1EyUVtUfvpixnYkDRoZUsi5ZVi
Blockexplorer.com shows: 16va6NxJrMGe5d2LP6wUzuVnzBBoKQZKom

Just for the sake of it I tried using all the other hashes in that ScriptPubKey block as well, but none yielded the result blockexplorer.com had.
What am I missing here?
thx

my test transaction has a Base160 encoding, so according to my understanding it was sent to an address

I guess you mean ripemd160 or base 16 (hexadecimal) rather than Base160. Ripemd160 is just a hashing algorithm so the output is just bytes, probably encoded in hex (base 16). You can guess it is a ripemd hash based on its length, but not based on its encoding, because the entire transaction is usually displayed in hex.

But to convert from a pubkey hash to an address, you also have to add the checksum onto the end, rather than just the version byte (the 0x00). That is most likely why you are getting a different result, because you have no created a checksum before encoding it with base58.

See the steps outlined here for more info: https://en.bitcoin.it/wiki/Technical_background_of_version_1_Bitcoin_addresses#How_to_create_Bitcoin_Address


-fallbackfee option in sendtoaddress I'm trying to send some bitcoins using bitcoin-cli API, but bitcoin core tells me that Fallbackfee is disabled. How can I set a value for fallbackfee?
I've tried to specify it like
 bitcoin-cli sendtoaddress -fallbackfee=someValue but it didn't work.
 I've also set true for substractfeefromamount and false for replaceable

It seem like you tried to run fallbackfee in the terminal ? fallbackfee is a configuration option and should be put inside a bitcoin.conf file, if you dont have this file on your bitcoin directory you can create it: https://en.bitcoin.it/wiki/Running_Bitcoin#Bitcoin.conf_Configuration_File

Then add your fallbackfee=someValue (without the -) inside your bitcoin.conf file on a new line then restart your bitcoin client and try your command again.


how is Proof of Burn policed to prevent simultaneous buying into multiple alt currencies? Proof of Burn lets someone buy into an Alt Coin.

How is it policed so that someone doesn't "double-spend" by using the same Proof of Burn to simultaneously buy into Alt Coin 1 and Alt Coin 2?

One approach to proof of burn is that you burn coins by sending them to a particular address specified by the altcoin.  For instance, with Counterparty, you could collect XCP by sending bitcoins to the "burn address" 1CounterpartyXXXXXXXXXXXXXXXUWLpVr, thus making the bitcoins unspendable.  Presumably no other altcoin is going to choose that particular address as their burn address, so there is no way you could earn any other currency by burning coins in that manner.

Of course, someone could have started another currency (call it PDQ) that awards credit for coins burned to the Counterparty address, and then people sending coins to the Counterparty address would earn both XCP and PDQ.  I don't know of any reason why anybody would want to do that, or why anyone should expect the hypothetical PDQ currency to pick up any value.

Your reference to "double spend" suggests something different: that you might try to send bitcoins to the burn address for some altcoin, collect your altcoin reward, and then use a double-spend attack to reverse your burn transaction and keep the bitcoins after all (perhaps later burning them for a second altcoin).  As Andrew Chow says, the first altcoin should prevent this by waiting to award the altcoins until the bitcoin transaction has sufficiently many confirmations.


A Bitcoin soft fork idea to help compress the blockchain I've thought about a soft fork that can help storage costs.

Why don't we force miners to embed the height of the TX Merkle tree in the first two bytes of the 4-byte block header version?

It would have two advantages:

It'd fix the leaf-node brute force weakness (CVE-2017-12842), which is currently fixed only by standard-ness rules but not by consensus rules.
Similarly to the description in BIP 141, we can introduce a type of node that is neither a pruned node nor a complete full node, but they'd have txindex=1 for transactions with unspent outputs. Those nodes would first store full blocks. When the next block comes, using their txindex they'd look up the block, find the transaction and check if all outputs are spent. If so, they would remove the transaction from the storage of that block but only keep its hash. This would save a large space since it seems to me that most scenarios of querying a txindex-enabled node would use gettransaction on transactions with unspent outputs?

Any comments? I don't think this is worth sending to bitcoin-ml.

Why don't we force miners to embed the height of the TX Merkle tree in the first two bytes of the 4-byte block header version?

That would be a sane softfork, but it would need to take into account that due to BIP65, the block version (which is a signed integer) needs to be at least 4, restricting it to 2^31-4 values. Maintaining compatibility with BIP9 and possibly BIP340, which assign meaning to certain bits in the version number, would complicate things further.

Also, it's hard to convince miners to softfork in a change that complicates matters for them, which means that absent a successful UASF-style pressure, it's unlikely this would be adopted.

  It'd fix the leaf-node brute force weakness (CVE-2017-12842), which is currently fixed only by standard-ness rules but not by consensus rules.

Indeed! I think a consensus change that enforces a minimal transaction size instead is probably far less invasive.

  Similarly to the description in BIP 141, we can introduce a type of node that is neither a pruned node nor a complete full node, but they'd have txindex=1 for transactions with unspent outputs. Those nodes would first store full blocks. When the next block comes, using their txindex they'd look up the block, find the transaction and check if all outputs are spent. If so, they would remove the transaction from the storage of that block but only keep its hash. This would save a large space since it seems to me that most scenarios of querying a txindex-enabled node would use gettransaction on transactions with unspent outputs?

I don't see how this change is related to this potential mode of operation. Whatever you suggest blocks commit to in their header, it can instead just be remembered by nodes when they first validate a block, without consensus change. To a node locally, if it itself validated how many transactions there actually in the block, it won't ever convince itself of anything else.

I also don't think this mode has any benefits. It shares the slowness of the pre-UTXO model validation(*) with the lack of ability to provide full blocks (like current pruned nodes) while consuming far more disk space (it would need to keep every transaction fully that has at least one unspent output, rather than keeping just the unspent outputs themselves).

(*) Before Bitcoin 0.8, instead of a blockchain + UTXO set, there was a blockchain + index into that chain for every transaction + a boolean for every output whether it was spent or not. This was slow, because it meant that the working set (data frequently accessed by the code) was effectively the whole blockchain (doing many random seeks into for every input being spent). In the UTXO model introduced in 0.8, the UTXO set is kept independently from the blockchain (it does not contain pointers into the blockchain; it contains a copy of all the UTXOs), enabling efficient caching of just the UTXOs, and pretty making the blockchain unnecessary for normal operation (except serving blocks to other peers, or rescanning). That model is what enabled pruning too, as the blockchain itself is no longer used for validation.


C# code for Bitcoin Cash address conversion between legacy and new format I need to convert legacy Bitcoin Cash addresses to new format and back. I am aware of similar question, but it asks about PRC and has solution using python, JS. I need it done in C# with no dependencies.

Does anyone know a library? Or have working sample?

Just found a SharpCashAddr library.
Has pure C# implementation of address conversion in both ways.


What can be bitcoin's secret can be at most and at least? We know that: S(Secret-Scalar) x G(Generater Point-Point(X,Y)) = Public Key
In bitcoin, what is the range of that secret can be? What can it be at most and at least? Is there a limit to it like 2^256? If yes what is the logic behind that too?

The maximum and minimum private key possible is defined by ECDSA and the curve being used. In ECDSA, the private key is an integer between 1 and n - 1, where n is the order of the generator point G. Bitcoin uses the secp256k1 curve whose generator has an order n = 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141, which is almost 2^256.
This means that the minimum value for a private key is 1 and the maximum is 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364140. If you use an integer outside of this range, taking the modulo n of that integer will give you a value that is in the valid range (except for multiples of n for which the modulo is zero).


US Power Supply for Antminer s9 I have ordered Antminer S9. After doing some research I discovered that APW3+-12-1600 PSU 1600W is a recommended power supply however it requires 200+ voltage which is not available to me.

I live in the US and the standard wall socket output voltage is 110V.

Could you recommend a power supply that  would work well with S9 in the US without impeding its designed performance?

A recommendation or a reference to a working guide would be highly appreciated.

I live in North America as well and just wanted to let you know that even though 110V is the most common wall socket voltage you've actually already got 220V coming in to your house.  There are 2 110V lines 180° out of phase from the other ... yadda yadda, some technical mumbo-jumbo...

Long story short, as long as you live in a building where you have access to the breaker box you should be able to add in a 220V circuit to power your miners, you may already have a couple in there for an electric range or drier, etc.

If electrical work is not your forte you should be able to get an electrician in to get you set up fairly easily, the hardest part is deciding where you want to access the power from and then routing the wiring there.

Hope that helps!

-J


Cloning a HW wallet's contents to one or more other HW wallets Is it possible/feasible to clone the contents of a HW wallet to one ot more other HW wallets ( for example to have identical copies in different locations for backup )?

It appears that this should work in theory for 'BIP 039' compliant wallets ( i.e. regeneration of wallet contents on the backup wallet from recovery-seed of first/master wallet ?).

Any snags or gotchas with the above?

Furthermore, if cloning is possible, does it only work for bitcoin or would it cover all cryptocurrencies supported by a HW wallet?

Yes, you can have multiple instantiations of the same wallet. If you input the same seed phrase, and use the same derivation scheme, then you will have multiple copies of the same wallet.

This works for all types of wallets, software, hardware, etc.

  for example to have identical copies in different locations for backup?

Yes, but the usual recommendation is to keep a backup of your seed phrase, in case you forget your PIN, or the hardware fails, etc.

  if cloning is possible, does it only work for bitcoin or would it cover all cryptocurrencies supported by a HW wallet?

This is possible for all cryptocurrencies included in a BIP39 hardware wallet, I'm not familiar with any exceptions. However it would be best to carefully consult the product manuals in any case, to ensure you understand the nature of the wallet and your backups fully.


bitcoin core 0.10.1 upgrade stuck syncing I just upgraded from Bitcoin Core 0.9 to 0.10.1 on Ubuntu 14.4 after being gone for a few months (blockchain data is from February).  When I loaded up bitcoin-qt, it seemed to be working fine and began correctly syncing the missing blocks.  I then quit bitcoin-qt and later restarted the system and it now refuses to get blocks after February 28th, 2015.

I get the following error repeatedly:

ERROR: AcceptToMemoryPool : nonstandard transaction: non-final

I am now attempting a -reindex -rescan, but it looks like this will take a day week or so on my old system due to its older CPU.

Any other suggestions?

Additional notes:

I confirmed that port 8333 was open and node was visible on bitnodes.io with multiple incoming connections.

The message ERROR: AcceptToMemoryPool is to do with your node accepting new transactions from the network and doesn't have anything to do with your local sync state. It just means that someone made a transaction and broadcast it to you which does not respect the rules of your current software version.

It should really be "INFO" rather than error, or simply just not logged at all.


Is the idea of color coins/open assets still alive? Are there any interesting projects ahead on this way? Since Ethereum has taken the way for smart contracts, it seems to me that the color coins projects have been abandoned in favour of the Ethereum ecosystem. But I might be wrong. Are there any interesting projects still for this approach?

There are at least 5 different colored coins implementations on bitcoin that I'm aware of. The ones in active development include:

Colu - They recently showed how their implementation can be used with the lightning network. https://www.colu.com/
Chromaway - They've been running a lot of pilots with various banks and whatnot. http://chromaway.com/

There's also a slack channel for colored coins as well, which you can see here: http://coloredcoins.org/

So no, it's not dead and there's still plenty of development going on.


How to use BitCoin private keys (a primer) I am learning about BitCoin private keys and trying to figure out what the best way to use them are. I get their purpose and that they need a strong password, etc. But what I don't understand in particular is how they relate to transactions and wallets.

I just ran bitcoin-cli importprivkey <key> (which has been running for like 5 minutes, who knows how long this will take, and I am brand new). I am actually not sure what the point is for adding the key to the wallet. Does it somehow relate to transactions? Why do I need to add a private key to my wallet? Can/should I add more than one to a wallet? Or, oh! I think I remember, the wallet key is just for storing your private keys. But why don't I just store it myself in a different way? What advantage does having it stored in a wallet offer?

Then the second part of the question is, what key I should be signing my transactions with, and how. Can I say "wallet, give me a key by name" or something?

Final part of the question is, how many keys I should have. Should I just have 1 key for everything? 2 just to switch it up every now and then? 10 or 100 or 1000? A new key for every transaction? I don't know, what is the ideal here? Is it best to use some keys for one thing, and others for another?

But what I don't understand in particular is how they relate to transactions and wallets.

This requires a long answer. Here's a nice intro which should answer this.

  I am actually not sure what the point is for adding the key to the wallet. Does it somehow relate to transactions? Why do I need to add a private key to my wallet?

If you read the above intro to cryptography in Bitcoin, this question is almost fully answered. You need a private key because that's the secret half you use to sign transactions. Otherwise  people could spend your Bitcoins.

  Can/should I add more than one to a wallet? Or, oh! I think I remember, the wallet key is just for storing your private keys. But why don't I just store it myself in a different way? What advantage does having it stored in a wallet offer?

Yes you should create many. In fact, one private key for each transaction is ideal. You can store these keys anywhere you want, but a wallet program will do many nice things for you. The wallet keeps track of how much Bitcoin you have, it gives you an easy way to sign TX's and send them to the network, it groups all your received transactions and allows you to combine their amounts to form new transactions and so on. A profesionally developed wallet will also normally employ good security practices. But nothing's stopping you from rolling your own key store.

  Then the second part of the question is, what key I should be signing my transactions with, and how. Can I say "wallet, give me a key by name" or something?

Bitcoin Core and other wallets offer a database management system to manage your keys for you. Yes you can usually give them mnemonic names or start typing a prefix and the wallet software suggests the rest. You should sign your TX's with a key you've never used before. That's the general rule.

  Final part of the question is, how many keys I should have.

One key per transaction. Never reuse keys.


RDD sent to RED address I wanted to transfer my my RDD coins from Bittrex account to my cryptsy account. I mistakenly sent the RDD coins to A RED generated address on my Criptsy account.

Pls how is it possible to recover my coins? The techs at Cryptsy have been on it for 2 weeks now and have been very helpful in keeping me updated.

I would appreciated some suggestions.

You have the first part right. REDD and RDD use the same pub/priv encoding scheme. Therefore we can simply export the privkey of his RED deposit address and import it into the REDD wallet. Then rescan. This does take time and we are working on ways to automate this. (It happens quite often ) -Mullick "Technical Support Manager"


Why do not all the coinbase texts have the block heigh in it? The coinbase text of #511329 starts with a, #511330 starts with b, #511331 starts with c... (and so on until z), but #511426 for example starts with F, the next one with m, the next one with "... regarding https://coin.dance/blocks

Why do some of them follow the rules, but others not?

All coinbase transactions do contain the block height, and have done so since block 227,835.  It's required by BIP 34.  Since all other miners enforce this rule, a block which broke it would get orphaned and would not become part of the block chain.

You're simply not looking at the right thing.   The height is encoded by a single byte giving the number of bytes to follow (currently 0x03) and then the height as a little-endian binary number.  Blockchain.info displays the coinbase transaction scriptsig both in hex and as characters, but not all bytes correspond to a printable ASCII character, so it displays a � character for such bytes (there seems to not be a one-to-one correspondence between bytes and characters, so it may be trying to parse it as Unicode or something).

Decimal 511329 is hex 0x07cd61, so its coinbase starts with the bytes 0x03 0x61 0xcd 0x07 (remember, little endian).  Now 0x03 is unprintable and 0x61 is a, so you see an a in that text.  Decimal 511330 is hex 0x08cd62, so you see 0x03 0x62 0xcd 0x07, and 0x62 is b.

But decimal 511426 is hex 0x07cdc2, so the coinbase starts 0x03 0xc2 0xcd 0x07.  None of these correspond to any printable character.  The transaction goes on as 03c2cd07ce46... and 0x46 is ASCII F.  This happens to be the first printable character in the coinbase transaction, but it isn't part of the block height at all; just part of whatever other data the miner felt like including.  You've ignored the bytes which were not printable, but you can't do that.

Likewise the coinbase for 511247 starts out 03c3cd07fabe6d6d...  Again, the block height is included exactly as it should be, since decimal 511427 is hex 0x07cdc3.  It so happens that the first printable character is 0x6d, ASCII m.  But again  that has nothing to do with the block height.


How should I do if I want to run a full node in GUI? I'd like to run a full node within bitcoin-qt.exe(It's GUI)

I would like to run it as full node like typing command : "bitcoind -daemon"

Is it enough to run by just execute a GUI wallet(bitcoin-qt.exe)?

Thank you.

Yes. Bitcoin Core is always a full node software and does not have any SPV components within it. Running any part of Bitcoin Core (bitcoind or bitcoin-qt) means that you are running a full node.


How does bitcoin's price volatility compare to commodities/stocks with comparable market capitalizations? Bitcoin's long term (after 21 million units have been created) market cap is about $102 million.

Price volatility of individual commodities/stocks is inversely correlated with their market cap, so price volatility is to be expected with bitcoin, but relative to commodities/stocks with similar market caps, does it have a volatile price?

I'm guessing that price volatility for bitcoin would be low relative to commodities and stocks with comparably sized markets because it has lower transaction costs allowing for a more liquid market, and I'd like to know if the data shows this to be the case, but I don't know where to start looking as I'm not very familiar with commodity and stock markets and trading.

You wrote: "Price volatility of individual commodities/stocks is inversely correlated with their market cap". There is just a coincidental correlation between the two. Instead, I would say that there will be price volatility when investors are unsure about the value of an asset. You can see this with the value of for example Facebook. It is just very hard to judge the value of their assets, regardless of their huge market capitalization. Similarly, the value of Profit Points (which I invest heavily in at the moment) will heavily depend on the expectation of future profits of Open-org.com. On the other hand, one has government bonds, which have a very stable value, because it is relatively easy to calculate their value and there is usually not large risks involved.

Just to be clear about the value of Bitcoins...
If you buy Bitcoins you get a share of the future output of the Bitcoin economy.
You can see the master himself (Warren Buffet) explain this here. I believe that it is hard to judge what the future output of the Bitcoin economy will be, but it will be easier and easier the bigger the market capitalization of the Bitcoin economy, so for Bitcoins there will be a correlation between the two, but other factors like risk of government crackdown will also affect the volatility.


Tx to a multisig address in testnet not working I've sent a tx to a newly created multisig address on testnet, but I don't understand why I didn't get the funds yet.

What I've done so far was to create 3 separate wallets, and get the 3 pubkeys to create the multisig address from python bitcoinrpc, and just in case I've used the command line too:

>>> multi_list = ['0355f3c263aeb7859e53d3549d3c9bc99cd581154d16e259fe390e029d6bda5b78',
...     '030a53f844570b8c26794276e205cdeab87ab0d7802d2abb5116a5472e3adc7dc1',
...     '0210b58f846754a9d0d70e226688e0693a241fd58e315d738399e40e68308b88f9']
>>> btc.createmultisig(2, multi_list)
{u'redeemScript': u'52210355f3c263aeb7859e53d3549d3c9bc99cd581154d16e259fe390e029d6bda5b7821030a53f844570b8c26794276e205cdeab87ab0d7802d2abb5116a5472e3adc7dc1210210b58f846754a9d0d70e226688e0693a241fd58e315d738399e40e68308b88f953ae', u'address': u'2N8DirDvhxVEm61b3JMc75Hsdqe8aWg9Vvu'}

Then, I've sent from another account some coins

>>> btc.sendfrom('myaccount', '2N8DirDvhxVEm61b3JMc75Hsdqe8aWg9Vvu', 0.15)
u'fa9982d579877ba31ed9c530ae99df1f67c1632ae8f3c7e4db8af1fbc442dfe8'

But on blockexplorer the vout address is marked as "unknown", and on btclook also the output was marked as "???"

The raw tx says, in the ScriptPub of the vout marks the "type': 'scripthash'"

What have I done wrong?
Are multisig addresses working on testnet? (I assume yes)

Additionaly, I'm using bitcoin core v0.9.1 which was recently released.

UPDATE: looks like the testnet blockexporer don't know how to handle the multisig addresses (probably because it was hardcoded the p2sh magicbyte from mainnet) and shows them as "strange", but my TX was confirmed ok and i was able to spend the incoming txs.


Unsure where to look Here is an odd situation, I believe.
I THINK I created a Bitcoin account many years ago. It seems there was a site that gave bitcoin to people who signed up. It was just a few. My sister sent me a link.
Problem is, I do not remember where it was. What information do I need to have to try and track down this account? Is it even possible?

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.


How do I send a transaction directly to a miner or pool for processing? I am interested in sending a transaction directly to a miner or a pool for processing.  I have general familiarity with Bitcoin-QT.  What additional knowledge and steps must I have in order to send a transaction directly to a pool?

You can use this service.

https://blockchain.info/pushtx

It will transmit transactions for you. Useful for testing or for sending money over TOR.


How deep is the Bitcoin market? How do we know the size of the Bitcoin transactions?  How do we know that the price action is not being driven by a couple (or otherwise small group) of investors that are just flipping small fractions of Bitcoin back and forth?

Exchanges' order books are usually public.  See for instance https://www.gdax.com/trade/BTC-USD.  The graph in the middle is a helpful visualization of depth.

I'm not going to quote any specific numbers here because they would be instantly obsolete.

Of course, there are lots of exchanges, so to get the "big picture" you'd have to aggregate their data.


Purpose of difficulty? Is the purpose of difficulty only to manage the rate of a cryptocurrency's creation, or should difficulty also increase over time to compensate for Moore's Law for a consistent level of security?

Would a cryptocurrency with an extremely short difficulty time of < 5 seconds, even 1 second, be secure?

The purpose of the difficulty is to maintain a 10 minutes average delay between each block and by the way to ensure the Bitcoin emission rate.

The difficulty is adjusted every 2016 Blocks (2 weeks) to compensate the increase or the decrease of the network calculation power.

If the difficulty is so low that the network generates blocks in less than 5 seconds this would be highly unsecure because this would not let time for the blocks to be shared on the network. The result would be a lot of orphan blocks.

Some altcoins were launched with 15 seconds blocks target. Many of them like smallChange failled and doesn't exists anymore.


Supermajority to prevent 51% attack? I would think that amending the bitcoin protocol to require a supermajority, say 60% or 75%, to verify proof of work help reduce the risk of a 51% attack. If this is so, what are the major obstacles or things I'm not contemplating?

The only thing that immediately came to mind was that it would increase the time horizon on which most transactions are verified, which could be significantly detrimental to the ecosystem. What else?

The 51% attack is emergent behavior of the system. It's not because there's a "50%" buried somewhere in the protocol that can just be changed to 60% or 75%. Someone with more hashing power than everyone else combined can, given enough time, always build a longer chain than everyone else.


How can I determine how much "gains" I've had from Bitcoin? I bought a bunch of BTC in early 2013. Since then, I've bought very small parts of Bitcoin every now and then up until now, for much larger (and increasing) price.
Many of those "original" coins have been lost. While there was a "hard fork gold rush", I gained some more from the ones I already had by claiming "Bitcoin Gold" and "Bitcoin Diamond" and all kinds of such things and then trading them back to real Bitcoin using various non-KYC/AML webpages which allowed me to do this without registering any account. I can't even remember the name of those services, let alone the exact details of when I did it or how much I got.
I have no idea whether the coins I have left today are all from those original coins, which I bought for next to nothing, or if some of them are part of the ones I bought in later years, at a much steeper price. I have no idea how I'd even figure that out.
With such a messy situation, how can I possibly calculate how much taxes I owe to the government if I were to sell/spend my coins? I seriously don't understand how I can possibly determine how much "gains" I've had considering the messiness of it all.
With this in mind, what am I supposed to do? Assume that all the coins I have left are part of my first batch of coins, even though this will mean that I have to pay taxes on basically the full balance? And even if I go that route, I can't prove how much I paid or when. (It was Localbitcoins pre-KYC/AML.)
I don't understand how I'm supposed to figure this out, and the government's website is (of course) to no help. What would be the most reasonable thing to do? Just "bite the bullet" and pretend that I got all the coins I currently have for free, and thus have to pay taxes on the entire balance?

It may be a bit of work, but you should be able to trace on a blockchain explorer (eg blockstream.info) when you acquired the bitcoin with the current addresses you have.
If you can't prove how much you paid for it with a record for each purchase, your tax jurisdiction may accept a historic exchange rate from a well known and reputable public exchange at that time. I suggest asking your government if that is a possibility first, before reporting that you received the coins for free.
To calculate your gains from your purchases and sales, different accounting methods exist (FIFO, LIFO, WAC, etc). If your government is not clear on which method they accept or don't know how to do that, you may need to contact a local tax advisor to help you out further.


How do bitcoin merchants know that it was YOU that payed them When I try to buy something using bitcoins, how does that merchant know that I have payed them the agreed amount.

In other words, how does the merchant know that I payed for the product, and that they can start shipping the product to me. I thought that bitcoin was anonymous in its transactions

because they most likely generated a new address for you to send your payment to.  Since you're the only one that was given that address, when the payment comes in for that address, they know it was  you that paid it.


Online bitcoin tools playground? Currently I'm reading a great book Mastering Bitcoin and the author on his first articles suggests to the reader build from the source Bitcoin Core environment and down load the whole blockchain ledger (about 60Gb) to my local storage to be able perform common queries. But it's to long way for me.

So, is there any where on Internet already exist an online bitcoin-cli command line tool where I could practice?

Thank you!

There is chainquery which allows you to try some cli commands online. Not all commands are available, but it's a good start to get your feet wet. https://chainquery.com/bitcoin-api


Can an altcoin be worth less than 1 satoshi (0.00000001 BTC)? I have a friend who thinks that it's safe to invest in any altcoin that approaches 1 satoshi (0.00000001 BTC) in value, because there will always be someone who is willing to buy it at that price, and if BTC continues to rise in value, that means the altcoin can only ever go up in value.

Is this a reasonable position?

Can an altcoin be worth less than 1 satoshi (0.00000001 BTC)?

Yes

  Is this a reasonable position?

No


In the Ardor API, how can one return more than 100 results from an API call? Currently the Ardor API, limits results of 100 at a time. Is there a way to return more than 100 results using the api calls?

The 100 results per API call limit, is a DDOS protection mechanism when connecting to a remote node.

To remove this limitation and allow any API retrieve as many results as possible, do one of the following:

Connect to a localhost node.
Connect to a remote node and specify the administrator password (adminPassword parameter)

You can learn more about setting the admin password here: https://desk.zoho.eu/portal/jelurida/kb/articles/what-is-the-admin-password

Alternatively, as a node operator you can customize the number of records returned when no password is specified using the nxt.maxAPIRecords property.


How Blockchain transaction verification takes place? How does each transaction verifying node come to know if the sender has enough amount in its wallet to transfer to the receiver or not? How are Blockchain transactions validated?

Each node stores the entire history of transactions (the blockchain). When a node hears about a new transaction, it performs a series of checks to make sure that transaction is valid.

So, when someone sends a tx, their software will use the private key of an unspent output (a 'bitcoin') to cryptographically sign the transaction. This signature proves ownership of the unspent output, and authorizes movement of the coins.

So when a node hears about a new transaction, it checks to make sure that the signature is valid. If the signature is not valid, it will ignore the transaction.

If you attempt to spend more coins than you own, then the signature will not be valid according to the blockchain record kept by the nodes. It is not possible to forge authenticity, you either own the coins and can create a valid transaction, or not.

Note that 'transaction validation' in this case just happens on each node, as the tx is relayed through the network. This is different than 'transaction confirmation', which happens when miners include a transaction in the next block. After 'validation', txs are stored in each nodes memory pool (mempool), until they are confirmed in a block.


What will happen if all bitcoin nodes are pruned? Does Bitcoin handle the case where all nodes are pruned?

How a new node would get the full Blockchain?

If all nodes were pruned a new node would keep making connections looking for an unpruned peer forever and fail to sync.  If instead almost all were pruned it would simply take a longer time than today to get connected to them and start syncing.


Pruning a Simplicity case expression I am trying to spend from a branched Simplicity program, but I don't wanna supply the signatures in the untaken branch, so I am trying to prune the program by hand. I have verified that I can take the commitmentRoot of a checkSig with the signature set to undefined.

To make a valid spend, I think I need to construct a pruned program that has the same CommitmentRoot that the full program has. So I boiled by program down to a single case expression:

u :: CommitmentRoot () ()
u = unit

full :: CommitmentRoot (Bit, ()) ()
full = cond u unit

pruned :: CommitmentRoot (Bit, ()) ()
pruned = assertr (commitmentRoot u) unit

But the CommitmentRoots do not have the same hash:

*Main> (encode.fromShort.hash256.commitmentRoot) pruned
"7b4082aaae5e289f29855ede047b2b6598805b153324aa3a5fd4fec5b1a86053"
*Main> (encode.fromShort.hash256.commitmentRoot) full
"dded2b0938bb9f58f20324ab1f699e7006ffd8e9251b3ddd0f551de1d66fe119"

What gives? Is my understanding that I need a matching CommitmentRoot incorrect? If it is not correct, how do I prune a case expression correctly?

Furthermore, section "4.3.2.1 Pruning Unused case Branches" of the Simplicity Technical Report claims that "We can effectively replace any unused branch in a case expression with its commitment Merkle root." But if I do that, I cannot run the Simplicity program with runKleisli. So how is this supposed to work?

The definition of cond is

cond thn els = match (drop els) (drop thn)

Expanding this in your definition of full yields

full = match (drop unit) (drop u)

The correct pruned version should be

pruned = assertl (drop unit) (commitmentRoot (drop u))

which has commitment root that matches:

let full = cond unit unit in (flip Numeric.showHex "".integerHash256.commitmentRoot) (full :: CommitmentRoot (Bit, ()) ())
"dded2b0938bb9f58f20324ab1f699e7006ffd8e9251b3ddd0f551de1d66fe119"

let pruned = assertl (Simplicity.Term.Core.drop unit) (commitmentRoot (Simplicity.Term.Core.drop unit :: CommitmentRoot ((),()) ())) in (flip Numeric.showHex "".integerHash256.commitmentRoot) (pruned :: CommitmentRoot (Bit, ()) ())
"dded2b0938bb9f58f20324ab1f699e7006ffd8e9251b3ddd0f551de1d66fe119"

Better library support for pruning expressions is something that will be developed.


how much profit can I expect if I start mining today on my Gaming laptop? Is there a website/soft that can help me estimate how much I can expect to earn, based on my current hardware configuration?

P.S. I don't pay for electricity or wifi costs. Its included in my utilities.

Nothing to a few penny per year, even without paying for electricity or internet it's way too slow as of end of 2016. If you want to do mining you will need to do that on alt-coin that don't rely on SHA256.


Does the 100+ GB blockchain database contain every transaction? Does the 100+ GB blockchain database contain every transaction since the beginning, or only a digest of them?

I've read Nakamoto's paper and I see:

  the spent transactions before it can be discarded to save disk space [...] Merkle Tree  [...]

thus this question: is the 100+ GB blockchain already the result of a space-saving lossy process?

Blockchain contains every confirmed transaction since the beginning. There are some tricks to save disk space of course.


understanding bits and difficulty in a block header This block:
https://blockchain.info/block/00000000000000000025c089d0a7b2bf6241888c4dd90ab7a4c4baa6a2823551

Shows difficulty at 3,007,383,866,429.73, and bits at 392009692.

If I want to see how many zeros need to be in the hash, I believe I can just do:

(log2(3007383866429.73) + 32) / 4) => 18.362911541451258

Which is correct..  But how does bits come from difficulty?  How can I calculate the number of zeros from the bits instead of the difficulty?

Contrary to popular belief, Bitcoin's proof of work is not actually based on the number of zeroes. Rather the block hash, when interpreted as a 256 bit integer, must be less than the target value. The target value is what actually determines the difficulty. The target value is represented in a compact form in the nBits field of the block header.
The nBits field of the block header compresses the target from 256 bits into a 32 bits. A description of the format can be found here.
Basically, the nBits field, when represented in Big endian, is split into two parts: the first byte, and the last three bytes. The formula for decompressing the nBits field is as follows: (last three bytes) * 256 ^ ((first byte) - 3). This gives you a 256 bit integer that has the first 3 most significant bytes of the target.


Avalon AUC2 converter for Avalon 6? Can I use a USB controller of sorts? I can not find a single AUC2 converter for the Avalon 6. Canaan.io seems to be extremely uninformative concerning what this thing is and where to get one and it is sold separately from their Avalon 6!

First - do I need it for a single Avalon 6 miner? It seems I do from some instructions on this website, search for AUC Controller and you will see it in a picture, though it seems they are calling the AUC a Controller while it is called a Converter by Canaan.

In the linked page it says: "For AvalonMiner 6 you need an AUC2"

I have searched far and wide to find this "AUC2" converter... I can't find it ANYWHERE! Is there some kind of converter that will take its place, that perhaps I can just update the firmware??

I found that AUC3 is an acronym for "AUC3 (AvalonMiner USB Convertor 3)" but I can't find this for sale anywhere either!

I have found a lead That somehow these are indeed some kind of controller which has updateable firmware. I am wondering if this indeed the case and more specifics on which type of converter I need i.e. does it have to be both a USB2IIC & USB2UART converter as the above website says?

Yes, you do need an AUC to run any avalon miner.  AUC3's will work on AV6.  But AUC2's will NOT work on AV741.

I've been looking for a spare as well and have tried a few generic USB2I2C devices from china with no luck.  I'm just not that skilled with these sorts of things.


Regarding Stellar as an Alternative currency transaction manager I am working on an alternative currency.
We are not wedded to any particular software, but have definite term and conditions for participants.
Our own dispute resolution system, and standard of value.  One credit equals the median hourly wage for your community. We also impose a transaction fee of 2.5% to each party to support the institutions to manage dispute and legal documents and promote  the exchange.   We also are based on the lets system with equal positive and negative balances.

Could we potentially use your Stellar system to manage the transactions in a system such as this ?

Andrew Hill

(Full disclosure:  I work for Stellar.org)

I'm not quite sure what you mean by "We also are based on the lets system with equal positive and negative balances.", so I cannot comment on how that effects Stellar's viability for your problem, but I can talk about the transaction fee you would require.

As of now (December 2015), the stellar network itself only has support for the native transaction fees used for spam prevention.  This means that you would have to implement your own support for transaction fees.  Let me describe how one such system might work on the stellar network:

Since the stellar network doesn't have support for collecting a transaction fee at the time of payment, you must instead collect transaction fees after the fact.  Members of this system would be invoiced by you with their billed fees, and they would pay to keep their account in good standing.  When an account is not in good standing, your system would revoke access to your currency (see "Controlling asset holders" at https://www.stellar.org/developers/learn/concepts/assets.html for details) that would prevent the account from making or receiving payments in your currency until you restore access.

Now, such a system is definitely more complicated than if the stellar network handled custom transaction fees natively, but our intention is to keep the core stellar network as simple as possible, and one of the features that got chopped was support for asset-based transaction fees.  Luckily, this is a great opportunity for a group of developers to build a helper service to support this use case.  Tracking payments on the stellar network and managing an account's standing based upon a set of customizable business rules seems like a generically useful tool to have available for developers and could benefit a large range of use cases, from custom currencies to e-commerce systems, to even something crazy like a stellar-funded metered power grid.  I'd be happy to discuss such a solution further if you're interested.