Skip to content

Commit a6296a8

Browse files
fix null query filter conversion from sigma to query string query (opensearch-project#722) (opensearch-project#813)
* fix null query filter conversion from sigma to query string query Signed-off-by: Surya Sashank Nistala <[email protected]> * fix rule to query conversion tests for null filter Signed-off-by: Surya Sashank Nistala <[email protected]> * enhance test to verify non null doc doesnt match null query Signed-off-by: Surya Sashank Nistala <[email protected]> --------- Signed-off-by: Surya Sashank Nistala <[email protected]> (cherry picked from commit a59a014) Co-authored-by: Surya Sashank Nistala <[email protected]>
1 parent 7fbe7c0 commit a6296a8

File tree

2 files changed

+32
-0
lines changed

2 files changed

+32
-0
lines changed

src/test/java/org/opensearch/securityanalytics/DetectorThreatIntelIT.java

Whitespace-only changes.

src/test/java/org/opensearch/securityanalytics/TestHelpers.java

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -209,6 +209,38 @@ public static String randomRule() {
209209
"level: high";
210210
}
211211

212+
public static String randomNullRule() {
213+
return "title: null field\n" +
214+
"id: 5f92fff9-82e2-48eb-8fc1-8b133556a551\n" +
215+
"description: Detects remote RPC calls to possibly abuse remote encryption service via MS-EFSR\n" +
216+
"references:\n" +
217+
" - https://attack.mitre.org/tactics/TA0008/\n" +
218+
" - https://msrc.microsoft.com/update-guide/vulnerability/CVE-2021-36942\n" +
219+
" - https://github.com/jsecurity101/MSRPC-to-ATTACK/blob/main/documents/MS-EFSR.md\n" +
220+
" - https://github.com/zeronetworks/rpcfirewall\n" +
221+
" - https://zeronetworks.com/blog/stopping_lateral_movement_via_the_rpc_firewall/\n" +
222+
"tags:\n" +
223+
" - attack.defense_evasion\n" +
224+
"status: experimental\n" +
225+
"author: Sagie Dulce, Dekel Paz\n" +
226+
"date: 2022/01/01\n" +
227+
"modified: 2022/01/01\n" +
228+
"logsource:\n" +
229+
" product: rpc_firewall\n" +
230+
" category: application\n" +
231+
" definition: 'Requirements: install and apply the RPC Firew all to all processes with \"audit:true action:block uuid:df1941c5-fe89-4e79-bf10-463657acf44d or c681d488-d850-11d0-8c52-00c04fd90f7e'\n" +
232+
"detection:\n" +
233+
" selection:\n" +
234+
" EventID: 22\n" +
235+
" RecordNumber: null\n" +
236+
" condition: selection\n" +
237+
"falsepositives:\n" +
238+
" - Legitimate usage of remote file encryption\n" +
239+
"level: high";
240+
}
241+
242+
243+
212244
public static String randomNullRule() {
213245
return "title: null field\n" +
214246
"id: 5f92fff9-82e2-48eb-8fc1-8b133556a551\n" +

0 commit comments

Comments
 (0)