Author

Topic: how to avoid coins being sent to a change address? (Read 1281 times)

legendary
Activity: 3472
Merit: 4801
- snip -
the change moving into a different address will remain there for quite a long time if you don't use the main address.
- snip -

Remember, the concept of a "main address" is entirely in your head.  You have picked just one of the hundred or more addresses that your wallet is keeping track of and you have decided to call that address a "main address".  You wallet doesn't differentiate, and it doesn't know that you have decided to call that address a "main address".  As far as your wallet is concerned, all addresses are equal.  They are just addresses.  There is no "main" one.

Every amount that you receive from a transaction is also treated equally.  If you receive 0.1 BTC from a transaction that someone else sends to you, or 0.1 BTC in change from a transaction that you sent, the wallet just sees it as an unspent 0.1 BTC output. It doesn't care if the amount was change or not.  This is even true if you choose to re-use an address.  If you have an empty wallet and you receive five 0.1 BTC outputs all to the same address, the wallet doesn't "combine" them into a single 0.5 BTC output.  It keeps them as five separate 0.1 BTC outputs, and will choose which outputs to spend the same way that it would if they were sent to 5 different addresses.

legendary
Activity: 896
Merit: 1000
the security part, and the post from DannyHamilton made me decide to not proceed with setting a manual change address. but when it comes to the privacy aspect, the change moving into a different address will remain there for quite a long time if you don't use the main address. so if i choose to spend 0.50btc where my main address contains 0.45btc, and the change address 0.05btc, will they both start moving at the same time, and thus be visible and link the change address to my main address as it will be too obvious? or is it also possible to just spend the amount you have in your change wallet where the coins in the main wallet remain untouched?
You can do that using coin control to select the inputs that you want to spend. Otherwise, the wallet will automatically choose which inputs to spend and it may end up linking your addresses.

never knew that it was possible to go that deep into all the inputs so easily without actually needing to create raw transactions. thanks for making me a bit smarter this quickly. much appreciated.
staff
Activity: 3458
Merit: 6793
Just writing some code
the security part, and the post from DannyHamilton made me decide to not proceed with setting a manual change address. but when it comes to the privacy aspect, the change moving into a different address will remain there for quite a long time if you don't use the main address. so if i choose to spend 0.50btc where my main address contains 0.45btc, and the change address 0.05btc, will they both start moving at the same time, and thus be visible and link the change address to my main address as it will be too obvious? or is it also possible to just spend the amount you have in your change wallet where the coins in the main wallet remain untouched?
You can do that using coin control to select the inputs that you want to spend. Otherwise, the wallet will automatically choose which inputs to spend and it may end up linking your addresses.
legendary
Activity: 896
Merit: 1000
It is highly recommended that you do not do this as address reuse is not recommended.

If you are sure that you want to reuse change addresses, go to Settings > Options and then the Wallet tab. Check the box for "Enable coin control features". Then click OK. When you go to send, you will now see a box for Coin Control. Check the box for "Custom Change address" and then enter the address that you want to use as your change address. Then send your Bitcoin and the change will go to wherever you specified.

can you elaborate on why it isn't recommended to use my main wallet as change destination? is it more privacy related, or has it more to do with the security? and thanks, i found the option to set a custom change address. i haven't done it yet as i will wait for your reply whether or not it will harm the security of my address.
It isn't recommended because it can both hurt your security and your privacy. By reusing addresses, people who pay you can easily see how much money you have. It becomes fairly easy to track who you are paying and how much. New change addresses also makes it possible to say that the change was going to someone else and not back to yourself; it allows for plausible deniability, something you can't do with reusing addresses.

For security, using new addresses and never reusing addresses will help protect against any attack that would break ECDSA (any attack in which a private key can be found from a public key in a meaningful amount of time). When you spend, you are really spending to the hash of a public key. Once you spend the Bitcoin from that output, you will be revealing the public key in the spending transaction. This makes it potentially vulnerable to be cracked. However, if you always use new addresses, then your Bitcoin is still safe as by that time the public key is revealed and the private key cracked, the Bitcoin should already have been spent.

the security part, and the post from DannyHamilton made me decide to not proceed with setting a manual change address. but when it comes to the privacy aspect, the change moving into a different address will remain there for quite a long time if you don't use the main address. so if i choose to spend 0.50btc where my main address contains 0.45btc, and the change address 0.05btc, will they both start moving at the same time, and thus be visible and link the change address to my main address as it will be too obvious? or is it also possible to just spend the amount you have in your change wallet where the coins in the main wallet remain untouched?

- snip -
my main wallet
- snip -

Your main wallet is Bitcoin Core.

A wallet is a collection of one or more bitcoin addresses along with the private keys necessary to spend the outputs that are associated with those addresses.

The fact that you want to re-use one of those many addresses again and again does not make that address a wallet.  I suppose you can make the poor decision to re-use the same address for everything, and then you could choose to call that your "main address", but you're going to cause yourself confusion if you keep referring to an address as a wallet.

If you stop thinking of an address as a wallet or an account number, then the whole thing makes much more sense.

Think of an address as an invoice number.  You wouldn't re-use an invoice number to receive payments from multiple people.  An address is something you give to someone to use once so that when you receive the payment you can identify who sent it and why they sent it.  Your wallet generates addresses (invoice numbers) for you. You then give those invoice numbers (addresses) to people that you want to receive payment from.  Those people then include that invoice number (address) when they pay you so they can be sure that you will identify the purpose and source of the payment you receive.

When you send a payment to someone, you use two invoice numbers.  One for the person you are paying (so they know who it is from and why it was sent), and one for your own wallet (allowing the wallet to track exactly when and why it received that change payment).

The wallet keeps track of all the invoices that you've received payment on for you and can combine the values of those receipts when generating transactions to send.

that's correct, yes. the main wallet is indeed bitcoin core. if i look at it from the point of being an invoice number, then it indeed doesn't make any sense to reuse it for different people. actually, that would be pretty dumb as you would lose track of important information. both you and knightdk thanks for giving me a wider field of sight. it's more clear now.  Smiley
legendary
Activity: 3472
Merit: 4801
- snip -
my main wallet
- snip -

Your main wallet is Bitcoin Core.

A wallet is a collection of one or more bitcoin addresses along with the private keys necessary to spend the outputs that are associated with those addresses.

The fact that you want to re-use one of those many addresses again and again does not make that address a wallet.  I suppose you can make the poor decision to re-use the same address for everything, and then you could choose to call that your "main address", but you're going to cause yourself confusion if you keep referring to an address as a wallet.

If you stop thinking of an address as a wallet or an account number, then the whole thing makes much more sense.

Think of an address as an invoice number.  You wouldn't re-use an invoice number to receive payments from multiple people.  An address is something you give to someone to use once so that when you receive the payment you can identify who sent it and why they sent it.  Your wallet generates addresses (invoice numbers) for you. You then give those invoice numbers (addresses) to people that you want to receive payment from.  Those people then include that invoice number (address) when they pay you so they can be sure that you will identify the purpose and source of the payment you receive.

When you send a payment to someone, you use two invoice numbers.  One for the person you are paying (so they know who it is from and why it was sent), and one for your own wallet (allowing the wallet to track exactly when and why it received that change payment).

The wallet keeps track of all the invoices that you've received payment on for you and can combine the values of those receipts when generating transactions to send.
staff
Activity: 3458
Merit: 6793
Just writing some code
It is highly recommended that you do not do this as address reuse is not recommended.

If you are sure that you want to reuse change addresses, go to Settings > Options and then the Wallet tab. Check the box for "Enable coin control features". Then click OK. When you go to send, you will now see a box for Coin Control. Check the box for "Custom Change address" and then enter the address that you want to use as your change address. Then send your Bitcoin and the change will go to wherever you specified.

can you elaborate on why it isn't recommended to use my main wallet as change destination? is it more privacy related, or has it more to do with the security? and thanks, i found the option to set a custom change address. i haven't done it yet as i will wait for your reply whether or not it will harm the security of my address.
It isn't recommended because it can both hurt your security and your privacy. By reusing addresses, people who pay you can easily see how much money you have. It becomes fairly easy to track who you are paying and how much. New change addresses also makes it possible to say that the change was going to someone else and not back to yourself; it allows for plausible deniability, something you can't do with reusing addresses.

For security, using new addresses and never reusing addresses will help protect against any attack that would break ECDSA (any attack in which a private key can be found from a public key in a meaningful amount of time). When you spend, you are really spending to the hash of a public key. Once you spend the Bitcoin from that output, you will be revealing the public key in the spending transaction. This makes it potentially vulnerable to be cracked. However, if you always use new addresses, then your Bitcoin is still safe as by that time the public key is revealed and the private key cracked, the Bitcoin should already have been spent.
legendary
Activity: 896
Merit: 1000
It is highly recommended that you do not do this as address reuse is not recommended.

If you are sure that you want to reuse change addresses, go to Settings > Options and then the Wallet tab. Check the box for "Enable coin control features". Then click OK. When you go to send, you will now see a box for Coin Control. Check the box for "Custom Change address" and then enter the address that you want to use as your change address. Then send your Bitcoin and the change will go to wherever you specified.

can you elaborate on why it isn't recommended to use my main wallet as change destination? is it more privacy related, or has it more to do with the security? and thanks, i found the option to set a custom change address. i haven't done it yet as i will wait for your reply whether or not it will harm the security of my address.
staff
Activity: 3458
Merit: 6793
Just writing some code
It is highly recommended that you do not do this as address reuse is not recommended.

If you are sure that you want to reuse change addresses, go to Settings > Options and then the Wallet tab. Check the box for "Enable coin control features". Then click OK. When you go to send, you will now see a box for Coin Control. Check the box for "Custom Change address" and then enter the address that you want to use as your change address. Then send your Bitcoin and the change will go to wherever you specified.
legendary
Activity: 3612
Merit: 5297
https://merel.mobi => buy facemasks with BTC/LTC
for example, when my wallet has a balance of 0.55btc, and i want to send 0.20btc to a certain person, the remaining balance, or a part of it, goes to a different address (change address), while i want everything to remain in my main wallet. i know it's possible, but only not sure how to do it. i am working with bitcoin core 0.12.1.

I'm not an expert with core, but i don't think it's something you can easily do, except by creating the transaction from the cli or using the coin controll features (that way you can chose a custom change address, and use your "main" address)...

Altough there's no need to avoid change addresses (as a matter of fact, i think most users would actually say it's a good thing to use change adresses), if you really want to do this, i'd suggest using electrum (go to preferences, disable "use change adresses').
legendary
Activity: 896
Merit: 1000
for example, when my wallet has a balance of 0.55btc, and i want to send 0.20btc to a certain person, the remaining balance, or a part of it, goes to a different address (change address), while i want everything to remain in my main wallet. i know it's possible, but only not sure how to do it. i am working with bitcoin core 0.12.1.
Jump to: