Bitcoin Forum
March 19, 2024, 10:08:15 AM *
News: Latest Bitcoin Core release: 26.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Node Address Sharing. The use of Time.  (Read 783 times)
MatthewLM (OP)
Legendary
*
Offline Offline

Activity: 1190
Merit: 1004


View Profile
July 26, 2012, 11:20:45 PM
 #1

Hello can anyone explain the use of time for sharing addresses. This is might confusing to me:

https://github.com/bitcoin/bitcoin/blob/master/src/main.cpp#L2475

Like, why does it set the time for addresses advertised with times over 10 minutes in the future to five days ago?

Can anyone explain the exact mechanism for the use of time and perhaps advise on another more straightforward mechanism?

Thanks.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1710842895
Hero Member
*
Offline Offline

Posts: 1710842895

View Profile Personal Message (Offline)

Ignore
1710842895
Reply with quote  #2

1710842895
Report to moderator
1710842895
Hero Member
*
Offline Offline

Posts: 1710842895

View Profile Personal Message (Offline)

Ignore
1710842895
Reply with quote  #2

1710842895
Report to moderator
1710842895
Hero Member
*
Offline Offline

Posts: 1710842895

View Profile Personal Message (Offline)

Ignore
1710842895
Reply with quote  #2

1710842895
Report to moderator
gmaxwell
Moderator
Legendary
*
expert
Offline Offline

Activity: 4158
Merit: 8343



View Profile WWW
July 26, 2012, 11:32:30 PM
 #2

with times over 10 minutes in the future to five days ago?

The reason it twiddles the time in various ways in various places is because the time is used to prioritize peer selection (in some limited ways), if peers could send you times in the far future they could unduly influence your peer selection.
MatthewLM (OP)
Legendary
*
Offline Offline

Activity: 1190
Merit: 1004


View Profile
July 27, 2012, 08:08:02 PM
 #3

Hmm, yes. Though if a node wanted to place their addresses as high priority it could try to set the times to near 10 minutes in the future.

Perhaps to avert this somewhat, the addresses with the times placed close to the network time, are given the same priority. So if we wanted addresses from now to five minutes ago with a margin of 10 minutes, we could place the addresses from 15 minutes ago to 10 minutes in the future as the highest priority with the time set to now. As usual addresses after 10 minutes in the future can be set to 5 days ago (But why if below 100000000?). All other times remain the same.

?
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!