Skip to content

Commit

Permalink
Print beacon version information when running beacon-dump -v (#46)
Browse files Browse the repository at this point in the history
  • Loading branch information
yunzheng committed Mar 31, 2023
1 parent d85b02a commit 486738b
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions dissect/cobaltstrike/beacon.py
Expand Up @@ -4,6 +4,7 @@
import os
import io
import sys
import time
import hashlib
import logging
import ipaddress
Expand Down Expand Up @@ -1032,6 +1033,29 @@ def main():
settings = config.settings
for setting, value in settings.items():
print(f"{setting} = {value!r}")
if args.verbose >= 1:
print("-" * 50)
print(
"pe_export_stamp = {}, {}, {}".format(
config.pe_export_stamp,
hex(config.pe_export_stamp),
time.ctime(config.pe_export_stamp),
)
)
print(
"pe_compile_stamp = {}, {}, {}".format(
config.pe_compile_stamp,
hex(config.pe_compile_stamp),
time.ctime(config.pe_compile_stamp),
)
)
print(
"max_setting_enum = {} - {}".format(
config.max_setting_enum,
BeaconSetting(config.max_setting_enum),
)
)
print("beacon_version =", config.version)
elif args.type == "c2profile":
profile = c2profile.C2Profile.from_beacon_config(config)
print(profile.as_text())
Expand Down

0 comments on commit 486738b

Please sign in to comment.