text:
Is transaction time correlated to block generation time
As I unterstood in other answers (see https://bitcoin.stackexchange.com/a/8922/74399), a transaction is added to the blockchain, once a new block has been found/generated.
The average time between two blocks is about 8 minutes regarding the past 24 hours.
Does this mean, that my transaction will take an average of 8 minutes to become visible in the blockchain?
Is it known in the network as an "unconfirmed transaction" (so it's save)?

On average, based on Bitcoin protocol, a block takes 10 minutes to mine.  Transactions that optimize miner profit take precedence in the block. In other words, the transactions that pay the highest fee get incorporated into the block first and therefore get confirmed the fastest since currently the mempool is large. The mempool consists of all transactions that are waiting to be mined into a block. A transaction that pays a low fee can be stuck in the mempool for a very long time if the mempool remains crowded, so it’s hard to say how long a particular transaction can take; but, yes, a transaction that is broadcast to the network remains unconfirmed until mined into the blockchain.

So according to that, in the Bitcoin blockchain it takes at least 10 minutes (on average) for a transaction to be confirmed?

Bitcoin protocol explicitly calls for 10 minute blocks and mining difficulty adjusts every two weeks to keep it consistent.  However, whether or not a specific transaction gets included in a block depends on supply and demand economics.  If the mempool (waiting line/queue) is large, the transactions paying the highest fees get incorporated into the blockchain first. If the queue is short, miners incorporate even smaller fee transactions to make the highest possible profit in the block.


text:
Real-time price data for cryptocurrencies
I need some source (preferably free) for real-time (or some reasonable time lag) for quotes of cryptocurrencies. Can you suggest anything?
What does Kraken or Poloniex use?

the price on an exchange will be determined by the user. the user (=trader) decide for how much {money, other coins, whatever} they buy or sell a coin/token.
if you want to have the prices of many exchanges/many coins/many token you can use the coinmarketcap api for example. coinmarketcap calculates the average price of several well known exchanges. but in practice every exchange has an api which provides the data of the current orders/price. see for example api-docs: gdax, poloniex, binance, bitfinex, bittrex, kraken.

source: Stack Exchange

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/3.0/

sort: votes


text:
Why does Bitcoin uses a Script language?
From what I heard is that Bitcoin use Script to verify transactions (I'm probably wrong).
Wouldn't be sufficient just signing the transaction with the private key and append the signature to the transaction? This way everyone could verify if the transaction was sent form that public key.
Is this insecure?
I imagine that Script is used for other things too. But If I only wanted to verify the transaction, I could do it with a simple signature right?
Thanks

Bitcoin could function with just a simple mechanism for signing transactions, but it would not be as versatile.  By locking and unlocking outputs with a scripting language, a great deal more becomes possible.  For example, smart contracts, payment channels, multisig, etc...
By using scripts, bitcoin is better.

Yes it does use a language called script. The transactions have both a locking and unlocking script and it is there to allow the specification of simple conditions for spending so that transaction validation is not based on a static pattern and allows the spending of money to be programmable. The locking script normally contains the public key hash while the unlocking script normally contains a digital signature. The scripting language also caters for more complex multisignature scripts. If you just limited the processing to a signature verification then it would not allow for richer functionality and multisignature functionality.

Thanks. I'm trying to create my own "bitcoin" JUST TO LEARN more about how it works. So If I want to do simple blockchain, that the only functionallity I want is to verify that the person who created the transaction is the owner, then I could ignore the Script language and simply add a signature. Right?

Yes that is right.

a signture proofs, that the (hash value of) transaction was signed by a specific person (therefor the privkey is required). Also you need to proof, that you are the rightful owner, and the tx is not moved by someone else (gets stolen). To spend a tx, a hash calculation needs to be done, to move the funds from A to B. This is why there is the pubkey script comes in. The std P2PKH transaction comes with a (ripemd160) hash, that you must be able to create from the pubkey. And with today's knowledge, you can only create this, if you don't have this pubkey. Then you just "see" a tx with a hash in the blockchain. Yu can't steel it...
I recommend the book from Andreas (Mastering Bitcoin), or a similiar resource, to gain the understanding, why it was implemented this way in Bitcoin - at least this helped me alot :-)

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/3.0/


text:
TCP vs HTTP in Bitcoin
Why does bitcoin use TCP instead of creating a web server and using HTTP to comunicate between the nodes?
What's the advantage of using TCP over a HTTP server?
Is that important?

Http is a protocol that works on TCP.
So if you have an http-server, it uses TCP to communicate anyway.
The better question would be "Why should they use an http-server if they don't need it?".
They don't need/want to show a website. They just want to send binary information easily and want to be sure that the other peer received it completly/correctly. And TCP is the perfect protocol for that.


text:
How miners with less power win?
As I understand, when multiple persons mine blocks, only the first one who  solves block is the winner and gets rewarded.
Basically the winner is the one (solo miner or group in pool) who has the most computing power.
That said, when the next block is being mined, again the same person will win because of his computing power.
My question is, how the other mines with less power get chance to win i.e to find the hash of the block before the most powerful miner (regardless if that is person or group) ?

That said, when the next block is being mined, again the same person will win because of his computing power.

No. Higher mining power means just higher chances to mine a block.
If there are 3 miners:

Miner A with 4 Gigahashes per second
Miner B with 6 Gigahashes per second
Miner C with 1 Gigahash per second

Together, they can hash 11.000.000.000 times per second (4+6+1 gigahashes).
The probability for the first miner to win is 4/11 = 36%, the probability for the second miner to win is 6/11 = 55%, the probability for the third miner to win is 1/11 = 9%.
If miner B hashes the block, the next block can of course also be hashed by miner A, B or C.

In order to mine block the miner needs to find the appropriate nonce.
Let's say the needed nonce is the number 5423. Each miner starts from 0 and increments it by 1 until 5423 is reached. How miner with less power would get to that number before someone with more power ?

(1) There is not only the nonce. Look at https://coin.dance/blocks#blockDetails In the column coinbase text, you can see strings there. If miner A has a different string than miner B (default case), then they can both hash with the same nonce (even with the same transactions) and there are different results.

(2) You don't even need to start at 0. You could pick random nonces each time. You could pick 1.111.321, then 912.110, then 889.099, then 1.555.555...

@nozo, in practice, it's more like a lottery.  There is no ideal way to find the nonce, but by trying more attempts in the same time period you increase your odds.  This is the same as buying more lottery tickets.

If you buy 10 lottery tickets, then you have a smaller chance of winning than someone with 1000 lottery tickets. But you can still win.
It sounds like you are assuming that the person with the most lottery tickets will always win the lottery. That's not how lotteries (or randomness) works.
And yes, mining is a lottery. Each hash is a lottery ticket.

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/


text:
Lightning - a lost transaction
I would like to understand if there is a way to loose a transaction received over the payment channel.
What is a mechanism for keeping track of all the transactions occurred in a channel?

Only the parties in the channel need to keep track of what transactions happened in the channel; they are not broadcast publicly. They keep track of this by using a database local to the wallet only.


text:
What is the min relay min fee code -26?
What is this code ?
66 : min relay fee not met  ( code - 26 )
I received this code after trying to send my
rawtransaction.

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

The method is now named -getinfo in Bitcoin Core v26.0.


text:
Is the 'Remote' In 'Remote Procedural Call' something of a misnomer?
My understanding of an RPC is that Bitcoin-qt (client) will send an RPC to bitcoind (or an instance of bitcoind on another machine if the configuration settings are changed to make that happen) and then bitcoind will respond to the RPC with either the requested information, or an error. So in this instance 'remote' refers to the remoteness between bitcoin-qt and bitcoind and not 'remote' in the following, more frequent use of the word.
Generally in computer science, something 'remote' or 'remote access' refers to another machine, whereas, the vast majority of the time(right?), bitcoin-qt and bitcoind are on the same machine.

Bitcoin-qt does not interact with bitcoind at all. Bitcoin-qt is a full node by itself, entirely stand-alone.
There is a tool shipped with Bitcoin Core called bitcoin-cli which allows RPC commands to be issued.
You can certainly interact with your Bitcoin Core node from another machine via the RPC (remote).

As with any other RPC, of course the RPC client can run on a different machine than the RPC server.
As such, that happens with bitcoin-cli and bitcoind.
Your confusion simply arises from the historic accident that the Bitcoin Core GUI currently accesses the local bitcoin node using an inner procedure call interface instead of a remote procedure call interface.

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/


text:
How much of the Bitcoin Source code is untouchable? [CVE-2018–17144]
My understanding is that CVE-2018–17144 (inflation bug introduced in 0.15) was partially a result of how convoluted the original code is.
Regardless of the specific CVE-2018–17144 example, are there parts of the bitcoin source code that are 'untouchable'? How much magic is there in the source code that contributors need to just figure out exists?
If bitcoin broke, would the core team jump at the opportunity to recreate bitcoin with all the new features (mast, tap, schnorr) etc. without the 'cancerous centre'? Is describing the source code as having a cancerous centre a huge overstatement, or is it playfully accurate? Is the idea of current contributors working around the old code like walking on eggshells accurate?

I think that's an incorrect impression. The code involved in CVE-2018-17144 was relatively recent (the UTXO handling logic was written in 0.8 (released feb 2013), and underwent a few small changes after, and a large improvement in 0.15). If by "original code" you refer to the code written by Satoshi, this issue is unrelated, as fairly little of that code is left.
The issue wasn't that the code was not understood. It's that it wasn't clear which piece of code was responsible for what.
For performance reasons, block validation is split up in multiple stages; some run when the block is first received, some run later when it's actually a candidate for becoming part of the best chain ("activation"). The general principle is that you try to make the work wasted on verifying an invalid block proportional to the work an attacker has to do. To accomplish that, you verify the things that are cheap to fake first, and things that are expensive to fake later.
One of those checks was whether there were double spends within a transaction. Initially, this check was done when the block was received directly, and a sanity check during activation. In 0.14, in a performance improvement, the check in the initial block was removed, as it became the critical path for validation of compact blocks. This was wrong; instead of removing the code, it should have been moved to activation time, but it appeared that the activation code was already doing this check. In 0.15, when the UTXO handling code was rewritten, this sanity check at activation time was removed as well, because it didn't appear to be actually part of the validation code.
The mistake in my view was that the split up of responsibility for this type of double-spending check was non-obvious and should have been documented. I was largely responsible for this. Several procedures are in place to help prevent issues of this magnitude, including a sometimes annoyingly slow review process, and functional tests (which do exercise double-spending, ... just not double-spending-within-one-transaction). In this case, those procedures failed.
The rest of my answer is my personal opinion, as I don't think I can speak for anyone else.

are there parts of the bitcoin source code that are 'untouchable'?

No. Certainly some parts are more dangerous to modify, but everything is a question of cost vs. benefit. The changes in 0.15 were a very justified performance improvement, and got a lot of eyes, but not enough. For the future I think this means the bar for review, and tests, vs the possible gain needs to be revisited for changes touching this UTXO handling code.

How much magic is there in the source code that contributors need to just figure out exists?

I don't think there is any magic. Certainly not all logic is equally easy to understand, but that is true for any software project.

If bitcoin broke, would the core team jump at the opportunity to recreate bitcoin

My personal opinion is that rewriting something from scratch is orders of magnitude harder to do correctly than making small incremental changes that are individually-reviewable. Note that the bar for correctness in consensus code is extremely high: not only must it accept all valid blocks, it must also reject all invalid blocks. This sort of consistency between codebases is extremely hard to maintain. Most reimplementations of Bitcoin's consensus rules have had one or a few serious mistakes in their history, and I wouldn't be surprised if most of them still have not exactly the same logic in all cases.

bitcoin with all the new features (mast, tap, schnorr) etc.

Thankfully, those things are very well-isolated changes with a simple interface to the rest of the system. Script validation is pretty much just a "call a function with the output and input without much of any other context, and return true or false". There are also obvious ways to introduce backward-compatible changes in it: simply add additional "return false" statements in it that don't modify any other variables.

Is describing the source code as having a cancerous centre a huge overstatement, or is it playfully accurate?

I wouldn't know what that centre would be, so I think it's an overstatement.

Is the idea of current contributors working around the old code like walking on eggshells accurate?

Touching consensus code is always walking on eggshells, but that doesn't mean it shouldn't or can't be done. I also don't think it would be any different if the code had a different history - consensus correctness is just a hard problem.

I think you also miss a bit of history here:  In the original code this kind of double spend was only caught in block construction/connection and so there was a bug where the mempool could could contain these transactions (which was mostly harmless except they could show up unconfirmed in the wallet).  This test was specifically added to protect the mempool and nothing else.  But its importance was undocumentedly (and unintentionally?) increased by later changes.

The mistake here depended on the fact that people "knew" the history and original purpose of the code and didn't know that far away consensus rules had been weakened.I think it's informative to observe that "bitcoin-abc" rewrote double spend validation for their "ctor" change and managed to preserve the same bug and not detect it in the new test cases they added. The fact that double spending within a transaction isn't the same as general double spending is exactly the sort of cryptographic subtly that comes up and is fiendishly hard to get right.


text:
Bitcoin Mining Pool setup - Pool does not own wallet address
I have setup multiple pools in the past for different Algo using NOMP, UNOMP, MPOS, YIIMP, etc open source solution. But it is first time I am setting a pool for Bitcoin - Tried UNOMP, NOMP, and NiceNOMP already. Mining works perfectly fine. Blocks are found, submitted, and balance is also visible in the node.
However, the payouts doesn't work. On checking the logs, I see an error
Daemon does not own pool address - payment processing can not be done with this daemon, {"isvalid":true,"address":"<wallet-address","scriptPubKey":"<script-publickey>","isscript":false,"iswitness":false}

I have triple checked wallet address with.
bitcoin-cli getaddressesbylabel ""

It belongs to the node. Just to be 100% sure, I also tried
bitcoin-cli dumpprivkey <wallet-address>

I did receive the private key for the wallet address specified. Further, I also updated the conf file to use legacy address only:
 addresstype=legacy

Node and pool are hosted on the same server connecting through 127.0.0.1
Below is the config file removing the obvious security details:
rpcuser=
rpcpassword=
txindex=1
server=1
addresstype=legacy
fallbackfee=0.00001

To all the future folks coming to this page from Google. The solution is simple.
The solution is for UNOMP, but it should be same for other pools as well.
Open:
paymentProcessors.js

go to line 84 and change
isMine to isValid

restart the pool and payment processor will load without error. I just realized that validateAddress response has changed but pool libs are not updated.


text:
How to make concurrent calls to bitcoin core rpc?
I am trying to call getBlock for 100k blocks, but it is too slow to call them sequentially. This is what I am trying. I have a full node of bitcoin core running. I set the -rpcthreads=100 and -rpcworkqueue=100, and I use js to make Promise.all([multiple rpc calls]). To my understanding, rpcthreads allows concurrent calls, but maybe I misunderstood it. I expected the time it takes to run 2 getblock to be similar of running 1. However, I am not seeing a huge performance increase (running 2 roughly takes double the time). What is the correct way to make bitcoin core accept concurrent rpc requests? Thanks!
my bitcoin core config: -server -rpcuser=un -rpcpassword=pw -txindex=1 -rpcthreads=100 -rpcworkqueue=100
my attempt to make it concurrent (client being a wrapper class around the rpc api.):
const before = Date.now();
await Promise.all([
  client.getBlock('0000000000000000000119e179a3169afe7e1dbd867cb9070a6f75a583b98fb3'),
  client.getBlock('0000000000000000000119e179a3169afe7e1dbd867cb9070a6f75a583b98fb3')
]);
const afterAll = Date.now();

console.log('time for all');
console.log(afterAll - before);

This is expected. Most of the RPC handling is single-threaded due to access to internal data structures that aren't designed for multi-threaded access.

I would assume the issue is not Bitcoin Core, even with default RPC settings I do see noticeable increase in client performance when using async/await (C# library). My suggestion is to investigate how the client code handles the RPC request/response + block parsing.


text:
What is the incentive to use bitcoin due to transaction fees?
Apologies for any naivety in the question, as my understanding of the subject is still basic.
My understanding is that once all the coins have been mined, the incentive for miners comes solely from client transaction fees. When that happens, why would someone choose to use bitcoin and pay a transaction fee over fiat currency without a fee?
Does this mean bitcoin is fundamentally infeasible as a general use form of currency? If so, what are the specific use cases that make it more appealing, even with the necessity of transaction fees? If not, what would compel general use adoption?

Compare this with the increasing adoption of contactless payment in western countries. There is a fee involved but it is small and invisible to the consumer. The retailer pays the fee (and passes the cost to the consumer in higher prices).
So long as the transaction fees are low, and people value the other benefits, this won't be a problem.

But wouldn't miners need to charge very high amount of transaction fees to break even on the resources required to mine?

@RajShah: If The mining-reward has halved to a negligible amount and transaction fees are the only significant reward for mining, then miners whose operations are unsustainable without excessive fees will not break even and will go out of business. I believe many other factors influence tx fees not just miners needs.

There are two scenarios we could see as the block subsidy (inflation) halves every ~4 years:

The number of fee-paying transactions increase per block whilst median next-block fee remains low/negligible
The fee per on-chain transaction increases

We are currently seeing scenario 2 play out, where most user transactions are expected to take place off-chain. Transactions that are made on-chain are expected to be settlements of many off-chain transactions, likely collecting a large number of smaller fees within.
Both scenarios are fueled mostly by adoption of the network, and until the subsidy is gone (zero inflation), increases in coin price will help to sustain miner incentive.

where does that first point come from? can you explain your reasoning?

why would someone choose to use bitcoin and pay a transaction fee over
  fiat currency without a fee?
what are the specific use cases that make it more appealing, even with
  the necessity of transaction fees?

Bitcoin as a form of payment offers great incentives to both buyer and seller depending on the transaction use case involved, regardless of the fee involved. Some of these would include:

Convenient (Ease of use in international payments)
No risk of inflation. See this for more details.
Smart payments: Through smart contracts, automatic/self executing payments can be made based on specified conditions. (Not possible with cash without reliance on a third party)
Cheaper (compared to situations where fiat currency conversions would required.)

Does this mean bitcoin is fundamentally infeasible as a general use
  form of currency?

As bitcoin adoption grows, scaling solutions such as Lightning Network will allow for micro payments. Over time the fees from settling these micro transactions would be significant and therefore incentivize miners.


text:
Opening a short position on Kraken requires BTC to begin with?
Suppose I have US Dollars on Kraken and no BTC. And suppose I expect the Bitcoin price to drop a bit (which I don't, but suppose) so I would want to speculate and take a short position.
Is this possible at all, or do I first need to have BTC in my account, in order to 'short sell' them?
It feels kind of counter-intuitive to first buy BTC to then immediately sell (short) them.
Suppose I don't want a higher leverage, i.e. I just want to short "1x" so to speak. So the price going down by 7% would mean 7% profit (minus trading fees). Am I right in thinking I should then first buy BTC, and then sell that with 2x leverage?
And similarly if I'd want to short with 3x leverage. But have no BTC yet. Should I then first buy BTC (through a normal order, not margin) and then margin sell it with 4x leverage?

It seems to me it is only logical you first need to "own" a commodity before you can short it. Similar to how people borrow stocks to short, no?

You actually don't need BTC to short BTC. You just need some form of Fiat i.e. USD, EUR, etc, as collateral. In a short market, you would sell your asset on the spot market, and then open a margin short position.
So you would have no BTC and all Fiat. When you do this, you're borrowing someone else's (or the exchanges) BTC. That means you need to pay them back.
When you're ready to "close the position" i.e. pay them back, you buy the exact same amount of BTC at the cheaper price, thereby repaying the loan, and keep the leftover Fiat as your benefit. That's all there is to it.

You have to get money into the exchange to purchase and secure your position somehow. BTC is probably an easy way to do it but you could also do it with EUR or USD. You will need BTC to close the position but since you're going to be shorting BTC, you won't want to hold BTC while the position is open, so you'll be holding some form of fiat instead.

Thanks, I understand I will need to keep some collateral to secure the position. And you're right, if I'd be shorting BTC I wouldn't want to hold BTC at the same time. Can you give an example? Suppose the current BTC price is $6000, and in my account I have $3000 (and no BTC). Suppose I want to use my entire $3K to short Bitcoin, at 5x leverage. What do I do exactly, i.e. what details do I fill in at the order page? Very much appreciated, I'm trying to wrap my head around this and especially how it's handled in Kraken.

This article might be helpful: https://steemit.com/trading/@cryptoplayhouse/huoe1dbx


text:
Is there some way to safely prove that you control a certain number of Bitcoin?
I want to know if there is some Bitcoin Core-supported feature where it takes the current amount in your wallet.dat and dumps it in such a way that another person can take the data and verify that you own X amount of Bitcoin, obviously without giving up the private keys/control of the coins, and somehow tying them to an arbitrary string, such as a real name, nickname, e-mail address, greeting of some kind, etc.
If this is possible, how is it done and how does it work on a technical level?
And is/could this be done without actually revealing which coins/parts of coins you control? Only that you have X amount of BTC in your wallet.dat?
And how easy is it to verify this "public coin proof" blob of cryptic characters? One might guess that most people would just look at the amount of Bitcoin on this "receipt", that greeting text, and the encryption-looking text following it and assume that it must be the right person, without actually feeding it into Bitcoin Core. So it should be very simple to verify, such as being able to drag and drop the file/image into a Bitcoin Core GUI window and immediately get a "Correct: X BTC" alert box pop-up, or a "Could not verify proof blob." error message.

Most Bitcoin addresses are derived using public key cryptography, so in the same way that our wallet can use a private key to sign a transaction that spends some BTC, it can also use a private key to sign an arbitrary message (in this case, a message that says "I own this address!").
As example: By using the private key that controls a funded bitcoin address, you can prove that you own the coins stored at that address (or at least, you can prove that you have knowledge of the private key that can spend them). Lets say Address X has 1 BTC, and so you create a message that reads 'Address X is controlled by Takwon', and then sign that message using the private key for Address X. You can now pass this signed message to someone, and they can verify that you do indeed have knowledge of that private key.
This post has info about how to create a signed message using bitcoin-cli:
How to sign a message using Bitcoin private key?
This post has info about how to verify a signed message using bitcoin-cli:
How can I verify a signed message?
This post has info about the nature of the signed message - to be absolutely sure that someone owns the address in question, you should provide a message that they will sign.
If someone wanted to pretend to be Satoshi by posting a fake signature to defraud people how could they?

And is/could this be done without actually revealing which coins/parts of coins you control? Only that you have X amount of BTC in your wallet.dat?

The method above reveals which address(es) you control to anyone that is verifying the signed message(s). I am unaware of any method that would allow you to prove ownership of some amount of coin, without revealing which specific UTXOs constitute those funds. Perhaps there is some fancy ZKP math which could be done on a UTXO set commitment to accomplish this, but as far as I know no such thing has been developed for Bitcoin at this time (and, perhaps it is not possible, I'll leave that to the cryptographic experts to explain in more detail).


text:
What are the chances that Bitcoin changes its proof-concept one day?
Is it realistic/possible that the bitcoin core team make a new Bitcoin Improvement Proposal (BIP) on day in which they propose to change Proof of Work (POW) with something else (proof of stake for example)?
And yes, I know that POW was already part of "Satoshi Nakamoto's" paper Bitcoin: A Peer-to-Peer Electronic Cash System.
POW takes already more energy than smaller countries and it's proved that there are cheeper solutions (the existence of many alt-coins proves that).
Do you think, it's realistic? Maybe far in the future? Maybe without a hardfork?

Chances of a replacement are very low. In fact, this is actually mentioned in the bitcoin community maintained wiki, which seems quite official.
See the "Prohibited Changes" list, where adding an alternative proof algorithm is listed under the "disputed" category.

Disputed:
  Adding alternatives to Proof of Work such as Proof of Stake. This could change core bitcoin too much, but with widespread agreement of some sort might be possible.

Note that they talk of adding, not replacing.

An idea I've seen floating around that would not necessarily require a hardfork is to add more mining algorithms as time goes on. Rather than switching to a new algorithm, you allow miners to use any of a number of algorithms. This could greatly improve decentralization since different hardware would be needed for each algorithm.

"it's proved that there are cheeper solutions"

It has not been proven there are cheaper solutions. Altcoins are cheaper because they're less valuable. Mining costs tend to approach the value of the mining reward + fees. A bitcoin block is by far the most valuable block out of any cryptocurrency, and therefore there are more miners putting more work into mining those blocks. Economics dictates that miners will compete until their net profit is 0 (in the economic sense that includes opportunity costs).
So until an alternative to Proof-of-Work is proven to be robust, no alternative will likely be attempted. The consensus in the community is that its unlikely that there is a way to do better than PoW, but of course that may prove to be wrong.

Although some of this question is primarily opinion based, it raises some interesting ideas.
Firstly, there is no way to do it without a hardfork, because all blocks mined without SHA256 PoW would be invalid to old nodes.
Any hardfork is quite drastic, and changing the PoW algorithm especially, such a measure would likely only be taken if SHA256 was broken.
Note that PoS has many flaws and would certainly never be used in bitcoin. Likely that another ASIC-friendly PoW algorithm would replace SHA-256 if it was ever needed.
Also note that the energy spent keeping the network secure is useful in that respect, and bitcoin mining consumes less energy than gold mining, that's a common criticism which is quite unfair


text:
about transaction
I requested for withdrawal an amount of 7.48 BTC from my coin bank wallet having address 1Eurieh......REXWr. on 22 Jan.
Today 24 Jan ,my bl. in coin bank wallet is zero, but this amount is missing in my receiving end " My Ether Wallet" having address 0xbE3........2293.
How can i check this transaction on blockchain ace this transaction..
Please help to trace this tranaction.
Kind regards.
Dave

you may have a look at blockchain.info. You can enter your tx ID, and see the status. Hope this helps, as otherwise the information is a bit a mix of bitcoin and ethereum. Maybe you can outline, from which wallet you sent. I am not aware that you can send bitcoins to an ethereum wallet...

I could not find any instructions for the Coin Bank wallet but, what you need to trace a transaction is the transaction ID. Once you have that there are various websites, you can look it up on, like http://blockchain.info
I would try contacting Coin Bank to find out how to get the transaction ID and try to deal with it as a lost transaction. The truth is, your BTC may be lost. If the transaction is not yet confirmed then there may be hope, you could try RBF (replace-by-fee) and instead send the BTC back to yourself or, you could try and double spend with a higher fee before the original transaction is confirmed. Both of these possibilities will depend on what features Coin Bank have available; it may be possible for them to do this on their backend if you cannot do it yourself in the wallet?
Also, Bitcoin and Ether are not compatible. I feel bad for you. You cannot send Bitcoin to Ether; it will not work. By the sound of it, Coin Bank may not have any send to address checking because the address you are sending to does not even look like a Bitcoin address.

thanx for your suggestions. I wrote to Coin bank team and they told me, they have transferred my balance coin bank funds to my GB21 account.
Dave


text:
Syncing Issues - Hashrate?
Okay, I cloned a Dash source (learning)
Compiles fine on Linux/Win, I have peers and it was mining blocks fine during the initial launch. 200 Blocks mined, all peers sync'd up fine, sent Tx between one another. Everything works perfect.
I killed mining on it as there was no need for me to keep mining it (just learning) but I have found that since then, It will not sync, at all. Is constantly showing "catching up" What I have tried:

Rescan
Reindex
Tried a different machine
Let it sit for hours.

Nothing moves sync wise and it no longer will load any blocks after reindex (stays at zero). I figured it was related to no hashrate but I can't mine anything on it since the wallet isn't synced (i'm assuming). The error i get trying to mine is
json_rpc_call failed w/cpuminer

setgenerate will only show 0 hash

Of course it isn't synced if you haven't mined blocks in a while. The assumption with networks similar to Bitcoin (and thus Dash) is that mining is constant so if a node sees that its most recent block is old, it will assume that it is not synced.
The RPC calls will check to see if you are synced and then only serve data to mining software if it is. You can just disable this check in the source code so that you can mine again.

My suggestion (I do not know about Dash specifically), if there are no new blocks for a timeout period the node thinks it is behind. This is certainly the case with some (non-Dash) clients.

Thanks for your response. Same rules apply here i believe. I just don't know how I'm supposed to mine a new block when it won't allow it.

@sic_null Reset your time clock to just after the last block was mined.


text:
Multisig (2 of 3) BCH, one signed before fork, one after
Right before the BCH fork a multisig (2 of 3) transaction was signed by the other party, and mine after the fork and successfully broadcasted (coinb.in), so got my BTC.
Later I realized there might be BCH in there as well, but broadcasting the same final raw hex on the Bitcoin Cash mainnet (viabtc.com) keeps failing.
Am I missing something here? Or is it impossible because the other party's raw transaction hex code is not recognized on the BCH chain?
Broadcasting on blockdozer returns;
An error occured:
16: mandatory-script-verify-flag-failed (Signature must use SIGHASH_FORKID). Code:-26

Was the multisig transaction confirmed before or after the fork block?  If before, you should simply be able to spend it on the BCH chain.  If after, both parties will have to re-sign with BCH rules, as in the answer below.  It would help if you can share the txid.

You cannot simply rebroadcast a bitcoin transaction on the bcash chain, due to replay protection. You need to sign the transaction using the SIGHASH_FORKID as the error message says, which means you will need to use a BCH wallet to resign the transaction


text:
Walletnotify hits twice, immediately
So I've read most of what is tagged with walletnotify, but haven't found a solution. I know walletnotify is supposed to run twice, one for the unconfirmed transaction and again, when it reaches 1 confirmation. For me, it runs twice, right off the bat.
bitcoin.conf:
server=1
daemon=1

maxconnections=12
maxuploadtarget=20
rpcuser=xxxx
rpcpassword=xxxx
testnet=1
rpcallowip=52.86.xx.xx
walletnotify=/home/scripts/transaction.sh %s
keypool=10000

transaction.sh:
#!/bin/sh
F=notify_log
D=`date +"%Y%m%d%H%M%S"`
echo ${D} - ${1} >> ${F}

Produces an output of:
20180126015435 - cf59f4c18a80773164c7efdf2a77722099722b3a61274f940aea52cbd600db2b
20180126015435 - cf59f4c18a80773164c7efdf2a77722099722b3a61274f940aea52cbd600db2b

Same TXID, same timestamp. But why twice?

did you ever figure this out? I have the same issue.  on the mainnet I get the events about 10min apart (as expected), but in testnet they come in at the same time i.e. after 1 confirmation (about 30min)

I would love to help but it's too long ago and I don't remember, sorry!

walletnotify will execute every time you either
1.receive bitcoin
2.send bitcoin
3.when a bitcoin gets its first confirmation.

@Dawg are you transfer payment in your wallet it self ?
if yes then OK , if not try to send/receive the payments from other bitcoin node then you can observe clearly ,Cheers

try it
#!/bin/bash
F=/home/btcdev/wallet_transaction_log
D=`date +"%Y%m%d%H%M%S"`
echo ${D} - ${1} >> ${F}

Ref: https://bitcointalk.org/index.php?topic=203438.0


text:
Protecting against bitcoin thieves as a casual user
I hope this is an appropriate question here. I never got a chance to write it out earlier, but with the recent price changes looming it came to my mind again.
Around July 2013 I started to take some limited interest in bitcoin. Around this time, GPU based miners were still relatively viable, so I took my medium-grade gaming PC, set it up with a better GPU, and did a stint of casual mining. After some months, I had received about 0.7 BTC, but I generally deemed it not super profitable, and stopped. The PC was windows 7, used for the mining and a few games, and other general consumer tasks.
A few years later I became interested in the crypto space again and opened my old bitcoin client, only to find out that about a year after mining the coins (May 2014), they had all been transferred out somewhere unknown to me. At the time, for me, this pretty much destroyed most of the credibility of bitcoin, as from the perspective of a casual user, I had not really done anything wrong or unusually shady or dangerous.
I'm looking back into this space yet again after some of the recent news. So my question breaks down to:

What is the most likely situation that had played out, in order for me to lose my coins like this, on a casually used system, using the official bitcoin client?
If the above issue was due to some kind of known vulnerability, has it since been fixed?
What other measures can a new, non-power user take in order to protect from this type of significant theft, within reason?

Thanks for reading~

What other measures can a new, non-power user take in order to protect from this type of significant theft, within reason?

For money stored long term, move the coins to a hardware wallet or some form of offline wallet (cold storage).
Use a transaction (rather than importing keys or using an existing seed-phrase) to move the money to a wallet with fresh keys that have never been on any network-connected device.
Theft is not the only risk. Make backups of the wallet and/or seed phrase or keys. Test recovery from those backups. Educate heirs about recovery.
See What kinds of wallets are there?


text:
Can not find or remember exchange
About 4 years ago i gave my son some BTC for his Birthday....
Trying to teach him a bit of financial responsibility.....
he created a wallet, on an exchange i believe, i wasnt part of that, as i insisted he take charge and responsibilty for his own, and, keep passwords, seed etc safe.
Fast forward till now..... He can not remember which exchange he created the wallet on, i do have the original wallet numbers however...... dont have seed.
it there anyway to tell which exchange it went to , he " thought he saved all the info on his computer..... kids huh.

Related: https://bitcoin.stackexchange.com/q/103688/5406

[is] there anyway to tell which exchange it went to

In general it isn't possible.

i do have the original wallet numbers

Wallet numbers aren't really a thing, there are wallet-IDs for some custodial wallets and there are Bitcoin-addresses for normal wallets.
If the number has hyphens in it, that might be a Wallet ID for an account at blockchain.com. In which case their support might be able to help.
If the number looks like a Bitcoin address, it isn't generally possible to trace those anywhere useful and you can't recover control from an address alone.
There are specialist businesses that perform blockchain analysis to try to infer relationships between addresses and to infer ownership of addresses. They are probably expensive to use and probably do not find anything useful in most cases.
It may be better to look for email or other text messages relating to a possible custodial account.


text:
Fixedseed ignored by bitcoin-qt
I play with bitcoin source code to learn,
I create my own fullnode, and change the chainparamsseeds.h to just use my own node as SeedSpec6, and comment the dns seeds in chainparams.cpp.
When open bitcoin-qt, it wont connect to node defined. but when I use addnode command, then it connect and start syncing.
Why same node can't be used form FixedSeednode config?
Thanks

Those nodes listed in chainparamsseeds.h are fallback seed nodes. They are not what Bitcoin Core uses by default to connect to the network, they are only used as a last resort if none of the other methods for finding nodes works.
Furthermore, the nodes listed there are seed nodes. This means that Bitcoin Core will connect to them briefly to get IP addresses of other nodes to connect to, and then disconnect from the seed node. They are not there to maintain full connections.
If you want to have a node connect to another node, use the addnode command.


text:
bitcoin node: what is the difference between simnet and regtest?
btcd, and presumably other bitcoin node implementations, seem to have 4 network options:

mainnet
testnet
regtest
simnet.

I get that mainnet and testnet both are "public" in that your node will communicate with other nodes and that both have an existing blockchain and genesis block.
However, from what I can tell, both simenet and regtest both create a local only blockchain, and both will create a new genesis block. I this case, what is the difference, and which is better (easier) for developing bitcoin applications?
This is what the documentation has to say:
--regtest             Use the regression test network
--simnet              Use the simulation test network

Simnet is only available for btcd (bitcoin node) and lnd (lightning node) afaik, while regtest is also available for bitcoind (bitcoin node), lnd and eclair (lightning nodes). The two modes are similar, according to documenation of LND:

Simnet is similar to regtest in that you'll be able to instantly mine blocks as needed to test lnd locally

Both also are similar in the fact that the payment addresses are unique, to prevent confusion with the main network.
Where they differ, I think, is that simnet goes a bit further and also applies some network changes to disable things like peer discovery.
But I couldn't find conclusive evidence for this. Since I do a lot of tests with multiple Lightning clients, I tend to use regtest, since that's more broadly supported.

How do I create a test network w/ 2 (or more ) physical nodes each on their own machine?
Can I do this w/ simnet or regtest??

Bitcoin nodes or Lightning nodes? Either way: yes you can do that with either simnet or regtest. But why are you thinking about doing tests with two physical machines? Tools like Simverse or Polar let you spin up multiple docker containers running Bitcoin core or one of the three main Lightning clients. You can do all the testing on a single machine. I've wrote a few blog posts on the former tool: https://www.gijsvandam.nl/topics/simverse/

gisjswijs: Why would I choose simnet vs. regtest (or vice versa) for this?

Thanks, I know I can run everything on one machine. & I have.  I'd like to run 2 (or more) physical machines because it more closely models the real world.

@JDOaktown I would use regtest. Simnet is only supported by Lightning Labs products (lnd, btcd) so it might make sense to use it when you only use those products, but even then I would prefer regtest, just because it's more widely supported.


text:
where do unspent outputs come from?
This post asks the same question: What is an "unspent output"? but the answers for me are completely incomprehensible, probably because I lack a key piece of knowledge.
I have read every article I can find on "unspent outputs" and with each I get more confused.  e.g. these:
https://www.r3.com/blog/2017/07/18/what-is-a-utxo/
https://bitcointalk.org/index.php?topic=2011399.0
Lets say I have 1 BTC in a coinbase wallet or similar.
Do I have any unspent outputs yet?
If yes, who created it?
If no, how does one create an unspent output (or in what circumstance/use case are they created?
Can a single address have more than one unspent output?  If so in which circumstance?
Is there some article which explains these fundamentals in layman terms?
This one is on the general subject but doesnt mention unclaimed outputs:
https://en.bitcoin.it/wiki/Transaction
It says this:

An output contains instructions for sending bitcoins. Value is the
  number of Satoshi (1 BTC = 100,000,000 Satoshi) that this output will
  be worth when claimed.

What is the relationship between claimed and unspent?
Is unspent unclaimed?
How does one claim unclaimed outputs, and in what circumstance would they end up unclaimed?

Further information also in this thread : https://bitcoin.stackexchange.com/questions/69869/what-happens-to-utxos-when-a-transaction-output-script-is-satisfied

You are just puzzling your self. We will start step by step.
What is Bitcoin output?
An output is an amount that was sent (via a standard transaction) to a Bitcoin address.
So when I send some bitcoins the recipient address is output address and if the recipient didn't spend the input I sent, it will be unspent output.
What is the relationship between claimed and unspent?
it's just the status of the output.
Do I have any unspent outputs yet?
No, You have one input. and the sender has "unspent output" which belongs to you.
If no, how does one create an unspent output (or in what circumstance/use case are they created?
When you make a transaction, you are creating outputs.
Unspent or claimed is whether the recipient spent the bitcoins or not.
Can a single address have more than one unspent output? If so in which circumstance?
outputs do not belong to addresses, but transactions. and a single transaction can have more than one output (e.g.) if you were sending for more than one address in same time.
Is there some article which explains these fundamentals in layman terms?
Mastering Bitcoin book.

Very helpful!  The crux is that if someone sends me 1BTC, then They seem to have an the unspent output, not me. I thought i would have the unspent output. What do I have, an unspent input?

Exactly, They will have unspent output if they didn't spend the coins you sent. You will have nothing but you had 1 BTC as input and you made an output from that input.


text:
Building enviornment, libraries, and compiling... What does that mean?
I'm an absolute beginner and I am reading the guide on how to build an altcoin (forked from litecoin) here and I am confused on the first steps. I don't want someone else to do it, I want myself to do it. Can someone tell me how to do that using VS Community 2017?

Welcome to Bitcoin.SE! Your question is very broad and requires a very long and complex answer. Please try breaking it down and see how to ask for more assistance.

Build environment: the environment in which the source code is compiled and built into a complete binary which you can run. This typically consists of the compiler, linker, OS you are building on, and OS you want the binaries to be built for.
Library: A library is a set of code that your or other's programs use. They are compiled just like any other program but they do not contain main functions so it cannot be run as its own executable. Libraries are used to avoid code duplication for things that can be used across multiple programs.
Compiling: The process of turning source code into an executable binary. You must compile source code in order to actually use it.

Can someone tell me how to do that using VS Community 2017?

You really shouldn't do that. Bitcoin Core, which most altcoins' primary software (including Litecoin) are based off of, is designed for being build in a Unix environment (primarily Linux and MacOS). It is substantially more difficult to build it in a Windows environment, particularly with the tools that Microsoft provides (e.g. Visual Studio). It is instead recommended that you use the Windows Subsystem for Linux. Instructions for doing that are available here


text:
How do I ask other nodes for their stale blocks?
I want data on as many stale blocks as possible. Is there a way to ask peer nodes to run "getchaintips" and get their results?
Previously, I used Blockchain.info's API call for this, but it seems like they deleted their data on stale blocks (even when I directly search for a known stale block's hash, no results are found).
I've also heard of using merged mining data to find extra stale blocks, per Stifter et al 2019. This method was used to find many stale blocks that weren't propagated to nodes run by certain websites; the paper looks at stale blocks from Decker and Wattenhoffer 2013, Blockchain.info, Bitcoin.com, and ChainQuery.com. However, this method misses many stale blocks that those websites picked up.
My current best idea is to ask as many peers as possible for their "getchaintips", but I don't know how to do this. Can someone help, suggest an alternative method, and/or provide some of their own data?

You can’t. Nodes don’t respond to messages about stale blocks because this would be a fingerprinting vector.

Forgive my ignorance, but in what ways could this fingerprint be abused? Mapping the connectivity of other nodes in the network? Mapping the network's distribution of competing chain tips? I can understand this for tor-only nodes, but for nodes with public IPs its not as obvious to me what the attack vector would be.

Giving nodes a persistent identity is clearly a bad idea for privacy. Being able to specifically link them to transmission broadcasts would be possible for example.

Right, I was sort of on the right track then. That makes sense, thanks.

@Anonymous I understand that.  However, the Stifter et al 2018 paper states that "a limit of thirty days is imposed on how far back stale blocks will be served to peers."  They reference the Bitcoin source code on GitHub, but I haven't found the exact line yet.  So there must be a way to ask for stale blocks less than 30 days old, right?

https://github.com/bitcoin/bitcoin/blob/c8971547d9c9460fcbec6f54888df83f002c3dfd/src/net_processing.cpp#L63

This only really applies to getdata. So you have to know the hash you’re asking for.

Okay got it.  Thanks a lot!  The question is still open for someone to suggest an alternative method of gathering this data.  My hope now is that someone could post their "getchaintips" results, such as in this post, despite the protocol that you pointed out.


text:
fee 4 times what I am sending
I am attempting my first Bitcoin transfer from Abra to Bittrex. I am only sending the equivalent of $10 US dollars to test it. The money did not go through as I do not have enough in my account to pay the fee which is $44!! Is this right - it costs $44 USD  in fees to send $10 USD?

Yes, they are that high at the moment. You should not send such small amounts of bitcoins nowadays. You could wait until the Lightning Network works. The fees will probably fall then.

I don't know what a Lightning Network is (but will google). Do you know when it will work.

I read somewhere that the fees can be less at night. Is that true? Is the percentage of the fee smaller for larger amounts of money?

I doubt fees are lower at night, but yes, the fee is not dependent on how much you are sending, but rather the transactions size in bytes. Please see my answer for more details.

Thank you. I was adivised to just send a small amount of money when I am getting started in case I make a mistake. I will add more money to my account and send a larger amount.

There are still 130MBs of transactions that are not include in blocks. So there is (almost) no way that a transaction with a very small fee (0.10$ for example) is confirmed at night because there are sill a lot of other people paying more.

Yes. The price of transactions fees in Bitcoin are not a percentage of the amount you are sending, they are formed from a market process and influenced by their size in bytes.
As there is a limited amount of space in each block, all users are currently bidding against each other for space in the blocks. As you can see here, the price of transaction fees has been bid up to approximately what you described.


text:
Pls advice how to start bitcoin trading
Please advice how to start bitcoin trading. Advice step by step Coze I am new Lerner
And which trading house is genuine and in case need refund our money can get immidatly back
Thanks

First, any funds invested in cryptocurrency runs  the risk of being lost. That said, you’ll need a cryptowallet. I use Blockchain.info which holds bitcoin(BTC), bitcoin cash and etherium. There are other wonlibe wallets that hold more currencies so you’ll want to research and decide which is best for you but for bitcoin, Coinbase is fine. Also, there are are hardware wallets like the ledger nano which is probably the best option but costly. Coinbase is a trustworthy exchange to purchase bitcoin as well as Litecoin, ether and bitcoin cash. This can work as a wallet but not suggested. You can link your bank account or debit card both take time to be validated. Debit transactions are instant once valid. My bank transactions are now instant but that feature may take making some transactions. Once BTC is available on Coinbase you’ll need to send it to your wallet. Buying and sending currency all come with fees just so you’re a are. Once you get to sending BTC to wallet I can Answer any questions on that processs if need be but you might tigur it out on your own. Just make sure and information is entered correctly othewise you may lose your BTC.  Also remember to backup all account keys and passwords somewhere safe because asking to reset these are not an option. I hope that helps and good luck.

bitcoin(BCH) and bitcoin cash are the same. Also not etherium ethereum.

Yes, thank you I misspelled ethereum. Although I would disagree that BCH and BTC are the same as they have different value. I just put the wrong code after bitcoin, should have been BTC. But I understand BCH forked from bitcoin and are essentially the same

That's not the same. They are different.


text:
Is my cold wallet still cold?
I created a new wallet.dat on a dedicated, secured machine with Bitcoin Core.
Then I encrypted it.
Then I sent my "fortune" of coins to it.
Then I backed the file up by putting it on all my disks on my normal PC as well as offline disks.
I even added it to Bitcoin Core on my normal PC, so it now lets me switch between my unencrypted "hot"/"live" wallet and the encrypted "cold" wallet in Bitcoin Core in a very neat manner, allowing me to always look to check that the coins are still there in the "cold" one.
Since I'm afraid to death of losing the encryption password, I did not write it down on physical paper and stick it into the fireproof safe (it could still burn, or get dissolved from water leaking in, or get seized/stolen under gunpoint). Instead, the password is PARTIALLY in various text files backed up on all storage devices I have, including instructions for how to input the rest of the password, which is based on "things that I know very well but others would struggle to guess or find out", such as past pets' nicknames and things like that.
I thought and worried for years before finally coming up with this scheme. To me, it seems like the only sensible solution, having very carefully looked into those hardware wallets and all other (known to me) ways to secure your coins.
My question is: is my "cold" wallet really "cold" if it's literally lying around on my Internet-connected Windows 10 machine, albeit in encrypted form and never decrypted on that machine? Or does it have to always be offline, even if encrypted, to be considered "cold"?

Then what the hell is mine? Luke-warm?

That wouldn't be a cold wallet. A cold wallet is one where the private keys aren't stored on an Internet-connected device, even in encrypted form.
If you just want to check your balance, you should be able to export your addresses, and import them as a watch-only wallet, then keep the private key file (even encrypted) off of your computer. Also, 10+ BTC is far past the point at which I would just consider purchasing a hardware wallet.


text:
I made a Bitcoin Core deposit and don't have a big enough HDD to download data
Wondering if anyone can help me. I downloaded bitcoin core (not realising you have to download all bitcoin data with it) and I am on a mac so I don't have enough disk space to complete the download (even if my disk was empty). I therefore have BTC in the account but will never be able to spend it, is there anything I can do?

next to the disk space and time required for the full node client, an option may be to extract the priv key from your core wallet, and bring it into Electrum (or similiar wallet).

Or you can buy a cheap USB 1Tb harddisk. Plug that in and then at startup elect to put the datadir (AND THE WALLET) on that.
If you do this and then send any coins make sure you backup the wallet.


text:
How can blockchain send my all money without any notification??
Yesterday  I made deposit  in blockchain wallet and  after that next morning  when i chk my Wallet  all bitcoin  were sent to an address  even i didn't made any transaction  how can any one tell me and this was my first  transaction  in blockchain can anyone know jow to recover  my fund

Did you have 2FA enabled?

Yes i have enabled


text:
Decide Currency before buying mining hardware?
As different Crypto-Currencies have different underlying Algorithms (e.g. SHA256, Scrypt, CryptoNight, etc : Source). Does this mean that if I am looking to buy cryptocurrency mining hardware, I need to decide the hardware after I decide which currency I am looking to mine? For example, a GPU setup may be good for Ethereum but for LiteCoin, I need some ASIC hardware?

Yes, decide coins first then the hardware. As for Ethereum, they will soon be switching over to Proof-Of-Stake(not mineable). As for LiteCoin, anything other than Antminer L3+ will be a waste of time and money. You can check with mining calculator to determine if your intended setup is profitable.

Predict how much the coins will be worth ten years later. Choose coins while keeping this in mind.


text:
Market manipulation of spot prices to profit from Bitcoin Futures
Bitcoin futures are derivative instruments based on a closing Bitcoin price.  Is it possible for traders of Bitcoin futures to manipulate the closing Bitcoin price in order to profit from their Bitcoin futures position?

I have heard rumors that they are already doing this.


text:
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?

How deep is the gold market? How do we know gold price is not a pump and dump? Its all people's belief.

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.

Don't have enough points yet to upvote you.  Since bitcoin transactions can occur in fractions of a bitcoin, I'm trying to get some confirmation that these markets are not being manipulated.


text:
How to send a 100KB OP_RETURN?
I'm trying to send an OP_RETURN transaction, and the program says that I can't do it because it is over 80 bytes. I would like to send a transaction using OP_RETURN that stores data. There is a site called https://bico.media/, but I can't use it because I want to use the testnet.
Note: I know that this is bordering on off-topic, but it makes sense and is related to bitcoin. I want to ask how to send an OP_RETURN that large easily, and I think it would be applicable to bitcoin SV too.

If your question is how to easily send a transaction with a 100 kB OP_RETURN, the answer is that you don't. You'd need to contact a miner or mine it yourself to get such a non-standard transaction accepted.

The provided link talks about bsv (offtopic scam), which explains a lot because no sane person would think of doing that on the Bitcoin.

You will not be able to send a transaction with an OP_RETURN larger than 80 bytes unless you mine a block that includes the transaction. An OP_RETURN larger than 80 bytes is considered non-standard, but still valid, meaning nodes will not relay your transaction (on default settings) but will accept the transaction if it is included in a block.
An alternative would be to create multiple OP_RETURN outputs, each of 80 bytes, totaling to your 100KBs. This would require 1,280 OP_RETURN outputs which, again, would be non-standard as it is larger than the maximum relay transaction size for nodes (100KB). You would again need to contact a miner/mine it yourself in a block, or split the OP_RETURN values in half and include 640 OP_RETURNs in one transaction and 640 OP_RETURNs in another transaction.


text:
I want to transfer my bitcoin but i cannot
I want to transfer bitcoin to a wallet adress but when i send it gives me this error
There was a problem sending your transaction Uneconomical UTXO requested [type: 1 (limit 5643), txOut.val: 4123, required: 109544]
What it means and how can i send ?  Please help me thanks

Uneconomical UTXO requested

This usually means the amounts you are trying to send are so incredibly tiny that the transaction fees will cost more (perhaps much much more) than the amount being sent.
See dust
See helpful comments to other similar unanswered questions:

cant send btc, Uneconomical UTXO requested
Uneconomical UTXO requested

Maybe its like using DHL or FedEx to send a small piece of a 1 paisa coin to someone.

Bitcoin is not meant for transactions in large scale.
You need to set up a Lightning-network for this.
It is the promised solution to the transaction prob.


text:
How to get uncompressed BTC address and private key from bit module for Python?
I am new in programming and BTC. I want to make some BTC address with private keys. Till now I learn that we have compressed and uncompressed private keys. But I get only compressed private keys and address. How I can get uncompressed private key and adress with bit module? This number is just for example. I don't use them for my address. Please do the same. It's not safe to use it for your address. I made this code till now
from bit import Key
dec=115792089237316195423570985008687907852837564279074904382605163141518156494336
key = Key.from_int(dec)
print(key.address)
print(key.to_wif())

I get this results 1A7o1vWzF4fx1yqmA1NzFbhnP97P9uYQ2Q L5oLkpV3aqBjhki6LmvChTCV6odsp4SXM6FfU2GppfKbjNXRE2Ge
I use this module https://pypi.org/project/bit/
If you know someone who can help please share with me. You can see code here https://pastebin.com/6gk1Ua2b

Why would you want to use uncompressed points?

maybe this will help? https://github.com/ofek/bit/issues/52

It looks like doing such a conversion is not well supported, nor is instantiating a private key as uncompressed unless you do so with a WIF key.
However, you can change the compressed-ness by doing:
key._public_key = key._pk.public_key.format(compressed=False)

But this requires you do to this immediately after instantiation as otherwise precomputed properties such as .address will not be recomputed.

Note that there generally is no reason you'd want to use uncompressed public keys.


text:
How to reduce number of inputs in bitcoin transaction?
We have a bitcoin node running on a server which we use to generate addresses to receive small payments from the users. We receive tons of small payments daily right now and then we are using the same bitcoin wallet to send payouts to our users using the sendmany rpc call.
This results in lots of inputs to cover the amount in outputs. Each new input increases the size of transaction by around 150 bytes and so we are loosing too much in fee.
Is there any way to reduce the number of inputs?
Suggestions would be really appreciated.
Thank you.

If you are accepting high volume of small transactions, you will be better off accepting bitcoins using Lightning Network. You could use open source solutions like BTCPayServer (not an endorsement, verify yourself) for generating lightning invoices which can be deployed as a self hosted solution or on a third party server.

But I am looking for a solution without using LN. Because I need a solution not only for BTC but for other similar ones like LTC, DOGE, etc. which doesn't have LN support yet.

I don't see a way out of it. Bitcoin operates on a UTXO based model rather than an account based model. So you WILL have to consolidate the UTXOs at one point or another. The only thing that I can think off to alleviate the problem is by using some optimizations of inputs to match the payouts that you guys do.

What if I make an internal transfer to an address on the same wallet with a very low fee? This will move all the unspent outputs to one single output which can be used later to pay other addresses. This is beneficial only if I can set a fee something below 1 sat/byte? Can I?

No, you cannot set fee below 1sat/vbyte. Currently Bitcoin Core uses a minRelayTxFee of 1sat/vbyte. If you create a transaction below that fee rate then it will be treated as non-standard and the nodes won't relay your transaction forward. Even if you do an internal transfer, you will have to pay fee on the inputs that you add to the transaction. The best cost beneficial way you have if to prevent change outputs by optimizing the inputs (care has to be taken to preserve privacy though).

Theoretically it could be done but practically it may not be possible. In theory, you could use SigHash_All | SigHash_AnyoneCanPay and set one output with a certain amount and reveal the tx. Now each user can add his own input with AnyoneCanPay and any amount. The tx won't be mineable until total input value exceeds that amount.

@CodingEnthusiast you would open yourself up for double spend attacks with that logic. People will sign the anyonecanpay input, leave the shop and spend the same input someplace else. Now that particular input is invalid.

This is a common issue for any service with BTC incomings/outgoings.
The answer is simply to consolidate all your inputs in a large transaction all at once, so you remove possibly hundreds of small outputs, and get one big at the end.
Usually people do this semi-regularly, though you also see people waiting until mempool fees are super low.
One reason you can afford to pay a relatively low fee for consolidation transactions, is because you're planning ahead in your consolidation transactions. You don't need it confirmed immediately (like you would for outgoings, perhaps), so it's OK if it takes a few hours, once your wallet has enough to keep paying customers.
Just pick a moment when the mempool looks super empty, and it'll work really well. If it's not super empty, you can still try low-balling the fee and waiting longer.

Yes, that is what I have been thinking to do. But this approach only works when someone is receiving tons of small payments and then at the end of the day, they can transfer all the funds to a single address with the lowest possible fee, which is 1 sat/byte.  For segwit, each additional input adds 93 bytes to the transaction. So, a transaction with 1000 inputs(1000 small received payments) and 2 outputs by default is 93328 bytes, 0.00093328 BTC fees.

1000 inputs is a lot - maybe you know that 100kb is literally a maximum transaction size on the network? Anyway, it's not the bitcoin networks fault your users are sending tiny tiny amounts. Fees are a reality, and some uses aren't meant to be. You should look into LN, otherwise you could go out of business if fees rise high enough :P (because future fees paid has nothing to do with coins you receive today)

What do you mean 100kb is the max. transaction size? Please share some resources to back that statement. @karimkorun

It's from the source code. https://github.com/bitcoin/bitcoin/blob/99813a9745fe10a58bedd7a4cb721faf14f907a4/src/policy/policy.h#L24
MAX_STANDARD_TRANSACTION_WEIGHT / 4 = 100kb
This is 'policy', so it's not a consensus rule, but it IS still enforced by 99% of nodes. You won't be able to send >100kb txs unless you talk to a miner and get them to mine it.


text:
Private keys for mainnet vs testnet
If I have valid private key to use on Bitcoin mainnet, can I use the same key to generate addresses and spend on testnet? If so, is this encouraged, or should one generally keep separate keys to use on mainnet and testnet?

Yes. A valid private key can be used either on testnet and mainnet. But key reuse is never a good thing, even within the same chain. Just use two different wallets, it's free!


text:
If the "wallet seed keywords phrase" is all that's needed to restore a hardware Bitcoin wallet, isn't backing that up a nightmare security-wise?
I buy a Trezor. I put all my coins on it. It has me type out the "wallet seed", which is a series of English words in the right order, onto a paper. And maybe I even buy a metallic card thing to fireproof it. And maybe I'll even put it inside my fireproof safe on top of that.
And then somebody steals the paper. Or finds the phrase in the passwords.txt file in my computer.
And now they have my coins.
Reading the manual/intro to hardware wallets, the first thing they tell you is to back up the seed phrase.
But the seed phrase gives you instant and full access to the wallet!
This just makes my head spin. I don't understand how they can give such advice when this completely violates your security. I don't understand the point of having a hardware wallet when you completely bypass the security it gives by "backing it up".

You're misunderstanding the purpose of a hardware wallet. So first, when you transact Bitcoin without a hardware wallet on a computer, there is a concern that any potential malware on the computer you're using will be able to steal the key (and therefore its associated Bitcoins) because the key has to be stored on the computer.
The point of a hardware wallet is to make it so you can safely transact with Bitcoin on a regular computer without compromising the security of your private key by storing it on your computer. Because the private key never touches your computer, any potential malware wouldn't be able to gain access to your Bitcoin. (So, if you store your seed phrase on your computer, you've entirely defeated the purpose of using a hardware wallet... so if that's what you're doing, I would recommend creating a new wallet and moving the coins over if you still want the security of the hardware wallet.)
If your concern is someone stealing your backed up seed phrase, it is your job to separately protect that seed phrase, whether it's by encrypting it, storing it in a secured location, etc. But these would be done with different tools (an encryption tool, a physical safe, etc.)

You're not supposed to store it in a passwords.txt file on your PC. Doing so defeats the purpose of having a hardware wallet.
As for the handwritten copy the mnemonic is there because most people don't get hacked but instead lose coins due to inadequate backups.
Hardware wallets are designed to protect you from online threats i.e. hackers and malware. If you feel you are under threat in the real world then you need to hire security guards.

BIP39 mnemonics accept an optional passphrase to secure your funds. Store your mnemonic only and then you don't have to worry about someone spending just from the words alone. That is of course, assuming you can remember your passphrase, or alternatively store your passphrase by itself somewhere else, maybe a friend or family member you trust.


text:
Can one mine bitcoin without including transactions and get accepted by network?
The answer was yes few years ago. Does it still apply as per 2020? If so, why I cannot find any blocks with no transactions recently? Is it not easier to mine blocks with no transactions?
Also, if it still applies, are there any mining software that would allow it? Cgminer and bfgminer are so old, are they still in use and what are you using guys?

similar recent question https://bitcoin.stackexchange.com/questions/99852/what-are-the-benefit-of-mining-an-empty-block

The answer was yes few years ago. Does it still apply as per 2020?

Yes, changing that would be a consensus change and require a fork of some kind.

If so, why I cannot find any blocks with no transactions recently?

Because it's more profitable to include transactions. Miners want to make money, and with the diminishing block subsidy, they will want to collect as much in transactions fees as possible, so they have to include transactions in their blocks.

Is it not easier to mine blocks with no transactions?

The amount of transactions in a block has no effect on its difficulty. It may be nominally "harder" because a bit more logic needs to be done to collect and choose the transactions to include, but this is negligible and the fees collected far outweigh any benefit to mining empty blocks.

Also, if it still applies, are there any mining software that would allow it? Cgminer and bfgminer are so old, are they still in use and what are you using guys?

AFAIK, both cgminer and bfgminer are still maintained. Old does not mean bad. They can mine empty blocks if whatever node provider they are connected to gives them empty blocks to mine.


text:
Transaction validation cost
what relation is between transaction size or a number of input and validation cost? for example, It's o(n) or o(n^2)?

That depends on which (and the amount of) opcodes used and there is no concrete answer.


text:
lost bitcoin on electrum - wallet closed after transaction went through?
i'm noob to bitcoin and lack advanced knowledge of how these wallets work. i followed guides on how to buy bitcoin and seemingly the transaction went fine, until my electrum wallet suddenly closed and when i opened it back up i could not find my transaction in history, my recieving address changed and the address i used to buy  bitcoin can not be found anywhere.
here is a link to the transaction https://blockchain.info/da/address/157gZExbGA27R33AFHmQS41EzFxXoUpBjP

and an image of the receipt after purchase
did i screw this up completely or can i still get my bitcoin into my electrum wallet?

Things to check: 1. is your Electrum connected, and have a green dot on the lower right corner? 2. Go to addresses tab, can you find your receiving address there?

yes me wallet is connected, and no i cannot find the receiving address under the adress tab

I don't know why the receiving address disappeared, but you can try to restore the wallet by using the same seed you created the wallet with. Electrum is a HD wallet, so you will get the same sequence of private keys, public keys, public addresses using the same seed every time. As long as your Electrum client is authentic, this is probably just a bug and you funds are safe.

i restored the wallet using the seed, but still not finding the address i used for my purchase.

Hmm.. weird. Here is what you can do: Open Electrum, click on on wallet, then master public keys. Copy the master public key and paste it in blockchain.info/xpub/"your master public key here" without the quotes. It will show you all the transactions related to your current Electrum seed. Is the 'lost' transaction listed there?

no, it says no transactions are found on this address

Well, if you are absolutely sure that you saw the transaction in Electrum, and the address has now disappeared even using the same seed. There is only one thing left to do: Submit an issue directly to the Electrum developers. https://github.com/spesmilo/electrum/issues and mention that you tried with your master public key and didn't find the corresponding transaction.

Hmm.. weird. Here is what you can do: Open Electrum, click on on
  wallet, then master public keys. Copy the master public key and paste
  it in blockchain.info/xpub/"your master public key here" without the
  quotes. It will show you all the transactions related to your current
  Electrum seed. Is the 'lost' transaction listed there?

Well, if you are absolutely sure that you saw the transaction in Electrum, and the address has now disappeared even using the same seed. There is only one thing left to do: Submit an issue directly to the Electrum developers. github.com/spesmilo/electrum/issues and mention that you tried with your master public key and didn't find the corresponding transaction.


text:
How is a Litecoin address generated?
How is a litecoin address generated? What hashing do they use?
For example, bitcoin addresses are generated like so: https://en.bitcoin.it/wiki/Technical_background_of_version_1_Bitcoin_addresses
I am looking for an answer like that but can't find it anywhere. Any litecoin searches turn up with bitcoin links.
Please do not give me Litecoin address generation sites or wallets to download. I want to know how I can manually program a litecoin address generator.

Litecoin uses exactly the same procedure to generate addresses, the only difference is the network prefix.
On step 4 (Add version byte in front of RIPEMD-160 hash) instead of 0x00 for bitcoin use
0x30 for Litecoin main-net or
0x6F for Litecoin test-net.
Your address should start with L then and will be a valid Litecoin address.
Full sequence:
0 - Having a private ECDSA key
18E14A7B6A307F426A94F8114701E7C8E774E7F9A47E2C2035DB29A206321725

1 - Take the corresponding public key generated with it (65 bytes, 1 byte 0x04, 32 bytes corresponding to X coordinate, 32 bytes corresponding to Y coordinate)
0450863AD64A87AE8A2FE83C1AF1A8403CB53F53E486D8511DAD8A04887E5B23522CD470243453A299FA9E77237716103ABC11A1DF38855ED6F2EE187E9C582BA6

2 - Perform SHA-256 hashing on the public key
600FFE422B4E00731A59557A5CCA46CC183944191006324A447BDB2D98D4B408

3 - Perform RIPEMD-160 hashing on the result of SHA-256
010966776006953D5567439E5E39F86A0D273BEE

4 - Add version byte in front of RIPEMD-160 hash (0x30 for Litecoin Main Network)
30010966776006953D5567439E5E39F86A0D273BEE

(note that below steps are the Base58Check encoding, which has multiple library options available implementing it)
5 - Perform SHA-256 hash on the extended RIPEMD-160 result
27872C1C5DF98F26A09EEBE7A048A52CCFFD647098EACDB6D5D48563B0DBE7B4

6 - Perform SHA-256 hash on the result of the previous SHA-256 hash
713B731B0E30DDD0B6E1F73E2EA2A1E298A35BBDB37FF13C593028515C3B2B50

7 - Take the first 4 bytes of the second SHA-256 hash. This is the address checksum
713B731B

8 - Add the 4 checksum bytes from stage 7 at the end of extended RIPEMD-160 hash from stage 4. This is the 25-byte binary Litecoin Address.
30010966776006953D5567439E5E39F86A0D273BEE713B731B

9 - Convert the result from a byte string into a base58 string using Base58Check encoding. This is the most commonly used Litecoin Address format
LKKSCYdyWP7fJDMZ1KUDbpj3yPmQ22MQrv

Was confused because here it shows that Bitcoin's testnet prefix is 0x6f as well. Apparently Bitcoin and Litecoin share same the testnet prefix.

$ python3.6 ltc_address_generator.py 0450863AD64A87AE8A2FE83C1AF1A8403CB53F53E486D8511DAD8A04887E5B23522CD470243453A299FA9E77237716103ABC11A1DF38855ED6F2EE187E9C582BA6
LKKSCYdyWP7fJDMZ1KUDbpj3yPmQ22MQrv

Please try the following py script, and generate a ltc address for your public key.
#!/usr/bin/env python3
# -*- coding: utf-8 -*-

import hashlib
import base58

def sha256(hexstr):
    """sha256 hash algorithm
    """
    return hashlib.new('sha256', bytes.fromhex(hexstr)).hexdigest()

def rip160(hexstr):
    """ripemd160 hash algorithm
    """
    return hashlib.new('ripemd160', bytes.fromhex(hexstr)).hexdigest()

def get_ltc_address(pubkey):
    """https://bitcoin.stackexchange.com/questions/65282/how-is-a-litecoin-address-generated
    """
    rip160_hash = "30" + rip160(sha256(pubkey.upper()).upper()).upper()
    sha256_hash = sha256(sha256(rip160_hash).upper()).upper()
    return base58.b58encode(bytes.fromhex(rip160_hash + sha256_hash[0:8]))

if __name__ == '__main__':
    import sys

    if len(sys.argv) != 2:
        print("[*] Usage: python %s publickey")
        sys.exit(1)

    print(get_ltc_address(sys.argv[1]))

# references
# https://en.bitcoin.it/wiki/Protocol_documentation#Addresses
# https://gist.githubusercontent.com/circulosmeos/97f2c155777434081cb56886c1b608be/raw/f960b4e89e86dcdf77fb6288c1005a7cb847cc98/easy-litecoin-address-from-public-key.py
# https://bitcoin.stackexchange.com/questions/65282/how-is-a-litecoin-address-generated
# https://bitcoin.stackexchange.com/questions/56923/is-this-how-to-generate-a-bitcoin-address-with-python
# https://iancoleman.io/bip39/


text:
Where exactly is the Inscription media stored in witness signature?
Is it stored in the witness program as
OP_FALSE
OP_IF
<data>
OP_ENDIF

or is it stored in annex as described in bip 341 or in some other form?

@VojtěchStrnad yes, it's illustrative, but it seems to be a normal SegWit transaction (OP_0), not taproot (OP_1). I was a bit confused by annex logic in ord wallet source code and thought they might use annex for data storage since it's simply ignored

The OP_0 is not in the output script but in the leaf script, to avoid executing the code branch that has the inscription data.

I think this is explained at https://docs.ordinals.com/inscriptions.html

Inscription content is serialized using data pushes within unexecuted conditionals, called "envelopes". Envelopes consist of an OP_FALSE OP_IF … OP_ENDIF wrapping any number of data pushes. Because envelopes are effectively no-ops, they do not change the semantics of the script in which they are included, and can be combined with any other locking script.
A text inscription containing the string "Hello, world!" is serialized as follows:
OP_FALSE
OP_IF
  OP_PUSH "ord"
  OP_1
  OP_PUSH "text/plain;charset=utf-8"
  OP_0
  OP_PUSH "Hello, world!"
OP_ENDIF

From what I have seen, the inscribed data appears in the second witness component of three. The last does not start with 0x50 so is not an annex if my (pretty sketchy) understanding is correct.


text:
Inscriptions with size less than 10Kb were seemingly possible before taproot, why did they become popular only now?
In 2017 SegWit soft fork introduced consensus limit on script size MAX_STANDARD_P2WSH_SCRIPT_SIZE=10000. With P2WSH, one could seemingly use the same script structure ("envelope") OP_FALSE OP_IF <data> OP_ENDIF to store up to ~10Kb of data in witness. Even though taproot removed the 10Kb restriction, the vast majority of inscriptions are under that limit currently. Why did they become popular now and why the popularity is commonly associated with taproot?

@Poseidon OP_RETURN is a different storage solution and has 80 bytes limit

There's really no reason inscriptions couldn't have been done with SegWit v0. The only difference would be that large inscriptions would have to be split across multiple inputs, making the construction slightly more expensive. Pre-SegWit you'd have to use a different transaction field for inscriptions and you couldn't use the witness discount, but methods of embedding arbitrary data in the chain have existed basically since the beginning of Bitcoin.
The lifting of that 10,000 byte script size limit, coupled with the fact that the currently used inscription standard requires that Taproot be used, is the likely reason it's associated with (and sometimes wrongly blamed for) inscriptions.

With P2WSH, one could seemingly use the same script structure ("envelope") OP_FALSE OP_IF  OP_ENDIF to store up to ~10Kb of data in witness

This is incorrect. The maximum standard witness script size for P2WSH is 3600 bytes.

Thanks for your answer. Where is that limit specified (code or bip)?

Follow the link. :) Note this is a standardness rule specific to Bitcoin Core, not a Bitcoin consensus rule.

Aw... GPT-4 strikes again...
https://i.postimg.cc/pX8YR9C1/Screenshot-2023-05-09-181726.png♂

Haha. I wonder why people keep using a tool with such a high false positive rate. It's literally even worse than sub-optimal search engines: you won't find what you're looking for but at least they'll admit it instead of making something up.


text:
Is there a script for bitcoin core which prints all spendable UTXOs given a private seed?
I am looking for an open source script or application which would take a private wallet key from the user (from terminal input or file, as mnemonic or xpriv string) and then connect to a bitcoind and output all UTXOs which are owned (spendable) by that key. Does something like that exist?

You can import a descriptor composed of the xpriv(s) (or xpub(s) if you just want to watch the coins) to the bitcoind wallet, and then rescan the block chain for transactions involving derived key up to a configured gap limit.
For importing the descriptor, use the importmulti RPC call in versions <0.21 and the importdescriptors RPC as of 0.21 (upcoming).
Both calls allow you to pass a creation timestamp in order to rescan the block chain from this point. You can otherwise manually call rescanblockchain.
Note that, depending on the number of blocks you are scanning, it will take some time. You can monitor the progress in your debug.log.

Thanks, I will look into that. Initially, I wanted to avoid using bitcoind wallet and was looking for a lightweight solution which would construct a set of HD wallet PKHs and scan the full UTXO database for matches (even though that's not part of bitcoin core api, it can be done locally)

You can avoid risking exposing your private keys and just check the addresses with scanutxooutset in the console or via JSON-RPC. Although it takes a few minutes, you don't have to wait for a full rescan and it's easy to get all UTXOs for any address or even xpub and it doesn't have to already be in your wallet like when importing keys.
Example in the console:
scantxoutset start '[{"desc":"addr(1SomeAddress)"},{"desc":"addr(1AnotherAddressToCheck)"}]'

or checking xpubs would look something like this:
scantxoutset start '[{"desc":"pkh(xpubMyXpubToCheck)"}]'

This python library comes close (disclaimer: I wrote it). It supports HD wallets via mnemonic or xprv and you can query outputs of addresses however it queries a block explorer for the outputs instead of bitcoind (you can probably tweak the code to replace the API call with an rpc call)

Looks interesting, but I didn't see the described functionality in the examples. I also specifically wanted to do everything locally and avoid queries to a 3rd party


text:
Can someone explain the byte composition of an inscription reveal transaction?
Doom was inscribed on chain. The reveal transaction had the following script
OP_PUSHBYTES_32 1809cc80b0c9bf0277e774f7f78c5dd0c61f9eda7bec7875dc99457bbf61af8f
OP_CHECKSIG
OP_0
OP_IF
OP_PUSHBYTES_3 6582895
OP_PUSHBYTES_1 1
OP_PUSHBYTES_23 746578742f68746d6c3b636861727365743d7574662d38
OP_0
OP_PUSHDATA2 520 3c21444f43545950452068746d6c3e3c68746d6c3e3c686561643e3c7469746c653e59657420416e6f74686572
...
OP_PUSHBYTES_73 682e73696e2c4b3d4d6174682e636f732c6b3d4d6174682e50492c71693d4d6174682e72616e646f6d2c573d4d6174682e6162732c45693d4d6174682e6d61783c2f7363726970743e
OP_ENDIF

Can someone provide an insight into the byte structure of the raw witness data (see picture below)? What's in the "header" 0e9713..d0? Why are there two copies of hash 1809cc80..af8f? Is there some online resource which could help me understand this better (besides bips)?
?

A taproot script path spend always has at least 2 witness items:

The second-to-last item is the leaf script.
The last item is the "control block" which consists of a leaf version, the taproot internal key (the public key before it was tweaked with the merkle root of the script tree) and optionally any merkle branches that prove the inclusion of the script in the tree. These are not present here because the tree only has one script (this might be required by the inscription standard, haven't checked).
Any remaining items are used as the initial stack for script execution. In this case the single remaining item is the signature that satisfies the OP_CHECKSIG opcode.

The public key 1809cc80..af8f is used both as an internal key and in the script. This would normally hurt privacy because you reveal that the key path has the same key as the script path, but in the case of inscriptions it doesn't really matter because you already reveal you weren't going to use the key path, and it probably simplifies the code a little.

I think Vojtěch Strnad answered your main questions, I just wanted to point out how the inscribed data is encoded:
You wrote:

OP_PUSHBYTES_32
1809cc80b0c9bf0277e774f7f78c5dd0c61f9eda7bec7875dc99457bbf61af8f
OP_CHECKSIG
OP_0
OP_IF
OP_PUSHBYTES_3 6582895

Those three bytes are hex 6F7264 which is ASCII   ord meaning the Ordinals project.

OP_PUSHBYTES_1 1
OP_PUSHBYTES_23 746578742f68746d6c3b636861727365743d7574662d38

Those 23 bytes are text/html;charset=utf-8 - the type of data inscribed

OP_0
OP_PUSHDATA2 520
3c21444f43545950452068746d6c3e3c68746d6c3e3c686561643e3c7469746c653e59657420416e6f74686572

Those 520 bytes are HTML (as indicated previously):
<!DOCTYPE html><title>Yet Another Doom Clone</title><canvas id=cQ></canvas><Mdiv id=qQ>
Yet Another Doom Clone

Loading...

Move: WASD
Aim/Shoot: Mouse/Click

By Nicholas Carlini

etc

I've also provided a more programmatic manual disassembly example at: https://bitcoin.stackexchange.com/questions/117018/understanding-how-ordinals-work-with-the-bitcoin-blockchain-what-is-exactly-sto/123647#123647


text:
Is there a limit for number of times Ordinal Inscriptions can be transferred to a new address?
Ordinal Inscriptions are typically created by making 10000-satoshi UTXOs. To transfer the Inscription to a new address (when it's sold, for example), the UTXO is spent and transaction fee is paid, thus the next owner's UTXOs is less than 10000 satoshi. Can it happen that at some point, after multiple transfers, the Inscription becomes un-transferable because the UTXO amount is not enough to cover the transaction fee?
At the time of this writing, there are over 400K txs in mempool and TX fees are routinely ~2000 satoshi

Only if wallets mishandle it, you aren't supposed to subtract the transaction fee from the inscription's 10k sats, but pay it using an additional UTXO. In theory, it'll continue to have the same amount forever...


text:
Can I cancel a transaction that has no confirmations due to low satoshis?
Hi all I changed the cost to transact from $24 us to $1.40 when I transferred my bitcoin funds and no one will confirm it. Is there anyway to cancel it? I can't do a double transaction because I was moving my entire wallet off my ledger Nano to GDAX

The only way to cancel it is to replace it with a newly created transaction that overrides the previous one, and hope that by the higher fee this one gets confirmed earlier.

Do I have to match the output amount i.e. 0.10 BTC or can it be a different amount?

Also do both BTC addresses I am sending to need to match?

It can be a different amount and a different destination address. What will happen is that the competing transaction with the higher fees will enter the blockchain first, and thefore the other transaction in the mempool, will never enter the blockchain and eventually be discarded because of bitcoin's safeguards agains double-spends.


text:
No. Transactions 0
Dears,
I just have sent my BTC to my wallet on crypto naptor and I see via blockchain.info tool the following:
No. Transactions 0
Total Received 0 BTC
Final Balance 0 BTC
I sent my BTC from eobot system to my wallet 1Ny9RuXuBJYRZs8jfRZ1PABkyc5435mRs2 :
Confirmation about sending please see below:
12/15/2017 1:45:21 AM PT WITHDRAW BTC 0.02845822 to 1Ny9RuXuBJYRZs8jfRZ1PABkyc5435mRs2 TXID c675182bab90695ccb88cf9fef23e67104e03a7433a13cc9354a997318c461da
Please advice why the balance as well as transaction number is 0 and why BTC hasn't been delivered yet.
Thanks a lot for your advice.

The transaction does not appear to exist on the network. Either Eobot has not broadcast the transaction yet, or it was unconfirmed for a while and forgotten by the network. In either case, you should contact Eobot as they are the only ones who can resolve this issue for you.

Andrew thanks for answer. I already sent two mails to eobot but no answer so far :(


text:
why my bit coin txn is still processing for more than 24 hours?
Can any one help me why this txn is pending for more than 24 hours?
https://blockchain.info/tx/df040a6a683f99cdbf5ba92410c143bad2a2b042288630a07dad6c59cbd9be5e

The fee you paid for the transaction is currently non competitive at 149.712 sat/B.  The transaction volume for legacy transactions on the Bitcoin network is at capacity which means people are paying much higher fees than usual.
Sites like https://bitcoinfees.earn.com/ can help you estimate a competitive fee.  Looking at their estimates for 141-150 S/B transactions it looks like 5x as many transactions have been processed in the last 24 hours than are currently waiting to be processed.
If your transaction is time sensitive, look into "Replace By Fee" to speed up your stuck transaction.  https://bitcoinmagazine.com/articles/what-to-do-if-your-bitcoin-transaction-gets-stuck-1481042383/


text:
Bitcoin Address Tag
I'm new to the cryptocurrency world but I was wondering if someone could help me answer my question regarding bitcoin address tags. I was on an exchange platform and I wanted to transfer my coins to another wallet... and they are asking me to put an address tag and also my bitcoin wallet number.
I found this site: https://blockchain.info/tags?form_type=0
Is this where I create my address tag?
I don't understand the link part, so I just link to a random site or it has to have my bitcoin address on that site for it to work? I'm confused :( Thank you for your help everyone!


text:
Can a Bitcoin wallet be identified as belonging to an exchange?
Ethereum wallets can be associated with Exchanges (e.g. Etherscan.io will tell you if an address is a Poloniex one).
Is this possible for Bitcoin addresses?

Yes, in theory is possible to guess the ownership of an address to an Exchange.
Notice that I said in theory and I also mentioned that it's a guess. That's because per design each address is anonymous. However, since the blockchain is public, you can analyze the type and amount of transactions getting in and out a specific address and make assumptions based on patterns.
An exchange has generally a large amount of transactions. If they use a finite amount of addresses, eventually transactions will reuse existing addresses.
If you provide a tool or a way for people to publicly share/associate specific addresses with Exchanges, then eventually you will build an archive of matches. I believe this is what Etherscan does.

If they use a finite amount of addresses, eventually transactions will reuse existing addresses. That's mathematically true, but the number of possible addresses is so large that reuse will not happen before the sun goes out.  In practice an exchange will never reuse a deposit address, and so the technique you describe will not be useful.

@NateEldredge That's not quite true. Many exchanges will provide one address to a user, leading to eventual reuse if the user makes multiple deposits. It is possible to identify the random address->desposit address->exchange hot/cold wallet trail given enough data points.


text:
If i have 42 tera hashes of mining power, how long will it take me to mine a block solo, and if i join a mining pool, how much bitcoin will I get?
If i have 42 tera hashes of mining power, how long will it take me to mine a block solo, and if i join a mining pool, how much bitcoin will I get? I am intrested in buying 4 Bitmain Antminer T9+.

At the time of writing, less power costs, and assuming no change in difficulty:

it would take on average 50 years, 21 weeks to generate a block.
it would produce on average 0.000678 BTC per day, or about $6.70.

Can you explain how you reached these values? Currently it looks like numbers pulled out of thin air.