Skip to content

Conversation

ghost
Copy link

@ghost ghost commented Mar 20, 2017

No description provided.

@gmaxwell
Copy link
Contributor

gmaxwell commented Mar 20, 2017

This still leaks that you were in IBD, but I think there isn't much that could be done about that. One possibility would be to use the best headers height which you'll have very early in sync... but it would require reasoning about some corner cases. @petertodd

@jonasschnelli
Copy link
Contributor

I think taking the headers height as @gmaxwell describes would make more sense. #9483 has some simple pre-work that would be reusable (1687a0e).

@ghost ghost changed the title wallet: don't leak height of local chain during inital sync wallet: use headers chain for fee sniping Mar 22, 2017
@ghost
Copy link
Author

ghost commented Mar 24, 2017

@jonasschnelli indeed

@maflcko
Copy link
Member

maflcko commented Mar 24, 2017 via email

@sipa
Copy link
Member

sipa commented Mar 24, 2017

@MarcoFalke I guess we can do both. When offline (= tip header too old), don't use anti fee sniping; otherwise, use tip header information.

@ghost ghost changed the title wallet: use headers chain for fee sniping wallet: use headers chain for anti fee sniping Mar 25, 2017
@keystrike
Copy link
Contributor

keystrike commented Mar 28, 2017

Yes, in the initial issue I described this because of the ability to fingerprint clients which are not synchronized for some time and will not synchronize in the future. The goal is to get rid of this unique metadata. I agree with @sipa's suggestion.

Just for interest I will check the blockchain for nlocktimes which are set to past times to look at the history of this metadata leak.

@laanwj
Copy link
Member

laanwj commented Jun 26, 2017

Needs rebase; and comments addressed.

@keystrike
Copy link
Contributor

keystrike commented Jun 27, 2017

I've made a comment related to this here.

@ghost
Copy link
Author

ghost commented Jun 27, 2017

Rebased and awaiting review.

@petertodd
Copy link
Contributor

In addition to the IsInitialChainDownload() check, it may be good to change the randomization thing to pick a random block in a much wider range, rather than just a few blocks back. Then make the IsInitialChainDownload() check also activate that randomization for all txs.

@ghost
Copy link
Author

ghost commented Jun 27, 2017

I'd prefer to remove the randomization thing or leave it as is.

@jonasschnelli
Copy link
Contributor

The extra headers CChain object is not really required (at least not for this use case).
I would go back to your original simple implementation of anti-fee sniping and just use pindexBestHeader as the header you get your height from.

@ghost
Copy link
Author

ghost commented Aug 20, 2017

Removed that headers CChain.

@petertodd
Copy link
Contributor

Concept NACK

W/ the various SHA256 alts that have been launched, and will be launched, it's quite possible that you have a headers chain with more blocks in it than the actual Bitcoin chain. This is even possible if that chain isn't the actual most-work chain, as you might not know about that chain.

I think re: privacy, changing the anti-fee sniping mechanism to occasionally pick nLockTime's from a much larger range is probably the better way to help the privacy problem.

@ryanofsky
Copy link
Contributor

ryanofsky commented Jan 9, 2018

Perhaps this issue could be tagged up for grabs if it's not still active. If I understand the suggestion, it's basically just to replace 100 with a much larger value here:

txNew.nLockTime = std::max(0, (int)txNew.nLockTime - GetRandInt(100));

@laanwj
Copy link
Member

laanwj commented Mar 1, 2018

Closing this, seems inactive.
I also agree with @petertodd, it's risky to lock in with just the headers - especially given all kinds of forks and alts starting from the bitcoin chain.

@laanwj laanwj closed this Mar 1, 2018
@Arezohayeman Arezohayeman mentioned this pull request Mar 21, 2018
@maflcko
Copy link
Member

maflcko commented Mar 5, 2019

Picked up in " wallet: Avoid leaking nLockTime fingerprint when anti-fee-sniping #15039 "

@bitcoin bitcoin locked as resolved and limited conversation to collaborators Dec 16, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants