Bitcoin Forum

Bitcoin => Bitcoin Technical Support => Topic started by: yakuza699 on February 08, 2014, 02:48:29 PM



Title: Bitcoin protocol changed?
Post by: yakuza699 on February 08, 2014, 02:48:29 PM
Hello all, i have question about bitcoin protocol today i did a transaction of 0.011+btc using brainwallet.com (raw transaction) and then i tried to do another transaction using same inputs but i failed it sayed An outpoint is already spent [(112121274, 1)] but i remember that i was able to do second transaction simply in the past (qt 0.8.5 time) so did bitcoin protocol changed or what tell me how to the second transaction using same inputs as before in the previous transaction.


Title: Re: Bitcoin protocol changed?
Post by: leancuisine on February 08, 2014, 08:21:31 PM
Hello all, i have question about bitcoin protocol today i did a transaction of 0.011+btc using brainwallet.com (raw transaction) and then i tried to do another transaction using same inputs but i failed it sayed An outpoint is already spent [(112121274, 1)] but i remember that i was able to do second transaction simply in the past (qt 0.8.5 time) so did bitcoin protocol changed or what tell me how to the second transaction using same inputs as before in the previous transaction.
Same inputs? If you used all of the inputs before in the first transaction, isn't that a double spend? :P


Title: Re: Bitcoin protocol changed?
Post by: byt411 on February 08, 2014, 08:34:03 PM
Hello all, i have question about bitcoin protocol today i did a transaction of 0.011+btc using brainwallet.com (raw transaction) and then i tried to do another transaction using same inputs but i failed it sayed An outpoint is already spent [(112121274, 1)] but i remember that i was able to do second transaction simply in the past (qt 0.8.5 time) so did bitcoin protocol changed or what tell me how to the second transaction using same inputs as before in the previous transaction.
Same inputs? If you used all of the inputs before in the first transaction, isn't that a double spend? :P

It IS a double spend. The BitCoin protocol hasn't changed, it's you being dumb and double spending without realizing it.


Title: Re: Bitcoin protocol changed?
Post by: leancuisine on February 08, 2014, 08:46:18 PM
Hello all, i have question about bitcoin protocol today i did a transaction of 0.011+btc using brainwallet.com (raw transaction) and then i tried to do another transaction using same inputs but i failed it sayed An outpoint is already spent [(112121274, 1)] but i remember that i was able to do second transaction simply in the past (qt 0.8.5 time) so did bitcoin protocol changed or what tell me how to the second transaction using same inputs as before in the previous transaction.
Same inputs? If you used all of the inputs before in the first transaction, isn't that a double spend? :P

It IS a double spend. The BitCoin protocol hasn't changed, it's you being dumb and double spending without realizing it.
It wasn't me, it was yakuza699.  :D


Title: Re: Bitcoin protocol changed?
Post by: byt411 on February 08, 2014, 11:17:17 PM
Hello all, i have question about bitcoin protocol today i did a transaction of 0.011+btc using brainwallet.com (raw transaction) and then i tried to do another transaction using same inputs but i failed it sayed An outpoint is already spent [(112121274, 1)] but i remember that i was able to do second transaction simply in the past (qt 0.8.5 time) so did bitcoin protocol changed or what tell me how to the second transaction using same inputs as before in the previous transaction.
Same inputs? If you used all of the inputs before in the first transaction, isn't that a double spend? :P

It IS a double spend. The BitCoin protocol hasn't changed, it's you being dumb and double spending without realizing it.
It wasn't me, it was yakuza699.  :D

Yeah I know, I was directing that comment at the author, not you. Sorry for misunderstanding.


Title: Re: Bitcoin protocol changed?
Post by: yakuza699 on February 09, 2014, 09:58:58 AM
Hello all, i have question about bitcoin protocol today i did a transaction of 0.011+btc using brainwallet.com (raw transaction) and then i tried to do another transaction using same inputs but i failed it sayed An outpoint is already spent [(112121274, 1)] but i remember that i was able to do second transaction simply in the past (qt 0.8.5 time) so did bitcoin protocol changed or what tell me how to the second transaction using same inputs as before in the previous transaction.
Same inputs? If you used all of the inputs before in the first transaction, isn't that a double spend? :P

It IS a double spend. The BitCoin protocol hasn't changed, it's you being dumb and double spending without realizing it.
It wasn't me, it was yakuza699.  :D

Yeah I know, I was directing that comment at the author, not you. Sorry for misunderstanding.

Wait wait wait isn't double-spending on bitcoin imposibble i used that method to troll my friends because you can only double-spend if you own 51% of the network isn't it?


Title: Re: Bitcoin protocol changed?
Post by: byt411 on February 09, 2014, 11:47:41 AM
Hello all, i have question about bitcoin protocol today i did a transaction of 0.011+btc using brainwallet.com (raw transaction) and then i tried to do another transaction using same inputs but i failed it sayed An outpoint is already spent [(112121274, 1)] but i remember that i was able to do second transaction simply in the past (qt 0.8.5 time) so did bitcoin protocol changed or what tell me how to the second transaction using same inputs as before in the previous transaction.
Same inputs? If you used all of the inputs before in the first transaction, isn't that a double spend? :P

It IS a double spend. The BitCoin protocol hasn't changed, it's you being dumb and double spending without realizing it.
It wasn't me, it was yakuza699.  :D

Yeah I know, I was directing that comment at the author, not you. Sorry for misunderstanding.

Wait wait wait isn't double-spending on bitcoin imposibble i used that method to troll my friends because you can only double-spend if you own 51% of the network isn't it?

No. Everyone can double spend. A 51% attack is controlling 51% of the hashing power, theoretically allowing you to double spend and create a fork of the blockchain.


Title: Re: Bitcoin protocol changed?
Post by: DannyHamilton on February 09, 2014, 05:35:18 PM
Hello all, i have question about bitcoin protocol today i did a transaction of 0.011+btc using brainwallet.com (raw transaction) and then i tried to do another transaction using same inputs but i failed it sayed An outpoint is already spent [(112121274, 1)] but i remember that i was able to do second transaction simply in the past (qt 0.8.5 time) so did bitcoin protocol changed or what tell me how to the second transaction using same inputs as before in the previous transaction.
Same inputs? If you used all of the inputs before in the first transaction, isn't that a double spend? :P

It IS a double spend. The BitCoin protocol hasn't changed, it's you being dumb and double spending without realizing it.
It wasn't me, it was yakuza699.  :D

Yeah I know, I was directing that comment at the author, not you. Sorry for misunderstanding.

Wait wait wait isn't double-spending on bitcoin imposibble i used that method to troll my friends because you can only double-spend if you own 51% of the network isn't it?

Correct.  Double-spending is impossible in bitcoin.  Once a transaction is confirmed in a block, the inputs are considered "spent", and any attempt to re-spend the same inputs will be seen as a double-spend attempt which will be rejected by all peers, all miners, and any well designed wallet software.  This is why you are receiving the error message, "An outpoint is already spent".  You are attempting to double-spend that output, and bitcoin won't let you.  This is not a change to the protocol, this is the original design of the protocol.  This is the problem that the protocol solved and why bitcoin works.


Title: Re: Bitcoin protocol changed?
Post by: byt411 on February 09, 2014, 06:15:23 PM
Hello all, i have question about bitcoin protocol today i did a transaction of 0.011+btc using brainwallet.com (raw transaction) and then i tried to do another transaction using same inputs but i failed it sayed An outpoint is already spent [(112121274, 1)] but i remember that i was able to do second transaction simply in the past (qt 0.8.5 time) so did bitcoin protocol changed or what tell me how to the second transaction using same inputs as before in the previous transaction.
Same inputs? If you used all of the inputs before in the first transaction, isn't that a double spend? :P

It IS a double spend. The BitCoin protocol hasn't changed, it's you being dumb and double spending without realizing it.
It wasn't me, it was yakuza699.  :D

Yeah I know, I was directing that comment at the author, not you. Sorry for misunderstanding.

Wait wait wait isn't double-spending on bitcoin imposibble i used that method to troll my friends because you can only double-spend if you own 51% of the network isn't it?

Correct.  Double-spending is impossible in bitcoin.  Once a transaction is confirmed in a block, the inputs are considered "spent", and any attempt to re-spend the same inputs will be seen as a double-spend attempt which will be rejected by all peers, all miners, and any well designed wallet software.  This is why you are receiving the error message, "An outpoint is already spent".  You are attempting to double-spend that output, and bitcoin won't let you.  This is not a change to the protocol, this is the original design of the protocol.  This is the problem that the protocol solved and why bitcoin works.

As far as I know, double spending is possible. Although it won't get confirmed. Sites that don't require confirmations for deposits will receive the deposit. 


Title: Re: Bitcoin protocol changed?
Post by: DannyHamilton on February 09, 2014, 07:02:13 PM
As far as I know, double spending is possible. Although it won't get confirmed. Sites that don't require confirmations for deposits will receive the deposit. 

You and I are using different definitions for the words "double spending".  Before we can discuss whether "double spending" is possible, we must first agree on what the words "double spending" mean.


Title: Re: Bitcoin protocol changed?
Post by: byt411 on February 09, 2014, 07:12:18 PM
As far as I know, double spending is possible. Although it won't get confirmed. Sites that don't require confirmations for deposits will receive the deposit. 

You and I are using different definitions for the words "double spending".  Before we can discuss whether "double spending" is possible, we must first agree on what the words "double spending" mean.

Spending an input 2 times.


Title: Re: Bitcoin protocol changed?
Post by: DannyHamilton on February 09, 2014, 07:26:40 PM
As far as I know, double spending is possible. Although it won't get confirmed. Sites that don't require confirmations for deposits will receive the deposit.  

You and I are using different definitions for the words "double spending".  Before we can discuss whether "double spending" is possible, we must first agree on what the words "double spending" mean.

Spending an input 2 times.

That doesn't mean anything.  You've used the word "spending" to describe "double spending".

Here's the definition I'm using:

Creating multiple transactions that each use the exact same output as an input and that are all included in the blockchain.

This is "spending an input 2 times", and it is not possible with bitcoin.

Anything else is a "double spending attempt", that will fail to become an actual double spend.  One transaction attempt will make it into a blockchain and therefore become a real transaction actually spending an input, and all other transaction attempts will be deleted and cease to exist.


Title: Re: Bitcoin protocol changed?
Post by: byt411 on February 09, 2014, 08:54:02 PM
As far as I know, double spending is possible. Although it won't get confirmed. Sites that don't require confirmations for deposits will receive the deposit.  

You and I are using different definitions for the words "double spending".  Before we can discuss whether "double spending" is possible, we must first agree on what the words "double spending" mean.

Spending an input 2 times.

That doesn't mean anything.  You've used the word "spending" to describe "double spending".

Here's the definition I'm using:

Creating multiple transactions that each use the exact same output as an input and that are all included in the blockchain.

This is "spending an input 2 times", and it is not possible with bitcoin.

Anything else is a "double spending attempt", that will fail to become an actual double spend.  One transaction attempt will make it into a blockchain and therefore become a real transaction actually spending an input, and all other transaction attempts will be deleted and cease to exist.

Even if the 2nd isn't included in the blockchain, if the site accepts 0 confirmations, then it is still credited.


Title: Re: Bitcoin protocol changed?
Post by: flower1024 on February 09, 2014, 08:55:59 PM

Even if the 2nd isn't included in the blockchain, if the site accepts 0 confirmations, then it is still credited.

have you tested this?
afaik bitcoind prohibits a transaction which inputs has already been spent in his mempool

EDIT: btw this is not a protocol issue. its up to the client how to handle 0confs and transaction which uses already spent inputs. the protocol just supplies the info necessary to make this decision


Title: Re: Bitcoin protocol changed?
Post by: DeathAndTaxes on February 09, 2014, 09:04:10 PM
As far as I know, double spending is possible. Although it won't get confirmed. Sites that don't require confirmations for deposits will receive the deposit.  

You and I are using different definitions for the words "double spending".  Before we can discuss whether "double spending" is possible, we must first agree on what the words "double spending" mean.

Spending an input 2 times.

That doesn't mean anything.  You've used the word "spending" to describe "double spending".

Here's the definition I'm using:

Creating multiple transactions that each use the exact same output as an input and that are all included in the blockchain.

This is "spending an input 2 times", and it is not possible with bitcoin.

Anything else is a "double spending attempt", that will fail to become an actual double spend.  One transaction attempt will make it into a blockchain and therefore become a real transaction actually spending an input, and all other transaction attempts will be deleted and cease to exist.

Even if the 2nd isn't included in the blockchain, if the site accepts 0 confirmations, then it is still credited.

Once the first tx is known to a particular node, the second won't even be relayed.  It would simply be rejected/dropped as invalid.  A tx whose inputs have already been spent is invalid.  Once the first tx is in a block, the site would never know about the transaction to give you credit.  This is what was occuring w/ MtGox broken withdraws.  MtGox was creating txs involving already spent inputs and thus they got rejected by every single node.  Users couldn't even see the tx on the network (either on the wallet or on sites like blockchain.info) because the network is designed to NOT relay double spends.

So once the first tx is known to a node, the second isn't a valid unconfirmed tx, it is simply invalid garbage discarded by the network.

The only way a 0-confirm double spend can occur is
a) attacker makes two txs which use the same input(s) A to the merchant and B back to the attacker.
b) the attacker broadcasts A & B to different parts of the network.
c) the merchant only learns about A and never learns about B
d) the miner who ends up solving the next block learns about B first
e) the merchant doesn't have other nodes looking for tx like B and report it to the merchant.

Still that assumes the A isn't already confirmed in a block.  If it is, you can't create a tx which spends an already spent input.  Your only option would be to rewrite the blockchain (in essence A never occured according to the blockchain so B isn't a "double spend" as far as the protocol is concerned it is the only spend).





Simple version: Danny is right (he usually is).


Title: Re: Bitcoin protocol changed?
Post by: GhostGum on February 10, 2014, 04:18:26 PM
This is how my every conversation inevitably goes.
* Early dialogue flows easily, understanding comes easy, good progress is made for all, little time wasted on the process of communication, be it understanding what othe rparty is saying, or trying to express own thoghts.
* Progress into more specific subject matter, have to concentrate on what other party is saying, and think about choosing words when expressing own thoughts.
* Must have failed to express correctly myself, or misread/misunderstood what other party was saying.
* try to reword or restructure what was trying to say, and listen moew intently to understand.
* half hour later realise that have completely digressed from original topic, just debating pure semantics by this point, and not realty getting anywhere fast.


Whilst it does mean a  lot  to express any knowledge or opinion as correctly as can, and It's important  to understand any information or thoughts given; and the semantics of what something means is very informative in it's own right. It  is a very time consuming way to progress very slowly.



This thread :/.