Home  >  Article  >  Does your Bitcoin really belong to you?

Does your Bitcoin really belong to you?

DDD
DDDforward
2024-03-06 13:30:281105browse

Currently, one Bitcoin is worth nearly 220,000 yuan. For newcomers who have just entered the circle, they must be very concerned about the security of Bitcoin.

So, is Bitcoin safe? In other words, are the Bitcoins in the wallet easily stolen by hackers?

01. Private key, public key, address

Just like bank withdrawals and online banking transfers that require entering passwords,use the bits in the wallet Coins also require a password, which is called a "private key."

The "private key" corresponds to the "public key", and the "public key" is like your bank account. Each bank account has a unique account number, which is also a bank card number. In the Bitcoin network, this bank card number is the "address". As long as others know your "bank card number" (i.e. address), they can transfer Bitcoin to you.

In a bank, the account opening process is basically "open a bank account - give the bank card number - set the bank card password - open the account successfully". But in the blockchain world, you first set a "password" (private key), then open a "bank account" (public key), and finally give the "bank card number" (address).

Does your Bitcoin really belong to you?

If you pick up a piece of paper on the road with only the bank card password written on it, but no bank card number, even this The bank card password is real, and you cannot withdraw the money in the related account.

But in the blockchain world, as long as you know someone else’s “bank card password” (private key), you can know someone else’s “bank account” (public key) and “bank card number” (address), you can withdraw the coins inside.

Why is this so?

This is because in the blockchain, the private key is encrypted to generate a public key, and the public key is converted into a format to generate an address. In other words, The private key can deduce the public key, and the public key can deduce the address.

02. Reverse derivation? no way!

Since "the private key can deduce the public key, and the public key can deduce the address", to use the Bitcoin in the account, you must enter the "password (private key)", Then the hacker has to To steal the Bitcoins in your wallet, you must and only need to get the "private key".

Does your Bitcoin really belong to you?

Theoretically, hackers have 2 ways to steal your private key:

1. Address/public key, reversely derive the private key.
2. Try the private keys one by one, which is brute force cracking.

The first method is not feasible because the encryption algorithm used by Bitcoin is "a slight error, a thousand miles difference!". If the input content is slightly changed even a little bit, the output results after encryption will be completely different from the previous output results, and these results have no rules to follow.

So, this encryption algorithm is "one-way" and "irreversible", and hackers cannot deduce the input (private key) from the output (address/public key).

03. How difficult is it to brute force a Bitcoin private key?

Since the first method is not feasible, what about the second method? Before answering this question, let's first look at how the private key is generated.

Suppose you toss a coin, heads up is 1, tails up is 0, toss 256 times in a row, record the result of each toss, and then convert it into a hexadecimal number, which is one Bitcoin private key.

What? So simple? So willful?

Yes, the private key of Bitcoin is randomly generated by "tossing a coin 256 times" through the program. Therefore, The essence of the Bitcoin private key is a 256-bit binary number.

Does your Bitcoin really belong to you?

Every time a coin is tossed, there are two sides, positive and negative, so tossing it 256 times, a total of "2 x 2 x2 x 2..." can appear. 2 x 2x2", that is, the multiplication of 256 2's, which is the result of "2 to the power of 256". So, the total number of Bitcoin private keys is theoretically "2 to the power of 256".

Note: The actual value of the total number of private keys is slightly lower than the theoretical value above because a small number of private keys are unavailable, but the impact on the total number is minimal.

How big is "2 to the power of 256"? It is approximately equal to "10 raised to the 77th power". So how big is "10 to the 77th power"?

If the oceans, rocks, and magma beneath the earth we live on were all filled with sand, the amount of sand on the entire earth would be approximately "10 to the 30th power." In other words, A planet as big as the earth and made entirely of sand would require "10 to the 30th power" of grains of sand.

Does your Bitcoin really belong to you?

"10 to the 77th power" is greater than "10 to the 30th power" "10 to the 47th power" Times, exactly 47 zeros. In a set of Bitcoin private keys that are "10 to the 47th power" times more than the amount of sand on the earth, trying one by one to decipher the private key corresponding to a certain address is simply more difficult than finding a needle in a haystack.

So, even if a hacker has a supercomputer, he cannot brute force crack the Bitcoin private key.

This is why many people say, "Bitcoin has guaranteed the sanctity of individual private property through technical means for the first time."

04. What if it was more powerful than a supercomputer?

Although no one can accurately predict how technology will develop in the future, if one day humans invent computers that are more powerful than supercomputers and quantum computers, wouldn’t the Bitcoin private key be unsafe? ?

Does your Bitcoin really belong to you?

Indeed, many people want to know whether quantum computers pose a threat to the security of Bitcoin. If there is a threat, Bitcoin has What measures can be taken.

Since this issue cannot be explained clearly in a few words, we will open a separate article to discuss this issue later, so stay tuned.

05. Conclusion

Of course, security issues not only involve technical issues, but also involve the storage of private keys. If your private key is stolen by hackers because your private key is improperly stored, or your computer is infected with a virus, or the wallet software you use has a vulnerability or backdoor, then the security of the Bitcoin in your wallet will be compromised. Talked about.

However, Bitcoin cannot be blamed for the theft of the private key due to his own mistakes, can it?

So, if someone uses the incident of Bitcoin theft to question the security of Bitcoin, how would you answer him? Welcome to leave a message in the message area.

The above is the detailed content of Does your Bitcoin really belong to you?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
This article is reproduced at:zhihu.com. If there is any infringement, please contact admin@php.cn delete