Bitcoin Forum

Bitcoin => Bitcoin Technical Support => Topic started by: bkc888 on November 18, 2013, 01:46:47 PM



Title: Why did this transaction send bitcoins back to itself?
Post by: bkc888 on November 18, 2013, 01:46:47 PM
https://blockchain.info/zh-cn/tx/c4de7f7152b117a2946d1c5513019e5dc1e79fa0fb5f9b1752c1c9e1c4e6c944

Thanks.


Title: Re: Why did this transaction send bitcoins back to itself?
Post by: rebuilder on November 18, 2013, 01:49:02 PM
Can a client be configured to send change to the originating address of the transaction?


Title: Re: Why did this transaction send bitcoins back to itself?
Post by: CIYAM on November 18, 2013, 01:49:47 PM
It just looks like the "change" was sent back to the original address (easy to do using "Coin Control" or by rolling your own "raw transaction").


Title: Re: Why did this transaction send bitcoins back to itself?
Post by: drrussellshane on November 18, 2013, 01:50:48 PM
Can a client be configured to send change to the originating address of the transaction?

Yes, and that sounds like what happened here.


Title: Re: Why did this transaction send bitcoins back to itself?
Post by: kokojie on November 18, 2013, 03:34:54 PM
Can a client be configured to send change to the originating address of the transaction?

blockchain.info wallet can do that


Title: Re: Why did this transaction send bitcoins back to itself?
Post by: Barek on November 18, 2013, 03:54:06 PM
However, it is not ideal to do that.

It reduces privacy (associates an address) and weakens security (reveals the public key).


Title: Re: Why did this transaction send bitcoins back to itself?
Post by: rbdrbd on November 18, 2013, 04:09:15 PM
Can a client be configured to send change to the originating address of the transaction?

blockchain.info wallet can do that

Armory client can as well (on Expert mode)


Title: Re: Why did this transaction send bitcoins back to itself?
Post by: rbdrbd on November 18, 2013, 04:11:18 PM
However, it is not ideal to do that.

It reduces privacy (associates an address) and weakens security (reveals the public key).

revealing the public key as-in exposing the address to a potential future quantum attack, or something more than this?


Title: Re: Why did this transaction send bitcoins back to itself?
Post by: DannyHamilton on November 18, 2013, 04:19:38 PM
However, it is not ideal to do that.

It reduces privacy (associates an address) and weakens security (reveals the public key).

revealing the public key as-in exposing the address to a potential future quantum attack, or something more than this?

When you receive bitcoins at an address that has never been used before, there are three levels of cryptography between the private key and the bitcoin address:

  • First there is ECDSA with the Secp256k1 curve resulting in a public key.
  • Then the public key is hashed with SHA-256.
  • Finally the result of the SHA-256 hash is hashed with RIPEMD-160.

It is the result of this RIPEMD-160 hash that is stored in the blockchain and converted to a bitcoin address.

When you send a bitcoin transaction that spends any of the outputs that have been received at an address, the ECDSA public key is included in the transaction.
This means that you then only have 1 level of cryptography between the address and the private key.  Since the ECDSA public key becomes publicly available, the protection of SHA-256 and RIPEMD-160 are lost.

From then on, any unspent outputs that remain associated with that address (or any new outputs sent to that address) no longer have the protection of SHA-256 or RIPEMD-160