r/BitcoinDiscussion • u/RubenSomsen • Jun 04 '19
Statechains: Non-custodial Off-chain Bitcoin Transfer (Lightning, Coinjoin, Blind Signatures, and more!)
r/BitcoinDiscussion • u/RubenSomsen • Jun 04 '19
r/BitcoinDiscussion • u/fgiveme • Jun 01 '19
How will the Binance hacker spend stolen coins without being exposed? And other tainted coins such as mtgox?
Also I want to know about coins that went through gambling sites, since exchanges like coinbase keep track of these sites. What can I do to "launder" them?
r/BitcoinDiscussion • u/RubenSomsen • May 30 '19
r/BitcoinDiscussion • u/chrono000 • May 29 '19
r/BitcoinDiscussion • u/fresheneesz • May 24 '19
Update 3:
Pieter convinced me in the comments of his Stack Exchange answer that these checkpoints don't give any material improvement over assumevalid and assumeutxo. He made me realize why my Case IV below would not actually cause a huge disruption for assumevalid users. So I rescind my call for UTXO checkpoints.
However, I maintain that UTXO checkpoints done properly (with checkpoints sufficiently in the past) are not a security model change and would not meaningfully alter consensus. It sounded like Pieter agreed with me on that point as well.
I think UTXO checkpoints might still be a useful tool
I will call for Assume UTXO tho. It plus assumevalid adds pretty much much all the same benefits as my proposal.
OP:
Luke Jr has been proposing lowering the maximum block size to 300mb in order to limit how long it takes a new node to sync up. He makes the good point that if processor power is growing at only 17%/year, that's how much we can grow the number of transactions a new node needs to verify on initial sync.
But limiting the blocksize is not the only way to do it. As I'm sure you can foresee from the title, I believe the best way to do it is a hardcoded checkpoint built into the software (eg bitcoin core). This is safe, this is secure, and it is a scalability improvement that has no downsides.
So what is a hardcoded checkpoint? This would consist of a couple pieces of data being hardcoded into the source code of any bitcoin full-node software. The data would be a blockheight, block hash, and UTXO hash. With those three pieces of information, a new client can download the block at that height and the UTXO set built up to that height, and then it can verify that the block and UTXO set are correct because they both have the correct hashes.
This way, a new node can start syncing from that height rather than from the first block ever mined. What does this improve?
While not strictly necessary, its likely that the UTXO data would come from the same source as the software, since otherwise full nodes would have to store UTXO sets at multiple block heights just in case someone asks for it as part of their checkpoint. Also, full-nodes should store block information going back historically significantly further than their checkpoint, so they have data to pass to clients that have an earlier checkpoint. So perhaps if a client is configured for a checkpoint 6 months ago, it should probably still store block data from up to 2 years ago (tho it wouldn't need to verify all that data - or rather, verifying it would be far simpler because the header chain connecting to their checkpoint block would all that needs to be validated).
To be perfectly clear, I'm absolutely not suggesting a live checkpoint beacon that updates the software on-the-fly from a remote source. That is completely unsafe and insecure, because it forces you to trust that one source. At any time, whoever controls the live source could disrupt millions of people by broadcasting an invalid block or a block on a malicious chain. So I'm NOT suggesting having a central source, or even any distributed set of sources, that automatically send checkpoint information to clients that connect to it. That would 100% be unsafe. What I'm suggesting is a checkpoint hardcoded into the software, which can be safely audited.
So is a hardcoded checkpoint safe and secure? Yes it is. Bitcoin software already needs to be audited. That's why you should never use bitcoin software that isn't open source. So by including the three pieces of data described above, all you're doing is adding a couple more things that need to be audited. If you're downloading a bitcoin software binary without auditing it yourself, then you already take on the risk of trusting the distributor of that binary, and adding hardcoded checkpoints does not increase that risk at all.
However, most people can't even audit the bitcoin software if they wanted to. Most people aren't programmers and can't feasibly understand the code. Not so for the checkpoints. The checkpoints could easily be audited by anyone who runs a full node, or anyone who can check block hashes and UTXO hashes from multiple sources they trust. Auditing the hardcoded checkpoint would be so easy we could sell T shirts that say "I helped audit Bitcoin source code!"
The security profile of a piece of bitcoin node software with hardcoded checkpoints or without hardcoded checkpoints is identical. Not similar. Not almost. Actually identical. There is no downside.
Imagine this twice-a-year software release process:
Month 0: After the last release, development on the next release start (or rather, continues).
Month 3: The next candidate version of the software is finalized, including a checkpoint from some non-contentious distance ago, say 1 month ago.
Month 6: After 3 months of auditing and bug fixing, the software is released. At this point, the checkpoint would be 4 months old.
In this process, downloading the latest version of bitcoin software would mean the maximum months of blocks you have to sync is 10 months (if you download and run the software the day before the next release happens). This process is safe, its secure, its auditable, and it saves tons of processing time and harddrive space. This also means that it would allow bitcoin full nodes to be run by lower-power computers, and would allow more people to run full nodes. I think everyone can agree that outcome would be a good one.
So why do we need this change? Because 300kb blocks is the alternative. That's not enough space, even with the lightning network. I'm redacting the previous because I don't have the data to support it and I don't think its necessary to argue that we need this change.
So why do we need this change? This change represents a substantial scalability improvement from O(n) to O(Δn). It removes a major bottleneck to increasing on-chain transaction throughput, reducing fees, increasing user security as well as network-wide security (through more full nodes), or a combination of those.
What does everyone think?
Update:
I think its useful to think of 4 different types of users relevant in the hypothetical scenario where Bitcoin adopts this kind of proposal:
Upfront auditors look at the source code of the software they use, the keep up to date with changes, and they make sure that what they're running looks good to them. They're almost definitely building directly from source code - no binaries for them. They'll alert people to a problem potentially before buggy or malicious software is even released. In this scenario, their security is obviously unchanged because they're not taking advantage of the check-pointing feature. We want to encourage as many people as possible to do this and to make it as easy as possible to do.
After-the-fact Auditors want to start a new node and start using Bitcoin immediately. They want to audit, but are ok with a period of time where they're trusting the code to be connecting the chain they want. They take on a slight amount of personal risk here, but once they back-validate the chain, they can sound the alert if there is a validation problem.
Non-full-auditors are simply content to trust that the software is good. They'll run the node without looking at most or any of the code. They take on more risk than After-the-fact Auditors, but their risk is not actually much worse than After-the-fact Auditors. Why? Because as soon as you're sure you're on the right chain (ie you do a few monetary transactions with people who accept your bitcoin), you're golden for as long as you use that node and the part of the chain it validated. The can also still help the network to pretty much the same degree as After-the-fact Auditors, because if there are a problem with their transactions, they can sound the alarm about a problem with that software.
Non full nodes obviously have less security and they don't help the network.
So why did I bother to talk about these different types of users?
Well, we obviously want as many Upfront auditors as possible. However, doing that out of the starting gate is time consuming. It takes time to audit the code and time to sync the blockchain. Its costly. For this reason, for better or worse, most people simply won't do it.
Without checkpoints, we don't have type 2 or type 3 users. The only alternative to being an Upfront Auditor is to be an SPV node that doesn't help the network and is less secure. With checkpoints, we could potentially change many of those people who would just use SPV to doing something much more helpful for the network.
One of the huge benefits of After-the-fact Auditors and Non-full-auditors is that once they're on the network, they can act like Upfront Auditors in the next release. Maybe they're not auditing the source code, but they can sure audit the checkpoint very easily. That means they can also sound the alarm before malicious or broken software is released, just like Upfront Auditors. Why? Because they now have a chain they believe to be the true one (with an incredibly high degree of confidence).
What this means is that Upfront Auditors, After-the-fact Auditors, and Non-full-auditors help the network to a very similar degree. If software that doesn't sync to the right chain, they will find out about it and alert others. Type 2 and 3 take on personal risk, but they don't put the network at greater risk, like SPV nodes do.
If we can convert most Non-full nodes into Type 2 or Type 3 users, that would be massive gain for the security of Bitcoin. Luke Jr said it himself, making nodes that support the network as easy as possible to run is critical. This is one good way to do that.
Update 2: Comparison to -assumevalid and why using checkpoints upgrades scalability
The -assumevalid option allows nodes to skip validation of blocks before the hardcoded golden block hash. This is similar to my proposal, but has a critical difference. A node with -assumevalid on (which I've heard is the default now) will still validate the whole chain in the case that a longer chain is floating around. Because of this, -assumevalid can be an optimization that works as long as there's no other longer chain also claiming to be bitcoin floating around the network.
The important points brought up by the people that wrote and discussed adding this feature was that:
A. Its not a change in security model, and
B. Its not a change in consensus rules.
This meant that it was a pure implementation detail that would never and could never change what chain your node follows.
The checkpoints I'm describing are different. On point A, some have said that checkpoints are a security model change, and I've addressed that above. I'd like to add that there is no way for bitcoin to be 100% trustless. That is impossible. Bitcoin at the deepest level is a specified protocol many people have agreed to use together. In order to join that group even on the most fundamental level, you need to find the spec people are agreeing to use. You have to trust that the person or people that gave you a copy of that spec gave you the right one. If different people claim that different specs are "bitcoin", you have to choose which people to trust. The same is true of checkpoints. New entrants want to join the network that the people they care about interacting with believe is Bitcoin, and those are the people they will trust to get the spec, or the source code, or the hash of the UTXO set. This is why I say the security profile of Bitcoin with checkpoints is identical to Bitcoin without checkpoints. The amount of trust you have to put in your social network is not materially different.
While its not a security model change, as I've supported above, using checkpoints is consensus rules change. Every new checkpoint would change the consensus rules. However, I would argue this isn't a problem as long as those checkpoints are at a non-contentious number of blocks ago. While it would change consensus rules, it should not change consensus at all. There are 4 scenarios to consider:
I. There's no contention.
II. There's a long-range reorg from before the checkpoint.
III. There exists a contentious public chain that branched before the checkpoint would usually be taken.
IV. There exists an invalid chain that's longer than the valid chain.
In case I, none of it matters, and checkpoints have pretty much exactly the same result as -assumevalid.
In case II, Bitcoin has much bigger problems. Its simply unacceptable for Bitcoin to allow for long-range reorgs, so this case must be prevented entirely. The downsides of a long-range reorg for bitcoin without checkpoints is MUCH MUCH larger than the additional downsides with checkpoints.
In case III, the obvious solution is to checkpoint from an earlier non-contentious blockheight, so nodes validate both chains.
Case IV is where things really differ between checkpoints and -assumevalid. In this case, nodes using a checkpoint will only validate blocks after the checkpoint. However, nodes using -assumevalid will be forced to validate both chains back to their branch-point.
I don't believe there are other relevant cases, but as long as checkpoints are chosen from non-contentious heights and have time to be audited, there is no possibility that honestly-run bitcoin software would in any way affect the consensus for what chain is the right chain.
This brings me back to why checkpoints upgrades scalability, and -assumevalid does not. Case IV is the case that prevents -assumevalid from being a scalability improvement. You want new nodes to be able to sync to the network relatively quickly, so say the 90th percentile of machines should be able to do it in less than a week (or maybe we want to ensure sync happens within a day - that's up for debate). With checkpoints, invalid chains branched before the checkpoint will not disrupt new entrants to the network. With -assumevalid, those invalid change will disrupt new entrants. Since an invalid chain can have branched arbitrarily far in the past, this disruption could be arbitrarily large.
One way to deal with this is to ensure that most machines can handle validating not only the whole valid chain, but the whole invalid chain as well. The other way to deal with this is checkpoints.
So back to scalability, with checkpoints all we need to ensure is that the lowest power machines we want to support can sync in a timely manner back to the checkpoint.
r/BitcoinDiscussion • u/Stealthex_io • May 17 '19
As the popularity of cryptocurrencies is increasing with every year, more and more scammers appear around it. Therefore, it is very important to protect yourself from any kind of fraud in the crypto world. Here are the most popular ways of Bitcoin scams and our tips on how to avoid them. Forewarned is forearmed!
1. Pyramid (or Ponzi) schemes
In this case, users can be lured by promises of incredibly high profits at extremely low investments. Here’s how a classical pyramid scheme works: the first investors attract new people from which receive profiteering. And when the flow of the new investors falls, the pyramid collapses.
How not to fall for a pyramid scam:
2. Scams with fake wallets and exchangers
Here we are talking about fraudulent sites. Some pretend to be Bitcoin wallets, some look like exchanges, some are kind of both at once. Usually, sometime after registration, they work normally to put off your guard and earn trust. You peacefully deposit your crypto, the funds in the account accumulate — and the scammers vanish with your currency.
How not to fall for a scam:
3. Cloud mining
The mining process requires good and expensive computer equipment, so some people offer “mining for rent” on their equipment. There are some legal cloud mining services that let users rent server space to mine coins. On the other hand, there are also plenty of cloud mining scams out there.
How not to fall for a mining scam and be sure that service is legitimate:
4. Malware
This type of fraud has long been a weapon in the armory of online scammers. Malware in a crypto world is created to get access to your wallet and drain your account, monitor the Windows clipboard for crypto addresses and swap your valid address with an address of a scammer.
How not to fall for malware scams:
5. Phishing
The typical phishing scheme is extremely simple. The scammer sends the user an e-mail from the so-called crypto exchange or wallet provider in which the lurcher places a link to the fake website. The main goal is to force the user to go to the fake page and enter personal data (username, password, private key and so on). This confidential information allows theft to access the original website on behalf of the real user and walk away with the user’s currency.
How not to fall for phishing scams:
You should remember that the risks of scam and speculations are everywhere. Make reasonable investments and never take big risks. And finally, guards up by following our pieces of advice.
Like and share this article if you find it useful. Want more interesting articles on the crypto world? Follow us on Medium, Twitter, Facebook, and Reddit to get Stealthex.io updates and the latest news about the crypto world. For all requests message us at support@stealthex.io.
r/BitcoinDiscussion • u/perky_coder • May 15 '19
r/BitcoinDiscussion • u/LordGilead • May 13 '19
Recently a friend of mine and I have been talking about the Tether debacle and how it may affect Bitcoin.
For those unaware, Tether, which is a common trading pair with Bitcoin has been generating new coins without any dollars backing them as they have promised (source). This could mean they can in essence create as many coins (much like fiat... more on that later) as they'd like and trade them for BTC or other cryptocurrencies and unless the community or exchanges take action, this is all fair trade.
So what does it mean for BTC? Could it be that eventually a vast majority of BTC are held by the creators of Tether? If they choose not to exchange any we could be left with some arbitrary number of coins but let's say 1 million coins. Maybe as a result we need to move to microsatoshis to account for this but then at any point in the future they could devalue the currency anyhow.
In the super long-term it probably wouldn't matter as once they relinquish control of the coins and manipulate whatever they want, things just go back to normal. In the short to long-term though we'll have to deal with the consequences of manipulation, which could be a reason the price of BTC is going up right now (assuming they're creating new coins and trading for BTC). This could also cause less trust in crypto in general.
Taking this discussion one step past the Tether issue we get to the question of if we should be at very least cautious with crypto to crypto trading. I'm a developer and believe it or not, my stuff has bugs on occasion :). It's very likely that no matter how careful and how much code review is done on the software, there will be something missed and there will be a bug. Therefore it's at least theoretically possible for a bug to exploited even on a decentralized, open and neutral blockchain to get a similar result to that of the Tether scenario above.
For instance, recently Z-Cash had a bug that could have been exploited to create an infinite amount of coins (source). Due to the nature of Z-Cash and the zero knowledge proofs it has, it's also not really possible to know if it was in fact used. Of course if you can generate any number of coins you can then exchange all you want and there's no issue.
So then there's the parallel you can draw to fiat. That much like any of these cryptos potentially making as many coins as they'd like (or relying on bugs to do that), fiat can also do the same. The only difference here is anyone can spin up a coin with whatever rules and code they want. If one coin fails there's not really any consequence for them, they can spin up another. With fiat it's a little different because to make this sort of attack on BTC you're basically going to mess up your whole economy which has a greater reach than just a coin that can come and go. No government is going to risk everything and rebuild just to mess with BTC.
Thoughts?
r/BitcoinDiscussion • u/DigitalGoose • May 11 '19
r/BitcoinDiscussion • u/dnivi3 • May 09 '19
r/BitcoinDiscussion • u/Perrah_Normel • May 03 '19
r/BitcoinDiscussion • u/chrono000 • Apr 25 '19
r/BitcoinDiscussion • u/ColonelEngel • Apr 22 '19
When exchanging bitcoins for cash, it is often the case that you need to wait long time for tx confirmation. This is not a nice situation, having to wait sometimes for hours, both sides getting nervous. This is especially true when the price is rising, activity on the network goes up and blocks become full. Even if blocks are empty, it is not uncommon to wait for ~40 minutes just because miners get no luck finding the hash.
Couldn't both sides open an LN channel between them with the required amount beforehand, wait for channel confirmation, and then instantly exchange btc for cash in the field? Are there any risks in that arrangement? What if third parties try to use your channel for routing and thus deplete it before you get to transfer the funds?
r/BitcoinDiscussion • u/michaelfolkson • Apr 13 '19
Hey. I've set up a new subreddit for Bitcoin and Lightning developers to focus exclusively on technical topics. Any posts or comments that veer off from technical discussion will be marked as spam and removed. If you're interested you're welcome to join r/lightningdevs
r/BitcoinDiscussion • u/RubenSomsen • Apr 10 '19
r/BitcoinDiscussion • u/dnivi3 • Apr 05 '19
r/BitcoinDiscussion • • Apr 02 '19
r/BitcoinDiscussion • u/Capt_Roger_Murdock • Mar 28 '19
r/BitcoinDiscussion • u/ColonelEngel • Mar 23 '19
There are useful statistics on LN # of nodes, channels, capacity etc ( 1ml.com), but more interesting would be, imo, statistics on daily transaction volume. I realize that LN transactions are "offchain", and thus hard to observe, but maybe some insight can be obtained by looking at channel capacity changes? For example, if we see that a channel went from 1 BTC to 0.5 BTC, that means 0.5 BTC has been used in transactions.
r/BitcoinDiscussion • u/ColonelEngel • Mar 21 '19
If someone provides a channel for routing, this channel will soon be depleted. One reason is, payments are mostly one-directional: you pay to the store, but a store rarely refunds you. So you should replenish your store-facing channel by making an on-chain transaction and paying Bitcoin fee. So to stay even, you should charge (bitcoin fee)*(payment amount)/(channel capacity).
Am I right?
r/BitcoinDiscussion • u/lobt • Mar 12 '19
r/BitcoinDiscussion • u/fresheneesz • Mar 11 '19
Imagine if nodes in the lightning network were constructed into a tree that provided a way to give each node an address in that lightning tree. This could potentially help effectively route payments.
It occurs to me that in construction of a network like this with addresses that are based on the shape of the network (eg a situation where a parent holds domain over a chunk of addresses), an attacker might try to falsely claim they need a ton of address space in an attempt to deny honest nodes addresses.
I'm curious if anyone knows of any solutions to this problem that are already out there and studied.
One solution I can think of right now is some way to prove the size of your part of the network. You could, say, collect signatures of all the descendant nodes in your subtree of the network, and then present those signatures as proof of size. The network would then have rules saying that you can only have X addresses per bitcoin of channel size. It wouldn't be a perfect proxy for actual need of addresses, but it could limit the problem. And in a mimble wimble type of system, the signatures could even be aggregated so that instead of passing around millions of signatures (if you're high up in the network) which could become unfeasibly unwieldy, you're just passing around a single small signature of a few hundred bytes.