From a08864aa52597a63e4961621261f62c4d2924b09 Mon Sep 17 00:00:00 2001 From: Simon Date: Sun, 9 Jan 2022 02:42:21 +0000 Subject: [PATCH] change references to Crc32 to SHA1 --- bridge_master.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/bridge_master.py b/bridge_master.py index 5610f74..606c5bd 100644 --- a/bridge_master.py +++ b/bridge_master.py @@ -1719,9 +1719,9 @@ class routerOBP(OPENBRIDGE): if _seq and self.STATUS[_stream_id]['lastSeq'] and (_seq != 1) and (_seq < self.STATUS[_stream_id]['lastSeq']): logger.warning("%s) *PacketControl* Out of order packet - last SEQ: %s, this SEQ: %s, disgarding. Stream ID:, %s TGID: %s ",self._system,self.STATUS[_stream_id]['lastSeq'],_seq,int_id(_stream_id),int_id(_dst_id)) return - #Duplicate DMR payload to previuos packet (by Crc32) + #Duplicate DMR payload to previuos packet (by SHA1 if _seq > 0 and _pkt_crc in self.STATUS[_stream_id]['crcs']: - logger.warning("(%s) *PacketControl* DMR packet payload with Crc32: %s seen before in this stream, disgarding. Stream ID:, %s TGID: %s: SEQ:%s packets: %s ",self._system,_pkt_crc,int_id(_stream_id),int_id(_dst_id),_seq, self.STATUS[_stream_id]['packets']) + logger.warning("(%s) *PacketControl* DMR packet payload with SHA1: %s seen before in this stream, disgarding. Stream ID:, %s TGID: %s: SEQ:%s packets: %s ",self._system,_pkt_crc,int_id(_stream_id),int_id(_dst_id),_seq, self.STATUS[_stream_id]['packets']) return #Inbound missed packets if _seq and self.STATUS[_stream_id]['lastSeq'] and _seq > (self.STATUS[_stream_id]['lastSeq']+1): @@ -2440,9 +2440,9 @@ class routerHBP(HBSYSTEM): if _seq and self.STATUS[_slot]['lastSeq'] and (_seq != 1) and (_seq < self.STATUS[_slot]['lastSeq']): logger.warning("%s) *PacketControl* Out of order packet - last SEQ: %s, this SEQ: %s, disgarding. Stream ID:, %s TGID: %s ",self._system,self.STATUS[_slot]['lastSeq'],_seq,int_id(_stream_id),int_id(_dst_id)) return - #Duplicate DMR payload to previuos packet (by Crc32) + #Duplicate DMR payload to previuos packet (by SHA1) if _seq > 0 and _pkt_crc in self.STATUS[_slot]['crcs']: - logger.warning("(%s) *PacketControl* DMR packet payload with Crc32: %s seen before in this stream, disgarding. Stream ID:, %s TGID: %s, SEQ: %s, packets %s: ",self._system,_pkt_crc,int_id(_stream_id),int_id(_dst_id),_seq,self.STATUS[_slot]['packets']) + logger.warning("(%s) *PacketControl* DMR packet payload with SHA1: %s seen before in this stream, disgarding. Stream ID:, %s TGID: %s, SEQ: %s, packets %s: ",self._system,_pkt_crc,int_id(_stream_id),int_id(_dst_id),_seq,self.STATUS[_slot]['packets']) return #Inbound missed packets if _seq and self.STATUS[_slot]['lastSeq'] and _seq > (self.STATUS[_slot]['lastSeq']+1):