Bitcoin Forum
December 14, 2024, 09:48:41 PM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: How the Blockchain works exactly ?  (Read 657 times)
OmegaStarScream (OP)
Staff
Legendary
*
Offline Offline

Activity: 3696
Merit: 6539



View Profile
February 23, 2016, 05:34:13 PM
 #1

I'm about to create a Bitcoin-related project (Decentralized) and I need some information's about everything related to the Blockchain technology (technical part mostly) . I will start and please correct me when I'm wrong and answer me when I ask a question Smiley

So basically , I know that each one of us have the Blockchain on his PC (unless you are using a Lightweight wallet) , once a transaction is made information's are added to the blockchain file (TXID , amount ,receiver , sender ) , right ?
Now what I don't understand , how I'm getting the blockchain and how other people are getting it as-well ? I mean from where the Bitcoin core is downloading it exactly ? Is there is direct link of it which I suppose there isn't  ?

If I made the transaction and information's are going to my local version of the blockchain , how the other people will get it ?  Huh It's kinda confusing when you really think of it at least this is how I see it .
I'd appreciate any deep explanation concerning this please , Project is this : https://bitcointalk.org/index.php?topic=1317201.0


I decided to make it Decentralized like some people asked me since no one would trust a Centralized database , right?

█▀▀▀











█▄▄▄
▀▀▀▀▀▀▀▀▀▀▀
e
▄▄▄▄▄▄▄▄▄▄▄
█████████████
████████████▄███
██▐███████▄█████▀
█████████▄████▀
███▐████▄███▀
████▐██████▀
█████▀█████
███████████▄
████████████▄
██▄█████▀█████▄
▄█████████▀█████▀
███████████▀██▀
████▀█████████
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
c.h.
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀█











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
Joel_Jantsen
Legendary
*
Offline Offline

Activity: 2072
Merit: 1353


Top-tier crypto casino and sportsbook


View Profile
February 23, 2016, 05:38:58 PM
 #2

How are you approaching towards the application ? Setting up the development environment ? I would be interested in knowing.For now
Quote
A blockchain in all it’s incarnations is a database type designed specifically for use in a DCN. It can hold any information, and can set rules on how information is updated. Its primary feature is that it is updated in discrete chunks called ‘blocks’ which are ‘chained’ together using hashes of the previous blocks content. A blockchain contains not only the information that is currently stored in the database, but also every change made to the database in its history. Known as the state and transactions respectively it makes for a database with a complete custodial history that cannot be altered without altering every subsequent block. A private key always signs ‘Transactions’ or requests to change the state of the database, and the signature is stored in the blockchain.

Source : https://dappsforbeginners.wordpress.com/tutorials/introduction-to-development-on-ethereum/

OmegaStarScream (OP)
Staff
Legendary
*
Offline Offline

Activity: 3696
Merit: 6539



View Profile
February 23, 2016, 05:42:51 PM
 #3

How are you approaching towards the application ? Setting up the development environment ? I would be interested in knowing.For now
Quote
A blockchain in all it’s incarnations is a database type designed specifically for use in a DCN. It can hold any information, and can set rules on how information is updated. Its primary feature is that it is updated in discrete chunks called ‘blocks’ which are ‘chained’ together using hashes of the previous blocks content. A blockchain contains not only the information that is currently stored in the database, but also every change made to the database in its history. Known as the state and transactions respectively it makes for a database with a complete custodial history that cannot be altered without altering every subsequent block. A private key always signs ‘Transactions’ or requests to change the state of the database, and the signature is stored in the blockchain.

Source : https://dappsforbeginners.wordpress.com/tutorials/introduction-to-development-on-ethereum/

I know it's some kind of databse but that still doesn't answer my question honestly . and I didn't really go deep into it , I'm thinking about how I'm going to make everything then start building up instead of starting then  get stuck .
also I'm asking about the concepts how the data are getting transfered etc ... I may not use the blockchain itself .

█▀▀▀











█▄▄▄
▀▀▀▀▀▀▀▀▀▀▀
e
▄▄▄▄▄▄▄▄▄▄▄
█████████████
████████████▄███
██▐███████▄█████▀
█████████▄████▀
███▐████▄███▀
████▐██████▀
█████▀█████
███████████▄
████████████▄
██▄█████▀█████▄
▄█████████▀█████▀
███████████▀██▀
████▀█████████
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
c.h.
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀█











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
tyz
Legendary
*
Offline Offline

Activity: 3360
Merit: 1533



View Profile
February 23, 2016, 05:49:13 PM
 #4

Well, you need to understand the decentralized peer-to-peer concept first then you could answer your question by yourself.
Each wallet is a client. If you connect with the internet , it uses a given list (often called node list) what is part of your wallet and tries to connect to one or more nodes of this list. If it connects to one or more nodes then you share your client IP with all those connected nodes. Now the other client nodes know that you are part of the network. If a other client connects to one of the nodes too, then it shares your IP and so one.

Good article where p2p networks are explained.
http://www.makeuseof.com/tag/p2p-peer-peer-file-sharing-works/
achow101
Staff
Legendary
*
Offline Offline

Activity: 3570
Merit: 6927


Just writing some code


View Profile WWW
February 23, 2016, 10:04:46 PM
 #5

There are two things that you are discussing here, the Bitcoin peer-to-peer network and the blockchain.

The way the p2p network works is that every block and every transaction is sent throughout the network in a flood. Every node on the network connects to several other nodes. This spreads out into a large network of nodes connected to each other. One node broadcasts a transaction or a block. Then all of its peers receive that block or transaction, validates it, and if it passes, that node relays it to all of its peers. So on and so forth so that every single node in the network has received every transaction and every block. Every node receives every transaction even if it doesn't care about that transaction.

The blockchain is different. The blockchain is a data structure made up of blocks. Blocks are data structures which contain the transactions. There is an 80 byte header which contains the version number, the timestamp, the previous block's hash, the merkle root (hash) of all of the transactions in the block and probably something else that I am forgetting. The rest of the block is just the raw data of the transactions included in that block. The blockchain is the collection of all of those blocks in order. They are ordered by the field in the header for the previous block. Since it includes the previous block's hash in the header, this links the blocks together in a chain, one had to have come before the other. This is what makes up the blockchain.

Hope this helps.

OmegaStarScream (OP)
Staff
Legendary
*
Offline Offline

Activity: 3696
Merit: 6539



View Profile
February 24, 2016, 07:28:43 AM
 #6

There are two things that you are discussing here, the Bitcoin peer-to-peer network and the blockchain.

The way the p2p network works is that every block and every transaction is sent throughout the network in a flood. Every node on the network connects to several other nodes. This spreads out into a large network of nodes connected to each other. One node broadcasts a transaction or a block. Then all of its peers receive that block or transaction, validates it, and if it passes, that node relays it to all of its peers. So on and so forth so that every single node in the network has received every transaction and every block. Every node receives every transaction even if it doesn't care about that transaction.

The blockchain is different. The blockchain is a data structure made up of blocks. Blocks are data structures which contain the transactions. There is an 80 byte header which contains the version number, the timestamp, the previous block's hash, the merkle root (hash) of all of the transactions in the block and probably something else that I am forgetting. The rest of the block is just the raw data of the transactions included in that block. The blockchain is the collection of all of those blocks in order. They are ordered by the field in the header for the previous block. Since it includes the previous block's hash in the header, this links the blocks together in a chain, one had to have come before the other. This is what makes up the blockchain.

Hope this helps.

For what comes to the peer-to-peer part , does it when when I make a transaction and it gets added to the blockchain , I will also send it to other people ? just like Windows 10 do updates ? It take the updates from people instead from a centralized Microsoft server ?
one more thing , do you have an idea how the password exactly works and what encryption is used ? I mean the password is stored where ? on the wallet.dat and encrypted using what algorithm ? and is it added to the wallet.dat once you setup the password ? I'm sorry if I'm bothering you with my silly questions btw , just need to know nthis stuff.  Smiley

█▀▀▀











█▄▄▄
▀▀▀▀▀▀▀▀▀▀▀
e
▄▄▄▄▄▄▄▄▄▄▄
█████████████
████████████▄███
██▐███████▄█████▀
█████████▄████▀
███▐████▄███▀
████▐██████▀
█████▀█████
███████████▄
████████████▄
██▄█████▀█████▄
▄█████████▀█████▀
███████████▀██▀
████▀█████████
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
c.h.
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀█











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
n0ne
Hero Member
*****
Offline Offline

Activity: 2646
Merit: 548


DGbet.fun - Crypto Sportsbook


View Profile WWW
February 24, 2016, 01:12:16 PM
 #7

It works by the process of getting registered in a common registry. This database can be accessed by anyone located over the next end. It works as a interconnective programming by which you can get access of transactions as well the real time database of the registered user.

CryptoGore
Full Member
***
Offline Offline

Activity: 181
Merit: 100

Bitflipy.com - $$_Flip your lucky coin_$$


View Profile WWW
February 24, 2016, 01:45:36 PM
 #8

I've never heard of the blockchain before. What exactly is it?
If you're not familiar with the blockchain, and it's still a relatively new concept in the world of electronic finance, you no doubt will have heard of Bitcoin. Bitcoin is a a peer-to-peer electronic cash system, also known as "cryptocurrency", which basically allows people to make instant, anonymous transactions online.

However, Bitcoin records every single transaction made on its network in a public record. This is known as the "blockchain".

How does Bitcoin work?
Bitcoins have to be "mined" using specialist mining software, which then carries out a series of intensive calculations to find a certain data sequence, or "block". The block produces a specific data pattern when the Bitcoin "hash" algorithm is applied to the data. Whoever manages to do this will basically win bitcoins, which they can then spend in a range of places online and off.

So how often is the blockchain added to?
A new blockchain is generated around every ten minutes and then shared throughout the network. This means it's constantly growing as completed "blocks" are made and added to the public ledger.

How many "blocks" exist on the blockchain?
There is a countless number of blocks on the blockchain at any one time -- as soon as one block gets completed, another is automatically generated.

So it's a bit like the way conventional banks have a full history of its customers' transactions?
Exactly. All Bitcoin transactions are entered chronologically in a blockchain, similarly to how typical bank transactions are recorded. You can think of the different blocks, then, like individual bank statements.

Can Bitcoin transactions be traced easily on the blockchain?
Yes. All the blocks are added to the blockchain in a linear, sequential order. Each block contains a hash of the previous block, creating a linked series from the "genesis" block right the way through to the current one. As every Bitcoin user must have a Bitcoin address -- a unique identifier that allows them to receive Bitcoins -- the blockchain contains a complete set of information about every address using Bitcoin and their balances at any point in history.

So how do you keep track of all your bitcoins?
You'll basically need something called a Bitcoin wallet: a free online wallet which you can use to make worldwide Bitcoin payments on your mobile or desktop.


source: http://www.wired.co.uk/news/archive/2015-07/01/simple-guide-to-the-blockchain

▄ ▀ ▄ ▀   BTC FLIP YOUR LUCKY COIN BTC Free credit signup BTC WWW.BITFLIPY.COM BTC  ▄ ▀ ▄ ▀
●▬●▬●▬●▬●▬●▬●▬●▬●▬●▬●   BitFlipy.com   ●▬●▬●▬●▬●▬●▬●▬●▬●▬●▬●
▄ ▀ ▄ ▀  OFFICIAL THREAD   ▄ ▀ ▄ ▀
achow101
Staff
Legendary
*
Offline Offline

Activity: 3570
Merit: 6927


Just writing some code


View Profile WWW
February 24, 2016, 02:59:53 PM
 #9

For what comes to the peer-to-peer part , does it when when I make a transaction and it gets added to the blockchain , I will also send it to other people ? just like Windows 10 do updates ? It take the updates from people instead from a centralized Microsoft server ?
When you make a transaction, your node sends it to every peer it is connected to. So yes, your analogy kind of works, except that the updates come from everyone.

one more thing , do you have an idea how the password exactly works and what encryption is used ? I mean the password is stored where ? on the wallet.dat and encrypted using what algorithm ? and is it added to the wallet.dat once you setup the password ?
The password is local and client specific. In bitcoin core, the password is hashed and manipulated a couple times to generate an encryption key. The wallet is then encrypted with AES-256 with that encryption key. I don't think any form of the password is actually kept in the wallet.


'm sorry if I'm bothering you with my silly questions btw , just need to know nthis stuff.  Smiley
No problem. I'm happy to help.

OmegaStarScream (OP)
Staff
Legendary
*
Offline Offline

Activity: 3696
Merit: 6539



View Profile
February 24, 2016, 04:06:59 PM
 #10

For what comes to the peer-to-peer part , does it when when I make a transaction and it gets added to the blockchain , I will also send it to other people ? just like Windows 10 do updates ? It take the updates from people instead from a centralized Microsoft server ?
When you make a transaction, your node sends it to every peer it is connected to. So yes, your analogy kind of works, except that the updates come from everyone.

one more thing , do you have an idea how the password exactly works and what encryption is used ? I mean the password is stored where ? on the wallet.dat and encrypted using what algorithm ? and is it added to the wallet.dat once you setup the password ?
The password is local and client specific. In bitcoin core, the password is hashed and manipulated a couple times to generate an encryption key. The wallet is then encrypted with AES-256 with that encryption key. I don't think any form of the password is actually kept in the wallet.


'm sorry if I'm bothering you with my silly questions btw , just need to know nthis stuff.  Smiley
No problem. I'm happy to help.

Everything seems crystal clear now , thank you so much .
One more question now ,you said the node sends it to every peer it is connected to , does it mean that every bitcoin user on the world is connected ? Same thing goes for Lightweight wallets & web wallets ?

█▀▀▀











█▄▄▄
▀▀▀▀▀▀▀▀▀▀▀
e
▄▄▄▄▄▄▄▄▄▄▄
█████████████
████████████▄███
██▐███████▄█████▀
█████████▄████▀
███▐████▄███▀
████▐██████▀
█████▀█████
███████████▄
████████████▄
██▄█████▀█████▄
▄█████████▀█████▀
███████████▀██▀
████▀█████████
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
c.h.
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀█











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
achow101
Staff
Legendary
*
Offline Offline

Activity: 3570
Merit: 6927


Just writing some code


View Profile WWW
February 24, 2016, 04:40:59 PM
 #11


Everything seems crystal clear now , thank you so much .
One more question now ,you said the node sends it to every peer it is connected to , does it mean that every bitcoin user on the world is connected ? Same thing goes for Lightweight wallets & web wallets ?
Yes. Any node, both full and SPV, are indirectly connected to every other node on the network.

Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!