scc-firewall-manager-sdk 1.13.665__py3-none-any.whl → 1.13.667__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of scc-firewall-manager-sdk might be problematic. Click here for more details.
- scc_firewall_manager_sdk/__init__.py +23 -1
- scc_firewall_manager_sdk/api/__init__.py +1 -0
- scc_firewall_manager_sdk/api/asa_interfaces_api.py +6565 -0
- scc_firewall_manager_sdk/api_client.py +1 -1
- scc_firewall_manager_sdk/configuration.py +1 -1
- scc_firewall_manager_sdk/models/__init__.py +21 -0
- scc_firewall_manager_sdk/models/asa_interface.py +184 -0
- scc_firewall_manager_sdk/models/asa_interface_page.py +102 -0
- scc_firewall_manager_sdk/models/duplex_type.py +39 -0
- scc_firewall_manager_sdk/models/ether_channel_interface_create_input.py +132 -0
- scc_firewall_manager_sdk/models/ether_channel_interface_patch_input.py +130 -0
- scc_firewall_manager_sdk/models/interface_ip_address.py +94 -0
- scc_firewall_manager_sdk/models/interface_ipv4_address.py +95 -0
- scc_firewall_manager_sdk/models/interface_ipv6_address.py +109 -0
- scc_firewall_manager_sdk/models/interface_mode.py +39 -0
- scc_firewall_manager_sdk/models/interface_runtime_data.py +101 -0
- scc_firewall_manager_sdk/models/interface_type.py +41 -0
- scc_firewall_manager_sdk/models/ip_type.py +39 -0
- scc_firewall_manager_sdk/models/link_state.py +38 -0
- scc_firewall_manager_sdk/models/physical_interface_patch_input.py +125 -0
- scc_firewall_manager_sdk/models/speed_type.py +41 -0
- scc_firewall_manager_sdk/models/sub_interface_create_input.py +130 -0
- scc_firewall_manager_sdk/models/sub_interface_patch_input.py +116 -0
- scc_firewall_manager_sdk/models/switch_port_config.py +94 -0
- scc_firewall_manager_sdk/models/vlan_id_range.py +90 -0
- scc_firewall_manager_sdk/models/vlan_interface_create_input.py +120 -0
- scc_firewall_manager_sdk/models/vlan_interface_patch_input.py +118 -0
- {scc_firewall_manager_sdk-1.13.665.dist-info → scc_firewall_manager_sdk-1.13.667.dist-info}/METADATA +1 -1
- {scc_firewall_manager_sdk-1.13.665.dist-info → scc_firewall_manager_sdk-1.13.667.dist-info}/RECORD +31 -9
- {scc_firewall_manager_sdk-1.13.665.dist-info → scc_firewall_manager_sdk-1.13.667.dist-info}/WHEEL +0 -0
- {scc_firewall_manager_sdk-1.13.665.dist-info → scc_firewall_manager_sdk-1.13.667.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Cisco Security Cloud Control Firewall Manager API
|
|
5
|
+
|
|
6
|
+
Use the documentation to explore the endpoints Security Cloud Control Firewall Manager has to offer
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.13.0
|
|
9
|
+
Contact: cdo.tac@cisco.com
|
|
10
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
|
+
|
|
12
|
+
Do not edit the class manually.
|
|
13
|
+
""" # noqa: E501
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import json
|
|
18
|
+
from enum import Enum
|
|
19
|
+
from typing_extensions import Self
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
class LinkState(str, Enum):
|
|
23
|
+
"""
|
|
24
|
+
LinkState
|
|
25
|
+
"""
|
|
26
|
+
|
|
27
|
+
"""
|
|
28
|
+
allowed enum values
|
|
29
|
+
"""
|
|
30
|
+
UP = 'UP'
|
|
31
|
+
DOWN = 'DOWN'
|
|
32
|
+
|
|
33
|
+
@classmethod
|
|
34
|
+
def from_json(cls, json_str: str) -> Self:
|
|
35
|
+
"""Create an instance of LinkState from a JSON string"""
|
|
36
|
+
return cls(json.loads(json_str))
|
|
37
|
+
|
|
38
|
+
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Cisco Security Cloud Control Firewall Manager API
|
|
5
|
+
|
|
6
|
+
Use the documentation to explore the endpoints Security Cloud Control Firewall Manager has to offer
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.13.0
|
|
9
|
+
Contact: cdo.tac@cisco.com
|
|
10
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
|
+
|
|
12
|
+
Do not edit the class manually.
|
|
13
|
+
""" # noqa: E501
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import pprint
|
|
18
|
+
import re # noqa: F401
|
|
19
|
+
import json
|
|
20
|
+
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr
|
|
22
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
23
|
+
from scc_firewall_manager_sdk.models.duplex_type import DuplexType
|
|
24
|
+
from scc_firewall_manager_sdk.models.interface_ipv4_address import InterfaceIpv4Address
|
|
25
|
+
from scc_firewall_manager_sdk.models.interface_ipv6_address import InterfaceIpv6Address
|
|
26
|
+
from scc_firewall_manager_sdk.models.interface_mode import InterfaceMode
|
|
27
|
+
from scc_firewall_manager_sdk.models.speed_type import SpeedType
|
|
28
|
+
from typing import Optional, Set
|
|
29
|
+
from typing_extensions import Self
|
|
30
|
+
|
|
31
|
+
class PhysicalInterfacePatchInput(BaseModel):
|
|
32
|
+
"""
|
|
33
|
+
PhysicalInterfacePatchInput
|
|
34
|
+
""" # noqa: E501
|
|
35
|
+
description: Optional[StrictStr] = Field(default=None, description="The description of the interface.")
|
|
36
|
+
duplex_type: Optional[DuplexType] = Field(default=None, alias="duplexType")
|
|
37
|
+
enabled: Optional[StrictBool] = Field(default=None, description="Indicates whether the interface is enabled.")
|
|
38
|
+
ipv4: Optional[InterfaceIpv4Address] = None
|
|
39
|
+
ipv6: Optional[InterfaceIpv6Address] = None
|
|
40
|
+
mac_address: Optional[StrictStr] = Field(default=None, description="The interface Media Access Control (MAC) address, a unique hardware identifier assigned to each physical interface. it is used for Layer 2 communication within a network segment.", alias="macAddress")
|
|
41
|
+
management_only: Optional[StrictBool] = Field(default=None, description="Indicates whether the interface is exclusively used for management traffic and does not carry regular user or data traffic", alias="managementOnly")
|
|
42
|
+
mode: Optional[InterfaceMode] = None
|
|
43
|
+
monitor_interface: Optional[StrictBool] = Field(default=None, description="Indicates if the interface is actively monitored for checking its operational status and health as part of an HA setup. It helps determine if the interface is functioning correctly and whether a failover to a standby device should be triggered in case of failure.", alias="monitorInterface")
|
|
44
|
+
mtu: Optional[StrictInt] = Field(default=None, description="The interface MTU (Maximum Transmission Unit), the largest size, in bytes, of a packet or frame that can be sent over a network interface without needing to be fragmented. It defines the maximum payload size that the interface can handle in a single transmission.")
|
|
45
|
+
name: Optional[StrictStr] = Field(default=None, description="The logical name of the interface. Interface names are unique in the scope of the device.")
|
|
46
|
+
security_level: Optional[StrictInt] = Field(default=None, description="Indicates the interface trust level, ranging from 0 (lowest) to 100 (highest).", alias="securityLevel")
|
|
47
|
+
speed_type: Optional[SpeedType] = Field(default=None, alias="speedType")
|
|
48
|
+
standby_mac_address: Optional[StrictStr] = Field(default=None, description="The standby interface Media Access Control (MAC) address, for use in a high-availability (HA) pair.", alias="standbyMacAddress")
|
|
49
|
+
__properties: ClassVar[List[str]] = ["description", "duplexType", "enabled", "ipv4", "ipv6", "macAddress", "managementOnly", "mode", "monitorInterface", "mtu", "name", "securityLevel", "speedType", "standbyMacAddress"]
|
|
50
|
+
|
|
51
|
+
model_config = ConfigDict(
|
|
52
|
+
populate_by_name=True,
|
|
53
|
+
validate_assignment=True,
|
|
54
|
+
protected_namespaces=(),
|
|
55
|
+
)
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
def to_str(self) -> str:
|
|
59
|
+
"""Returns the string representation of the model using alias"""
|
|
60
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
61
|
+
|
|
62
|
+
def to_json(self) -> str:
|
|
63
|
+
"""Returns the JSON representation of the model using alias"""
|
|
64
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
65
|
+
return json.dumps(self.to_dict())
|
|
66
|
+
|
|
67
|
+
@classmethod
|
|
68
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
69
|
+
"""Create an instance of PhysicalInterfacePatchInput from a JSON string"""
|
|
70
|
+
return cls.from_dict(json.loads(json_str))
|
|
71
|
+
|
|
72
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
73
|
+
"""Return the dictionary representation of the model using alias.
|
|
74
|
+
|
|
75
|
+
This has the following differences from calling pydantic's
|
|
76
|
+
`self.model_dump(by_alias=True)`:
|
|
77
|
+
|
|
78
|
+
* `None` is only added to the output dict for nullable fields that
|
|
79
|
+
were set at model initialization. Other fields with value `None`
|
|
80
|
+
are ignored.
|
|
81
|
+
"""
|
|
82
|
+
excluded_fields: Set[str] = set([
|
|
83
|
+
])
|
|
84
|
+
|
|
85
|
+
_dict = self.model_dump(
|
|
86
|
+
by_alias=True,
|
|
87
|
+
exclude=excluded_fields,
|
|
88
|
+
exclude_none=True,
|
|
89
|
+
)
|
|
90
|
+
# override the default output from pydantic by calling `to_dict()` of ipv4
|
|
91
|
+
if self.ipv4:
|
|
92
|
+
_dict['ipv4'] = self.ipv4.to_dict()
|
|
93
|
+
# override the default output from pydantic by calling `to_dict()` of ipv6
|
|
94
|
+
if self.ipv6:
|
|
95
|
+
_dict['ipv6'] = self.ipv6.to_dict()
|
|
96
|
+
return _dict
|
|
97
|
+
|
|
98
|
+
@classmethod
|
|
99
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
100
|
+
"""Create an instance of PhysicalInterfacePatchInput from a dict"""
|
|
101
|
+
if obj is None:
|
|
102
|
+
return None
|
|
103
|
+
|
|
104
|
+
if not isinstance(obj, dict):
|
|
105
|
+
return cls.model_validate(obj)
|
|
106
|
+
|
|
107
|
+
_obj = cls.model_validate({
|
|
108
|
+
"description": obj.get("description"),
|
|
109
|
+
"duplexType": obj.get("duplexType"),
|
|
110
|
+
"enabled": obj.get("enabled"),
|
|
111
|
+
"ipv4": InterfaceIpv4Address.from_dict(obj["ipv4"]) if obj.get("ipv4") is not None else None,
|
|
112
|
+
"ipv6": InterfaceIpv6Address.from_dict(obj["ipv6"]) if obj.get("ipv6") is not None else None,
|
|
113
|
+
"macAddress": obj.get("macAddress"),
|
|
114
|
+
"managementOnly": obj.get("managementOnly"),
|
|
115
|
+
"mode": obj.get("mode"),
|
|
116
|
+
"monitorInterface": obj.get("monitorInterface"),
|
|
117
|
+
"mtu": obj.get("mtu"),
|
|
118
|
+
"name": obj.get("name"),
|
|
119
|
+
"securityLevel": obj.get("securityLevel"),
|
|
120
|
+
"speedType": obj.get("speedType"),
|
|
121
|
+
"standbyMacAddress": obj.get("standbyMacAddress")
|
|
122
|
+
})
|
|
123
|
+
return _obj
|
|
124
|
+
|
|
125
|
+
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Cisco Security Cloud Control Firewall Manager API
|
|
5
|
+
|
|
6
|
+
Use the documentation to explore the endpoints Security Cloud Control Firewall Manager has to offer
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.13.0
|
|
9
|
+
Contact: cdo.tac@cisco.com
|
|
10
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
|
+
|
|
12
|
+
Do not edit the class manually.
|
|
13
|
+
""" # noqa: E501
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import json
|
|
18
|
+
from enum import Enum
|
|
19
|
+
from typing_extensions import Self
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
class SpeedType(str, Enum):
|
|
23
|
+
"""
|
|
24
|
+
SpeedType
|
|
25
|
+
"""
|
|
26
|
+
|
|
27
|
+
"""
|
|
28
|
+
allowed enum values
|
|
29
|
+
"""
|
|
30
|
+
AUTO = 'AUTO'
|
|
31
|
+
TEN = 'TEN'
|
|
32
|
+
HUNDRED = 'HUNDRED'
|
|
33
|
+
THOUSAND = 'THOUSAND'
|
|
34
|
+
TEN_THOUSAND = 'TEN_THOUSAND'
|
|
35
|
+
|
|
36
|
+
@classmethod
|
|
37
|
+
def from_json(cls, json_str: str) -> Self:
|
|
38
|
+
"""Create an instance of SpeedType from a JSON string"""
|
|
39
|
+
return cls(json.loads(json_str))
|
|
40
|
+
|
|
41
|
+
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Cisco Security Cloud Control Firewall Manager API
|
|
5
|
+
|
|
6
|
+
Use the documentation to explore the endpoints Security Cloud Control Firewall Manager has to offer
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.13.0
|
|
9
|
+
Contact: cdo.tac@cisco.com
|
|
10
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
|
+
|
|
12
|
+
Do not edit the class manually.
|
|
13
|
+
""" # noqa: E501
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import pprint
|
|
18
|
+
import re # noqa: F401
|
|
19
|
+
import json
|
|
20
|
+
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr
|
|
22
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
23
|
+
from scc_firewall_manager_sdk.models.interface_ipv4_address import InterfaceIpv4Address
|
|
24
|
+
from scc_firewall_manager_sdk.models.interface_ipv6_address import InterfaceIpv6Address
|
|
25
|
+
from scc_firewall_manager_sdk.models.vlan_id_range import VlanIdRange
|
|
26
|
+
from typing import Optional, Set
|
|
27
|
+
from typing_extensions import Self
|
|
28
|
+
|
|
29
|
+
class SubInterfaceCreateInput(BaseModel):
|
|
30
|
+
"""
|
|
31
|
+
SubInterfaceCreateInput
|
|
32
|
+
""" # noqa: E501
|
|
33
|
+
description: Optional[StrictStr] = Field(default=None, description="The description of the interface.")
|
|
34
|
+
enabled: Optional[StrictBool] = Field(default=None, description="Indicates whether the interface is enabled.")
|
|
35
|
+
ipv4: Optional[InterfaceIpv4Address] = None
|
|
36
|
+
ipv6: Optional[InterfaceIpv6Address] = None
|
|
37
|
+
mac_address: Optional[StrictStr] = Field(default=None, description="The interface Media Access Control (MAC) address, a unique hardware identifier assigned to each physical interface. it is used for Layer 2 communication within a network segment.", alias="macAddress")
|
|
38
|
+
management_only: Optional[StrictBool] = Field(default=None, description="Indicates whether the interface is exclusively used for management traffic and does not carry regular user or data traffic", alias="managementOnly")
|
|
39
|
+
monitor_interface: Optional[StrictBool] = Field(default=None, description="Indicates if the interface is actively monitored for checking its operational status and health as part of an HA setup. It helps determine if the interface is functioning correctly and whether a failover to a standby device should be triggered in case of failure.", alias="monitorInterface")
|
|
40
|
+
mtu: Optional[StrictInt] = Field(default=None, description="The interface MTU (Maximum Transmission Unit), the largest size, in bytes, of a packet or frame that can be sent over a network interface without needing to be fragmented. It defines the maximum payload size that the interface can handle in a single transmission.")
|
|
41
|
+
name: Optional[StrictStr] = Field(default=None, description="The logical name of the interface. Interface names are unique in the scope of the device.")
|
|
42
|
+
security_level: Optional[StrictInt] = Field(default=None, description="Indicates the interface trust level, ranging from 0 (lowest) to 100 (highest).", alias="securityLevel")
|
|
43
|
+
standby_mac_address: Optional[StrictStr] = Field(default=None, description="The standby interface Media Access Control (MAC) address, for use in a high-availability (HA) pair.", alias="standbyMacAddress")
|
|
44
|
+
sub_interface_id: Optional[StrictInt] = Field(default=None, description="The unique identifier of the sub-interface in the scope of the parent interface. It is used to differentiate between multiple sub-interfaces on the same parent interface. Range is 1 - 4294967295.", alias="subInterfaceId")
|
|
45
|
+
vlan_primary_id: Optional[StrictInt] = Field(default=None, description="The primary unique identifier of the VLAN associated with the sub-interface. Range is 1 - 4094.", alias="vlanPrimaryId")
|
|
46
|
+
vlan_secondary_ids: Optional[List[VlanIdRange]] = Field(default=None, description="The secondary identifiers of the VLAN associated with the sub-interface. Each range is defined by a start and end value, allowing for multiple VLANs to be associated with the sub-interface. Ranges are inclusive.", alias="vlanSecondaryIds")
|
|
47
|
+
__properties: ClassVar[List[str]] = ["description", "enabled", "ipv4", "ipv6", "macAddress", "managementOnly", "monitorInterface", "mtu", "name", "securityLevel", "standbyMacAddress", "subInterfaceId", "vlanPrimaryId", "vlanSecondaryIds"]
|
|
48
|
+
|
|
49
|
+
model_config = ConfigDict(
|
|
50
|
+
populate_by_name=True,
|
|
51
|
+
validate_assignment=True,
|
|
52
|
+
protected_namespaces=(),
|
|
53
|
+
)
|
|
54
|
+
|
|
55
|
+
|
|
56
|
+
def to_str(self) -> str:
|
|
57
|
+
"""Returns the string representation of the model using alias"""
|
|
58
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
59
|
+
|
|
60
|
+
def to_json(self) -> str:
|
|
61
|
+
"""Returns the JSON representation of the model using alias"""
|
|
62
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
63
|
+
return json.dumps(self.to_dict())
|
|
64
|
+
|
|
65
|
+
@classmethod
|
|
66
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
67
|
+
"""Create an instance of SubInterfaceCreateInput from a JSON string"""
|
|
68
|
+
return cls.from_dict(json.loads(json_str))
|
|
69
|
+
|
|
70
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
71
|
+
"""Return the dictionary representation of the model using alias.
|
|
72
|
+
|
|
73
|
+
This has the following differences from calling pydantic's
|
|
74
|
+
`self.model_dump(by_alias=True)`:
|
|
75
|
+
|
|
76
|
+
* `None` is only added to the output dict for nullable fields that
|
|
77
|
+
were set at model initialization. Other fields with value `None`
|
|
78
|
+
are ignored.
|
|
79
|
+
"""
|
|
80
|
+
excluded_fields: Set[str] = set([
|
|
81
|
+
])
|
|
82
|
+
|
|
83
|
+
_dict = self.model_dump(
|
|
84
|
+
by_alias=True,
|
|
85
|
+
exclude=excluded_fields,
|
|
86
|
+
exclude_none=True,
|
|
87
|
+
)
|
|
88
|
+
# override the default output from pydantic by calling `to_dict()` of ipv4
|
|
89
|
+
if self.ipv4:
|
|
90
|
+
_dict['ipv4'] = self.ipv4.to_dict()
|
|
91
|
+
# override the default output from pydantic by calling `to_dict()` of ipv6
|
|
92
|
+
if self.ipv6:
|
|
93
|
+
_dict['ipv6'] = self.ipv6.to_dict()
|
|
94
|
+
# override the default output from pydantic by calling `to_dict()` of each item in vlan_secondary_ids (list)
|
|
95
|
+
_items = []
|
|
96
|
+
if self.vlan_secondary_ids:
|
|
97
|
+
for _item in self.vlan_secondary_ids:
|
|
98
|
+
if _item:
|
|
99
|
+
_items.append(_item.to_dict())
|
|
100
|
+
_dict['vlanSecondaryIds'] = _items
|
|
101
|
+
return _dict
|
|
102
|
+
|
|
103
|
+
@classmethod
|
|
104
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
105
|
+
"""Create an instance of SubInterfaceCreateInput from a dict"""
|
|
106
|
+
if obj is None:
|
|
107
|
+
return None
|
|
108
|
+
|
|
109
|
+
if not isinstance(obj, dict):
|
|
110
|
+
return cls.model_validate(obj)
|
|
111
|
+
|
|
112
|
+
_obj = cls.model_validate({
|
|
113
|
+
"description": obj.get("description"),
|
|
114
|
+
"enabled": obj.get("enabled"),
|
|
115
|
+
"ipv4": InterfaceIpv4Address.from_dict(obj["ipv4"]) if obj.get("ipv4") is not None else None,
|
|
116
|
+
"ipv6": InterfaceIpv6Address.from_dict(obj["ipv6"]) if obj.get("ipv6") is not None else None,
|
|
117
|
+
"macAddress": obj.get("macAddress"),
|
|
118
|
+
"managementOnly": obj.get("managementOnly"),
|
|
119
|
+
"monitorInterface": obj.get("monitorInterface"),
|
|
120
|
+
"mtu": obj.get("mtu"),
|
|
121
|
+
"name": obj.get("name"),
|
|
122
|
+
"securityLevel": obj.get("securityLevel"),
|
|
123
|
+
"standbyMacAddress": obj.get("standbyMacAddress"),
|
|
124
|
+
"subInterfaceId": obj.get("subInterfaceId"),
|
|
125
|
+
"vlanPrimaryId": obj.get("vlanPrimaryId"),
|
|
126
|
+
"vlanSecondaryIds": [VlanIdRange.from_dict(_item) for _item in obj["vlanSecondaryIds"]] if obj.get("vlanSecondaryIds") is not None else None
|
|
127
|
+
})
|
|
128
|
+
return _obj
|
|
129
|
+
|
|
130
|
+
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Cisco Security Cloud Control Firewall Manager API
|
|
5
|
+
|
|
6
|
+
Use the documentation to explore the endpoints Security Cloud Control Firewall Manager has to offer
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.13.0
|
|
9
|
+
Contact: cdo.tac@cisco.com
|
|
10
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
|
+
|
|
12
|
+
Do not edit the class manually.
|
|
13
|
+
""" # noqa: E501
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import pprint
|
|
18
|
+
import re # noqa: F401
|
|
19
|
+
import json
|
|
20
|
+
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr
|
|
22
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
23
|
+
from scc_firewall_manager_sdk.models.interface_ipv4_address import InterfaceIpv4Address
|
|
24
|
+
from scc_firewall_manager_sdk.models.interface_ipv6_address import InterfaceIpv6Address
|
|
25
|
+
from typing import Optional, Set
|
|
26
|
+
from typing_extensions import Self
|
|
27
|
+
|
|
28
|
+
class SubInterfacePatchInput(BaseModel):
|
|
29
|
+
"""
|
|
30
|
+
SubInterfacePatchInput
|
|
31
|
+
""" # noqa: E501
|
|
32
|
+
description: Optional[StrictStr] = Field(default=None, description="The description of the interface.")
|
|
33
|
+
enabled: Optional[StrictBool] = Field(default=None, description="Indicates whether the interface is enabled.")
|
|
34
|
+
ipv4: Optional[InterfaceIpv4Address] = None
|
|
35
|
+
ipv6: Optional[InterfaceIpv6Address] = None
|
|
36
|
+
mac_address: Optional[StrictStr] = Field(default=None, description="The interface Media Access Control (MAC) address, a unique hardware identifier assigned to each physical interface. it is used for Layer 2 communication within a network segment.", alias="macAddress")
|
|
37
|
+
management_only: Optional[StrictBool] = Field(default=None, description="Indicates whether the interface is exclusively used for management traffic and does not carry regular user or data traffic", alias="managementOnly")
|
|
38
|
+
monitor_interface: Optional[StrictBool] = Field(default=None, description="Indicates if the interface is actively monitored for checking its operational status and health as part of an HA setup. It helps determine if the interface is functioning correctly and whether a failover to a standby device should be triggered in case of failure.", alias="monitorInterface")
|
|
39
|
+
mtu: Optional[StrictInt] = Field(default=None, description="The interface MTU (Maximum Transmission Unit), the largest size, in bytes, of a packet or frame that can be sent over a network interface without needing to be fragmented. It defines the maximum payload size that the interface can handle in a single transmission.")
|
|
40
|
+
name: Optional[StrictStr] = Field(default=None, description="The logical name of the interface. Interface names are unique in the scope of the device.")
|
|
41
|
+
security_level: Optional[StrictInt] = Field(default=None, description="Indicates the interface trust level, ranging from 0 (lowest) to 100 (highest).", alias="securityLevel")
|
|
42
|
+
standby_mac_address: Optional[StrictStr] = Field(default=None, description="The standby interface Media Access Control (MAC) address, for use in a high-availability (HA) pair.", alias="standbyMacAddress")
|
|
43
|
+
__properties: ClassVar[List[str]] = ["description", "enabled", "ipv4", "ipv6", "macAddress", "managementOnly", "monitorInterface", "mtu", "name", "securityLevel", "standbyMacAddress"]
|
|
44
|
+
|
|
45
|
+
model_config = ConfigDict(
|
|
46
|
+
populate_by_name=True,
|
|
47
|
+
validate_assignment=True,
|
|
48
|
+
protected_namespaces=(),
|
|
49
|
+
)
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
def to_str(self) -> str:
|
|
53
|
+
"""Returns the string representation of the model using alias"""
|
|
54
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
55
|
+
|
|
56
|
+
def to_json(self) -> str:
|
|
57
|
+
"""Returns the JSON representation of the model using alias"""
|
|
58
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
59
|
+
return json.dumps(self.to_dict())
|
|
60
|
+
|
|
61
|
+
@classmethod
|
|
62
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
63
|
+
"""Create an instance of SubInterfacePatchInput from a JSON string"""
|
|
64
|
+
return cls.from_dict(json.loads(json_str))
|
|
65
|
+
|
|
66
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
67
|
+
"""Return the dictionary representation of the model using alias.
|
|
68
|
+
|
|
69
|
+
This has the following differences from calling pydantic's
|
|
70
|
+
`self.model_dump(by_alias=True)`:
|
|
71
|
+
|
|
72
|
+
* `None` is only added to the output dict for nullable fields that
|
|
73
|
+
were set at model initialization. Other fields with value `None`
|
|
74
|
+
are ignored.
|
|
75
|
+
"""
|
|
76
|
+
excluded_fields: Set[str] = set([
|
|
77
|
+
])
|
|
78
|
+
|
|
79
|
+
_dict = self.model_dump(
|
|
80
|
+
by_alias=True,
|
|
81
|
+
exclude=excluded_fields,
|
|
82
|
+
exclude_none=True,
|
|
83
|
+
)
|
|
84
|
+
# override the default output from pydantic by calling `to_dict()` of ipv4
|
|
85
|
+
if self.ipv4:
|
|
86
|
+
_dict['ipv4'] = self.ipv4.to_dict()
|
|
87
|
+
# override the default output from pydantic by calling `to_dict()` of ipv6
|
|
88
|
+
if self.ipv6:
|
|
89
|
+
_dict['ipv6'] = self.ipv6.to_dict()
|
|
90
|
+
return _dict
|
|
91
|
+
|
|
92
|
+
@classmethod
|
|
93
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
94
|
+
"""Create an instance of SubInterfacePatchInput from a dict"""
|
|
95
|
+
if obj is None:
|
|
96
|
+
return None
|
|
97
|
+
|
|
98
|
+
if not isinstance(obj, dict):
|
|
99
|
+
return cls.model_validate(obj)
|
|
100
|
+
|
|
101
|
+
_obj = cls.model_validate({
|
|
102
|
+
"description": obj.get("description"),
|
|
103
|
+
"enabled": obj.get("enabled"),
|
|
104
|
+
"ipv4": InterfaceIpv4Address.from_dict(obj["ipv4"]) if obj.get("ipv4") is not None else None,
|
|
105
|
+
"ipv6": InterfaceIpv6Address.from_dict(obj["ipv6"]) if obj.get("ipv6") is not None else None,
|
|
106
|
+
"macAddress": obj.get("macAddress"),
|
|
107
|
+
"managementOnly": obj.get("managementOnly"),
|
|
108
|
+
"monitorInterface": obj.get("monitorInterface"),
|
|
109
|
+
"mtu": obj.get("mtu"),
|
|
110
|
+
"name": obj.get("name"),
|
|
111
|
+
"securityLevel": obj.get("securityLevel"),
|
|
112
|
+
"standbyMacAddress": obj.get("standbyMacAddress")
|
|
113
|
+
})
|
|
114
|
+
return _obj
|
|
115
|
+
|
|
116
|
+
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Cisco Security Cloud Control Firewall Manager API
|
|
5
|
+
|
|
6
|
+
Use the documentation to explore the endpoints Security Cloud Control Firewall Manager has to offer
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.13.0
|
|
9
|
+
Contact: cdo.tac@cisco.com
|
|
10
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
|
+
|
|
12
|
+
Do not edit the class manually.
|
|
13
|
+
""" # noqa: E501
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import pprint
|
|
18
|
+
import re # noqa: F401
|
|
19
|
+
import json
|
|
20
|
+
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr
|
|
22
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
23
|
+
from typing import Optional, Set
|
|
24
|
+
from typing_extensions import Self
|
|
25
|
+
|
|
26
|
+
class SwitchPortConfig(BaseModel):
|
|
27
|
+
"""
|
|
28
|
+
SwitchPortConfig
|
|
29
|
+
""" # noqa: E501
|
|
30
|
+
access_mode_vlan: Optional[StrictStr] = Field(default=None, description="The unique identifier, represented as a UUID, of the access VLAN that this interface is associated with.", alias="accessModeVlan")
|
|
31
|
+
protected_enabled: Optional[StrictBool] = Field(default=None, description="Indicates whether the switch port interface is protected or not. Protected prevents any Layer 2 communication (unicast, multicast, broadcast) between other protected ports on the same VLAN.", alias="protectedEnabled")
|
|
32
|
+
trunk_mode_allowed_vlans: Optional[List[StrictStr]] = Field(default=None, description="The unique identifiers, represented as UUIDs, of the VLAN interfaces that are permitted to pass traffic over the trunk port.", alias="trunkModeAllowedVlans")
|
|
33
|
+
trunk_mode_native_vlan: Optional[StrictStr] = Field(default=None, description="The unique identifier, represented as a UUID, of the trunk VLAN that this interface is associated with.", alias="trunkModeNativeVlan")
|
|
34
|
+
__properties: ClassVar[List[str]] = ["accessModeVlan", "protectedEnabled", "trunkModeAllowedVlans", "trunkModeNativeVlan"]
|
|
35
|
+
|
|
36
|
+
model_config = ConfigDict(
|
|
37
|
+
populate_by_name=True,
|
|
38
|
+
validate_assignment=True,
|
|
39
|
+
protected_namespaces=(),
|
|
40
|
+
)
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
def to_str(self) -> str:
|
|
44
|
+
"""Returns the string representation of the model using alias"""
|
|
45
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
46
|
+
|
|
47
|
+
def to_json(self) -> str:
|
|
48
|
+
"""Returns the JSON representation of the model using alias"""
|
|
49
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
50
|
+
return json.dumps(self.to_dict())
|
|
51
|
+
|
|
52
|
+
@classmethod
|
|
53
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
54
|
+
"""Create an instance of SwitchPortConfig from a JSON string"""
|
|
55
|
+
return cls.from_dict(json.loads(json_str))
|
|
56
|
+
|
|
57
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
58
|
+
"""Return the dictionary representation of the model using alias.
|
|
59
|
+
|
|
60
|
+
This has the following differences from calling pydantic's
|
|
61
|
+
`self.model_dump(by_alias=True)`:
|
|
62
|
+
|
|
63
|
+
* `None` is only added to the output dict for nullable fields that
|
|
64
|
+
were set at model initialization. Other fields with value `None`
|
|
65
|
+
are ignored.
|
|
66
|
+
"""
|
|
67
|
+
excluded_fields: Set[str] = set([
|
|
68
|
+
])
|
|
69
|
+
|
|
70
|
+
_dict = self.model_dump(
|
|
71
|
+
by_alias=True,
|
|
72
|
+
exclude=excluded_fields,
|
|
73
|
+
exclude_none=True,
|
|
74
|
+
)
|
|
75
|
+
return _dict
|
|
76
|
+
|
|
77
|
+
@classmethod
|
|
78
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
79
|
+
"""Create an instance of SwitchPortConfig from a dict"""
|
|
80
|
+
if obj is None:
|
|
81
|
+
return None
|
|
82
|
+
|
|
83
|
+
if not isinstance(obj, dict):
|
|
84
|
+
return cls.model_validate(obj)
|
|
85
|
+
|
|
86
|
+
_obj = cls.model_validate({
|
|
87
|
+
"accessModeVlan": obj.get("accessModeVlan"),
|
|
88
|
+
"protectedEnabled": obj.get("protectedEnabled"),
|
|
89
|
+
"trunkModeAllowedVlans": obj.get("trunkModeAllowedVlans"),
|
|
90
|
+
"trunkModeNativeVlan": obj.get("trunkModeNativeVlan")
|
|
91
|
+
})
|
|
92
|
+
return _obj
|
|
93
|
+
|
|
94
|
+
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Cisco Security Cloud Control Firewall Manager API
|
|
5
|
+
|
|
6
|
+
Use the documentation to explore the endpoints Security Cloud Control Firewall Manager has to offer
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.13.0
|
|
9
|
+
Contact: cdo.tac@cisco.com
|
|
10
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
|
+
|
|
12
|
+
Do not edit the class manually.
|
|
13
|
+
""" # noqa: E501
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import pprint
|
|
18
|
+
import re # noqa: F401
|
|
19
|
+
import json
|
|
20
|
+
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, StrictInt
|
|
22
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
23
|
+
from typing import Optional, Set
|
|
24
|
+
from typing_extensions import Self
|
|
25
|
+
|
|
26
|
+
class VlanIdRange(BaseModel):
|
|
27
|
+
"""
|
|
28
|
+
VlanIdRange
|
|
29
|
+
""" # noqa: E501
|
|
30
|
+
end: Optional[StrictInt] = None
|
|
31
|
+
start: Optional[StrictInt] = None
|
|
32
|
+
__properties: ClassVar[List[str]] = ["end", "start"]
|
|
33
|
+
|
|
34
|
+
model_config = ConfigDict(
|
|
35
|
+
populate_by_name=True,
|
|
36
|
+
validate_assignment=True,
|
|
37
|
+
protected_namespaces=(),
|
|
38
|
+
)
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
def to_str(self) -> str:
|
|
42
|
+
"""Returns the string representation of the model using alias"""
|
|
43
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
44
|
+
|
|
45
|
+
def to_json(self) -> str:
|
|
46
|
+
"""Returns the JSON representation of the model using alias"""
|
|
47
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
48
|
+
return json.dumps(self.to_dict())
|
|
49
|
+
|
|
50
|
+
@classmethod
|
|
51
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
52
|
+
"""Create an instance of VlanIdRange from a JSON string"""
|
|
53
|
+
return cls.from_dict(json.loads(json_str))
|
|
54
|
+
|
|
55
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
56
|
+
"""Return the dictionary representation of the model using alias.
|
|
57
|
+
|
|
58
|
+
This has the following differences from calling pydantic's
|
|
59
|
+
`self.model_dump(by_alias=True)`:
|
|
60
|
+
|
|
61
|
+
* `None` is only added to the output dict for nullable fields that
|
|
62
|
+
were set at model initialization. Other fields with value `None`
|
|
63
|
+
are ignored.
|
|
64
|
+
"""
|
|
65
|
+
excluded_fields: Set[str] = set([
|
|
66
|
+
])
|
|
67
|
+
|
|
68
|
+
_dict = self.model_dump(
|
|
69
|
+
by_alias=True,
|
|
70
|
+
exclude=excluded_fields,
|
|
71
|
+
exclude_none=True,
|
|
72
|
+
)
|
|
73
|
+
return _dict
|
|
74
|
+
|
|
75
|
+
@classmethod
|
|
76
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
77
|
+
"""Create an instance of VlanIdRange from a dict"""
|
|
78
|
+
if obj is None:
|
|
79
|
+
return None
|
|
80
|
+
|
|
81
|
+
if not isinstance(obj, dict):
|
|
82
|
+
return cls.model_validate(obj)
|
|
83
|
+
|
|
84
|
+
_obj = cls.model_validate({
|
|
85
|
+
"end": obj.get("end"),
|
|
86
|
+
"start": obj.get("start")
|
|
87
|
+
})
|
|
88
|
+
return _obj
|
|
89
|
+
|
|
90
|
+
|