403Webshell
Server IP : 127.0.0.1  /  Your IP : 192.168.99.1
Web Server : Apache/2.4.35 (Win64) OpenSSL/1.1.1b mod_fcgid/2.3.9
System : Windows NT WIN-JEJMB9EN0L0 10.0 build 14393 (Windows Server 2016) AMD64
User : Administrator ( 0)
PHP Version : 7.4.33
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  D:/laragon3/etc/apps/phpRedisAdmin/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : D:/laragon3/etc/apps/phpRedisAdmin/delete.php
<?php


if (!isset($_POST['post'])) {
  die('Javascript needs to be enabled for you to delete keys.');
}


require_once 'includes/common.inc.php';


if (isset($_GET['key'])) {
  // String
  if (!isset($_GET['type']) || ($_GET['type'] == 'string')) {
    // Delete the whole key.
    $redis->del($_GET['key']);
  }

  // Hash
  else if (($_GET['type'] == 'hash') && isset($_GET['hkey'])) {
    // Delete only the field in the hash.
    $redis->hDel($_GET['key'], $_GET['hkey']);
  }

  // List
  else if (($_GET['type'] == 'list') && isset($_GET['index'])) {
    // Lists don't have simple delete operations.
    // You can only remove something based on a value so we set the value at the index to some random value we hope doesn't occur elsewhere in the list.
    $value = str_rand(69);

    // This code assumes $value is not present in the list. To make sure of this we would need to check the whole list and place a Watch on it to make sure the list isn't modified in between.
    $redis->lSet($_GET['key'], $_GET['index'], $value);
    $redis->lRem($_GET['key'], 1, $value);
  }

  // Set
  else if (($_GET['type'] == 'set') && isset($_GET['value'])) {
    // Removing members from a set can only be done by supplying the member.
    $redis->sRem($_GET['key'], $_GET['value']);
  }

  // ZSet
  else if (($_GET['type'] == 'zset') && isset($_GET['value'])) {
    // Removing members from a zset can only be done by supplying the value.
    $redis->zRem($_GET['key'], $_GET['value']);
  }


  die('?view&s='.$server['id'].'&key='.urlencode($_GET['key']));
}


if (isset($_GET['tree'])) {
  $keys = $redis->keys($_GET['tree'].'*');

  foreach ($keys as $key) {
    $redis->del($key);
  }

  die('?&s='.$server['id']);
}

?>

Youez - 2016 - github.com/yon3zu
LinuXploit