A restrictive shell is a shell thathas been modified to allow you to do fewer things than a normal shell wouldallow you to do. It may allow you to run only certain programs. It may stop youfrom changing directories. Many sites run their own restrictive shells to allowlimited use of their systems over the Internet. Restrictive shells often makeuse of the restricted shell (rsh).
On poorly implemented restrictedshells you can break out of the restricted environment by running a programthat features a shell function.
A good example is vi.
Run vi and use thiscommand:
:set shell=/bin/sh
then shell using this command:
:shell
Many menu based restricted shellswill allow you to configure your user environment, or to run programs thatallow you to configure your user environment. Look for configuration optionsthat refer to executable programs.
If the program lets you define an editor,for example, try to set your editor to "/bin/csh -i -f"
If you are not allowed to readfiles, try to open them inside the e-mail program.
If you are not allowed to editfiles, try to save that to file from the e-mail program.
If your restricted shell preventsyou from using the "cd" command, try to FTP into your account andchange directories. FTP can aso be used to edit files by getting the file,editing it offline, and utting the net file back online.
Like most hacking, trying things isoften the most successful strategy.
Thanks...
0 comments:
Post a Comment