- Microsoft Azure
- Microsoft Sentinel
- KQL
- MacOS
- Windows 10
To scale our monitoring and enable advanced querying, we create a Log Analytics Workspace in Azure Monitor. This workspace is a cloud-based log repository that aggregates data from multiple sources, including VMs, networks, and other Azure services. We provision a new workspace by choosing a name, region, and pricing tier, then prepare it to receive logs from our honeypot VM. This centralized platform allows us to retain logs over time, apply filters, and use analytical tools to detect suspicious behavior with more granularity than is possible on the VM alone. We install the Log Analytics Agent (also known as the Microsoft Monitoring Agent) on our VM, which acts as a bridge between the server and our workspace. This agent collects performance metrics, system events, and security logs from the VM and forwards them to Azure Monitor. On Linux, the installation involves downloading the OMS agent, linking it to the workspace using a workspace ID and key, and verifying connectivity. After installation, we configure the agent to monitor specific log files, such as authentication logs or SSH logs, ensuring that all critical events are sent to the workspace for further analysis. With logs now flowing into the workspace, we begin using Kusto Query Language (KQL) to analyze them. KQL is a powerful query language similar to SQL but optimized for time series and log data. We start by writing basic queries to count login attempts, filter by IP address, or search for failed authentications.
To make our log analysis more meaningful, we enrich the attacker IP addresses with geolocation data. This involves mapping each IP to a location (e.g., country, region, city) using external services or datasets like MaxMind GeoLite2 or IPinfo, but in this case we just used a Google document found online. We create a CSV file containing IP addresses and their respective geolocation information, then upload this data into Azure Log Analytics using a custom log table or via PowerShell/Azure CLI. This additional context allows us to understand the geographical distribution of attackers and identify regional targeting patterns. With geolocation enrichment in place, we merge our log data and geolocation data within our workspace using KQL join operations. We write queries that correlate attacker IPs with countries or cities, showing us where threats originate. We also detect repeated attacks from the same region and analyze whether certain countries are attempting specific types of intrusions. This provides a clearer view of threat origins and attacker behavior patterns. Finally, we visualize our enriched log data using a geographic attack map. This can be done using tools like Power BI, Python (with Folium, Plotly, or Matplotlib), or Kibana. We plot the source locations of IPs on a world map, using bubbles or heatmaps to represent the volume of attacks from each region. This attack map offers a visual summary of real-time or historical attack activity and can be updated dynamically as new logs arrive. It not only makes the data more engaging but also provides insights for potential threat intelligence reporting or further automation.






