forked from p15670423/monkey
Common: Rename NetworkServiceNameEnum -> NetworkService
"Name" and "Enum" are redundant in this case
This commit is contained in:
parent
8bf1d1f46f
commit
f6ed8a997c
|
@ -28,7 +28,7 @@ JSONSerializable = Union[ # type: ignore[misc]
|
|||
]
|
||||
|
||||
|
||||
class NetworkServiceNameEnum(Enum):
|
||||
class NetworkService(Enum):
|
||||
UNKNOWN = auto()
|
||||
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@ from pydantic import Field, validator
|
|||
from common import OperatingSystem
|
||||
from common.base_models import MutableInfectionMonkeyBaseModel
|
||||
from common.transforms import make_immutable_sequence
|
||||
from common.types import HardwareID, NetworkServiceNameEnum, SocketAddress
|
||||
from common.types import HardwareID, NetworkService, SocketAddress
|
||||
|
||||
from . import MachineID
|
||||
|
||||
|
@ -35,7 +35,7 @@ class Machine(MutableInfectionMonkeyBaseModel):
|
|||
hostname: str = ""
|
||||
"""The hostname of the machine"""
|
||||
|
||||
network_services: Mapping[SocketAddress, NetworkServiceNameEnum]
|
||||
network_services: Mapping[SocketAddress, NetworkService]
|
||||
"""All network services found running on the machine"""
|
||||
|
||||
_make_immutable_sequence = validator("network_interfaces", pre=True, allow_reuse=True)(
|
||||
|
|
|
@ -13,7 +13,7 @@ from infection_monkey.exploit.HostExploiter.HostExploiter import (
|
|||
_publish_exploitation_event,
|
||||
_publish_propagation_event,
|
||||
)
|
||||
from common.types import NetworkPort, NetworkServiceNameEnum
|
||||
from common.types import NetworkPort, NetworkService
|
||||
from infection_monkey.exploit.log4shell_utils.ldap_server import LDAPServerFactory
|
||||
from monkey_island.cc.models import Machine, Node, Report
|
||||
from monkey_island.cc.models.networkmap import Arc, NetworkMap
|
||||
|
|
Loading…
Reference in New Issue