Skip to content

Commit 2bd6c44

Browse files
updating network traffic datamodel
1 parent df72135 commit 2bd6c44

File tree

1 file changed

+9
-8
lines changed

1 file changed

+9
-8
lines changed

pytest_splunk_addon/standard_lib/data_models/Network_Traffic.json

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -64,14 +64,15 @@
6464
{
6565
"name": "dest_ip",
6666
"type": "conditional",
67-
"condition": "| regex dest=\"(?:[0-9A-Fa-f]{1,4}:){7}[0-9A-Fa-f]{1,4}|(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)(?:\\.|$)){4}\"",
68-
"validity": "if(dest_ip==dest,dest_ip,null())",
67+
"condition": "dest_ip=*",
68+
"validity": "if(match(dest_ip, \"(?:[0-9A-Fa-f]{1,4}:){7}[0-9A-Fa-f]{1,4}|(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)(?:\\.|$)){4}\"),dest_ip,null())",
6969
"comment": "The IP address of the destination."
7070
},
7171
{
7272
"name": "dest_mac",
73-
"type": "optional",
74-
"validity": "if(dest==dest_mac,dest_mac,null())",
73+
"type": "conditional",
74+
"condition": "dest_mac=*",
75+
"validity": "if(match(dest_mac,\"^([0-9A-F]{2}[:-]){5}([0-9A-F]{2})$\"),dest_mac,null())",
7576
"comment": "The destination TCP/IP layer 2 Media Access Control (MAC) address of a packet's destination, such as 06:10:9f:eb:8f:14. Note: Always force lower case on this field and use colons instead of dashes, spaces, or no separator."
7677
},
7778
{
@@ -265,15 +266,15 @@
265266
{
266267
"name": "src_ip",
267268
"type": "conditional",
268-
"condition": "| regex src=\"(?:[0-9A-Fa-f]{1,4}:){7}[0-9A-Fa-f]{1,4}|(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)(?:\\.|$)){4}\"",
269-
"validity": "if(src_ip==src,src_ip,null())",
269+
"condition": "src_ip=*",
270+
"validity": "if(match(src_ip, \"(?:[0-9A-Fa-f]{1,4}:){7}[0-9A-Fa-f]{1,4}|(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)(?:\\.|$)){4}\"),src_ip,null())",
270271
"comment": "The ip address of the source."
271272
},
272273
{
273274
"name": "src_mac",
274275
"type": "conditional",
275-
"condition": "| regex src=\"^([0-9A-F]{2}[:-]){5}([0-9A-F]{2})$\"",
276-
"validity": "if(src==src_mac,src_mac,null())",
276+
"condition": "src_mac=*",
277+
"validity": "if(match(src_mac,\"^([0-9A-F]{2}[:-]){5}([0-9A-F]{2})$\"),src_mac,null())",
277278
"comment": "The source TCP/IP layer 2 Media Access Control (MAC) address of a packet's destination, such as 06:10:9f:eb:8f:14. Note: Always force lower case on this field and use colons instead of dashes, spaces, or no separator."
278279
},
279280
{

0 commit comments

Comments
 (0)