<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Dhiraj Ambigapathi on Medium]]></title>
        <description><![CDATA[Stories by Dhiraj Ambigapathi on Medium]]></description>
        <link>https://medium.com/@Darkhue?source=rss-3dfbbd830ee5------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*6d1KU509B80m1brR0mOOpw.jpeg</url>
            <title>Stories by Dhiraj Ambigapathi on Medium</title>
            <link>https://medium.com/@Darkhue?source=rss-3dfbbd830ee5------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 24 Nov 2026 03:58:44 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@Darkhue/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[AI Automation in Cyber Security]]></title>
            <link>https://medium.com/@Darkhue/ai-automation-in-cyber-security-7efa302f0d66?source=rss-3dfbbd830ee5------2</link>
            <guid isPermaLink="false">https://medium.com/p/7efa302f0d66</guid>
            <category><![CDATA[vulnerability]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[llm]]></category>
            <category><![CDATA[n8n]]></category>
            <dc:creator><![CDATA[Dhiraj Ambigapathi]]></dc:creator>
            <pubDate>Fri, 20 Feb 2026 07:45:05 GMT</pubDate>
            <atom:updated>2026-02-22T12:21:51.033Z</atom:updated>
            <content:encoded><![CDATA[<p>AI Automation in Cyber Security</p><p>In the modern landscape of offensive security and red teaming, speed and adaptability are everything. We have incredibly powerful command-line tools, but rigging them together, managing infrastructure, and correlating data manually remains a massive bottleneck.</p><p>We often find ourselves thinking: <strong>“Why can’t I kick off a comprehensive recon scan on a new target while I’m just grabbing a coffee?”</strong></p><p><strong>“Why can’t I trigger an automated enumeration of the latest CVEs against my asset list while I do my day Job?”</strong></p><p><strong>“Why can’t I initiate an instant PCAP triage while I’m literally racing toward a 2 AM incident response?”</strong></p><p><strong>“Why can’t I initiate a AI assisted Burpsuite mcp Active enumeartion of a domain, subdomain or API, while taking a nap ?”</strong></p><p>This Blog moves beyond theoretical automation. We are going to deconstruct a production-ready workflow we built that transforms a complex chain of security tools living on a remote server into a streamlined Telegram bot interface. This enables security professionals to conduct comprehensive subdomain enumeration and vulnerability assessments from anywhere, enriched with AI-powered analysis to cut through the noise.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/565/1*rYtx8nFpEk1G4-wFXcqLEg.png" /><figcaption>Enumerate a Domain</figcaption></figure><h3>The Philosophy: Why Build It This Way?</h3><p>As security practitioners, we love our CLI tools — the recon frameworks, the port scanners, the template-based vulnerability engines. But chaining them together usually results in fragile bash scripts that are hard to monitor and even harder to trigger remotely.</p><p>We needed a system that was robust, self-hosted, and mobile-first.</p><p>We chose <strong>n8n</strong> as the orchestration layer because it offers the best of both worlds: a visual builder for complex logic flows and the ability to drop into raw JavaScript or execute shell commands via SSH when needed. It runs as a system service (systemd) on our own hardware or as a Docker Instance, ensuring data privacy.</p><p>We chose <strong>Telegram</strong> as the interface because it’s fast, secure, supports push notifications, and crucially, allows for interactive buttons — perfect for inserting “human-in-the-loop” approval steps before launching noisy scans.</p><h3>System Architecture</h3><p>This isn’t just a wrapper around an API; it’s infrastructure orchestration. The architecture is designed to separate the “brains” (the logic) from the “muscle” (the scanning) and, crucially, to secure the entire pipeline from external threats.</p><p>At a high level, our n8n server acts as the Command &amp; Control (C2) hub. To protect this critical infrastructure, we do not expose it directly to the internet. Instead, we use a <strong>Cloudflare Tunnel</strong>. This establishes a secure, outbound-only connection from our n8n server to Cloudflare’s edge network. The telegram webhook hits Cloudflare first, which then tunnels the request securely to our server, meaning we have <strong>zero open inbound ports</strong>.</p><p><em>To maintain a true </em><strong><em>Defense in Depth</em></strong><em> posture, I’ve isolated my N8N environment across two Raspberry Pi 5s: one acting as the Master Monitor and the other as a dedicated Scanning Worker. I opted for the Pi 5 due to its perfect balance of availability and physical isolation capabilities. However, the beauty of this system is its flexibility — it can be adapted to almost any hardware (ARM, AMD, etc.) using Docker, though some platforms may require manual compilation.</em></p><p>Once n8n receives a command, it validates it and then dispatches jobs via SSH to a hardened scanning node where the heavy offensive tools reside. Finally, it pipes the raw output to LLM APIs to synthesize the findings.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*dzJ6TqS9Pxlkgn51WQ3YeA.png" /><figcaption>Basic Architecture.</figcaption></figure><h3>Component Responsibilities</h3><ul><li><strong>The Interface (Telegram):</strong> The frontend. It handles command input (/scan target.com), presents &quot;Yes/No&quot; approval buttons for active scanning, and delivers the final, sanitized reports.</li><li><strong>The Secure Gateway (Cloudflare Tunnel):</strong> The shield. It receives the webhook from Telegram, provides DDoS protection, hides our server’s real IP, and creates a secure path for the data to reach n8n. Also you can filter based on Geo-location, HTTP headers, SSL/TLS etc via cloudflare.</li><li><strong>The Brain (n8n):</strong> The orchestrator. It manages state, handles credentials securely, executes conditional logic, and transforms data between the different stages of the attack chain.</li><li><strong>The Muscle (SSH Scanning Node):</strong> A dedicated, disposable Linux server (Raspberry PI) holding the actual offensive security tooling. It executes the heavyweight scripts so the orchestrator doesn’t bog down.</li><li><strong>The Analysts (AI Services):</strong> LLM APIs act as junior analysts, parsing raw, messy CLI output into prioritized, readable summaries.</li></ul><h3>The Workflow: A Journey from Command to Report</h3><p>The workflow is event-driven. It doesn’t do anything until authorized. It moves intelligently from passive reconnaissance to active scanning, but only with explicit user permission at critical junctures.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mOIYSEFG_ASOdYsb353nFQ.png" /><figcaption>Workflow</figcaption></figure><h3>Step 1: The Gatekeeper (Trigger &amp; Validation)</h3><p>Everything starts with a webhook receipt from Telegram, routed securely through the Cloudflare Tunnel. But we don’t just take input and run with it — that’s how you get command/prompt injection vulnerabilities in your own tooling.</p><p>We use an n8n <strong>Code Node (JavaScript)</strong> immediately after the trigger for two critical functions:</p><ol><li><strong>Authorization Gate:</strong> It checks the incoming Telegram User ID against a hardcoded whitelist of security team members. If you aren’t on the list, the workflow silently drops the request.</li><li><strong>Input Sanitization:</strong> It employs strict regex validation to ensure the input is actually a domain name and contains no malicious characters before it ever touches a shell command.</li></ol><blockquote><strong><em>The Golden Rule of Automation:</em></strong><em> Never pass raw user input directly into an SSH execution node, even if you trust the user. Always sanitize first.</em></blockquote><h3>Step 2: The Heavy Lifting (Passive Reconnaissance)</h3><p>Once validated, n8n connects to our scanning node via SSH.</p><p>Instead of trying to manage ten different CLI tools inside n8n’s UI, we trigger a single, robust bash script on the remote server (our custom reconnaissance framework). This script handles the noisy work: enumerating subdomains using various passive sources, performing DNS resolution to discard dead hosts, and probing for live HTTP servers.</p><p>N8n monitors the SSH session for completion. Crucially, it parses the standard output to find the exact path where the structured results were saved, allowing subsequent nodes to know exactly where to pick up the trail.</p><h3>Step 3: The Pivot (Active Scanning &amp; The Human Loop)</h3><p>We now have a list of live targets. Up until this point, our traffic has been mostly passive DNS queries. Running a full vulnerability scanner generates significant noise and can impact target systems.</p><p><strong>We need a human in the loop.</strong></p><p>N8n sends a message back to Telegram with interactive buttons: <em>“Recon complete. 150 live assets identified. Do you want to launch active vulnerability scanning?”</em></p><p>The workflow actually pauses here.</p><ul><li>If the user clicks <strong>No</strong>, the workflow wraps up and sends the recon data.</li><li>If the user clicks <strong>Yes</strong>, n8n executes the next SSH node, firing up a template-based vulnerability scanner against the discovered URLs.</li></ul><h3>Step 4: Taming the Noise with AI</h3><p>CLI output from scanners is notoriously messy — full of ANSI color codes, verbose info logs, and false positives. Sending raw text to a phone screen is useless.</p><p>We tackle this in a three-stage pipeline:</p><ol><li><strong>Cleaning:</strong> An n8n Code node ingests the raw stdout and uses regex to strip terminal color codes and parse the results into a clean JSON object.</li><li><strong>Analysis:</strong> We pass this structured data to an LLM (like Claude) with a specific system prompt acting as an Offensive Security Engineer. We ask it to validate findings and prioritize them based on real-world exploitability.</li><li><strong>Summarization:</strong> For the final mobile-friendly view, we generate a “Bug Bounty Style” summary: high-impact findings only, with clear steps to reproduce, formatted in markdown for Telegram.</li></ol><h3><strong>Wait ! There’s more…</strong></h3><h3>The Intelligence Layer: Zeek, Suricata, and MCP</h3><p>The true power of this setup lies in its ability to transform raw packets into actionable intelligence. By leveraging <strong>MCP (Model Context Protocol) servers</strong>, I’ve bridged the gap between traditional NSM tools and Large Language Models:</p><ul><li><strong>Suricata:</strong> Acts as the frontline IDS, flagging known malicious signatures and protocol anomalies within my PCAP data.</li><li><strong>Zeek (formerly Bro):</strong> Provides deep, transaction-level logging, turning unstructured traffic into rich metadata (DNS queries, HTTP headers, and SSL certificates).</li><li><strong>MCP Integration:</strong> Instead of manually triaging alerts, I use MCP servers to feed Zeek logs and Suricata alerts directly into an AI-driven workflow. This allows for real-time, natural-language querying of network events, such as: <em>“Summarize all suspicious TLS handshakes from the scanning node in the last hour.”</em></li></ul><p>This synergy between <strong>isolated hardware</strong> and <strong>protocol-aware AI</strong> creates a highly resilient, automated SOC-in-a-box that punches far above its weight class.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/549/1*maY60sFKPVnlVKcibvjujw.png" /><figcaption>PCAP Analysis</figcaption></figure><h3>The External Intelligence: Shodan MCP Integration</h3><p>The real power comes from the <strong>Shodan MCP (Model Context Protocol) server</strong>. Shodan is not part of the packet inspection pipeline; instead, it provides the <strong>external lens</strong>.</p><p>By leveraging the Shodan MCP server within N8N, I can automatically correlate internal findings with global internet data:</p><ul><li><strong>CVE Tracking:</strong> Automatically fetch the latest vulnerability data for assets identified in my environment.</li><li><strong>Attack Surface Mapping:</strong> Cross-reference internal IPs with Shodan’s external scan history to see if any services are accidentally exposed to the public internet.</li><li><strong>AI-Driven Triage:</strong> Using the MCP protocol, I can ask an LLM: <em>“Based on the latest Zeek logs and Shodan’s CVE database, which of my internal assets are currently at the highest risk of exploitation?”</em></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/551/1*IsmTjWLKtJrjlwNKBuXjog.png" /><figcaption>latest cve</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/482/1*4jtB9WkTgsqke-jUz02k-w.png" /><figcaption>latest cve affected assets</figcaption></figure><h3>The Active Validation: Burp Suite Integration</h3><p>While Shodan identifies the “doors,” <strong>Burp Suite</strong> tests the “locks.” Once Shodan identifies an exposed web service or API, n8n triggers the Burp Suite REST API to move from passive observation to active security testing.</p><ul><li><strong>Automated DAST Scanning:</strong> As soon as Shodan discovers a new web-facing asset or after subdomain enumeration n8n can initiate a Burp Suite scan to probe for critical vulnerabilities like SQL Injection, Cross-Site Scripting (XSS), and Broken Authentication.</li><li><strong>API Vulnerability Probing:</strong> For discovered API endpoints, Burp Suite can be tasked to ingest OpenAPI/Swagger definitions. It tests for <strong>BOLA (Broken Object Level Authorization)</strong> and mass assignment vulnerabilities that Shodan’s metadata-based scans cannot see.</li><li><strong>Exploitability Verification:</strong> If Shodan flags a high-severity CVE (e.g., a vulnerable version of Log4j or Log4Shell), Burp Suite is automatically deployed to verify if the asset is actually exploitable or if existing mitigations (like a WAF) are successfully blocking the attack.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/573/1*tTrQMTDhHWBYEDQ_Xsj2Xg.png" /><figcaption>AI assisted Burpsuite Scan</figcaption></figure><h3>Security Architecture &amp; Defense-in-Depth</h3><p>When you build automation that performs security testing, the automation platform itself becomes a critical target. We approached the security of this system in layers.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*9e1GLopNjvxP-m3BqCLrxQ.png" /><figcaption>Entire Architecture</figcaption></figure><ul><li><strong>Network Layer (Cloudflare Tunnel):</strong> By using Cloudflare Tunnel, our n8n server has no open inbound ports. The tunnel establishes a secure outbound connection to Cloudflare’s network. This masks our server’s origin IP address, provides automatic DDoS protection, and allows us to enforce Zero Trust access policies before a request even reaches our infrastructure.</li><li><strong>Credential Isolation:</strong> SSH keys, Telegram bot tokens, and AI API keys are never hardcoded in the workflow nodes. They are stored in n8n’s encrypted credential store, accessible only at runtime.</li><li><strong>Execution Approvals:</strong> The most impactful step — active vulnerability scanning — cannot be automated away. It requires explicit, authenticated human approval via Telegram before execution.</li></ul><h3>Hard-Earned Lessons from the Field</h3><p>Building this wasn’t without its hurdles. Here are a few key takeaways from running this in production:</p><ul><li><strong>Handle Long Messages Gracefully:</strong> Telegram has a hard 4096-character limit per message. A verbose scan output will break your bot instantly. We had to implement a JavaScript “chunking” node right before the final output to split long reports into multiple readable Telegram messages automatically.</li><li><strong>Structured Outputs are Vital:</strong> Ensure your underlying scanning scripts output data into uniquely named directories based on a timestamp or run-hash. If two users trigger scans simultaneously and your script just writes to a generic /tmp/output.txt, you will have data collisions and race conditions.</li><li><strong>AI is for Formatting, Not Detection:</strong> Don’t blindly trust an LLM’s assessment of a vulnerability’s severity — it can hallucinate. However, you <em>can</em> trust it to take 500 lines of ugly grep output and turn it into a beautiful, readable Markdown table. Use AI for summarization and formatting; rely on your deterministic tools for detection.</li></ul><h3>Conclusion</h3><p>This workflow demonstrates that powerful security automation doesn’t require expensive enterprise SOAR platforms. By intelligently combining open-source orchestration (n8n), ubiquitous messaging apps (Telegram), standard Linux infrastructure, modern AI APIs, and secure networking principles like Cloudflare Tunnel, we can build highly capable, mobile-ready security assessment pipelines.</p><p>The goal isn’t to replace the security professional, but to automate the repetitive reconnaissance phase so the professional can focus on active exploitation and analysis the moment the notification arrives on their phone.</p><h3><strong>Reference Links</strong></h3><p>N8N Telegram Node — <a href="https://docs.n8n.io/integrations/builtin/app-nodes/n8n-nodes-base.telegram/">https://docs.n8n.io/integrations/builtin/app-nodes/n8n-nodes-base.telegram/</a></p><p>Telegram Bots — <a href="https://core.telegram.org/bots">https://core.telegram.org/bots</a></p><p>Cloudflare Tunnel — <a href="https://developers.cloudflare.com/cloudflare-one/networks/connectors/cloudflare-tunnel/">https://developers.cloudflare.com/cloudflare-one/networks/connectors/cloudflare-tunnel/</a></p><p>Zeek MCP — <a href="https://mcpmarket.com/server/zeek">https://mcpmarket.com/server/zeek</a></p><p>Suricata MCP — <a href="https://github.com/Medinios/SuricataMCP">https://github.com/Medinios/SuricataMCP</a></p><p>Shodan MCP — <a href="https://github.com/ADEOSec/mcp-shodan">https://github.com/ADEOSec/mcp-shodan</a></p><p>Burp MCP — <a href="https://github.com/six2dez/burp-ai-agent">https://github.com/six2dez/burp-ai-agent</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7efa302f0d66" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[MCP for Cybersecurity]]></title>
            <link>https://medium.com/@Darkhue/mcp-for-cybersecurity-ce2073d0c7de?source=rss-3dfbbd830ee5------2</link>
            <guid isPermaLink="false">https://medium.com/p/ce2073d0c7de</guid>
            <category><![CDATA[pentesting]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[artificial-intelligence]]></category>
            <category><![CDATA[mcp-server]]></category>
            <dc:creator><![CDATA[Dhiraj Ambigapathi]]></dc:creator>
            <pubDate>Wed, 16 Apr 2025 15:02:11 GMT</pubDate>
            <atom:updated>2025-04-16T15:02:11.417Z</atom:updated>
            <content:encoded><![CDATA[<p>Hi Everyone, MCP servers have been a game changer for implementing LLM into daily workflow. In this blog I will try to demonstrate how you can implement multiple MCP servers into a single MCP client which can communicate with multiple LLMs including Ollama, Anthrophic, Google, ChatGPT etc.</p><h3>What is MCP ?</h3><p>Model Context Protocol or just MCP is Anthrophic’s attempt to standardize the way we want Large Language Model to interact with external tools. Once integrated with a capable LLM, we can perform manual activities through a request, typically sent through a MCP client.</p><p>Ideally, we need to be able to add multiple MCP servers and be able to access multiple LLMs through a single MCP client. This is possible through <a href="https://5ire.app/docs">5ire</a>.</p><p>You can download 5ire from the link above and we will see how to set it up. Let’s consider a MCP server for shodan <a href="https://github.com/BurtTheCoder/mcp-shodan">here</a>.</p><figure><img alt="Install and Open the 5ire App and click on tools and then click on add" src="https://cdn-images-1.medium.com/max/1021/1*ZXP7Y00tpplGs-XewlcxWA.png" /></figure><p>To integrate this with 5ire we need to go to tools and add it.</p><p>Let’s read the configuration on shodan MCP <a href="https://github.com/BurtTheCoder/mcp-shodan">github page</a>.</p><figure><img alt="Shodan mcp server configuration" src="https://cdn-images-1.medium.com/max/542/1*eyErvgtPhW126xOotfl_Bw.png" /></figure><p>Now let’s add this to 5ire tools.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1018/1*aTodBtoV0nG1NKCAWCId4w.png" /></figure><p>Then we can add command, arguments and environment variables to integrate our MCP server. 5ire will create configuration on its own.<br>Once it’s working we will select which LLM to use. 5ire allows multiple LLM options including Google Gemini, Anthrophic Sonnet, ChatGPT, Ollama llama-3.2 and so on. All these are available under settings.</p><figure><img alt="Multi-LLM support" src="https://cdn-images-1.medium.com/max/980/1*BfAsV7gqPaI1YUezFnninw.png" /></figure><p>I highly suggest testing out Ollama and free tier of LLM before choosing to buy API credits for them.</p><p>Once everything is setup and working, we can query different LLMs and see how they carry out the tasks. I’ve integrated multiple MCP servers, links below.</p><p><a href="https://github.com/BurtTheCoder/mcp-shodan"><strong><em>Shodan MCP</em></strong></a></p><p><a href="https://github.com/zinja-coder/jadx-ai"><strong><em>JadX-AI</em></strong></a></p><p><a href="https://github.com/elastic/mcp-server-elasticsearch"><strong><em>ElasticSearch</em></strong></a></p><p><a href="https://github.com/DMontgomery40/pentest-mcp"><strong><em>Pentest-MCP</em></strong></a></p><p><a href="https://github.com/LaurieWired/GhidraMCP"><strong><em>Ghidra-MCP</em></strong></a></p><p>Below are some Proof of Concept for 5ire MCP client</p><figure><img alt="Pentest MCP" src="https://cdn-images-1.medium.com/max/786/1*EnZQRh4V3--uwnv7uYFZiA.jpeg" /></figure><figure><img alt="JadX-AI" src="https://cdn-images-1.medium.com/max/761/1*VghvxT0TXsHvRz7oZtnBBQ.jpeg" /></figure><figure><img alt="OpenSearch MCP" src="https://cdn-images-1.medium.com/max/736/1*mwrB452b1kcp9Vi6NUXnfw.jpeg" /></figure><p>Hope you learnt something from this short blog. I’m looking into more use cases for MCP and LLM in general for CyberSecurity and would add more blogs as I do.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ce2073d0c7de" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Packet level monitoring for Cloud]]></title>
            <link>https://medium.com/@Darkhue/packet-level-monitoring-for-cloud-a0cf216f342f?source=rss-3dfbbd830ee5------2</link>
            <guid isPermaLink="false">https://medium.com/p/a0cf216f342f</guid>
            <category><![CDATA[zeek]]></category>
            <category><![CDATA[soc]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[detection-engineering]]></category>
            <category><![CDATA[aws]]></category>
            <dc:creator><![CDATA[Dhiraj Ambigapathi]]></dc:creator>
            <pubDate>Fri, 29 Nov 2024 18:21:29 GMT</pubDate>
            <atom:updated>2024-11-29T18:21:29.023Z</atom:updated>
            <content:encoded><![CDATA[<h3>Network monitoring for AWS</h3><p>Hey everyone, today we will be going through monitoring AWS network using OpenSource Network Security Monitoring (NSM) Zeek framework.</p><p>The Problem statement is “How do we monitor Network across public cloud?” , unlike traditional systems we can’t put a switch or fetch packets directly. So this blog is a potential solution to increase your Cloud threat visibility and improve your SIEM/SOAR capabilities.</p><p><strong><em>Zeek</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/523/1*AfrvQcnOxwwo2lbRReoKLQ.png" /><figcaption>Zeek</figcaption></figure><p>Zeek is a passive, open-source network traffic analyzer.<br>Many operators use Zeek as a network security monitor (NSM) to support investigations of suspicious or malicious activity.<br>Zeek also supports a wide range of traffic analysis tasks beyond the security domain, including performance measurement and troubleshooting.<br>The protocol detection capability can be extended through Zeek scripts.</p><p><strong><em>Zeek Framework</em></strong></p><p>Zeek has Cluster and Standalone setup.</p><p>We will use standalone setup for our environment.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*rBgD0YIuObb-CFj68rr0fg.png" /><figcaption>Zeek Infrastructure</figcaption></figure><p>AWS Setup</p><p>For AWS monitoring we will need two instances.</p><ol><li>Instance to be monitored</li><li>Instance which will be used for setting up Zeek</li></ol><p>AWS allows Traffic Mirroring only for nitro instances. t3 instances are what we need to setup and perform network monitoring. You can create instances from EC2 tab.</p><p>I will use a t3.medium 4GB (Zeek server) and a t3.micro 1GB (host server).</p><p>I will mirror traffic from t3.micro and send it to t3.medium, where my Zeek framework is running for further analysis and logging.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*MaOZ9JxyFgzIs0YO5rB-Zg.png" /><figcaption>Create a t3.medium instance</figcaption></figure><p>Our End system or System to be monitored would be a t3.micro, with bare minimum configurations.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eDEje3-Vb62eX3Z5DO7dAg.png" /><figcaption>T3 micro system</figcaption></figure><p>AWS network architecture</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/941/1*87kdyb8vomIoxSOwNz1Xsw.png" /><figcaption>Network Architecture</figcaption></figure><p>As you can in the architecture, we are going to mirror traffic from virtual network adapter, detect and analyze it on our dedicated Zeek server.</p><p><strong>Zeek Installation</strong></p><p>We need to install Zeek on our t3.medium system, I followed official documentation <a href="https://docs.zeek.org/en/current/quickstart.html">here</a></p><p><strong>Setup AWS Traffic Mirror</strong><br>You can check out the link <a href="https://docs.aws.amazon.com/vpc/latest/mirroring/traffic-mirroring-getting-started.html#step-create-traffic-mirroring-target">here</a> for a walk through for setting up Amazon Traffic mirroring.</p><p>First we need to setup Mirroring Target, this will be the system that’s running Zeek which will detect and convert packets to logs.</p><figure><img alt="The Mirror Target i.e System running Zeek" src="https://cdn-images-1.medium.com/max/1024/1*cS_ASyZCdGKyEhlqmhoubQ.png" /><figcaption>Mirror Target (System running Zeek)</figcaption></figure><p>Then we need to create Filters, here we will allow all traffic for now, but it’s up to your discretion on how to configure for yourself.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*D6n23iqV5WjBvzR4yEg7Ww.png" /><figcaption>Creating Filters</figcaption></figure><p>Lastly we need to create a Session that will mirror packets on our system to be monitored and send it to our previously created Mirror target (System running Zeek).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*v-R4HZJa0CJ-Dmv3xQqfjw.png" /><figcaption>Traffic Mirror Session Created.</figcaption></figure><p>Once we have everything setup we can test it out by running Zeek and trying to create logs on other system.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/556/1*JL-ZsO-wc_KBkLA0jNrtLg.gif" /><figcaption>Final Working Setup.</figcaption></figure><p>Few things to remember:</p><p>AWS will charge for Traffic mirroring as shown <a href="https://aws.amazon.com/vpc/pricing/">here</a></p><p>Similar setup could be done across other Cloud service providers like Azure or Google Cloud with similar services and Zeek.</p><p>AWS Nitro instances support Traffic Mirroring, more to read <a href="https://docs.aws.amazon.com/vpc/latest/mirroring/traffic-mirroring-sessions.html">here</a></p><p>You can scale this and create more sessions, add further monitoring via Suricata or even pull these logs onto ELK stack or your SIEM/SOAR for further analysis, Incident Response or Forensics.<br>If you’d like me to write future blogs on expanding the detection series feel free to like and comment.</p><p>Once you pull logs it’s easy to create a Visualization like this</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ckTuJMNnMTgUgGE8wTrsKg.png" /><figcaption>Zeek Dashboard</figcaption></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a0cf216f342f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Build your own Raspberry Pi Home Lab]]></title>
            <link>https://medium.com/@Darkhue/build-your-own-raspberry-pi-home-lab-16e9820ec7e4?source=rss-3dfbbd830ee5------2</link>
            <guid isPermaLink="false">https://medium.com/p/16e9820ec7e4</guid>
            <category><![CDATA[raspberry-pi-5]]></category>
            <category><![CDATA[portainer]]></category>
            <category><![CDATA[docker]]></category>
            <category><![CDATA[homelab]]></category>
            <category><![CDATA[raspberry-pi-4]]></category>
            <dc:creator><![CDATA[Dhiraj Ambigapathi]]></dc:creator>
            <pubDate>Mon, 23 Sep 2024 19:24:27 GMT</pubDate>
            <atom:updated>2024-09-23T19:24:27.933Z</atom:updated>
            <content:encoded><![CDATA[<p>I got a Raspberry Pi a month ago and decided to use it to its full potential. I planned that I need few things which will secure not only my data but also provide multiple multimedia services. So I made a list of features I need in my Lab.</p><p>1. Cloud Storage with Mobile app to automatically upload my data.</p><p>2. Password Manager for all devices.</p><p>3. Multimedia Server so that I can stream Movies, Music and eBooks.</p><p>4. Global access to Raspberry Pi Lab without having to buy a Public IP.</p><p>5. Use Open Source projects/technologies .</p><p>Once the objectives were set, I picked my hardware.<br>The Hardware :-</p><ol><li>Raspberry Pi 5 (8GB RAM) —</li></ol><p><a href="https://www.raspberrypi.com/products/raspberry-pi-5/">https://www.raspberrypi.com/products/raspberry-pi-5/</a></p><p>2. Raspberry Pi M.2 Hat to add SSD storage —</p><p><a href="https://www.raspberrypi.com/products/m2-hat-plus/">https://www.raspberrypi.com/products/m2-hat-plus/</a></p><p>3. Setting up the RPi5 with SSD Hat</p><p><a href="https://www.raspberrypi.com/documentation/accessories/m2-hat-plus.html">https://www.raspberrypi.com/documentation/accessories/m2-hat-plus.html</a></p><p>4. Setup Video</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FEXWu4SUsaY8%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DEXWu4SUsaY8&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FEXWu4SUsaY8%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/7e5c59d466d0f0025ccf60b4b3fd720a/href">https://medium.com/media/7e5c59d466d0f0025ccf60b4b3fd720a/href</a></iframe><p>5. I also used GeekWorm UPS and Case for additional benefits and availability.</p><p><a href="https://geekworm.com/">All for Raspberry Pi, Jetson Nano, Arduino, Orange Pi by Geekworm.com</a></p><p>Note — If you are new to Raspberry Pi 5 it might take time to learn the process, feel free to do your own research.</p><p>The Platform :-</p><p>I wanted to run multiple software so as to have a certain level of isolation, I chose to use Docker as underlying platform. Along with it I wanted a GUI interface and not a Terminal for configuring and troubleshooting. So for this I found a very awesome project — PI-Hosted</p><p>Note: If you’re new to Docker feel free to visit the YouTube link below for a walk-through of setup.</p><p><a href="https://pi-hosted.com/">Pi-Hosted Portainer Template V2</a></p><p>Do support the Pi-hosted YouTube channel</p><p><a href="https://www.youtube.com/channel/UCrjKdwxaQMSV_NDywgKXVmw">Novaspirit Tech</a></p><p>My Pi-Hosted Dashboard</p><p>Pi-Hosted is basically Portainer support for RPi — 5. Portainer is a GUI interface to maintain your Docker containers and stacks.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Zt7AC8Y9NUIxbqmLk3SUhQ.png" /><figcaption>Portainer Dashboard.</figcaption></figure><p>Pi-Hosted also provides a bunch of custom templates, which can be configured and deployed asap. Just ensure you set the port mapping and choose proper volumes to mount while deploying custom templates. Expect a lot of troubleshooting because it’s how you will get better with containers.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/326/1*WR64Vk--P_6Wzy9QeW_glQ.png" /><figcaption>Publishing Ports</figcaption></figure><p>YouTube Playlist for Docker setup</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FE6IrT3g5Gqc%3Flist%3DPL846hFPMqg3iKNsXNCj0hYStTgflsJjkC&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DE6IrT3g5Gqc&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FE6IrT3g5Gqc%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/91bf572e1d0aa16175d78526708866c3/href">https://medium.com/media/91bf572e1d0aa16175d78526708866c3/href</a></iframe><p>So What am I running?</p><p>I’m running all custom templates which are found under pi-hosted templates. You can customize these as per your needs and deploy them.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/867/1*J5n-_kkMVHGIaYVAdqTptQ.png" /><figcaption>Custom Portainer Templates</figcaption></figure><ol><li>I’m running NextCloud through Docker template and currently am using it as a replacement for Google services like Google Drive, Photos and so on.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*yEYPicie286ZGlnS97Jb1w.png" /><figcaption>Running NextCloud within Portainer</figcaption></figure><p>NextCloud Docker —</p><p><a href="https://docs.linuxserver.io/images/docker-nextcloud">nextcloud - LinuxServer.io</a></p><p>NextCloud also provide Mobile App which can be seamlessly integrated with our private server.</p><p><a href="https://apps.nextcloud.com/apps/android_nextcloud_app">Android Nextcloud App</a></p><p>2. I’m using VaultWarden (compatible with BitWarden) as my Password Manager.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*t3hMBf6QakvlaaFsigDwJQ.png" /><figcaption>Running VaultWarden on Portainer</figcaption></figure><p>VaultWarden Docker —</p><p><a href="https://github.com/dani-garcia/vaultwarden/wiki">Home</a></p><p>BitWarden also provides a Mobile App which can be configured to connect to our Pi — Hosted VaultWarden server to store/fetch credentials.</p><p><a href="https://bitwarden.com/help/getting-started-mobile/">Password Manager Mobile Apps | Bitwarden Help Center</a></p><p>BitWarden also provides browser extensions for Chrome and Firefox, which also can be integrated with our cloud setup.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/350/1*IKkyiWqKTF0uziWdDIo06g.png" /><figcaption>Browser Extension for Firefox</figcaption></figure><p>3. The Whole setup is accessible through my TailScale VPN setup.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*M746OIz8G8qBsCX89xhCvg.png" /><figcaption>Running TailScale on Portainer</figcaption></figure><p><a href="https://tailscale.com/kb/1017/install">Tailscale quickstart · Tailscale Docs</a></p><p>Note — You can deploy many other containers as you wish, above are just for demonstration purpose.</p><p>Here’s a playlist for deployment of multiple other containers</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FcO2-gQ09Jj0%3Flist%3DPL846hFPMqg3jwkxcScD1xw2bKXrJVvarc&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DcO2-gQ09Jj0&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FcO2-gQ09Jj0%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/eb3257ad8a819fa6ee6b4608307ac32b/href">https://medium.com/media/eb3257ad8a819fa6ee6b4608307ac32b/href</a></iframe><p>The ARR Stack</p><p>The ARR Stack is configuration of multiple services/containers which will work together to fetch Torrents.</p><h3>Torrents can be illegal based on where you stay, so beware and do your own research.</h3><ol><li>Prowlarr — Prowlarr is Index manager where you can add which torrent feeds to search .</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6XXVH53NsmDpvj48LgReKQ.png" /><figcaption>Prowlarr Dashboard</figcaption></figure><p>2. Readarr — Readarr is an ebook collection manager tailored for Usenet and BitTorrent users. It monitors multiple RSS feeds to discover new books from your favorite authors and integrates with clients and indexers to download, organize, and rename them efficiently.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*TYR0PbW_iep1RyOwFyCQdw.png" /><figcaption>Readarr Dashboard</figcaption></figure><p>3. Sonarr — Sonarr is a personal video recorder (PVR) designed for Usenet and BitTorrent users. It tracks various RSS feeds to automatically download, sort, and rename new episodes of your favorite shows. It can also be set up to upgrade your existing files to higher quality versions as they become available.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/802/1*0UzXNDNxug-XLfwoWTkiPA.png" /><figcaption>Sonarr search</figcaption></figure><p>4. Transmission — Transmission is our torrent client which will integrated with Sonarr, Readarr and other managers to download content once Prowlarr has found relevant results.</p><p>Transmission Docker —</p><p><a href="https://docs.linuxserver.io/images/docker-transmission">transmission - LinuxServer.io</a></p><p>5. FlareSolverr — The system initiates a proxy server and remains in an idle state, consuming minimal resources while awaiting user requests. Upon receiving a request, it utilizes Selenium along with the undetected-chromedriver to launch a web browser (Chrome). It then opens the specified URL with the provided parameters and waits for the Cloudflare challenge to be resolved or until a timeout occurs.</p><p>6. Emby — Emby is my multimedia server which will read downloaded torrents and stream it through a web console. Emby also has IOS, Android Apps for seamless integration.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/778/1*QQEk9tG_CJQjJhvjhMN95g.jpeg" /><figcaption>ARR Stack</figcaption></figure><p>My Entire Architecture</p><figure><img alt="My Home Lab Setup Architecture for a summarized view of the blog" src="https://cdn-images-1.medium.com/max/985/1*_Z64lmmKNrxR7Zyvr-3I6A.jpeg" /><figcaption>Home Lab Setup</figcaption></figure><p>The Home Lab is a ever developing setup, I will definitely add more stuff to it and with every major upgrade I will also update this blog.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=16e9820ec7e4" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Wazuh — Monitor Everything]]></title>
            <link>https://medium.com/@Darkhue/wazuh-monitor-everything-8ba679d0ab7b?source=rss-3dfbbd830ee5------2</link>
            <guid isPermaLink="false">https://medium.com/p/8ba679d0ab7b</guid>
            <category><![CDATA[cyberdéfense]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[monitoring]]></category>
            <category><![CDATA[security]]></category>
            <category><![CDATA[blue-team]]></category>
            <dc:creator><![CDATA[Dhiraj Ambigapathi]]></dc:creator>
            <pubDate>Sun, 14 Jan 2024 18:45:42 GMT</pubDate>
            <atom:updated>2024-01-14T18:45:42.764Z</atom:updated>
            <content:encoded><![CDATA[<h3>Wazuh — Monitor Everything</h3><p>Wazuh Monitoring and Detection</p><p>I started working on SIEM solutions in 2019, eventually I decided to build a Open-Source solution to act as unified solution for Monitoring and Detection for Network, Systems, Docker and Containers, Cloud environments and focusing majorly on cost of working, which ideally must be as low as possible.</p><p>This is the adventure of understanding underlying information, setting up monitoring to detect security threats on widely different platforms, but gathering everything and visualization on one console.</p><p>The generic flow of the blog will be as follows:</p><p>. Where’s the data?</p><p>. How do we monitor?</p><p>. How do we fetch it?</p><p>. How do we understand it?</p><p>. What and how to detect threats?</p><p>Network Monitoring</p><p>Where’s the Data?</p><p>In Network Monitoring we know that data is flowing across wired and wireless medium. But there’s a difference between on-prem networks and on-cloud networks. So let’s break it down<br> On-prem Network can be monitored by analyzing packets at pivotal locations through port forwarding or port mirroring techniques. Using Span or TAP technologies is a quick way to gather packets without troubling the network.</p><p>SPAN technology.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/606/1*Gkqps6tua8Gn9cZ29QW7dA.png" /></figure><p>TAP technology.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/606/1*6BMtSNszeq6HdlWkpZS_og.png" /></figure><p>Note: Choosing between Span or TAP depends on network architecture.</p><p>How do we monitor?</p><p>Irrelevant to technology used to clone packets, they must be routed to Zeek and Suricata sensors.</p><p>How do we fetch it?</p><p>Zeek and Suricata are Network monitoring and detection open-source tools which also leverage threat intel via suricata rules.</p><p>Zeek converts packets to detailed logs for packet level analysis and suricata can detect threats in network based on suricata rules, which can be forwarded to ELK stack or Wazuh (our choice of open-source SIEM).</p><p>Official documentation from Elastic for integrating Zeek is <a href="https://www.elastic.co/blog/collecting-and-analyzing-zeek-data-with-elastic-security">here</a>.</p><p>ELK stack supports Suricata Module so we will just follow the official documentation <a href="https://www.elastic.co/guide/en/beats/filebeat/current/filebeat-module-suricata.html">here</a>.</p><p>Final Architecture</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/614/1*EXodq6WDK6KrYfmd7PrNcA.png" /></figure><p>How do we understand it?</p><p>Once the events and logs are pushed to ELK stack we can create rules for creating events and triggering alerts. These logs will be stored in elastic database which can later be leveraged for network-based threat hunting, incident response and forensics.</p><p>What and how to detect threats?</p><p>Network based threats can be detected via threat intelligence, here suricata rules. But it’s very important to understand logs and events to write rules and trigger alerts. We can also create a Dashboard to visualize threats.</p><p>Zeek Dashboard</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/606/1*1gesomHcV9jSMthWT5ZUJA.png" /></figure><p>Suricata GeoIP Dashbboard</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/606/1*ReRQILytOrmW5ZqMmSFfeA.png" /></figure><p>Suricata Dashboard</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/606/1*1iIa_tzvwO5VG3QYsb_NGQ.png" /></figure><p>SIEM</p><p>We will be using Wazuh (formerly Ossec) OpenSource SIEM for monitoring our assets. Wazuh provides detailed documentation <a href="https://documentation.wazuh.com/current/index.html">here</a>. Wazuh also has a support team via Google mailing list <a href="https://groups.google.com/g/wazuh">here</a>.</p><p><strong>Wazuh Architecture</strong></p><p>System Monitoring</p><p>Wazuh provides multiple agents which can be installed on assets for monitoring the system level threats.</p><p>We will be deploying wazuh server which will be main console which will provide data aggregation, correlation and visualization. Wazuh agents will be deployed on end points for monitoring and response.</p><p>Wazuh Manager and Agents</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/606/1*6IJpR2TtgCMNGeQKYM2EJg.png" /></figure><p>Wazuh provides agents for the following operating systems.</p><p>· Microsoft Windows</p><p>· Linux</p><p>· MacOS</p><p>· Oracle Solaris</p><p>· AIX</p><p>· HP-UX</p><p>A detailed list of wazuh agent packages can be found <a href="https://documentation.wazuh.com/current/installation-guide/packages-list.html">here</a>.</p><p>Where’s the data?</p><p>Wazuh agents fetch data from important locations via &lt;localfile&gt; and &lt;windows_registry&gt; configuration in ‘ossec.conf’ configuration file. But a user can edit this to provide custom locations. For refence checkout localfile config <a href="https://documentation.wazuh.com/current/user-manual/reference/ossec-conf/localfile.html">here</a>.</p><p>Windows ossec.conf</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/606/1*4wHMwBexYAAQs3RW9ixLaA.png" /></figure><p>How do we monitor?</p><p>Once we mention location of files to monitor in ‘ossec.conf’ properly with additional properties like frequency if needed, wazuh-agent will send the information periodically to wazuh-manager.</p><p>Windows ossec.conf</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/606/1*4EAN1qyRb1fQSRCocXbfyw.png" /></figure><p>How do we fetch it?</p><p>Wazuh-agents can be deployed from wazuh-manager via deploy new agent within agents tab.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/606/1*Vp0DF80rgVxCS50W44BU1g.png" /></figure><p>How do we understand it?</p><p>Wazuh understands default windows event logs and displays it on console with all relevant information. For custom logs or any other log format wazuh doesn’t understand we can write custom decoders using regex, decoder documentation <a href="https://documentation.wazuh.com/current/user-manual/ruleset/custom.html">here</a>.</p><p>Summary view of Windows logs.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/606/1*mRIcjcjFr-dikr1zVHEkMg.png" /></figure><p>Windows Events.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/574/1*F-jSSKkyfqkI47xcfr0n2w.png" /></figure><p>We can also integrate Sysmon and monitor those logs, detailed setup <a href="https://wazuh.com/blog/learn-to-detect-threats-on-windows-by-monitoring-sysmon-events/">here</a>.</p><p>What and how to detect threats?</p><p>We can write rules which trigger events, then we can create alerts from events which trigger when conditions are met.</p><p>Creating rules</p><p>Rules can be created via writing a rule detection, do follow this <a href="https://documentation.wazuh.com/current/user-manual/ruleset/ruleset-xml-syntax/rules.html">documentation</a> for more information.</p><p>Alerts</p><p>Once rules are triggered based on conditions we can create Alerts and send them through email, slack webhook or any other custom webhook, detailed documentation <a href="https://documentation.wazuh.com/current/user-manual/reference/ossec-conf/alerts.html">here</a>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/549/1*ews0Bu_E2CtWtJDYYheW9w.png" /></figure><p>Additionally, Wazuh provides FIM capabilities and Vulnerability detection for end points.</p><p>You can checkout this <a href="https://documentation.wazuh.com/current/user-manual/capabilities/vulnerability-detection/how-it-works.html">documentation</a> for vulnerability detection.</p><p>Docker and Containers</p><p>Where’s the data?</p><p>Docker and container monitoring can be broken down into two categories.</p><p>Docker service Monitoring and Docker Log Monitoring</p><p>How do we monitor?</p><p>Docker service monitoring.</p><p>This involves monitoring deployment, manipulation and modification of docker services to handle containers. Typically, this involves monitoring who deploys, deletes, stops, edits containers. We can monitor docker service and publish results using wazuh docker monitoring capabilities. Wazuh has a detailed documentation on monitoring docker service <a href="https://documentation.wazuh.com/current/user-manual/capabilities/container-security/monitoring-docker.html">here</a>.</p><p>Container data monitoring.</p><p>Docker container can create different types of logs. This can be web access logs, firewall logs, network logs etc, anything that’s deployed via containers can create logs and we must be able to pull these logs, detect threats and create alerts.</p><p>How do we fetch it?</p><p>We will use Wazuh-Agent to getch these logs by adding them into &lt;localfile&gt; as</p><p>Ossec.conf</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/458/1*mZ8TlBhUMYzXSSLFOVSzGw.png" /></figure><p>How do we understand it?</p><p>To understand this we need to parse the logs for wazuh to understand the log.</p><p>We will write a web-access-log decoder and save it in /var/ossec/etc/decoder/local_decoder.xml</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/1*nME_lQ9JXTkp733dvQNEqQ.png" /></figure><p>You will have to write custom decoders as per your log source.</p><p>Apache Docker ModSecurity Logs</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/599/1*J6PhKwd8xuFmIx_PCnXw_A.png" /></figure><p>Log entries parsed by decoder.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/606/1*hXkYBsP5MRNmeAiTQAX5mw.png" /></figure><p>This decoder outputs IP, protocol, URL and HTTP-Status code (id). We can then make alerts to detect and alert the organization about an attack</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/579/1*Mo_hzODXTghmzQQwCl0E1A.png" /></figure><p>Wazuh Documentation for Docker Monitoring — <a href="https://wazuh.com/blog/docker-container-security-monitoring-with-wazuh/">Wazuh Docker Monitoring</a></p><p>Cloud Monitoring</p><p>Where’s the data?</p><p>In Cloud the data can be segregated into Cloud operational data i.e Cloud resource related data like deployment, manipulation and terminating cloud services like virtual machines, firewalls, databases etc.</p><p>And The Cloud service operational data i.e Data created by a Cloud service while operational like API gateway logs, Virtual Machine logs etc.</p><p>How do we monitor?</p><p>We can use Cloud logging capabilities to log the events and then fetch the logs from there. For instance, we can setup CloudWatch or CloudTrail for different AWS services and create a role for wazuh to fetch the logs from there, detailed documentation <a href="https://documentation.wazuh.com/current/cloud-security/amazon/index.html">here</a>.</p><p>For Azure we can use Log Analytics/storage account to fetch and store logs, which can thereafter be pulled through Wazuh, detailed documentation <a href="https://documentation.wazuh.com/current/cloud-security/azure/index.html">here</a>.</p><p>Similarly, we can monitor GCP, detailed documentations <a href="https://documentation.wazuh.com/current/cloud-security/gcp/index.html">here</a>.</p><p>Benefit of using Wazuh for Cloud Monitoring?</p><p>Wazuh implements Log Pull method which can be used to fetch logs and delete them from Cloud storage, lowering cost of cloud in general.</p><p>Wazuh can act as a single solution for multi-cloud environment. There is no need to have multiple web consoles and even more troublesome configurations. You can view all activities in a single Web Console.</p><p>Correlation and Identifying threats become streamlined due to availability of all events in a single web console, leading to creation of simple to follow incident playbooks.</p><p>Wazuh also allows creation of response for incidents, which can allow to make automated responses when incident are detected, detailed documentation <a href="https://documentation.wazuh.com/current/user-manual/capabilities/active-response/index.html">here</a>.</p><p>How do we fetch it?</p><p>Depending on the Cloud Service Provider we must use different methods to acquire our data. These can be segregated into push or pull from log sources.</p><p>Pushing logs means to deploy a agent which can push logs from Cloud storage to our Wazuh instance, it’s costly since agent has to be deployed and consumes resources to run 24x7.</p><p>Pulling logs means querying the storages and fetching logs in a timely manner. This doesn’t involve any agents so it’s much cheaper and can be setup to fetch timeline logs only.</p><p>Wazuh Documentation to Integrate AWS is <a href="https://documentation.wazuh.com/current/cloud-security/amazon/index.html">here</a>.</p><p>Sample Snippet of Wazuh Ossec.conf for AWS</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/606/1*6Oz61uBgmlMPpgxuNIjnnQ.png" /></figure><p>Wazuh Documentation to integrate Azure is <a href="https://documentation.wazuh.com/current/cloud-security/azure/index.html">here</a>.</p><p>Sample Snippet of Wazuh Ossec.conf for Azure</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/590/1*QE6OMFM652IQR4BdWG6Uzg.png" /></figure><p>How do we understand it?</p><p>We need to be able to write decoders and rules in order to understand logs and visualize them to detect threats. We can check the logs stored in let’s say CloudWatch, understand it, write a regex decoder and test it.</p><p>AWS API Gateway Logs</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/606/1*Dzv3joq-s9Vg6oXv-1KxeA.png" /></figure><p>Azure Events</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/606/1*gyBVbQhRq1q5yHHn2qVitA.png" /></figure><p>What and how to detect threats?</p><p>We can create Dashboards out of visualized data which can be used for detecting threats. This has to be tailored to an organization’s threat landscape and Alerts must be created for high severity events.</p><p>Tailored Dashboard</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/606/1*ARqsd-MJBmgZK8FRTfCuHA.png" /></figure><p>I hope you got to learn something new with the blog and for more content follow me — Twitter @D4rkhu3.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8ba679d0ab7b" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Build your own Cloud]]></title>
            <link>https://medium.com/@Darkhue/build-your-own-cloud-fefc88a5d4fe?source=rss-3dfbbd830ee5------2</link>
            <guid isPermaLink="false">https://medium.com/p/fefc88a5d4fe</guid>
            <category><![CDATA[network]]></category>
            <category><![CDATA[vpn]]></category>
            <category><![CDATA[raspberry-pi]]></category>
            <category><![CDATA[cloud]]></category>
            <category><![CDATA[nextcloud]]></category>
            <dc:creator><![CDATA[Dhiraj Ambigapathi]]></dc:creator>
            <pubDate>Sun, 13 Nov 2022 18:23:29 GMT</pubDate>
            <atom:updated>2022-11-14T05:16:31.629Z</atom:updated>
            <content:encoded><![CDATA[<p>Hey everyone, this will a walk-through of building your own cloud based storage and providing it global access through VPN. The main objective is to make the private cloud sit in your local lan like your wifi and still make it accessible globally through VPN and additionally use Apps to improve user experience.</p><p>So first we need to decide where we will run our private cloud, you can use virtual machines, standalone systems etc. For me I had a raspberry pi 3 (1GB ram) lying around so I’m just gonna use that.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/0*33jYwaxmFhfEz5xE.jpg" /><figcaption>Raspberry Pi 3 model B</figcaption></figure><p>Now we need to decide what will be our private cloud, I chose to go with nextcloud since it is Opensource and has a large community support and multiple integration and add-ons.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*onWV_aIFh6rHCQxO.png" /><figcaption>NextCloud</figcaption></figure><p>Now since our hardware and software are chosen we need to setup the infrastructure. So download nextcloud image for raspberry pi from <a href="https://github.com/nextcloud/nextcloudpi/releases">here</a></p><p>Make sure you are downloading proper image, for me it’d be raspberry pi image.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ehczIu7WqIokOzZW85UMPA.png" /><figcaption>Raspberry Pi Image</figcaption></figure><p>Now we have to burn our image onto SD card for raspberry pi, I’m using a 16GB SD card. I will use raspberry pi imager from <a href="https://www.raspberrypi.com/software/">here</a>.</p><p>If you’re just getting started with raspberry pi, I’d highly suggest checking out this <a href="https://www.raspberrypi.com/documentation/computers/getting-started.html">blog</a>.</p><p>We select the nextcloud image which we downloaded earlier.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/680/1*pIT_zWJVZ037jLOvCk9PTg.png" /><figcaption>Select custom image</figcaption></figure><p>Then we select the SD card as storage.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/675/1*UXmm1ohYwwVEHphPso4BpQ.png" /><figcaption>Select SD card storage</figcaption></figure><p>Then we edit few settings by clicking on the gear icon.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/682/1*xJeXZv4WSlh9MA8klr2WVg.png" /><figcaption>Edit settings</figcaption></figure><p>Enable SSH and setup your wifi ssid name (name of your WiFi) and password here.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/672/1*1dKx6lOwFM2F-bdHd-qV9w.png" /><figcaption>Setup SSH and WiFi SSID and password</figcaption></figure><p>Now we write and wait for the process to complete.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/672/1*m_W-moi8l32uEwm1rUQCPg.png" /><figcaption>Burn image onto SD card</figcaption></figure><p>Once the image is written you can insert the SD card onto raspberry pi and turn it on.</p><p>Since we mentioned WiFi ssid and password, it connects to your wifi and a ip is assigned to it. You can check this easily by looking onto connected devices on your WiFi.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/278/1*eA2O-Jo4iTQULkJgPsDQzA.png" /><figcaption>IP assigned to Raspberry PI</figcaption></figure><p>And if you wait for 5–10 mins and connect to that IP via browser, you can see nextcloud is already loaded.</p><p>If you get a certificate error, click on advanced and proceed further.</p><p>It will prompt a temporary password, save it and when you proceed further by scrolling down you can use it to set a permanent password (this is a one time thing).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7KFmFr0lqSMSMoA3cDgQcA.png" /><figcaption>Save temporary passwords</figcaption></figure><p>Now you can click on activate, it will prompt you username and password</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/876/1*L79fDRnynW_OuQcxtpkwyg.png" /><figcaption>Activate the Cloud</figcaption></figure><p>Now we get access to the Cloud Console, here we can do a bunch of things. Complete documentation <a href="https://docs.nextcloud.com/server/latest/user_manual/en/">here</a>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eB2W3sI-NOhSXPBad7Wc_Q.png" /></figure><p>Now you can access Cloud management console and explore the options. The de-facto port for this is 4443.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*slMSXE6JDDif4jzJA-GHAQ.png" /><figcaption>Cloud Management Console</figcaption></figure><p>Now if we go back to the Web console, i.e port 443 or just https:// we can access the login page for Nextcloud</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*YoOjHDM4F8q1wt78PCy24Q.png" /><figcaption>NextCloud Login</figcaption></figure><p>Once we login we get access to out private cloud</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ezrMnjg1TTxq7A9915pxww.png" /><figcaption>Private Cloud setup</figcaption></figure><p>Explore the private cloud and discover its capabilities.</p><p>Now we need to setup VPN access for Global access.</p><p>We need to download Tailscale from <a href="https://tailscale.com/download/">here</a> and make a account from <a href="https://login.tailscale.com/login?next_url=%2Fwelcome">here</a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mQSrVkq9j2YXhTM_cO5pjg.png" /><figcaption>Tailscale Login</figcaption></figure><p>Since we’ve setup NextCloudPI on Raspberry PI which is on private network (WiFi Lan) we will use Tailscale to setup a shared VPN. Any device which is connected to this VPN can access our Private Cloud.</p><p>Once you setup Tailscale your device is connected to a VPN. Now we need to setup NetCloudPi to connect to VPN.</p><p>For this we need the API key, you can get it once you login to Tailscale and check Settings -&gt; Personal settings -&gt; Keys</p><p>Generate a Auth key</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-LhWj4RP7ZENoLsQZLr0Ig.png" /><figcaption>TailScale Auth Key</figcaption></figure><p>Now we can ssh into NetCloudPI and setup Tailscale, I’ll change password of user ‘pi’ via accessing the cloud management console and then turn on SSH.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7dJg1BOsVIfyfljNxrr2xg.png" /><figcaption>Turn on SSH</figcaption></figure><p>Once you setup the password and click on Active, we will have to wait for the changes to take place after clicking ‘Apply’.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*FVu490cq6hsx6_gOmP33Vg.png" /><figcaption>SSH enabled</figcaption></figure><p>Now we need to SSH into NetCloudPi and change password once</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/887/1*4UViQZm8qsTCiwvWODXFqA.png" /><figcaption>Login into NextCloudPI</figcaption></figure><p>Once we have changed the password, we can login again and install <a href="https://tailscale.com/download/linux">Tailscale</a>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*FDP6F8o4VbeM5HEQ29C9-A.png" /><figcaption>Install Tailscale on NextCloudPi</figcaption></figure><p>Now we need to connect NextCloudPI too tailscale VPN via Auth-key. The docs for that are <a href="https://tailscale.com/kb/1085/auth-keys/">here</a>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/861/1*VLUVx0ltBhJl2QTS96izvA.png" /><figcaption>Integrate TailScale with NextCloudPI</figcaption></figure><p>Once it is setup you can access Admin console for Tailscale and check the IP assigned to NextCloudPI. Tailscale is available for Android too so try that out at your leisure.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cWsNqgClTNoh1AfWVrqKew.png" /><figcaption>Connected to Tailscale</figcaption></figure><p>We will need this IP and edit NextCloudPI so that we can connect via VPN. We can do the changes easily through SSH.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/737/1*dp0e7JdiZVRdGyyJCopJuQ.png" /><figcaption>Edit config.php</figcaption></figure><p>Just add a simple line ‘2 =&gt; IP’ and mention the IP</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/349/1*tckFXEFigkDPBqf3ywUcrQ.png" /><figcaption>Listen via VPN</figcaption></figure><p>Once we have that done, we’re ready to access NextCloudPI via VPN</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*C44AYq_5JsUQdfw01vfE2Q.png" /><figcaption>Access Private Cloud via VPN</figcaption></figure><p>Lastly just for better user experience we can install NextCloud app via Android Store/ IOS store and mention the URL to connect via App.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/948/1*lY75xAEQWVrgyi2vTr6PRQ.png" /><figcaption>Android App store</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-nE3ZcKe63QU69itobSDwQ.png" /><figcaption>IOS Store</figcaption></figure><p>Accessing it via browser and IP is very troublesome, so we will now install a app which will be easy to use. Mention VPN or private IP (since we have setup VPN, it will be accessible on both IP’s) then mention credentials (which can be the temporary ones or change is on management console at nc-passwd).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-kvTSSw5AwH7fMV2eeGQ8g.jpeg" /><figcaption>Android App access</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*YVQDErj-lP45h3DCywawMg.jpeg" /><figcaption>Mention the URL for NextCloudPI</figcaption></figure><p>Then we can access the Private Cloud via App.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/743/1*gcZlgAXiS55rS0LIqE8WEQ.jpeg" /><figcaption>App access</figcaption></figure><p>That’s all for now, Let me know if you need assistance at any stage.</p><p>Finally you can store all kinds of Data like Videos, Images, Contacts,Passwords etc and it’ll physically be stored in your own Home.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*tetwV8dPyTkn7FOfkp-HMw.png" /><figcaption>NextCloudPI capabilities</figcaption></figure><p>Integrations and Apps extend this capabilities to Twitter, News, Dropbox etc.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/446/1*lZOlil_Z-2r-QUGpwKuhrA.png" /><figcaption>Integrations and Apps</figcaption></figure><p>Enjoy your own Cloud.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=fefc88a5d4fe" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[A Monitoring Journey]]></title>
            <link>https://medium.com/@Darkhue/a-monitoring-journey-e757e1a44cb4?source=rss-3dfbbd830ee5------2</link>
            <guid isPermaLink="false">https://medium.com/p/e757e1a44cb4</guid>
            <category><![CDATA[zeek]]></category>
            <category><![CDATA[suricata]]></category>
            <category><![CDATA[siem]]></category>
            <category><![CDATA[soc]]></category>
            <category><![CDATA[security]]></category>
            <dc:creator><![CDATA[Dhiraj Ambigapathi]]></dc:creator>
            <pubDate>Sun, 23 Oct 2022 07:37:35 GMT</pubDate>
            <atom:updated>2022-10-23T07:37:35.784Z</atom:updated>
            <content:encoded><![CDATA[<p>We’re surrounded by all sorts of Network. Wired and Wireless, no matter what you want to do in Cyber Security you’ve to use network in one or other way. So Monitoring Network is very important for Blue Team to keep up with upcoming Threats and Red Team to learn how can you be stealthy.</p><p>So I decided to build a Network security monitoring framework, but only with Open source solutions out there. The result of this looks like</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*knhWVsiaQO3IP4n9NehY9Q.png" /><figcaption>Infrastructure</figcaption></figure><p><strong>Explanation</strong></p><p>So we can either capture Network Traffic in real time or replay a already captured Network packets file also called PCAP or PCAP-NG. This will be sent across to Suricata which is our IDS and Zeek which is our NSM. Suricata will detect malicious activity based on suricata rules and Zeek will give us a in-depth look into Packet for Threat Hunting . But we need to visualize this, so we will feed results into Elastic for storage and Kibana will retrieve and visualize the results.</p><p>Visit GitHub <a href="https://github.com/xoep/NSM/blob/Configurations/README.md">repo</a> for entire setup walkthrough -</p><p><strong>Setting up Network Capture</strong></p><p>For Network capture you can use tools like tcpdump. For replaying packets you can use tools like tcpreplay.</p><p>There’re recent really good samples at <a href="https://www.malware-traffic-analysis.net/">here</a></p><p>Lastly you can just run Framework directly on a real time network, just make sure it has some sort of Malicious traffic in order for detection to work.</p><p><strong>Suricata</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*A1b2BKKESI5mKCyK0-oeuQ.jpeg" /><figcaption>Suricata is Looking at your Network —<a href="https://unsplash.com/photos/x3-OP_X0aH0?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditShareLink"> Artist</a></figcaption></figure><p>Suricata is a Open-Source Intrusion Detection System, with additional capability to analyze PCAP. Suricata rules for detection can be updated from numerous resources, both Open-source and Commercial. This makes Suricata a important component for our Framework. Suricata creates eve.json which includes Alerts, Anomalies, File information etc all can be used for Threat Hunting.</p><p><strong>Zeek</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/210/0*stzWZfMUFZk5gHtp" /><figcaption>Zeek for the Geek— <a href="https://docs.zeek.org/en/master/about.html">Zeek about</a></figcaption></figure><p>Zeek is a Open-Source Network Security Monitoring tool. Zeek gives a in-depth analysis to perform a Packet level analysis. Zeek creates different types of logs for all the protocols. For Anomalies, Zeek creates weird.log. Zeek is a crucial component of out framework for Deep Packet Inspection, which is essential for Threat Hunting.</p><p><strong>ELASTIC SUITE</strong></p><p>Elastic suite is a bunch of tools that help to Aggregate, Correlate and Visualize data. We will use these to visualize our results from Zeek and Suricata.</p><p>Initially we need to get the data collected from Zeek and Suricata logs and Aggregated at Elastic, our Database. For this we will use Filebeat. Filebeat utility ships logs to Elastic and also supports modules which will come in handy while creating a Dashboard.</p><p>Next component is the Brain itself, aka Elasticsearch. Elasticsearch is a Open-source search engine for all sorts of structured and unstructured data. We will run Elasticsearch on localhost, for security reasons and configure Filebeat to send data to it.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/673/1*XiAYiyw495PQAAV3trgRJQ.png" /><figcaption>Elasticsearch is running on localhost</figcaption></figure><p>Lastly we have Kibana. Kibana is again a Open-source tool that provides a Web console and interacts with indexed data in Elastic to provides search and data visualization. In short Kibana is our access portal for all the data we’ve been collecting till now. Kibana will be configured to localhost, due to security reasons and Nginx reverse proxy will be setup to access Kibana. Filebeat also will be configured to access Kibana to add Dashboards.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Tfjn2Z9gr4e-h6Ba8KyBng.png" /><figcaption>Kibana Dashboards</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XZ0R7RdxWdQrhkyR_6wbuA.png" /><figcaption>Geo-location on Dashboard</figcaption></figure><p>We have different dashboards created by Filebeat, but also the capability to customize our own</p><p><strong>The Results</strong></p><p>Once Everything is setup properly, troubleshooted for bugs and interface issues, we can start our Analysis. I will be using samples from <a href="https://www.malware-traffic-analysis.net/">here</a>. And you can see the results.</p><p><strong>The Future</strong></p><p>I plan to expand the project in near future, let me know what additions would you like to see.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e757e1a44cb4" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[A Plan for OSCP]]></title>
            <link>https://medium.com/@Darkhue/a-plan-for-oscp-9b6030e365f5?source=rss-3dfbbd830ee5------2</link>
            <guid isPermaLink="false">https://medium.com/p/9b6030e365f5</guid>
            <category><![CDATA[training]]></category>
            <category><![CDATA[red-team]]></category>
            <category><![CDATA[offensive-security]]></category>
            <category><![CDATA[oscp]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <dc:creator><![CDATA[Dhiraj Ambigapathi]]></dc:creator>
            <pubDate>Mon, 27 Jun 2022 04:07:29 GMT</pubDate>
            <atom:updated>2022-06-27T04:07:29.963Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/300/0*yUx5pN8KhfzbhrDo" /></figure><p>Hey, everyone welcome to my OSCP journey.</p><p>I got my OSCP recently and I really enjoyed the Journey, and would like to share my plan going into the Exam.</p><figure><img alt="OSCP certificate" src="https://cdn-images-1.medium.com/max/1024/1*5auHuG_EEi7l-YOxPVL7Dg.jpeg" /></figure><p><strong>The Preparation</strong></p><p>Before even enrolling into OSCP, I planned to complete Learning paths on Tryhackme for a good foundation. This will help you a lot as when you buy OSCP bundle you’ve limited time and want to make sure you get the best out of it.</p><p>Practicing your basics also helps in troubleshooting problems you will face during Lab as well as Exam. Get good in command line interface for Linux as well as Windows.</p><p>Tryhackme provides a month access to all rooms and learning path for $10, which I find better in comparison to other competitors and content available.</p><p>This is sequence of Learning Paths I followed</p><p>(I)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/359/1*w20z9bATrFLTjl9hp5UwrA.png" /><figcaption>Pre-Security Introduces and revises basic security concepts.</figcaption></figure><p>(II)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/358/1*NalFMf50a4rQ3-6hh64oqQ.png" /><figcaption>Complete Beginner is similar to Pre-Security, just few additional rooms to practice</figcaption></figure><p>(III)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/357/1*6PnBa6EH2_8ZIOpSj8YRlQ.png" /><figcaption>Introduction and Revising Web concepts</figcaption></figure><p>(IV)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/360/1*Crk7qNGAol3TdN4UN74NGw.png" /><figcaption>Junior-Penetration Tester provides a good insight into Exploitation and Methodology</figcaption></figure><p>(V)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/360/1*GlFl1DqV9R78IZo5ynHy0A.png" /><figcaption>Here’s where you will find Intermediate Machines</figcaption></figure><p>(VI)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/359/1*I2-oxkx41UCOLarBURYneQ.png" /><figcaption>Not Mandatory room, but revises some core concepts</figcaption></figure><p>You can check my tryhackme certs <a href="http://9b7607df-4463-48a8-96db-901d029abbbf/">here</a></p><p>(VII)</p><p>I also completed TCM security course. TCM security has a 12 hours course on Ethical hacking <a href="https://www.youtube.com/watch?v=fNzpcB7ODxQ">here</a></p><p>Next I highly suggest completing <a href="https://docs.google.com/spreadsheets/u/1/d/1dwSMIAPIam0PuRBkCiDI88pU3yzrqqHkDtBngUHNCw8/htmlview">TJ Nulls list</a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*t4nxRaJLKTKW-J4K-NHZuA.png" /><figcaption>HacktheBox</figcaption></figure><p>I started with <a href="https://app.hackthebox.com/login">HacktheBox</a> subscription ($10 for a month) and followed TJ Nulls list.</p><p>Highly suggest Ippsec’s youtube video list of OSCP machines <a href="https://youtube.com/playlist?list=PLidcsTyj9JXK-fnabFLVEvHinQ14Jy5tf">here</a></p><p>Other reference for HacktheBox Machines</p><p><a href="https://0xdf.gitlab.io/">0xdf</a></p><p><a href="https://ippsec.rocks/">ippsec</a></p><p>I bought a 30 day OSCP lab access after completing HacktheBox.</p><p>During OSCP Lab period, I managed to complete 58 Machines, unlocking 2 Networks. Do make sure to complete the Active Directory Machines in OSCP labs and make Report document for it while solving (as a proper complete report is worth 10 points).</p><p>I felt OSCP Labs are comparatively easier than the Exam.</p><p>So next I solved Proving Grounds Machines from TJ Nulls List.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*bvB5VotyiyCHP9Ih0klvRw.png" /></figure><p><a href="https://portal.offensive-security.com/sign-up/pg">Proving Grounds</a> are costlier than Hackthebox or Tryhackme ($20 for a month) but provides Machines very similar to Exam ones. So be completely prepared before subscribing to Proving Grounds Practice. I managed to solve 34 Machines in Proving grounds following TJ Nulls List.</p><p>Active Directory</p><p>TCM security provides a beginner level course for Active directory <a href="https://academy.tcm-sec.com/p/practical-ethical-hacking-the-complete-course">here</a></p><p>Apart from Learning path rooms, here are my suggestions for Active Directory on Tryhackme</p><p><a href="https://tryhackme.com/room/vulnnetactive">VulnNet-Active</a></p><p><a href="https://tryhackme.com/room/raz0rblack">Raz0rBlack</a></p><p><a href="https://tryhackme.com/room/enterprise">Enterprise</a></p><p>Buffer-OverFlow Labs</p><p>Buffer OverFlow is not mandatory as per the OSCP format now, but It very much will be the easiest machine in Exam. Buffer OverFlow is very much dependent on your muscle memory, so practice is the key to understand flow and how to troubleshoot issues.</p><p>Tryhackme has some very good rooms to practice Buffer-OverFlow</p><p><a href="https://tryhackme.com/room/bufferoverflowprep">Buffer-OverFlow Lab</a></p><p><a href="https://tryhackme.com/room/brainpan">Brainpan</a></p><p><a href="https://github.com/stephenbradshaw/vulnserver">VulnServer</a></p><p>Additional Platforms to practice</p><p><a href="https://www.cyberseclabs.co.uk/">Cyberseclabs</a></p><p><a href="https://academy.hackthebox.com/">HacktheBox-Academy</a></p><p><a href="https://www.virtualhackinglabs.com/">Virtual Hacking Labs</a></p><p><a href="https://portswigger.net/web-security">PortSwigger Academy</a></p><p>The Routine</p><p>I had a 9–6 job, so allotted morning 6–9 and evening 6–11 slots for practicing labs. Sticking to a schedule is the key to completing labs in limited time and building up the muscle memory to identify and exploit machines on a regular basis.</p><p>Remember OSCP is a 24 hour exam, so you need to be able to root machines in a limited time. I had set goals to complete Easy machines in 1–2 hours, Intermediate machines within 3–4 hours and Hard machines within 8 hours.</p><p>I wasn’t able to do that initially but eventually was able to meet those constraints. The key for this is to make your own notes. It’s ok to refer walkthroughs, but remember to solve machine and make detailed notes out of them.</p><p>The Multitasking</p><p>During OSCP you’ve multiple Machines to exploit in a limited time, so you’ve to multitask. For this I got used to TMUX, refer <a href="https://tryhackme.com/room/rptmux">Tryhackme</a></p><p>Performing Reconnaissance on multiple machines parallelly is a important objective, I prefer <a href="https://github.com/Tib3rius/AutoRecon">autorecon</a> from TiB3rius. Autorecon is a good tool, but it provides lot of information so do understand its capabilities, switches and commands. Its always better to understand manual Reconnaissance before using Automated tools.</p><p>Take your Breaks</p><p>Its a 23 hour 45 min Exam, so take breaks periodically. I prefer to take breaks after I completely solve a Machine and acquire required Proof-of-concepts for reports or 15 min break every 2 hours.</p><p>During Breaks do anything that releases stress, I prefer to take short naps with alarm. Its also important to be energetic so I did take couple Red bulls during the exam, to be awake. Lastly remember to be hydrated.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9b6030e365f5" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>