-
Notifications
You must be signed in to change notification settings - Fork 28
/
Copy pathazure-eventhub-ad.rules
71 lines (51 loc) · 14.2 KB
/
azure-eventhub-ad.rules
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
# Sagan azure-eventhub-ad.rules
# Copyright (c) 2009-2023. Quadrant Information Security <www.quadrantsec.com>
# All rights reserved.
#
# Please submit any custom rules or ideas to [email protected] or the sagan-sigs mailing list
#
#*************************************************************
# Redistribution and use in source and binary forms, with or without modification, are permitted provided that the
# following conditions are met:
#
# * Redistributions of source code must retain the above copyright notice, this list of conditions and the following
# disclaimer.
# * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the
# following disclaimer in the documentation and/or other materials provided with the distribution.
# * Neither the name of the nor the names of its contributors may be used to endorse or promote products derived
# from this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS AS IS AND ANY EXPRESS OR IMPLIED WARRANTIES,
# INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
# USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
#*************************************************************
alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] Risk Event Detected - unlikelyTravel"; program: azureEventHub; json_content:".properties.riskEventTypes","unlikelyTravel"; json_contains; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: suspicious-traffic; reference:url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-azure-monitor-sign-ins-log-schema; sid:5004760; rev: 4;)
alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] Risk Event Detected - anonymizedIPAddress"; program: azureEventHub; json_content:".properties.riskEventTypes","anonymizedIPAddress"; json_contains; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: suspicious-traffic; reference:url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-azure-monitor-sign-ins-log-schema; sid:5004761; rev: 4;)
alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] Risk Event Detected - maliciousIPAddress"; program: azureEventHub; json_content:".properties.riskEventTypes","maliciousIPAddress"; json_contains; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: suspicious-traffic; reference:url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-azure-monitor-sign-ins-log-schema; sid:5004762; rev: 4;)
alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] Risk Event Detected - unfamiliarFeatures"; program: azureEventHub; json_content:".properties.riskEventTypes","unfamiliarFeatures"; json_contains; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: bad-unknown; reference:url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-azure-monitor-sign-ins-log-schema; sid:5004763; rev: 4;)
alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] Risk Event Detected - malwareInfectedIPAddress"; program: azureEventHub; json_content:".properties.riskEventTypes","malwareInfectedIPAddress"; json_contains; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: suspicious-traffic; reference:url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-azure-monitor-sign-ins-log-schema; sid:5004764; rev: 4;)
alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] Risk Event Detected - suspiciousIPAddress"; program: azureEventHub; json_content:".properties.riskEventTypes","suspiciousIPAddress"; json_contains; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: suspicious-traffic; reference:url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-azure-monitor-sign-ins-log-schema; sid:5004765; rev: 4;)
alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] Risk Event Detected - leakedCredentials"; program: azureEventHub; json_content:".properties.riskEventTypes","leakedCredentials"; json_contains; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: correlated-attack; reference:url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-azure-monitor-sign-ins-log-schema; sid:5004766; rev: 5;)
alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] Risk Event Detected - investigationsThreatIntelligence"; program: azureEventHub; json_content:".properties.riskEventTypes","investigationsThreatIntelligence"; json_contains; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: correlated-attack; reference:url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-azure-monitor-sign-ins-log-schema; sid:5004767; rev: 4;)
alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] Risk Event Detected - generic"; program: azureEventHub; json_content:".properties.riskEventTypes","generic"; json_contains; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: suspicious-traffic; reference:url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-azure-monitor-sign-ins-log-schema; sid:5004768; rev: 4;)
alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] Risk Event Detected - unknownFutureValue"; program: azureEventHub; json_content:".properties.riskEventTypes","unknownFutureValue"; json_contains; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: suspicious-traffic; reference:url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-azure-monitor-sign-ins-log-schema; sid:5004769; rev: 4;)
alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] atRisk Event Detected"; program: azureEventHub; json_content:".properties.riskState","atRisk"; json_meta_content:!".properties.riskEventTypes[]",unfamiliarFeatures; json_contains; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: suspicious-traffic; reference:url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-azure-monitor-sign-ins-log-schema; sid:5004770; rev: 7;)
alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] confirmedCompromised Event Detected"; program: azureEventHub; json_content:".properties.riskState","confirmedCompromised"; json_contains; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: correlated-attack; reference:url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-azure-monitor-sign-ins-log-schema; sid:5004771; rev: 4;)
alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] unknownFutureValue Event Detected"; program: azureEventHub; json_content:".properties.riskState","unknownFutureValue"; json_contains; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: bad-unknown; reference:url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-azure-monitor-sign-ins-log-schema; sid:5004772; rev: 4;)
alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] High Risk During Sign in"; program: azureEventHub; json_content:".properties.riskLevelDuringSignIn","high"; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: correlated-attack; reference:url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-azure-monitor-sign-ins-log-schema; sid:5004773; rev: 4;)
#alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] Account lockout"; program: azureEventHub; json_content:".resultType","50053"; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: unsuccessful-user; reference:url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-sign-ins-error-codes; sid:5004774; rev: 4;)
alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] Brute Force (Invalid username or password)"; program: azureEventHub; json_content:".resulttype","50126"; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: brute-force; reference: url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-sign-ins-error-codes; sid:5004776; rev: 6;)
#alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] Brute Force (Invalid password)"; program: azureEventHub; json_content:".resultType","50056"; json_map: "src_ip", ".callerIpAddress"; json_map: "dest_ip", ".callerIpAddress"; json_map: "username", ".properties.userPrincipalName"; classtype: brute-force; reference:url,docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-sign-ins-error-codes; sid:5004777; rev: 5;)
alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] Possible Brute Force Attempt (Invalid username or password) [10/1]"; program: azureEventHub; meta_content:"resultType|22 3a| |22|%sagan%",50126,50056; after:track by_src, count 10, seconds 300; threshold:type suppress, track by_src, count 1, seconds 86400; xbits:set,brute_force,track ip_src,expire 21600; classtype:brute-force; parse_src_ip: 1; reference: url,https://docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-sign-ins-error-codes; sid:5014177; rev:1;)
#alert any $HOME_NET any -> $EXTERNAL_NET any (msg: "[AZURE-EVENTHUB-AD] Account lockout after Brute Force Attempt"; program: azureEventHub; content:"resultType|22 3a| |22|50053"; content: "Account is locked"; classtype: unsuccessful-user; parse_src_ip: 1; reference: url,https://docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/reference-sign-ins-error-codes; sid:5014178; rev: 1;)
alert any any any -> any any (msg: "[AZURE-EVENTHUB-AD] CRITICAL - Global Administrator Created"; program: azureEventHub; json_content: ".operationName", "Add member to role"; content: "Global Administrator"; classtype: suspicious-traffic; reference: url,https://learn.microsoft.com/en-us/azure/role-based-access-control/rbac-and-directory-admin-roles; sid: 5014648; metadata: created_on 2024_05_09, mitre_technique_id T1136, updated_on 2024_06_06; rev:4;)
alert any any any -> any any (msg: "[AZURE-EVENTHUB-AD] Security Operator Created"; program: azureEventHub; json_content: ".operationName", "Add member to role"; content: "Security Operator"; classtype: suspicious-traffic; reference: url, https://learn.microsoft.com/en-us/entra/identity/role-based-access-control/permissions-reference; sid: 5014649; metadata: created_on 2024_05_09, mitre_technique_id T1136, updated_on 2024_06_13; rev:3;)
alert any any any -> any any (msg: "[AZURE-EVENTHUB-AD] Security Administrator Created"; program: azureEventHub; json_content: ".operationName", "Add member to role"; content: "Security Administrator"; classtype: suspicious-traffic; reference: url, https://learn.microsoft.com/en-us/entra/identity/role-based-access-control/permissions-reference; sid: 5014650; metadata: created_on 2024_05_09, mitre_technique_id T1136, updated_on 2024_06_13; rev:3;)
alert any any any -> any any (msg: "[AZURE-EVENTHUB-AD] User Administrator Created"; program: azureEventHub; json_content: ".operationName", "Add member to role"; content: "User Administrator"; classtype: suspicious-traffic; reference: url,https://learn.microsoft.com/en-us/azure/role-based-access-control/rbac-and-directory-admin-roles; sid: 5014651; metadata: created_on 2024_05_09, mitre_technique_id T1136, updated_on 2024_06_13; rev:2;)
alert any any any -> any any (msg: "[AZURE-EVENTHUB-AD] Partner Tier2 Support Created"; program: azureEventHub; json_content: ".operationName", "Add member to role"; content: "Partner Tier2 Support"; classtype: suspicious-traffic; reference: url,https://posts.specterops.io/microsoft-breach-what-happened-what-should-azure-admins-do-da2b7e674ebc; reference: url,https://learn.microsoft.com/en-us/entra/identity/role-based-access-control/permissions-reference; sid:5014658; metadata: created_on 2024_05_15, updated_on 2024_06_13, mitre_technique_id T1136; rev:2;)
alert any any any -> any any (msg: "[AZURE-EVENTHUB-AD] Privileged Role Administrator Created"; program: azureEventHub; json_content: ".operationName", "Add member to role"; content: "Privileged Role Administrator"; classtype: suspicious-traffic; reference: url,https://posts.specterops.io/microsoft-breach-what-happened-what-should-azure-admins-do-da2b7e674ebc; reference: url,https://learn.microsoft.com/en-us/entra/identity/role-based-access-control/permissions-reference; sid:5014659; metadata: created_on 2024_05_15, updated_on 2024_06_13, mitre_technique_id T1136; rev:2;)