Agent: Move definition of exploit template constants for log4shell

The LINUX_EXPLOIT_TEMPLATE_PATH and WINDOWS_EXPLOIT_TEMPLATE_PATH are
not used in exploit_builder.py, and therefore have no reason to be
defined in this file. They are now defined in the __init__.py
This commit is contained in:
Mike Salvatore 2022-01-12 16:46:31 -05:00
parent 7733ec29ca
commit c2f3042442
2 changed files with 4 additions and 4 deletions

View File

@ -1,9 +1,11 @@
from pathlib import Path
from .exploit_builder import (
build_exploit_bytecode,
InvalidExploitTemplateError,
LINUX_EXPLOIT_TEMPLATE_PATH,
WINDOWS_EXPLOIT_TEMPLATE_PATH,
)
from .ldap_server import LDAPExploitServer
from .service_exploiters import get_log4shell_service_exploiters
from .exploit_class_http_server import ExploitClassHTTPServer
LINUX_EXPLOIT_TEMPLATE_PATH = Path(__file__).parent / "LinuxExploit.class.template"
WINDOWS_EXPLOIT_TEMPLATE_PATH = Path(__file__).parent / "WindowsExploit.class.template"

View File

@ -3,8 +3,6 @@ from pathlib import Path
# This code has been adapted from https://github.com/alexandre-lavoie/python-log4rce
LINUX_EXPLOIT_TEMPLATE_PATH = Path(__file__).parent / "LinuxExploit.class.template"
WINDOWS_EXPLOIT_TEMPLATE_PATH = Path(__file__).parent / "WindowsExploit.class.template"
INJECTION_TAG = "###"