Bitcoin Forum
October 17, 2018, 02:21:08 AM *
News: Make sure you are not using versions of Bitcoin Core other than 0.17.0 [Torrent], 0.16.3, 0.15.2, or 0.14.3. More info.
 
   Home   Help Search Donate Login Register  
Pages: [1]
  Print  
Author Topic: How to judge illegal transactions?  (Read 980 times)
stdo
Newbie
*
Offline Offline

Activity: 7
Merit: 0


View Profile
August 26, 2017, 02:15:08 PM
 #1

I wonder how the bitcoin protocol judge illegal transactions. As they say, the miner will look throughout the public ledger to make sure the transaction is alright. There are thousands of transactions in each block, if the miner has to check throughout the public ledger for each transaction, this would be very inefficient.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1539742868
Hero Member
*
Offline Offline

Posts: 1539742868

View Profile Personal Message (Offline)

Ignore
1539742868
Reply with quote  #2

1539742868
Report to moderator
aleksej996
Sr. Member
****
Offline Offline

Activity: 420
Merit: 311


Do not trust the government


View Profile WWW
August 26, 2017, 04:29:06 PM
 #2

You really just need to look for transactions that you would include in blocks, the highest fee ones. Miners already look through all the transactions, that is how they know which are the highest fee onces. They even check if their parent transaction is not confirmed and if they both average out at a high enough fee and so on for their parent's parent transaction, hence the Child-pay-for-parent method of getting your transactions confirmed.

There would also be no real way of forcing miners to check for legality of transactions, since miners can be anonymous, just like other Bitcoin users.

░░░░░░░▄▄▄▄▄▄
░░░░▄██████████▄
░░░██████████████
░░██████▐▌██████
█████░░░░░░░▀█████
██████▄▄░░▄▄░░██████
████████░░▀▀▄██████
████████░░▄▄▄░░█████
██████▀▀░░▀▀▀░░█████
█████░░░░░░░░█████
░░██████▐▌██████
░░░██████████████
░░░░▀██████████▀
░░░░░░░▀▀▀▀▀▀
░░░

                   BitCloak Bitcoin Mixer  
  BTC & BCH | API| MULTIADDRESS| PGP PROOF|  FAST MIX |  ESCROW|  MORE !

░░░░░░░▄▄▄▄▄▄
░░░░▄██████████▄
░░░██████████████
░░██████▐▌██████
█████░░░░░░░▀█████
██████▄▄░░▄▄░░██████
████████░░▀▀▄██████
████████░░▄▄▄░░█████
██████▀▀░░▀▀▀░░█████
█████░░░░░░░░█████
░░██████▐▌██████
░░░██████████████
░░░░▀██████████▀
░░░░░░░▀▀▀▀▀▀
░░░

achow101
Moderator
Legendary
*
expert
Offline Offline

Activity: 1554
Merit: 1701


3F1Y9yquzvY6RWvKbw2n2zeo9V5mvBhADU


View Profile WWW
August 26, 2017, 04:32:24 PM
 #3

Every single full node (not just miners) fully verifies every single transaction it receives. It does the same for every block. Since blocks and transactions can be mostly validated in parallel, it really isn't all that slow. Furthermore, the entire blockchain is not rechecked for every block, nor does it need to be rescanned for every block. Node software has more efficient ways of checking up transaction by storing various data separately, e.g. maintaining a separate database for the UTXO set which is used for checking transaction validity. Furthermore transactions in new blocks don't need to be revalidated if you have already seen them in your mempool. So that saves validation time as well.

zertsekel
Newbie
*
Offline Offline

Activity: 18
Merit: 0


View Profile
August 26, 2017, 04:40:05 PM
 #4

I wonder if Bitcoin Core, when first installed, rechecks **all** the transactions from the genesis block...
Does anyone know?
aleksej996
Sr. Member
****
Offline Offline

Activity: 420
Merit: 311


Do not trust the government


View Profile WWW
August 26, 2017, 04:46:54 PM
 #5

I wonder if Bitcoin Core, when first installed, rechecks **all** the transactions from the genesis block...
Does anyone know?

Yes. It does it while it is downloading them.

░░░░░░░▄▄▄▄▄▄
░░░░▄██████████▄
░░░██████████████
░░██████▐▌██████
█████░░░░░░░▀█████
██████▄▄░░▄▄░░██████
████████░░▀▀▄██████
████████░░▄▄▄░░█████
██████▀▀░░▀▀▀░░█████
█████░░░░░░░░█████
░░██████▐▌██████
░░░██████████████
░░░░▀██████████▀
░░░░░░░▀▀▀▀▀▀
░░░

                   BitCloak Bitcoin Mixer  
  BTC & BCH | API| MULTIADDRESS| PGP PROOF|  FAST MIX |  ESCROW|  MORE !

░░░░░░░▄▄▄▄▄▄
░░░░▄██████████▄
░░░██████████████
░░██████▐▌██████
█████░░░░░░░▀█████
██████▄▄░░▄▄░░██████
████████░░▀▀▄██████
████████░░▄▄▄░░█████
██████▀▀░░▀▀▀░░█████
█████░░░░░░░░█████
░░██████▐▌██████
░░░██████████████
░░░░▀██████████▀
░░░░░░░▀▀▀▀▀▀
░░░

zertsekel
Newbie
*
Offline Offline

Activity: 18
Merit: 0


View Profile
August 26, 2017, 04:55:53 PM
 #6

I wonder if Bitcoin Core, when first installed, rechecks **all** the transactions from the genesis block...
Does anyone know?

Yes. It does it while it is downloading them.

What if I download the Bitcoin Blockchain via torrent?
Do all the pre-existing transactions get checked as well?
aleksej996
Sr. Member
****
Offline Offline

Activity: 420
Merit: 311


Do not trust the government


View Profile WWW
August 26, 2017, 05:04:12 PM
 #7

I think only the last couple of them. Maybe if you don't download the chainstate files then it will have to in order to generate them. otherwise with downloading a whole data directory, I think only a couple of last ones.

There isn't really a benefit of downloading from a torrent, just a risk. Bitcoin is already peer to peer so downloading a blockchain is already like a torrent, it is just slower because it checks them. Maybe there is even an option for Bitcoin Core not to check them while downloading so you get the same effect, but maybe still safer, since you get it from the network and not just some guy.

░░░░░░░▄▄▄▄▄▄
░░░░▄██████████▄
░░░██████████████
░░██████▐▌██████
█████░░░░░░░▀█████
██████▄▄░░▄▄░░██████
████████░░▀▀▄██████
████████░░▄▄▄░░█████
██████▀▀░░▀▀▀░░█████
█████░░░░░░░░█████
░░██████▐▌██████
░░░██████████████
░░░░▀██████████▀
░░░░░░░▀▀▀▀▀▀
░░░

                   BitCloak Bitcoin Mixer  
  BTC & BCH | API| MULTIADDRESS| PGP PROOF|  FAST MIX |  ESCROW|  MORE !

░░░░░░░▄▄▄▄▄▄
░░░░▄██████████▄
░░░██████████████
░░██████▐▌██████
█████░░░░░░░▀█████
██████▄▄░░▄▄░░██████
████████░░▀▀▄██████
████████░░▄▄▄░░█████
██████▀▀░░▀▀▀░░█████
█████░░░░░░░░█████
░░██████▐▌██████
░░░██████████████
░░░░▀██████████▀
░░░░░░░▀▀▀▀▀▀
░░░

zertsekel
Newbie
*
Offline Offline

Activity: 18
Merit: 0


View Profile
August 26, 2017, 05:16:25 PM
 #8

I think there is a bitcoin daemon configuration flag that enables to "trust" pre-existing blocks... Not sure though...
achow101
Moderator
Legendary
*
expert
Offline Offline

Activity: 1554
Merit: 1701


3F1Y9yquzvY6RWvKbw2n2zeo9V5mvBhADU


View Profile WWW
August 26, 2017, 05:24:14 PM
 #9

What if I download the Bitcoin Blockchain via torrent?
Do all the pre-existing transactions get checked as well?
Yes. It will check all transactions and blocks it knows of. If a transaction is in a block that has a specific descendant block (the assumevalid block), then signatures are not checked. Everything else is still checked. Note that using the bootstrap.dat torrent will be slower than syncing from p2p.

HeroC
Legendary
*
Offline Offline

Activity: 862
Merit: 1000


GPG: FA122C1A | IRC: HeroCC


View Profile WWW
August 26, 2017, 05:26:50 PM
 #10

I think there is a bitcoin daemon configuration flag that enables to "trust" pre-existing blocks... Not sure though...

Not sure why you'd need to use it, syncing is much faster now and verifying transactions doesn't take that much CPU power.
luv2drnkbr
Hero Member
*****
Offline Offline

Activity: 796
Merit: 1000



View Profile
August 28, 2017, 11:04:46 PM
 #11

I wonder how the bitcoin protocol judge illegal transactions. As they say, the miner will look throughout the public ledger to make sure the transaction is alright. There are thousands of transactions in each block, if the miner has to check throughout the public ledger for each transaction, this would be very inefficient.

Every full node does this.  That's why syncing takes forever.  Yes, it's inefficient.  But it's also the only way we know how to have such a system operate.

AGD
Legendary
*
Offline Offline

Activity: 1703
Merit: 1026


HODLER SINCE 2013


View Profile
September 08, 2017, 11:13:21 AM
 #12

I wonder how the bitcoin protocol judge illegal transactions. As they say, the miner will look throughout the public ledger to make sure the transaction is alright. There are thousands of transactions in each block, if the miner has to check throughout the public ledger for each transaction, this would be very inefficient.

There are valid inputs and valid (because authorized by a signature of a private key) outputs. There is no need to check the whole public ledger (blockchain). If an address had no valid (like illegal) input, there will be a balance of 0. If the address had a valid input, which already was confirmed by the network, it can be spent by signing with the private key.

Bitcoin is not a bubble, it's the pin!
+++ GPG Public key FFBD756C24B54962E6A772EA1C680D74DB714D40 +++ http://pgp.mit.edu/pks/lookup?op=get&search=0x1C680D74DB714D40
jal007
Full Member
***
Offline Offline

Activity: 141
Merit: 100


View Profile
September 08, 2017, 04:29:28 PM
 #13

you should learn about blockchain and how transactions are saved there
Syke
Legendary
*
Offline Offline

Activity: 2744
Merit: 1019


View Profile
September 08, 2017, 07:40:15 PM
 #14

I wonder how the bitcoin protocol judge illegal transactions. As they say, the miner will look throughout the public ledger to make sure the transaction is alright. There are thousands of transactions in each block, if the miner has to check throughout the public ledger for each transaction, this would be very inefficient.

What would you rather have, inefficiency or inaccuracy for a monetary system?

Buy & Hold
Pages: [1]
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!