<?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 Mohammed Shyoukh on Medium]]></title>
        <description><![CDATA[Stories by Mohammed Shyoukh on Medium]]></description>
        <link>https://medium.com/@iVaR01?source=rss-c489a7f263f8------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*2co6lWgSMQxpO9btYDvA4g.jpeg</url>
            <title>Stories by Mohammed Shyoukh on Medium</title>
            <link>https://medium.com/@iVaR01?source=rss-c489a7f263f8------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 28 Nov 2026 17:27:31 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@iVaR01/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[JUST CTF Local DFIR — Writeup]]></title>
            <link>https://medium.com/@iVaR01/just-ctf-local-dfir-writeup-ec7184e150a0?source=rss-c489a7f263f8------2</link>
            <guid isPermaLink="false">https://medium.com/p/ec7184e150a0</guid>
            <category><![CDATA[play]]></category>
            <category><![CDATA[medium]]></category>
            <category><![CDATA[ctf]]></category>
            <category><![CDATA[forensics]]></category>
            <category><![CDATA[ctf-writeup]]></category>
            <dc:creator><![CDATA[Mohammed Shyoukh]]></dc:creator>
            <pubDate>Thu, 26 Dec 2024 20:14:53 GMT</pubDate>
            <atom:updated>2024-12-26T20:31:16.080Z</atom:updated>
            <content:encoded><![CDATA[<h3>JUST CTF Local DFIR — Writeup</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eKSPjZs8Hye__9i8XBxLOw.png" /></figure><h3>The Silent Intruder — Medium</h3><p>Description:</p><blockquote>A system has been compromised by an unknown attacker. Analyze the memory dump to uncover the traces of the intruder.</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/625/1*QQDsMut0VeCnjn6Vflxddg.png" /></figure><p>We have a file called memdump.zip containing a memory dump file for analysis. Let’s first connect to the Netcat server.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*msgbge12zTmc7Sa-LwurZg.png" /></figure><p>Q1 — What is the volatility memory profile of the system?</p><p>In the beginning, we should extract our zip file and use volatility2.6 to analyze then we should use this command to get the profile of the system:</p><pre>python2 vol.py -f path/to/memfile imageinfo</pre><p>This command yields the following result:</p><blockquote>Volatility Foundation Volatility Framework 2.6.1 INFO : volatility.debug : Determining profile based on KDBG search… Suggested Profile(s) : Win10x64_19041 AS Layer1 : SkipDuplicatesAMD64PagedMemory (Kernel AS) AS Layer2 : FileAddressSpace (/home/kali/Desktop/memdump.raw) PAE type : No PAE DTB : 0x1aa002L KDBG : 0xf80379e00b20L Number of Processors : 2 Image Type (Service Pack) : 0 KPCR for CPU 0 : 0xfffff80376626000L KPCR for CPU 1 : 0xffff99812afa7000L KUSER_SHARED_DATA : 0xfffff78000000000L Image date and time : 2024–12–24 10:24:10 UTC+0000 Image local date and time : 2024–12–24 02:24:10 -0800</blockquote><p>Based on the output, the system profile is “Win10x64_19041”</p><blockquote>Answer: Win10x64_19041</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/734/1*c-baFJiaor2j6_rQEq1pTg.png" /></figure><p>Q2 — when was the memory dump captured? YYYY-MM-DD HH:MM:SS</p><p>From the output above, we can see the image date and time</p><blockquote>Answer: 2024–12–24 10:24:10</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Izu82IAxh4BD0OEu5Scvpw.png" /></figure><p>Q3 — What is the name and PID of the process the attacker used to perform malicious activities? filename.ext_XXXX</p><p>To answer this question, we can use several volatility plugins including pslist, pstree, and cmdline.</p><p>I will use cmdline for this one.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/966/1*FIEsk2deF4m5A0goB_VbVA.png" /></figure><p>We can see that rundll32.exe is used to execute functions from DLL files</p><blockquote>Answer: rundll32.exe_6428</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/834/1*jWKpFFc6hYvBY58VW6-kUQ.png" /></figure><p>Q4 — What is the name and PID of the spawned process? filename.ext_XXXX</p><p>To find the spawned process we should look for rundll32.exe, and we can use the following command:</p><pre>python2 vol.py -f memdump.raw —profile=Win10x64_19041 pstree</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/702/1*2IMyYt4V5P_Frp_9pENWkA.png" /></figure><p>we can see cmd.exe is a sub-process from rundll32.exe so it is the answer</p><blockquote>Answer: cmd.exe_6540</blockquote><p>Q5 — What is the full path of the executable file used by the attacker to establish a reverse shell? C:\path\to\file\Filename.ext</p><p>for this question we should look for the DLL list to find the path we can do that using this command:</p><pre>python2 vol.py -f ../memdump.raw --profile=Win10x64_19041 dlllist --pid 6428</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*UJiABcsZiE2KJdK9x5V4sg.png" /></figure><p>Looking through the DLL list, we can identify the key file: simple.dll</p><blockquote>Answer: C:\Windows\System32\simple.dll</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/728/1*UhfBGMvUKdnrPJyaPrAPJQ.png" /></figure><p>Q6 — What is the attacker’s IP address and port number? IP: PORT</p><p>There are two ways to solve this challenge, but let’s take the more complex approach by first dumping the simple.dll file using this command.</p><pre>python2 vol.py -f ../memdump.raw --profile=Win10x64_19041 dlldump  --pid=6428 -D ../testfile --base=0x00007ffc98760000 </pre><p>We can get the base address for the DLL from the previous dlllist command using the rundll32.exe PID.</p><p>Next, we’ll analyze the file using Ghidra to examine its contents.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*T44QPEk36RXXZ2McbjbYFA.png" /></figure><p>In the symbol tree, we can see several functions. Let’s examine the function called “VerifyThemeVersion”.</p><p>Click on the function thunk_FUN_7ffc98771760() and double-click to open it.</p><p>Inside this function, you will find the IP address and port number.</p><blockquote>Answer:192.168.220.166:4441</blockquote><p>Alternatively, we can find the IP: PORT more easily by analyzing the file with Volatility 3 using this command:</p><pre>python3 vol.py -f ../memdump.raw windows.netstat </pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0gjPoZd5K8kyLDOBMeq5PQ.png" /></figure><p>Q7 — Can you identify the registry path of the persistence technique used by the attacker and the command line used to run the DLL file? HIVENAME\\\\_Commandline</p><p>To find the registry path used for persistence, we can use the following command:</p><pre>python3 vol.py -f ../memdump.raw windows.registry.printkey --key &quot;Microsoft\Windows\CurrentVersion\Run&quot;</pre><p>After running this command, we can identify the relevant registry hive</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Krk-4amkbpkmSYCZ2h1axA.png" /></figure><p>Now we have found the full registry path, but we only need the portion starting from the hive name. The first part is:</p><p>SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run</p><p>Now let’s find the second part of the answer: the command line.</p><p>To find the command line portion, we can use a simple command that will reveal the answer:</p><pre>python2 vol.py -f ../memdump.raw --profile=Win10x64_19041 cmdline | grep rundll32.exe</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/965/1*A8AuD7aSpht6qDp2NiU0Yg.png" /></figure><p>we have the second part of the answer now which is: rundll32.exe simple.dll,VerifyThemeVersion</p><blockquote>Answer: SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run_rundll32.exe simple.dll,VerifyThemeVersion</blockquote><p>Q8 — What is the function name in the DLL containing the reverse shell payload?</p><p>he asks for the function name that we revealed earlier using ghidra which is:</p><blockquote>Answer: VerifyThemeVersion</blockquote><p>special thanks to mrfa3i for this challenge ❤</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ec7184e150a0" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[CyGenixCTF — Unmask]]></title>
            <link>https://medium.com/@iVaR01/cygenixctf-unmask-6332c4dd17d5?source=rss-c489a7f263f8------2</link>
            <guid isPermaLink="false">https://medium.com/p/6332c4dd17d5</guid>
            <category><![CDATA[digital-forensics]]></category>
            <category><![CDATA[ctf-writeup]]></category>
            <category><![CDATA[steganography]]></category>
            <category><![CDATA[ctf]]></category>
            <category><![CDATA[forensics]]></category>
            <dc:creator><![CDATA[Mohammed Shyoukh]]></dc:creator>
            <pubDate>Sun, 25 Aug 2024 15:16:35 GMT</pubDate>
            <atom:updated>2024-12-28T19:22:20.820Z</atom:updated>
            <content:encoded><![CDATA[<h3>CyGenixCTF — Unmask</h3><h4>Description :</h4><blockquote>A crucial file has been tampered with in a way in order to conceal its true contents. Your mission is to unmask the data and retrieve the hidden information. Lets find out your worth and if you have what it takes to uncover and extract the forensic evidence. And if you do, I assure you, the return will be rewarding. All the best Agent!</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/375/1*zL6u9hHawO6UD5nSuE9mTA.png" /></figure><p>This is a digital forensics challenge for this challenge we have a file called Challenge.dat</p><p>in this file, we have a hex string that looks like an encoded string if we try to decode we will not have anything</p><p>but if we looked at the first line: 52 44 48 49 0d 00 00 00 0a 1a 0a 0d 47 4e 50 89</p><p>it looks like a PNG header but reversed and if we tried to decode these values we would have the PNG header like this :<br>“””</p><p>RDHI<br>GNP<br>“””</p><p>To solve this problem we will have to reverse these hex numbers to get the image and for that</p><p>we will have to write a simple Python code to do this process for us like this :</p><pre>def rev(file):<br>    with open(file, &#39;r&#39;) as file:<br>        for line in file:<br>            line = line.strip()<br>            hex_bytes = line.split()<br>            revb = hex_bytes[::-1]<br>            reversed = &#39; &#39;.join(revb)<br>            print(reversed)<br>file = &#39;challenge.dat&#39;<br>rev(file) </pre><p>this script will reverse the bytes as we want it to be :<br><strong> 89 50 4e 47 0d 0a 1a 0a 00 00 00 0d 49 48 44 52</strong></p><p>the real PNG header now we can take all hex values then we will use <strong>CyberChef</strong> to decode from hex</p><p>after that, we will get the decoded image</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Vl53510hZlhnYEom0IlBzg.png" /></figure><p>and we found the flag</p><p>flag<strong>: CyGenixCTF{Th3_jUmbl3D_uP_PNG_3b9cd0e17f}</strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6332c4dd17d5" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[KnightCTF — API Key]]></title>
            <link>https://medium.com/@iVaR01/knightctf-api-key-bebb4e11fecf?source=rss-c489a7f263f8------2</link>
            <guid isPermaLink="false">https://medium.com/p/bebb4e11fecf</guid>
            <category><![CDATA[ctf-writeup]]></category>
            <category><![CDATA[forensics]]></category>
            <category><![CDATA[networking]]></category>
            <category><![CDATA[writeup]]></category>
            <category><![CDATA[ctf]]></category>
            <dc:creator><![CDATA[Mohammed Shyoukh]]></dc:creator>
            <pubDate>Mon, 22 Jan 2024 11:45:25 GMT</pubDate>
            <atom:updated>2024-01-22T11:45:25.590Z</atom:updated>
            <content:encoded><![CDATA[<h3>KnightCTF — API Key</h3><p>this a writeup for API Key — KnightCTF Category — Network</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4-L3wZ0B9JNdc0I1u-DUYw.png" /></figure><p>so first of all, I downloaded the attached file at the first challenge and started to analyze the packets to find anything about the API Key and I found this</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vAFoAayqDR2JBttCv2HFNA.png" /></figure><p>app.zip file so I decided to export it to see what is this file</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*b6LB2HwvDEzTtk5SVbwBiQ.png" /></figure><p>after unzipping the file I found a file called models</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8k31LP7rysCehoGQpyqW8A.png" /></figure><p>there is a PHP file called db — database so look into it</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*I1dwjQ--v-JusUf2x7vovg.png" /></figure><p>and I found the API Key .</p><p>flag is : KCTF{6eea9135–2801–4560-b44c-f297b5f46f2f}</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=bebb4e11fecf" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>