Bitcoin Forum
September 27, 2018, 11:25:59 PM *
News: ♦♦ New info! Bitcoin Core users absolutely must upgrade to previously-announced 0.16.3 [Torrent]. All Bitcoin users should temporarily trust confirmations slightly less. More info.
 
   Home   Help Search Donate Login Register  
Pages: [1]
  Print  
Author Topic: How to detect double spending?  (Read 1858 times)
myohmy81
Sr. Member
****
Offline Offline

Activity: 271
Merit: 250


www.secondstrade.com - 190% return Binary option


View Profile
March 19, 2015, 08:12:43 AM
 #1

Hi everyone  Grin

i have a question

How to detect double spending?

I think
Some site detecting double spending (etc luckybit or satoshibones)

Because they give it a reward for betting 0 confirm transaction

help me buddy


1538090759
Hero Member
*
Offline Offline

Posts: 1538090759

View Profile Personal Message (Offline)

Ignore
1538090759
Reply with quote  #2

1538090759
Report to moderator
1538090759
Hero Member
*
Offline Offline

Posts: 1538090759

View Profile Personal Message (Offline)

Ignore
1538090759
Reply with quote  #2

1538090759
Report to moderator
1538090759
Hero Member
*
Offline Offline

Posts: 1538090759

View Profile Personal Message (Offline)

Ignore
1538090759
Reply with quote  #2

1538090759
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1538090759
Hero Member
*
Offline Offline

Posts: 1538090759

View Profile Personal Message (Offline)

Ignore
1538090759
Reply with quote  #2

1538090759
Report to moderator
nuno12345
Sr. Member
****
Offline Offline

Activity: 275
Merit: 250


View Profile
March 19, 2015, 02:12:56 PM
 #2

There is no bullet proof way but you can prevent them with some techniques.
1-Check for transaction fee, if 0 and amount is small, assume its a double spend.
2-Use some service like blocktrail and check the double_spend flag (not working in some cases).
3-If its eg. gambling related, accept 0 confs and allow the user to gamble, but only withdraw after the minconfs.
3-Implement your own double spend prevention, assuming your running a full node+rpc:
3a-After you get the desired tx start a loop of lets say 1min.
3b-Use getrawmempool and grab every transaction in the mem pool.
3c-Parse each transaction and check if any of the VIN's matches your original transaction VIN.
3d-If after 1min no other transactions match the VIN, you can say its not a double spend.

With any of the above methods your still vulnerable to finney attacks (blockchain forks) and some race attacks, but your dramatically reduce your chances of getting attacked.

Hope this helps.

lophie
Hero Member
*****
Offline Offline

Activity: 924
Merit: 1000

Unlimited Free Crypto


View Profile
March 19, 2015, 02:35:25 PM
 #3

There is no bullet proof way but you can prevent them with some techniques.
1-Check for transaction fee, if 0 and amount is small, assume its a double spend.
2-Use some service like blocktrail and check the double_spend flag (not working in some cases).
3-If its eg. gambling related, accept 0 confs and allow the user to gamble, but only withdraw after the minconfs.
3-Implement your own double spend prevention, assuming your running a full node+rpc:
3a-After you get the desired tx start a loop of lets say 1min.
3b-Use getrawmempool and grab every transaction in the mem pool.
3c-Parse each transaction and check if any of the VIN's matches your original transaction VIN.
3d-If after 1min no other transactions match the VIN, you can say its not a double spend.

With any of the above methods your still vulnerable to finney attacks (blockchain forks) and some race attacks, but your dramatically reduce your chances of getting attacked.

Hope this helps.

A successful double spend of $10000 happened hours during the hard fork of v0.8 (or was it v0.6). The right answer is never detailed in my opinion. The right answer should be "It depends on how big the amount is and what state the network is". Relative security is the ultimate answer.... relative security.

Currently even for significantly large amounts the majorty would trust 3 confirmations not to be double spent.

Will take me a while to climb up again, But where is a will, there is a way...
Muhammed Zakir
Hero Member
*****
Offline Offline

Activity: 560
Merit: 504


I prefer Zakir over Muhammed when mentioning me!


View Profile WWW
March 19, 2015, 05:21:50 PM
 #4

AFAIK check whether input(s) of transaction you received is really UTXO(s) i.e. check whether input of the transaction is spent in another transaction. If yes, then second transaction is a double spend.

Transactions which got 1 confirmation is hard to double spend but as a matter of security, atleast 2 confirmation for deposits is recommended.

redsn0w
Legendary
*
Offline Offline

Activity: 1540
Merit: 1019


#Free market


View Profile
March 19, 2015, 05:31:33 PM
 #5

AFAIK check whether input(s) of transaction you received is really UTXO(s) i.e. check whether input of the transaction is spent in another transaction. If yes, then second transaction is a double spend.

Transactions which got 1 confirmation is hard to double spend but as a matter of security, atleast 2 confirmation for deposits is recommended.

Second or first , it depends of how much fee will you put in those transactions. If you want to "play" or better do some double spend, try this site : http://gangsta.strangled.net/  (create new addresses, don't use your personal bitcoin daily address).
Muhammed Zakir
Hero Member
*****
Offline Offline

Activity: 560
Merit: 504


I prefer Zakir over Muhammed when mentioning me!


View Profile WWW
March 19, 2015, 05:47:35 PM
 #6

Second or first , it depends of how much fee will you put in those transactions. If you want to "play" or better do some double spend, try this site : http://gangsta.strangled.net/  (create new addresses, don't use your personal bitcoin daily address).

My bad! Thank you!

I didn't know about that site but I don't like importing keys to such walllets, so bitundo.com is doing a better job except for Brand New members.

myohmy81
Sr. Member
****
Offline Offline

Activity: 271
Merit: 250


www.secondstrade.com - 190% return Binary option


View Profile
March 20, 2015, 12:55:37 AM
 #7

There is no bullet proof way but you can prevent them with some techniques.
1-Check for transaction fee, if 0 and amount is small, assume its a double spend.
2-Use some service like blocktrail and check the double_spend flag (not working in some cases).
3-If its eg. gambling related, accept 0 confs and allow the user to gamble, but only withdraw after the minconfs.
3-Implement your own double spend prevention, assuming your running a full node+rpc:
3a-After you get the desired tx start a loop of lets say 1min.
3b-Use getrawmempool and grab every transaction in the mem pool.
3c-Parse each transaction and check if any of the VIN's matches your original transaction VIN.
3d-If after 1min no other transactions match the VIN, you can say its not a double spend.

With any of the above methods your still vulnerable to finney attacks (blockchain forks) and some race attacks, but your dramatically reduce your chances of getting attacked.

Hope this helps.

Really thanks buddy Smiley

myohmy81
Sr. Member
****
Offline Offline

Activity: 271
Merit: 250


www.secondstrade.com - 190% return Binary option


View Profile
March 20, 2015, 01:00:24 AM
 #8

AFAIK check whether input(s) of transaction you received is really UTXO(s) i.e. check whether input of the transaction is spent in another transaction. If yes, then second transaction is a double spend.

Transactions which got 1 confirmation is hard to double spend but as a matter of security, atleast 2 confirmation for deposits is recommended.

Really Thanks very much Smiley

gdassori
Hero Member
*****
Offline Offline

Activity: 938
Merit: 1000



View Profile
May 18, 2015, 08:30:20 PM
 #9

Second or first , it depends of how much fee will you put in those transactions. If you want to "play" or better do some double spend, try this site : http://gangsta.strangled.net/  (create new addresses, don't use your personal bitcoin daily address).

My bad! Thank you!

I didn't know about that site but I don't like importing keys to such walllets, so bitundo.com is doing a better job except for Brand New members.

hi, developer here, keys are imported client side and never exposed, code is open.
also, you can download the source from github (https://github.com/gdassori/gangsta) and run it locally, since the hosted version could be compromised.

as advised, the tool is unstable and just for playing, I'm not responsible if you, let's say, spend 1 BTC in fees because of software failure.


virtualx
Hero Member
*****
Offline Offline

Activity: 644
Merit: 500



View Profile
May 18, 2015, 10:06:56 PM
 #10

There is no bullet proof way but you can prevent them with some techniques.
1-Check for transaction fee, if 0 and amount is small, assume its a double spend.
2-Use some service like blocktrail and check the double_spend flag (not working in some cases).
3-If its eg. gambling related, accept 0 confs and allow the user to gamble, but only withdraw after the minconfs.
3-Implement your own double spend prevention, assuming your running a full node+rpc:
3a-After you get the desired tx start a loop of lets say 1min.
3b-Use getrawmempool and grab every transaction in the mem pool.
3c-Parse each transaction and check if any of the VIN's matches your original transaction VIN.
3d-If after 1min no other transactions match the VIN, you can say its not a double spend.

With any of the above methods your still vulnerable to finney attacks (blockchain forks) and some race attacks, but your dramatically reduce your chances of getting attacked.

Hope this helps.

Why is there no bullet proof way? What are the chances of getting attacked? What happens if it is a double spend? Huh

achow101_alt
Sr. Member
****
Offline Offline

Activity: 268
Merit: 250


View Profile
May 19, 2015, 12:23:45 AM
 #11

Why is there no bullet proof way? What are the chances of getting attacked? What happens if it is a double spend? Huh
There is no bullet proof way because anyone can send two transactions with the same inputs without anything stopping them.  The chances of being attacked depends on the person you are dealing with, and generally, accepting 0 confirmations with large transactions have a high risk of a double spend. If there is a double spend, either the seller sees that a double spend happened and doesn't send the goods, or the buyer gets the goods and keeps his money. The seller can protect himself by waiting for a couple confirmations to ensure that another transaction to double spend cannot be accepted by the network.

Tip Me!: 1AQx99s7q1wVinbgXbA48BaZQVWpHe5gYM | My PGP Key: Fingerprint 0x17565732E08E5E41
Troonetpt
Sr. Member
****
Offline Offline

Activity: 322
Merit: 250


View Profile
May 19, 2015, 01:44:32 PM
 #12

They is no way stop double spending if the confirmation less than 1. If we could, we can make the confirmation time to zero second.
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!