!C99Shell v. 2.5 [PHP 8 Update] [24.05.2025]!

Software: Apache/2.4.41 (Ubuntu). PHP/8.0.30 

uname -a: Linux apirnd 5.4.0-204-generic #224-Ubuntu SMP Thu Dec 5 13:38:28 UTC 2024 x86_64 

uid=33(www-data) gid=33(www-data) groups=33(www-data) 

Safe-mode: OFF (not secure)

/var/www/html/proxy_server/node_modules/redis-info/   drwxr-xr-x
Free 13.15 GB of 57.97 GB (22.69%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     index.js (2.44 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
'use strict';
var _ = require('lodash');

module.exports = {
  parse: function (info) {
    return parseFields(splitStr(info));
  }
};


function startWith(pattern) {
  return function (value) {
    return value.indexOf(pattern) === 0;
  };
}


function split(s) {
  return function (v) {
    return v.split(s);
  };
}

function orEmptyStr(v) {
  return v || '';
}


function takeN(func, n) {
  return function (v) {
    return func(v[n]);
  };
}

function takeFirst(func) {
  return takeN(func, 0);
}

/**
 * Split the info string by \n and :
 * @param  {String} str the returned redis info
 * @return {Array}     Array of [key, value]
 */
function splitStr(str) {
  return str.split('\n')
    .filter(function (line) {
      return line.length > 0 && line.indexOf('#') !== 0;
    })
    .map(function (line) {
      return line.trim().split(':');
    });
}

function parseDatabases(info) {
  return info
    .filter(takeFirst(startWith('db')))
    .map(function _parseDatabaseInfo(args) {
      var dbName = args[0];
      var value = args[1];
      var values = orEmptyStr(value).split(',');

      function extract(param) {
        return parseInt(orEmptyStr(_.find(values, startWith(param))).split('=')[1] || 0, 10);
      }

      return {
        index: parseInt(dbName.substr(2), 10),
        keys: extract('keys'),
        expires: extract('expires')
      };
    })
    .reduce(function (m, v) {
      m[v.index] = {
        keys: v.keys,
        expires: v.expires
      };
      return m;
    }, {});
}

function parseCommands(info) {
  return _.fromPairs(info.filter(function (a) {
      return orEmptyStr(a[0]).indexOf('cmdstat_') === 0;
    })
    .map(function _parseCommands(args) {
      var v = args[0];
      var a = args[1];
      var val = _.fromPairs(orEmptyStr(a).split(',').map(split('=')));
      if (_.has(val, 'calls')) {
        val.calls = parseInt(val.calls, 10);
      }
      if (_.has(val, 'usec')) {
        val.usec = parseInt(val.usec, 10);
      }
      if (_.has(val, 'usec_per_call')) {
        val.usec_per_call = parseFloat(val.usec_per_call, 10);
      }
      return [orEmptyStr(v).split('_')[1], val];
    }));
}

function parseFields(info) {
  var fields = info.reduce(function (m, v) {
    if (!v[0].trim() || v[0].indexOf('db') === 0 ||  v[0].indexOf('cmdstat_') === 0) {
      return m;
    }
    m[v[0]] = v.slice(1).join(':');
    return m;
  }, {
    databases: parseDatabases(info),
    commands: parseCommands(info)
  });

  return fields;
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0073 ]--