Skip to content

Commit 4bd1de0

Browse files
committed
refactor(rules): Remove inbound/outbound network macros
Removes inbound/outbound network macros from the rule and switches to using only the connect socket event.
1 parent b75d8ed commit 4bd1de0

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

rules/persistence_network_connection_via_startup_folder_executable_or_script.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: Network connection via startup folder executable or script
22
id: 09b7278d-42e3-4792-9f00-dee38baecfad
3-
version: 1.0.5
3+
version: 1.1.0
44
description: |
55
Identifies the execution of unsigned binary or script from the
66
Startup folder followed by network inbound or outbound connection.
@@ -22,6 +22,10 @@ condition: >
2222
|(load_untrusted_executable and module.path imatches startup_locations) or
2323
(load_executable and ps.name in script_interpreters and ps.cmdline imatches startup_locations)
2424
|
25-
|((inbound_network) or (outbound_network)) and ps.cmdline imatches startup_locations|
25+
|connect_socket and
26+
ps.cmdline imatches startup_locations and
27+
net.dip != 0.0.0.0 and net.dip not in ('0:0:0:0:0:0:0:1', '::1') and
28+
not cidr_contains(net.dip, '127.0.0.0/8', '10.0.0.0/8', '172.16.0.0/12', '192.168.0.0/16')
29+
|
2630
2731
min-engine-version: 3.0.0

0 commit comments

Comments
 (0)