From fbf1e8f30d003c679fe763a59151e0c31f7a2a33 Mon Sep 17 00:00:00 2001 From: Nicolas Bareil Date: Fri, 7 May 2021 01:29:27 -0700 Subject: [PATCH] Merging decrypt_beacons() --- beacon_utils.py | 4 +++- parse_beacon_config.py | 33 --------------------------------- 2 files changed, 3 insertions(+), 34 deletions(-) diff --git a/beacon_utils.py b/beacon_utils.py index 2102004..1e5b7ea 100644 --- a/beacon_utils.py +++ b/beacon_utils.py @@ -55,7 +55,10 @@ def get_beacon_data(url, arch): eicar_offset = buf.find(b'EICAR-STANDARD-ANTIVIRUS-TEST-FILE') if eicar_offset != -1: return buf + return decrypt_beacon(buf) + +def decrypt_beacon(buf): offset = buf.find(b'\xff\xff\xff') if offset == -1: _cli_print('[-] Unexpected buffer received') @@ -74,5 +77,4 @@ def get_beacon_data(url, arch): b = struct.unpack_from('