In restricted aegir shell (user o1.ftp) there is an issue while parsing commandline (alias expansion?).
It's enough to have "drush" written anywhere in the string to get an error.
The shell give the alert as if we tried to invoke drush from an invalid path...

o1.ftp:~$ vi nonsensedrushnonsense.txt

 This drush command can not be run in /home/o1.ftp
 Please cd to the valid sites/foo.com directory first
 or use a valid @alias, for example: drush @foo.com status
 Hint: Use 'drush aliases' command to see all available aliases

Comments

omega8cc’s picture

Status: Active » Closed (works as designed)

You should not use "drush" keyword in the path or site names.

netdreamer’s picture

Ok... but what if i need to edit a text file where drush is just a simple part of the name?!?
I was trying to fix a module (module.drush.inc) with a simple "vi nameofthemodule.drush.inc" and it was forbidden.
Then i tried something stupid: in my home directory, i worte a textfile called blabladrushblabla.txt and it was also forbidden... it's a bit too much aggressive, I think!

omega8cc’s picture

Yeah, the problem is that it is hard to avoid this without opening security holes in current hardened setup.

omega8cc’s picture

Version: 6.x-2.0-rc22 » 6.x-2.x-dev
Status: Closed (works as designed) » Needs work

Actually, we should fix this, I think.

~Grace

  • Commit fdd5540 on master by omega8cc:
    Issue #2238805 by netdream - Command line filtering in lshell too much...
omega8cc’s picture

Component: Code » Other Services
Status: Needs work » Fixed

  • Commit fdd5540 on master, 6.x-2.x by omega8cc:
    Issue #2238805 by netdream - Command line filtering in lshell too much...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.