improved logging

This commit is contained in:
DJ2LS 2023-08-26 16:16:48 +02:00
parent 9a9f636562
commit 4e185ea612
2 changed files with 4 additions and 3 deletions

View file

@ -926,9 +926,7 @@ class DATA:
)
# now check if we have valid hmac signature - returns salt or bool
salt_found = helpers.search_hmac_salt(self.dxcallsign, self.mycallsign, data_frame_crc, data_frame, token_iters=100)
self.log.info(
"[TNC] [HMAC] Salt found", salt=salt_found
)
if salt_found:
# hmac digest received
self.arq_process_received_data_frame(data_frame, snr, signed=True)

View file

@ -549,6 +549,9 @@ def search_hmac_salt(dxcallsign: bytes, mycallsign: bytes, search_token, data_fr
filepath = filename
# check if file exists else return false
if not check_if_file_exists(filename):
log.warning(
"[TNC] [HMAC] Token file not found", file=filename,
)
return False
try: