mirror of
https://github.com/markqvist/Reticulum.git
synced 2024-12-23 04:10:18 +00:00
Emission timestamp in announce.
This commit is contained in:
parent
c0fb419fe1
commit
e8ee26f78d
@ -149,6 +149,9 @@ class Destination:
|
||||
destination_hash = self.hash
|
||||
random_hash = RNS.Identity.get_random_hash()[0:5]+int(time.time()).to_bytes(5, "big")
|
||||
|
||||
# TODO: Remove
|
||||
RNS.log("ArB: "+RNS.hexrep(random_hash))
|
||||
|
||||
if app_data == None and self.default_app_data != None:
|
||||
if isinstance(self.default_app_data, bytes):
|
||||
app_data = self.default_app_data
|
||||
|
@ -776,8 +776,10 @@ class Transport:
|
||||
# local to this system, and that hops are less than the max
|
||||
if (not any(packet.destination_hash == d.hash for d in Transport.destinations) and packet.hops < Transport.PATHFINDER_M+1):
|
||||
random_blob = packet.data[RNS.Identity.KEYSIZE//8+10:RNS.Identity.KEYSIZE//8+20]
|
||||
|
||||
announce_emitted = int.from_bytes(random_blob[5:10], "big")
|
||||
# TODO: Remove
|
||||
RNS.log("ArB: "+RNS.hexrep(random_blob))
|
||||
RNS.log("Announce timestamp is: "+str(announce_emitted))
|
||||
random_blobs = []
|
||||
if packet.destination_hash in Transport.destination_table:
|
||||
|
Loading…
Reference in New Issue
Block a user