If i would like to send a number of my bitcoin to you, I publish my intention and also the nodes scan the complete bitcoin network to validate that!
1) To declare I have the bitcoin that I would like to send;
2) My Bitcoin balance haven’t already sent it to somebody else.
Once that info is confirmed, my dealing gets enclosed in an exceedingly “block” that gets hooked up to the previous block – therefore the term “blockchain.”
Transactions can’t be undone or tampered with, otherwise as a result it'd mean re-doing all the blocks that came after.
My bitcoin wallet doesn’t truly possess my bitcoin. What it will record is my bitcoin address, that keeps a record of all of my previous transactions, and so of my balance. This address – a protracted string of thirty four letters and numbers – is additionally called my “public key.” I don’t mind that the entire world will see these sequence. every address/public key includes a corresponding “private key” of sixty four letters and numbers. This is often personal, and it’s crucial that I keep it secret and safe. The 2 keys are connected, however there’s no method that you simply could comprehend my personal key from my public key.
That’s necessary, as a result of any transaction I issue from my Bitcoin address has to be “signed” with my personal key. To do that, I place each my personal key and also the sending details (how many Bitcoin or a fraction of I would like to send, and to whom I want to send) into the Bitcoin software or application on my pc or smartphone.
With this info, the program spits out a digital signature, that gets sent resolute to the network for validation.
The transaction can be validated – that's, it is confirmed I legit own the Bitcoin that i'm transferring to you, which I haven’t already sent it to some other person – by plugging the signature and my public key (which everybody on the network knows) into the Bitcoin program. This is often one in every of the genius components of Bitcoin: if the signature was created with the personal key that corresponds to it public key, the program can validate the dealings, while not knowing what the personal key's. That’s the brilliant part of Bitcoin.
The network then confirms that I haven’t antecedently spent the bitcoin by running through my address history, that it will do as a result of it is aware of my address (= my public key), and since all previous transactions are public on the Bitcoin ledger.
Once my transaction has been validate, it gets enclosed into a “block,” along side with a variety of different transactions.
A brief detour to debate what a “hash” is, as a result of it’s necessary for successive paragraph: a hash is created by a “hash function,” which is a complicated mathematics equation that reduces any number of text or data to 64-character string. It’s not random – on every occasion you set therein specific data set through the hash perform, you’ll get an equivalent 64-character string. However if you modify such a lot as a comma, you’ll get a very completely different 64-character string. This whole article might be reduced to a hash, and unless I modify, take away or add something to the text, a similar hash may be created again and again. This can be awfully effective way to tell if anything has been modified, and is how the blockchain will ensure that a transaction has not been tampered with.
Back to our blocks: every block includes as a part of its data, a hash of the previous block. That’s what makes it a part of a chain, therefore the term “blockchain.” So, if one little part of the previous block was tampered with, this block’s hash would ought to modification (remember that one little modification within the input of the hash data changes the output). Thus, if you wish to modify one thing within the previous block, you furthermore might ought to modify something (= the hash) within the current block, as a result of the one that's presently enclosed is not any longer correct. That’s terribly onerous to try to perform, particularly since by the time you’ve reached half way, it is most likely another block on prime of the current one. You’d then even have to modify that one as well and so on to the next.
This is what makes Bitcoin nearly tamper-proof. I say nearly because it’s not impossible, it's extremely difficult and therefore it is unlikely.
And if you wish to delight in some mindless fascination, you can sit in front of your PC and watch every single Bitcoin transactions float by. Blockchain.info are great in this, but if you wish a hypnotically fun version, visit BitBonkers to find out.