--Yep, that's pretty much the situation in a nutshell.

--BTW, "pwd" is the current working directory. If you issue:
' pwd ' in bash, it will tell you where you are. Same as:
' echo $PWD ' == Which is the environment variable.

--If you have "pwd" (actually :$PWD in your $PATH, it tells bash to look in your current directory for executable files... NOT something you want to do as Root, for the aforementioned reasons. Hard-core *nix purists don't have a $PATH *at all* in root; they issue ' /sbin/ifconfig ' and stuff like that so it ALWAYS gets executed from the right directory. (' man whereis ')

[quote="Flibble"]
Quote Originally Posted by Hermanh
thanks, the script is running.
Code:
./filename
did do it. I did not expect that because it runned as knoppix using just
Code:
filename
Knoppix user must have pwd in the PATH. Its a really bad idea to do this with root accounts though from a security perspective. I have managed to elevate privilege on a number of *nix boxes (whilst doing authorised pen tests I hasten to add) through this technique. Root has pwd in his path and /tmp is world writable. Stick a script called ls in there and then give him cause to go looking in tmp (fill up disk by stuffing directory full of crap). Poor sap follows standard sysadmin technique and navigates into the directory and runs ls [-alSr] which runs the dropped in script. This usually does something like echo a standard add user line into the /etc/password file and then run the real ls command.