Commit Graph

2973 Commits

Author SHA1 Message Date
Jonhnathan 41dd521546 [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 11 (#5026)
* [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 11

* Apply suggestions from code review

Co-authored-by: Samirbous <64742097+Samirbous@users.noreply.github.com>

---------

Co-authored-by: Samirbous <64742097+Samirbous@users.noreply.github.com>
2025-08-28 12:28:49 -07:00
Jonhnathan 9c08869575 [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 9 (#5024) 2025-08-28 12:15:25 -07:00
Jonhnathan be18b4db16 [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 8 (#5023)
* [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 8

* Apply suggestions from code review

Co-authored-by: Samirbous <64742097+Samirbous@users.noreply.github.com>

* Update defense_evasion_wdac_policy_by_unusual_process.toml

---------

Co-authored-by: Samirbous <64742097+Samirbous@users.noreply.github.com>
2025-08-28 12:04:55 -07:00
Jonhnathan 48dfb759cd [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 7 (#5022) 2025-08-28 11:51:45 -07:00
Jonhnathan 1af98a6170 [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 6 (#5021)
* [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 6

* Apply suggestions from code review

Co-authored-by: Samirbous <64742097+Samirbous@users.noreply.github.com>

* Update defense_evasion_proxy_execution_via_msdt.toml

---------

Co-authored-by: Samirbous <64742097+Samirbous@users.noreply.github.com>
2025-08-28 11:37:15 -07:00
Jonhnathan b91e73714e [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 5 (#5020)
* [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 5

* Update defense_evasion_ms_office_suspicious_regmod.toml
2025-08-28 11:26:09 -07:00
Jonhnathan 85a0d27b13 [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 4 (#5019)
* [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 4

* Update rules/windows/defense_evasion_microsoft_defender_tampering.toml

Co-authored-by: Samirbous <64742097+Samirbous@users.noreply.github.com>

---------

Co-authored-by: Samirbous <64742097+Samirbous@users.noreply.github.com>
2025-08-28 11:05:42 -07:00
Jonhnathan 0fbf57c1d9 [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 3 (#5018)
* [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 3

* Apply suggestions from code review

Co-authored-by: Samirbous <64742097+Samirbous@users.noreply.github.com>

* Update rules/windows/defense_evasion_file_creation_mult_extension.toml

* Update rules/windows/defense_evasion_file_creation_mult_extension.toml

---------

Co-authored-by: Samirbous <64742097+Samirbous@users.noreply.github.com>
2025-08-28 10:55:21 -07:00
Jonhnathan 8ab98458fa [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 2 (#5017)
* [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 2

* Update defense_evasion_code_signing_policy_modification_registry.toml

* Update defense_evasion_communication_apps_suspicious_child_process.toml

* Update rules/windows/defense_evasion_communication_apps_suspicious_child_process.toml

* Update defense_evasion_communication_apps_suspicious_child_process.toml

---------

Co-authored-by: Samirbous <64742097+Samirbous@users.noreply.github.com>
2025-08-28 10:40:34 -07:00
Jonhnathan 00c6e785cb [Rule Tuning] Windows - Small Adjusts for Compatibility (#5032) 2025-08-28 10:20:13 -07:00
Jonhnathan 9c2ceb2bd7 [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 1 (#5016)
* [Rule Tuning] Windows 3rd Party EDR Compatibility - Part 1

* Update defense_evasion_amsi_bypass_dllhijack.toml

* Update command_and_control_outlook_home_page.toml

* Update command_and_control_outlook_home_page.toml

* Update defense_evasion_amsi_bypass_dllhijack.toml

* Update rules/windows/command_and_control_port_forwarding_added_registry.toml

Co-authored-by: Samirbous <64742097+Samirbous@users.noreply.github.com>

---------

Co-authored-by: Samirbous <64742097+Samirbous@users.noreply.github.com>
2025-08-28 06:43:09 -07:00
Samirbous fbfc696a86 Update command_and_control_unusual_network_connection_to_suspicious_web_service.toml (#5008) 2025-08-26 13:03:59 +01:00
Isai bfb29ecf37 [Rule Tuning] First Time Seen AWS Secret Value Accessed in Secrets Manager (#4992)
This rule is evaluating the "new terms" against every individual role session, rather than against the Role itself. This is causing a massive volume of alerts
- updated rule description and investigation guide
- reduced execution window and interval
- replaced new terms from `user.id` to combination of `cloud.account.id` and `user.name` to account for evaluation against Roles and in the event that separate AWS accounts under the same Org reuse IAM user names. This will only evaluate the Role instead of each individual role session, which should greatly improve performance.
2025-08-25 12:00:47 -04:00
Isai df179f0ab1 [Rule Tuning] AWS STS GetCallerIdentity API Called for the First Time (#4995)
* [Rule Tuning] AWS STS GetCallerIdentity API Called for the First Time

Rule is executing as expected with no troubling alerts in telemetry. For tuning I've:

- reduced the execution window
- removed MD from description and FP as it's not supported in Kibana UI
- edited some of the language of IG to speak about the exclusion of AssumedRoles
- edited the highlighted fields for consistency across AWS rules

* updated broken link

updated broken reference link
2025-08-25 11:44:58 -04:00
Ruben Groenewoud a4a5b171c4 [New Rule] Multi-Base64 Decoding Attempt from Suspicious Location (#4931)
* [New Rule] Multi-Base64 Decoding Attempt from Suspicious Location

* ++

* Update rules/linux/defense_evasion_multi_base64_decoding_attempt.toml

Co-authored-by: Mika Ayenson, PhD <Mikaayenson@users.noreply.github.com>

* Update rules/linux/defense_evasion_multi_base64_decoding_attempt.toml

Co-authored-by: Mika Ayenson, PhD <Mikaayenson@users.noreply.github.com>

---------

Co-authored-by: Mika Ayenson, PhD <Mikaayenson@users.noreply.github.com>
2025-08-25 10:31:25 +02:00
Isai c151d69d36 [Rule Tuning] AWS STS AssumeRole with New MFA Device (#4999)
* [Rule Tuning] AWS STS AssumeRole with New MFA Device

This rule is triggering as expected and low volume of alerts in telemetry. This tuning:
- slight edits to IG
- removed user.id wildcard usage in query as this field always exists for these events
- added the from and interval fields for consistency across rules (they are currently using the same values by default so no real change here)

* adding investigation fields

adding investigation fields
2025-08-22 14:48:39 -04:00
shashank-elastic ee70674e2c Add all rule types DaC testing (#4969) 2025-08-20 19:04:57 +05:30
Eric Forte dde448ee6b [Bug] Rule Toml Write Formatting Wrongly Formats \\\\x (#4978)
* Fix rule and mitigate py toml

* Bump patch version

* Add reference to issue

* Add unit test for path issues

* Update comment

* Certain strings were not properly escaped

* Updated to use json instead of repr

* replace _old_dump_str with json.dumps

* Bump Version
2025-08-18 17:03:51 -04:00
github-actions[bot] fb76ec1b2d Lock versions for releases: 8.18,8.19,9.0,9.1 (#4991) 2025-08-18 22:36:37 +05:30
Samirbous 9dfc42aa1d [Tuning] Connection to Commonly Abused Web Services - alerts JetBrains to GH (#4973)
* Update command_and_control_common_webservices.toml

* Update command_and_control_common_webservices.toml

---------

Co-authored-by: Jonhnathan <26856693+w0rk3r@users.noreply.github.com>
2025-08-18 17:21:04 +01:00
Jonhnathan 58f62fd138 [Rule Tuning] Suspicious Windows Powershell Arguments (#4961) 2025-08-18 09:02:04 -07:00
Jonhnathan 0507bcd150 [Rule Tuning] ES|QL PowerShell Rules (#4984) 2025-08-18 08:44:18 -07:00
Jonhnathan 273650d746 [Rule Tuning] Potential RemoteMonologue Attack (#4967)
* [Rule Tuning] Potential RemoteMonologue Attack

* Update defense_evasion_regmod_remotemonologue.toml
2025-08-18 08:22:53 -07:00
shashank-elastic c28b6d84b5 Investigation guides Update (#4990) 2025-08-18 20:36:46 +05:30
Samirbous 1557eae9d4 [New] Command Line Obfuscation via Whitespace Padding (#4860)
* Create defense_evasion_whitespace_padding_command_line.toml

* Update defense_evasion_whitespace_padding_command_line.toml

* Update defense_evasion_whitespace_padding_command_line.toml

* Update and rename defense_evasion_whitespace_padding_command_line.toml to defense_evasion_whitespace_padding_command_line.toml

* Update rules/cross-platform/defense_evasion_whitespace_padding_command_line.toml

Co-authored-by: Ruben Groenewoud <78494512+Aegrah@users.noreply.github.com>

* Update rules/cross-platform/defense_evasion_whitespace_padding_command_line.toml

Co-authored-by: Ruben Groenewoud <78494512+Aegrah@users.noreply.github.com>

* Update defense_evasion_whitespace_padding_command_line.toml

* Update defense_evasion_whitespace_padding_command_line.toml

---------

Co-authored-by: Ruben Groenewoud <78494512+Aegrah@users.noreply.github.com>
2025-08-18 15:26:52 +01:00
Jonhnathan 5f7b821e12 [Rule Tuning] Suspicious PrintSpooler Service Executable File Creation (#4976)
Co-authored-by: Mika Ayenson, PhD <Mikaayenson@users.noreply.github.com>
2025-08-18 06:29:28 -07:00
Samirbous 36b33e2c13 Update persistence_services_registry.toml (#4989) 2025-08-18 14:05:25 +01:00
Isai b7de4f5126 [Tuning] SDH - Investigating MFA Deactivation with no Re-Activation for Okta User Account (#4986)
* [Tuning] SDH - Investigating MFA Deactivation with no Re-Activation for Okta User Account

This tuning addresses SDH ticket by:
- replacing sequence by `okta.actor.id` with `okta.target.id` in query. This will ensure the deactivation and activation attempts are measured against the target entity. To account for instances where separate users (okta.actor.id) perform deactivation and activation actions against the same target account (okta.target.id)
- Adjusts the investigation guide to use correct target vs. actor fields

* add actor and target id fields to investigation guide

Co-authored-by: Terrance DeJesus <99630311+terrancedejesus@users.noreply.github.com>

---------

Co-authored-by: Terrance DeJesus <99630311+terrancedejesus@users.noreply.github.com>
2025-08-15 18:02:15 -04:00
Jonhnathan c8ee4c8ce3 [New Rule] Potential Web Shell ASPX File Creation (#4939)
* [New Rule] Potential Web Shell ASPX File Creation

* Update persistence_web_shell_aspx_write.toml

* Update persistence_web_shell_aspx_write.toml
2025-08-15 12:09:06 -03:00
Jonhnathan 532b68cc93 [Rule Tuning] PowerShell Script Block Logging Disabled (#4980) 2025-08-14 17:29:45 -03:00
Terrance DeJesus e3a7ee94fc [Rule Tuning] Microsoft Entra ID Suspicious Session Reuse to Graph Access (#4954)
* adjusted query

* add keep; lint

* Update rules/integrations/azure/initial_access_entra_graph_single_session_from_multiple_addresses.toml

Co-authored-by: Jonhnathan <26856693+w0rk3r@users.noreply.github.com>

---------

Co-authored-by: Jonhnathan <26856693+w0rk3r@users.noreply.github.com>
2025-08-13 17:41:58 -04:00
Jonhnathan 8f441a7191 [Rule Tuning] Creation or Modification of Root Certificate (#4970)
* [Rule Tuning] Creation or Modification of Root Certificate

* Update defense_evasion_create_mod_root_certificate.toml

* Update rules/windows/defense_evasion_create_mod_root_certificate.toml

---------

Co-authored-by: shashank-elastic <91139415+shashank-elastic@users.noreply.github.com>
2025-08-13 09:41:57 -03:00
Jonhnathan 1dd1bb8f1e [Rule Tuning] Fixes FPs related to a process.args_count bug (#4971) 2025-08-13 08:46:46 -03:00
github-actions[bot] 154283f457 Lock versions for releases: 8.18,8.19,9.0,9.1 (#4963) 2025-08-06 08:58:16 +05:30
Terrance DeJesus b28338c680 [Rule Tuning] ESQL Query Field Dynamic Field Standardization (#4912)
* adjusted Potential Widespread Malware Infection Across Multiple Hosts

* adjusted Microsoft Azure or Mail Sign-in from a Suspicious Source

* adjusted AWS EC2 Multi-Region DescribeInstances API Calls

* adjusted AWS Discovery API Calls via CLI from a Single Resource

* adjusted AWS Service Quotas Multi-Region  Requests

* adjusted AWS EC2 EBS Snapshot Shared or Made Public

* adjusted AWS S3 Bucket Enumeration or Brute Force

* adjusted AWS EC2 EBS Snapshot Access Removed

* adjusted Potential AWS S3 Bucket Ransomware Note Uploaded

* adjusted AWS S3 Object Encryption Using External KMS Key

* adjusted AWS S3 Static Site JavaScript File Uploaded

* adjusted AWS Access Token Used from Multiple Addresses

* adjusted AWS Signin Single Factor Console Login with Federated User

* adjusted AWS IAM AdministratorAccess Policy Attached to Group

* adjusted AWS IAM AdministratorAccess Policy Attached to Role

* adjusted AWS IAM AdministratorAccess Policy Attached to User

* adjusted AWS Bedrock Invocations without Guardrails Detected by a Single User Over a Session

* adjusted AWS Bedrock Guardrails Detected Multiple Violations by a Single User Over a Session

* adjusted AWS Bedrock Guardrails Detected Multiple Policy Violations Within a Single Blocked Request

* adjusted Unusual High Confidence Content Filter Blocks Detected

* adjusted Potential Abuse of Resources by High Token Count and Large Response Sizes

* AWS Bedrock Detected Multiple Attempts to use Denied Models by a Single User

* Unusual High Denied Sensitive Information Policy Blocks Detected

* adjusted Unusual High Denied Topic Blocks Detected

* adjusted AWS Bedrock Detected Multiple Validation Exception Errors by a Single User

* adjusted Unusual High Word Policy Blocks Detected

* adjusted Microsoft Entra ID Concurrent Sign-Ins with Suspicious Properties

* adjusted Azure Entra MFA TOTP Brute Force Attempts

* adjusted Microsoft Entra ID Sign-In Brute Force Activity

* adjusted Microsoft Entra ID Exccessive Account Lockouts Detected

* adjusted Microsoft 365 Brute Force via Entra ID Sign-Ins

* deprecated Azure Entra Sign-in Brute Force Microsoft 365 Accounts by Repeat Source

* adjusted Microsoft Entra ID Session Reuse with Suspicious Graph Access

* adjusted Suspicious Microsoft OAuth Flow via Auth Broker to DRS

* adjusted Potential Denial of Azure OpenAI ML Service

* adjusted Azure OpenAI Insecure Output Handling

* adjusted Potential Azure OpenAI Model Theft

* adjusted M365 OneDrive Excessive File Downloads with OAuth Token

* adjusted Multiple Microsoft 365 User Account Lockouts in Short Time Window

* adjusted Potential Microsoft 365 User Account Brute Force

* adjusted Suspicious Microsoft 365 UserLoggedIn via OAuth Code

* adjusted Multiple Device Token Hashes for Single Okta Session

* adjusted Multiple Okta User Authentication Events with Client Address

* adjusted Multiple Okta User Authentication Events with Same Device Token Hash

* adjusted High Number of Okta Device Token Cookies Generated for Authentication

* adjusted Okta User Sessions Started from Different Geolocations

* adjusted High Number of Egress Network Connections from Unusual Executable

* adjusted Unusual Base64 Encoding/Decoding Activity

* adjusted Potential Port Scanning Activity from Compromised Host

* adjusted Potential Subnet Scanning Activity from Compromised Host

* adjusted Unusual File Transfer Utility Launched

* adjusted Potential Malware-Driven SSH Brute Force Attempt

* adjusted Unusual Process Spawned from Web Server Parent

* adjusted Unusual Command Execution from Web Server Parent

* adjusted  Rare Connection to WebDAV Target

* adjusted Potential PowerShell Obfuscation via Invalid Escape Sequences

* adjusted Potential PowerShell Obfuscation via Backtick-Escaped Variable Expansion

* adjusted Unusual File Creation by Web Server

* adjusted Potential PowerShell Obfuscation via High Special Character Proportion

* adjusted Potential Malicious PowerShell Based on Alert Correlation

* adjusted Potential PowerShell Obfuscation via Character Array Reconstruction

* adjusted Potential PowerShell Obfuscation via String Reordering

* adjusted Potential PowerShell Obfuscation via String Concatenation

* adjusted Potential PowerShell Obfuscation via Reverse Keywords

* adjusted PowerShell Obfuscation via Negative Index String Reversal

* adjusted Dynamic IEX Reconstruction via Method String Access

* adjusted Potential Dynamic IEX Reconstruction via Environment Variables

* adjusted Potential PowerShell Obfuscation via High Numeric Character Proportion

* adjusted Potential PowerShell Obfuscation via Concatenated Dynamic Command Invocation

* adjusted Rare Connection to WebDAV Target

* adjusted Potential PowerShell Obfuscation via Invalid Escape Sequences

* adjusted Potential PowerShell Obfuscation via Backtick-Escaped Variable Expansion

* adjusted Potential PowerShell Obfuscation via Character Array Reconstruction

* adjusted Potential PowerShell Obfuscation via High Special Character Proportion

* adjusted Potential PowerShell Obfuscation via Special Character Overuse

* adjusted Potential PowerShell Obfuscation via String Reordering

* adjusted Suspicious Microsoft 365 UserLoggedIn via OAuth Code

* adjusted fields that were inconsistent

* adjusted additional fields

* adjusted esql to Esql

* adjusted several rules for common field names

* updating rules

* updated dates

* updated dates

* updated ESQL fields

* lowercase all functions and logical operators

* adjusted dates for unit tests

* Update Esql_priv to Esql_temp as these don't hold PII

* PowerShell adjustments

* Make query comments consistent

* update comment

* reverted 2856446a-34e6-435b-9fb5-f8f040bfa7ed

* Update rules/windows/discovery_command_system_account.toml

* removed dot notation

---------

Co-authored-by: Jonhnathan <26856693+w0rk3r@users.noreply.github.com>
2025-08-05 19:35:41 -04:00
Mika Ayenson, PhD 215cdf0f8f [Rule Tuning] Elastic Security External Alerts (#4962) 2025-08-05 15:48:10 -05:00
Eric Forte a726da5e83 [Bug] [DAC] Custom Rules Filter Discrepancy on Stacks Upgraded to 8.18 (#4945)
* Update Custom Rules KQL

* Bump Patch Version

* Update detection_rules/kbwrap.py

Co-authored-by: Marshall Main <55718608+marshallmain@users.noreply.github.com>

* Use or instead of and

* Bump patch version

* Fix results len typo

---------

Co-authored-by: Marshall Main <55718608+marshallmain@users.noreply.github.com>
2025-08-05 09:42:25 -04:00
github-actions[bot] c210a88b1f Lock versions for releases: 8.18,8.19,9.0,9.1 (#4960) 2025-08-04 22:37:59 +05:30
Mika Ayenson, PhD 80e44d0fb8 [Rule Tuning] AI4DSOC External Promotion Alerts (#4959) 2025-08-04 11:27:00 -05:00
shashank-elastic 2c2b15368c Update latest integration manifests and schema and investigation guides (#4957) 2025-08-04 19:30:01 +05:30
Sergey Polzunov ff46a7ab4a fix: Allow different order of the metadata fields in ESQL queries (#4956)
* Initial commit

* Python project version bump
2025-08-02 02:26:39 +02:00
Jonhnathan 04ca2c8128 [New Rule] Unusual Web Config File Access (#4927)
* [New Rule] Unusual Web Config File Access

* Update credential_access_web_config_file_access.toml
2025-08-01 09:35:08 -03:00
Jonhnathan 3de9456197 [Rule Tuning] Script Execution via Microsoft HTML Application (#4950) 2025-08-01 07:55:14 -03:00
Eric Forte a9ad66935c [FR] [DAC] Add Arbitrary File location Support for Local Creation Date (#4915)
* Add support for local file contents

* Update Rule Params

* Update CLI docs

* Update to Pathlib

* Format updating

* Delete duplicate

* Update logic to handle just local_contents path

* Update to Glob Based Approach

* Updated to use RawRuleCollection

* Fix Logging Typo

* New utils functions no longer needed

* Update naming for convention
2025-07-31 14:35:00 -04:00
Eric Forte bf3071d3d1 [FR] Add white space checking for KQL parse (#3789)
* Add whitespace checking for KQL parse

* Add unit test for blank space check

* Bump patch version

* Add test cases for newline blank space

* Add additional unit tests

* Update to only walk tree once

---------

Co-authored-by: Terrance DeJesus <99630311+terrancedejesus@users.noreply.github.com>
2025-07-31 14:23:53 -04:00
Mika Ayenson, PhD 1dc3926203 [New Rules] External Promotion Alerts (#4903) 2025-07-31 11:00:50 -05:00
Mika Ayenson, PhD f2fac1bc48 [FR] [DAC] Add existing mitre threat information on import (#4948) 2025-07-31 09:44:09 -05:00
Terrance DeJesus 0e78ce360b [Rule Tuning] Microsoft Azure or Mail Sign-in from a Suspicious Source (#4946)
* change indices in ESQL query

* adjusted rule name
2025-07-31 09:57:02 -04:00
Terrance DeJesus 756a7f49ba [Rule Tuning] Microsoft Entra ID MFA TOTP Brute Force Attempts (#4937)
* tuning rule 'Microsoft Entra ID MFA TOTP Brute Force Attempts'

* adjusted logic
2025-07-29 09:24:20 -04:00
github-actions[bot] f348e92f06 Lock versions for releases: 8.18,8.19,9.0,9.1 (#4926) 2025-07-22 21:19:44 +05:30