Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- include('http://apocalypsecheats.xyz/client3/login/db.php');
- $action = $_GET['action'];
- $username = $con->real_escape_string($_GET['username']);
- $password = $con->real_escape_string(md5($_GET['password']));
- define("CHUNK_SIZE", 1024*1024); // Size (in bytes) of tiles chunk
- // Read a file and display its content chunk by chunk
- function readfile_chunked($filename, $retbytes = TRUE) {
- $buffer = "";
- $cnt =0;
- // $handle = fopen($filename, "rb");
- $handle = fopen($filename, "rb");
- if ($handle === false) {
- return false;
- }
- while (!feof($handle)) {
- $buffer = fread($handle, CHUNK_SIZE);
- echo $buffer;
- ob_flush();
- flush();
- if ($retbytes) {
- $cnt += strlen($buffer);
- }
- }
- $status = fclose($handle);
- if ($retbytes && $status) {
- return $cnt; // return num. bytes delivered like readfile() does.
- }
- return $status;
- }
- if(!$action)
- {
- echo "Acces denied.";
- }
- else
- {
- else if($action == "login6")
- {
- $query = $con->query("SELECT * FROM users WHERE username = '$username' and password = '$password'");
- $cnt = $query->num_rows;
- if($cnt > 0)
- {
- $logged_in = 1;
- }
- else
- {
- $logged_in = 0;
- }
- }
- if ($logged_in) {
- $filename = "http://archive.apocalypsecheats.xyz/xdddddd/nice_bro";
- $mimetype = "mime/type";
- header("Content-Type: ".$mimetype );
- readfile_chunked($filename);
- }
- else {
- echo "Acces denied.";
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement