csle_rest_api.resources.create_emulation package
Submodules
csle_rest_api.resources.create_emulation.routes module
Routes and sub-resources for the /create-emulation resource
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_beats_config(emulation_data: Dict[str, Any]) BeatsConfig [source]
Converts the json emulation data to the beats config
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- Returns
the beats configuration
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_containers_config(emulation_data: Dict[str, Any]) ContainersConfig [source]
Converts the json emulation data to a containers configuration object.
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- Returns
the ContainersConfig of the emulation
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_docker_stats_manager_config(emulation_data: Dict[str, Any]) DockerStatsManagerConfig [source]
Converts the json emulation data to the docker stats manager configuration
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- Returns
the docker stats manager configuration
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_elk_config(emulation_data: Dict[str, Any]) ElkConfig [source]
Converts the json emulation data to the default ELK configuration
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- Returns
the ELK configuration
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_emulation_config(emulation_data: Dict[str, Any]) EmulationEnvConfig [source]
Converts the json emulation data to an emulation environment configuration object.
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- Returns
the emulation environment configuration
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_flags_config(emulation_data: Dict[str, Any]) FlagsConfig [source]
Converts the json emulation data to a flags configuration object.
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- Returns
The flags confguration
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_host_manager_config(emulation_data: Dict[str, Any]) HostManagerConfig [source]
Converts the json emulation data to the host manager configuration
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- Returns
the host manager configuration
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_kafka_config(emulation_data: Dict[str, Any]) KafkaConfig [source]
Converts the json emulation data to the kafka configuration
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- Returns
the kafka configuration
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_ossec_ids_manager_config(emulation_data: Dict[str, Any]) OSSECIDSManagerConfig [source]
Converts the json emulation data to the OSSEC IDS manager configuration
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- Returns
the OSSEC IDS manager configuration
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_ovs_config(emulation_data: Dict[str, Any]) OVSConfig [source]
Converts the json emulation data to the OVS config
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_resource_constraints_config(emulation_data: Dict[str, Any]) ResourcesConfig [source]
Converts the json emulation data to the resource constraints config
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- Returns
generates the ResourcesConfig
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_sdn_controller_config(emulation_data: Dict[str, Any]) Union[None, SDNControllerConfig] [source]
Generates the Converts the json emulation data to the SDN controller config
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_services_config(emulation_data: Dict[str, Any]) ServicesConfig [source]
Converts the json emulation data to the services config
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- Returns
The services configuration
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_snort_ids_manager_config(emulation_data: Dict[str, Any]) SnortIDSManagerConfig [source]
Converts the json emulation data to the Snort IDS manager configuration
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- Returns
the Snort IDS manager configuration
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_static_attacker_sequences(subnet_masks: List[str]) Dict[str, List[EmulationAttackerAction]] [source]
Generates Converts the json emulation data to the attacker sequences config
- Parameters
subnetmasks – list of subnet masks for the emulation
- Returns
the default static attacker sequences configuration
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_topology_config(emulation_data: Dict[str, Any]) TopologyConfig [source]
Converts the json emulation data to the topology config
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- Returns
the Topology configuration
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_traffic_config(emulation_data: Dict[str, Any]) TrafficConfig [source]
Converts the json emulation data to the traffic config
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- Returns
the traffic configuration
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_users_config(emulation_data: Dict[str, Any]) UsersConfig [source]
Converts the json emulation data to the users config
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- Returns
generates the UsersConfig
- csle_rest_api.resources.create_emulation.routes.convert_json_data_to_vulns_config(emulation_data: Dict[str, Any]) VulnerabilitiesConfig [source]
Converts the json emulation data to the vulnerabilities config
- Parameters
emulation_data – the emulation data in JSON format received from front-end
- Returns
the vulnerability config