!C99Shell v. 2.0 [PHP 7 Update] [25.02.2019]!

Software: Apache. PHP/7.3.33 

uname -a: Linux acloudg.aryanict.com 4.18.0-513.9.1.lve.el8.x86_64 #1 SMP Mon Dec 4 15:01:22 UTC
2023 x86_64
 

uid=1095(katebhospital) gid=1098(katebhospital) groups=1098(katebhospital) 

Safe-mode: OFF (not secure)

/lib/node_modules/npm/node_modules/readdir-scoped-modules/   drwxr-xr-x
Free 292.94 GB of 429.69 GB (68.17%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     readdir.js (2.95 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
var fs = require ('graceful-fs')
var dz = require ('dezalgo')
var once = require ('once')
var path = require ('path')
var debug = require ('debuglog') ('rds')

module . exports = readdir
readdir.sync = readdirSync

function readdir (dir, cb) {
  fs . readdir (dir, function (er, kids) {
    if (er)
      return cb (er)

    debug ('dir=%j, kids=%j', dir, kids)
    readScopes (dir, kids, function (er, data) {
      if (er)
        return cb (er)

      // Sort for bonus consistency points
      data = data . sort (function (a, b) {
        return a > b ? 1 : -1
      })

      return cb (null, data)
    })
  })
}

function readdirSync (dir) {
  var kids = fs . readdirSync (dir)
  debug ('dir=%j, kids=%j', dir, kids)
  var data =  readScopesSync (dir, kids)
  // Sort for bonus consistency points
  data = data . sort (function (a, b) {
    return a > b ? 1 : -1
  })

  return data
}

// Turn [ 'a', '@scope' ] into
// ['a', '@scope/foo', '@scope/bar']
function readScopes (root, kids, cb) {
  var scopes = kids . filter (function (kid) {
    return kid . charAt (0) === '@'
  })

  kids = kids . filter (function (kid) {
    return kid . charAt (0) !== '@'
  })

  debug ('scopes=%j', scopes)

  if (scopes . length === 0)
    dz (cb) (null, kids) // prevent maybe-sync zalgo release

  cb = once (cb)
  var l = scopes . length
  scopes . forEach (function (scope) {
    var scopedir = path . resolve (root, scope)
    debug ('root=%j scope=%j scopedir=%j', root, scope, scopedir)
    fs . readdir (scopedir, then . bind (null, scope))
  })

  function then (scope, er, scopekids) {
    if (er)
      return cb (er)

    // XXX: Not sure how old this node bug is. Maybe superstition?
    scopekids = scopekids . filter (function (scopekid) {
      return !(scopekid === '.' || scopekid === '..' || !scopekid)
    })

    kids . push . apply (kids, scopekids . map (function (scopekid) {
      return scope + '/' + scopekid
    }))

    debug ('scope=%j scopekids=%j kids=%j', scope, scopekids, kids)

    if (--l === 0)
      cb (null, kids)
  }
}

function readScopesSync (root, kids) {
  var scopes = kids . filter (function (kid) {
    return kid . charAt (0) === '@'
  })

  kids = kids . filter (function (kid) {
    return kid . charAt (0) !== '@'
  })

  debug ('scopes=%j', scopes)

  if (scopes . length === 0)
    return kids

  var l = scopes . length
  scopes . forEach (function (scope) {
    var scopedir = path . resolve (root, scope)
    debug ('root=%j scope=%j scopedir=%j', root, scope, scopedir)
    then (scope, fs . readdirSync (scopedir))
  })

  function then (scope, scopekids) {
    // XXX: Not sure how old this node bug is. Maybe superstition?
    scopekids = scopekids . filter (function (scopekid) {
      return !(scopekid === '.' || scopekid === '..' || !scopekid)
    })

    kids . push . apply (kids, scopekids . map (function (scopekid) {
      return scope + '/' + scopekid
    }))

    debug ('scope=%j scopekids=%j kids=%j', scope, scopekids, kids)
  }

  return kids
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

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

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

--[ c99shell v. 2.0 [PHP 7 Update] [25.02.2019] maintained by KaizenLouie | C99Shell Github | Generation time: 0.0958 ]--