From 3add113fa5979e7a7d76f3bb9bf77e974436c993 Mon Sep 17 00:00:00 2001 From: Translator Date: Sun, 21 Jun 2026 13:53:42 +0000 Subject: [PATCH] Translated ['src/pentesting-cloud/azure-security/az-unauthenticated-enum --- .../az-monitor-alert-phishing.md | 62 +++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 src/pentesting-cloud/azure-security/az-unauthenticated-enum-and-initial-entry/az-monitor-alert-phishing.md diff --git a/src/pentesting-cloud/azure-security/az-unauthenticated-enum-and-initial-entry/az-monitor-alert-phishing.md b/src/pentesting-cloud/azure-security/az-unauthenticated-enum-and-initial-entry/az-monitor-alert-phishing.md new file mode 100644 index 000000000..cc86358da --- /dev/null +++ b/src/pentesting-cloud/azure-security/az-unauthenticated-enum-and-initial-entry/az-monitor-alert-phishing.md @@ -0,0 +1,62 @@ +# Az - Monitor Alert Phishing + +{{#include ../../../banners/hacktricks-training.md}} + +## Monitor Alert Phishing + +वर्तमान में[^disclosure] Azure Monitoring Action Group notification को bypass करना संभव है, जो user के monitoring group में add होने पर भेजी जाती है, जिससे attacker `azure-monitor@microsoft.com` से arbitrary addresses पर partially custom monitoring messages और titles के साथ emails भेज सकता है, full DMARC validation सहित। + +[^disclosure]: यह Microsoft को 3/17/2026 को रिपोर्ट किया गया था। जब आप इसे पढ़ रहे हों, तब तक उन्होंने इसे resolve किया हो भी सकता है और नहीं भी। + +इस attack को perform करने के लिए, आपको एक Azure subscription और targets की एक list चाहिए। + +### Setup +#### Entra ID +जिस भी user को आप target करना चाहते हैं, उसके लिए अपने tenant में एक Entra ID user बनाएं। आप सभी settings default छोड़ सकते हैं और username के रूप में कुछ भी इस्तेमाल कर सकते हैं। +एकमात्र setting जो matter करती है वह `Contact Information` के तहत `Email` property है। इसे actual target email address पर set करें। + +जब आपने अपना user(s) बना लिया हो, तो उन्हें ***SUBSCRIPTION*** पर `Monitoring Reader` assign करें। + +अब permissions को propagate होने के लिए 24 घंटे प्रतीक्षा करें[^slow]. Practical रूप में, यह सिर्फ कुछ घंटे लेता हुआ लगता है, लेकिन Microsoft gonna Microsoft. + +[^slow]: [Yes, it is actually that slow](https://learn.microsoft.com/en-us/azure/azure-monitor/alerts/action-groups#email-azure-resource-manager) + +#### Azure Monitor Action Group +`Name` और `Display Name` victim को दिखाई देंगे, इसलिए कुछ appropriate चुनें। +यदि आपको किसी ऐसे Action Group का नाम पता है जिस पर victim subscribed है, तो वह एक अच्छा choice हो सकता है। + +notification type को `Email Azure Resource Manager` पर set करें, और target को `Monitoring Reader` पर। `Common Alert Schema` enable न करें। +हालांकि attack तब भी "work" करेगा यदि आप ऐसा करते हैं, लेकिन customizable fields deeper में छिपे होंगे, और email के front में अधिक context शामिल होगा, जिससे यह थोड़ा कम convincing हो सकता है। + + +#### Azure Monitor Alert Rule +यहीं सबसे important customization होती है! + +name emails के subject में और email के top के पास शामिल होगा। यह cloning existing alert का एक और useful use-case हो सकता है। +description वह जगह होगी जहाँ आप अपना "payload" रखना चाहेंगे। इसके आसपास formatting बदलना संभव नहीं है, लेकिन आप content को पूरी तरह customize कर सकते हैं, उदाहरण के लिए एक [OAuth App Phish](./az-oauth-apps-phishing.md) link के साथ। + + +अंत में, trigger condition को कुछ ऐसा set करें जिसे आप control कर सकें कि वह कब trigger होगा। एक example `ServiceApiHit` हो सकता है, जो किसी specific resource तक scoped हो। + +यदि आप अभी भी Entra Role assignments के propagate होने का इंतजार कर रहे हैं, तो rule को तब तक disable करने पर विचार करें जब तक आप ready न हों, ताकि यदि rule accidentally trigger हो जाए तो emails multiple times न जाएं। + +### Execution + +बस आपने जिस metric का उपयोग किया था, उसे trigger करें। यदि आपने `ServiceApiHit` को एक keyvault resource और "greater than zero" threshold के साथ use किया है, तो आप +`az keyvault show --name $VAULT` का उपयोग करके alert trigger कर सकते हैं। + +आपने अपने Alert Rule को कैसे configured किया है, इस पर निर्भर करते हुए, आप Alert Rule के अभी भी Alert state में रहने पर Action Group को disable करना चाह सकते हैं, ताकि alert के "Resolved" होने पर दूसरा email न भेजा जाए। + +
जंगली दुनिया में इस exploit का उपयोग करते हुए attacker का एक example.
+ + + +### OPSEC Considerations +इस attack के साथ कुछ identifying information को hide करना संभव नहीं है। +विशेष रूप से, इसमें आपका subscription ID शामिल है, जिसे tenant ID, tenant domains, ect में reverse किया जा सकता है। +यदि आप इसके लिए अपने own Azure account का उपयोग कर रहे हैं, तो सुनिश्चित करें कि यह ऐसा account हो जिसके flagged होने पर आप ठीक हों, यदि Microsoft को इसका पता चल जाए। + +## References +- [https://learn.microsoft.com/en-us/azure/azure-monitor/alerts/action-groups#email-azure-resource-manager](https://learn.microsoft.com/en-us/azure/azure-monitor/alerts/action-groups#email-azure-resource-manager) + +{{#include ../../../banners/hacktricks-training.md}}