Skip to content

Commit

Permalink
Merge branch 'master' of github.com:oasis-open/cti-python-stix2 into …
Browse files Browse the repository at this point in the history
…main
  • Loading branch information
chrisr3d committed Jul 9, 2020
2 parents 87d178d + c497038 commit 0d6db44
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 15 deletions.
5 changes: 0 additions & 5 deletions stix2/test/v21/test_observed_data.py
Expand Up @@ -1139,7 +1139,6 @@ def test_network_traffic_socket_example():
h = stix2.v21.SocketExt(
is_listening=True,
address_family="AF_INET",
protocol_family="PF_INET",
socket_type="SOCK_STREAM",
)
nt = stix2.v21.NetworkTraffic(
Expand All @@ -1149,15 +1148,13 @@ def test_network_traffic_socket_example():
)
assert nt.extensions['socket-ext'].is_listening
assert nt.extensions['socket-ext'].address_family == "AF_INET"
assert nt.extensions['socket-ext'].protocol_family == "PF_INET"
assert nt.extensions['socket-ext'].socket_type == "SOCK_STREAM"


def test_correct_socket_options():
se1 = stix2.v21.SocketExt(
is_listening=True,
address_family="AF_INET",
protocol_family="PF_INET",
socket_type="SOCK_STREAM",
options={"ICMP6_RCVTIMEO": 100},
)
Expand All @@ -1172,7 +1169,6 @@ def test_incorrect_socket_options():
stix2.v21.SocketExt(
is_listening=True,
address_family="AF_INET",
protocol_family="PF_INET",
socket_type="SOCK_STREAM",
options={"RCVTIMEO": 100},
)
Expand All @@ -1182,7 +1178,6 @@ def test_incorrect_socket_options():
stix2.v21.SocketExt(
is_listening=True,
address_family="AF_INET",
protocol_family="PF_INET",
socket_type="SOCK_STREAM",
options={"SO_RCVTIMEO": '100'},
)
Expand Down
10 changes: 0 additions & 10 deletions stix2/v21/observables.py
Expand Up @@ -503,16 +503,6 @@ class SocketExt(_Extension):
),
('is_blocking', BooleanProperty()),
('is_listening', BooleanProperty()),
(
'protocol_family', EnumProperty(allowed=[
"PF_INET",
"PF_IPX",
"PF_APPLETALK",
"PF_INET6",
"PF_AX25",
"PF_NETROM",
]),
),
('options', DictionaryProperty(spec_version='2.1')),
(
'socket_type', EnumProperty(allowed=[
Expand Down

0 comments on commit 0d6db44

Please sign in to comment.