forked from p15670423/monkey
Common: Use NetworkPort in TCPScanConfiguration
This commit is contained in:
parent
5fc4d52d9f
commit
1a01b7c5dc
|
@ -3,6 +3,7 @@ from typing import Dict, Tuple
|
|||
from pydantic import PositiveFloat, conint, validator
|
||||
|
||||
from common.base_models import MutableInfectionMonkeyBaseModel
|
||||
from common.types import NetworkPort
|
||||
|
||||
from .validators import (
|
||||
validate_ip,
|
||||
|
@ -128,7 +129,7 @@ class TCPScanConfiguration(MutableInfectionMonkeyBaseModel):
|
|||
"""
|
||||
|
||||
timeout: PositiveFloat
|
||||
ports: Tuple[conint(ge=0, le=65535), ...]
|
||||
ports: Tuple[NetworkPort, ...]
|
||||
|
||||
|
||||
class NetworkScanConfiguration(MutableInfectionMonkeyBaseModel):
|
||||
|
|
|
@ -27,7 +27,7 @@ SCAN_TARGET_CONFIGURATION = {
|
|||
TIMEOUT = 2.525
|
||||
ICMP_CONFIGURATION = {"timeout": TIMEOUT}
|
||||
|
||||
PORTS = [8080, 443]
|
||||
PORTS = [0, 8080, 443]
|
||||
TCP_SCAN_CONFIGURATION = {"timeout": TIMEOUT, "ports": PORTS}
|
||||
|
||||
FINGERPRINTERS = [{"name": "mssql", "options": {}}]
|
||||
|
|
Loading…
Reference in New Issue