PHP Shell 2.1 review

Download
by rbytes.net on

PHP Shell is a shell wrapped in a PHP script

License: GPL (GNU General Public License)
File size: 19K
Developer: Martin Geisler
0 stars award from rbytes.net

PHP Shell is a shell wrapped in a PHP script. PHP Shell is a tool you can use to execute arbitrary shell-commands or browse the filesystem on your remote webserver. This replaces, to a degree, a normal telnet-connection.

You can use it for transferring your site as a compressed file, and then unpack it on the webserver, administration and maintenance of your website using commands like ps, free, du, df etc…

If PHP is running in Safe Mode, then you cannot use PHP Shell — sorry. Safe Mode restricts the commands that can be executed using the proc_open() call in PHP, and it also restricts the files and directories that can be accessed using other calls in PHP.

The effect is, that PHP Shell simply doesn’t work — you cannot change directory and you cannot execute any commands.

Safe Mode is often used on servers that host several websites for different users to limit the users ability to peek at each others files.

Limitations:
There are some limitations on what kind of programs you can run. It won’t do no good if you start something like Netscape or even vi. All programs have to be strictly command-line programs, and they will have no chance of getting user input after they have been launched. They probably also have to terminate within 30 seconds, as this is the default time-limit imposed unto all PHP scripts, to prevent them from running in an infinite loop. Your ISP may have set this time-limit to something else.

But you can rely on all the normal shell-functionality, like pipes, output and input redirection, etc… (There is no < tab >-completion, though)

Using

Like any other shell. When you point your browser at PHP Shell and types in your password (see the file INSTALL for more information on how to change the password), you’ll be presented with a rather simple page containing nothing much except a big window with the cursor blinking at the bottom, signaling that it’s ready to obey your commands.

Write a command and press , or alternatively — is you insist — press the “Execute Command” button. The command will be executed and the result will be shows in the terminal. You can now enter another command.

To be more precise: the terminal is updated with the command line you have just executed, the output of the command to standard out (stdout) and following that any error output sent to stderr.

The commands are executed relative to a current working directory, which is written at the top. You change this by the normal cd command.

What's New in This Release:
Authentication is now handled internally in PHP in an attempt to solve reported login problems.
Configuration settings were moved to an ini file, and handling of PHP Safe Mode was improved with better error messages.

PHP Shell 2.1 search tags