mirror of
https://github.com/markqvist/Reticulum.git
synced 2025-06-21 13:14:08 -04:00
Added announce frequency stats
This commit is contained in:
parent
0fd75cb819
commit
136713eec1
3 changed files with 13 additions and 2 deletions
|
@ -887,6 +887,8 @@ class Transport:
|
|||
# thread.start()
|
||||
|
||||
Transport.transmit(interface, packet.raw)
|
||||
if packet.packet_type == RNS.Packet.ANNOUNCE:
|
||||
interface.sent_announce()
|
||||
sent = True
|
||||
|
||||
if sent:
|
||||
|
@ -1227,8 +1229,11 @@ class Transport:
|
|||
# announces, queueing rebroadcasts of these, and removal
|
||||
# of queued announce rebroadcasts once handed to the next node.
|
||||
if packet.packet_type == RNS.Packet.ANNOUNCE:
|
||||
if interface != None and RNS.Identity.validate_announce(packet, only_validate_signature=True):
|
||||
interface.received_announce()
|
||||
|
||||
local_destination = next((d for d in Transport.destinations if d.hash == packet.destination_hash), None)
|
||||
if local_destination == None and RNS.Identity.validate_announce(packet):
|
||||
if local_destination == None and RNS.Identity.validate_announce(packet):
|
||||
if packet.transport_id != None:
|
||||
received_from = packet.transport_id
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue