Re: Distinguishing ssh-logins from sftp-logins



"MO" == mog128 <mattes.opel@xxxxxx> writes:

MO> Hey, thank you both for your interesst.

MO> I've tried using /bin/false or /dev/null as shell for non-ssh
MO> users, but experienced that the sftp-server did not execute
MO> correctly.

That's because sshd uses the remote account's shell to run any programs on
the user's behalf ($SHELL -c ...).

--
Richard Silverman
res@xxxxxxxx

.



Relevant Pages

  • Re: Redirection issue
    ... 1- execute input commands from standard input, ... the phrase "it does not work anymore" carries very little meaning. ... after compilation and execution of the shell with a simple command like ...
    (comp.lang.c)
  • vulnerabilities in scponly
    ... without allowing shell access. ... scponly makes no effort to verify the path to the scp or sftp-server ... arbitrary commands by simply uploading a file. ... However, if this is *NOT* the case, the user could execute arbitrary ...
    (Bugtraq)
  • RE: Shell Shoveling?!?
    ... Subject: Shell Shoveling?!? ... you need to somehow execute code on the box. ... > 2) wouldn't there be a requirement to escalate privileges in order ... > to run NetCat on the compromised host? ...
    (Pen-Test)
  • Re: Redirection issue
    ... 1- execute input commands from standard input, ... "does not work" could be anything from not compiling, not executing, ... after compilation and execution of the shell with a simple command like ...
    (comp.lang.c)
  • Re: Script Header
    ... > On a shell script, ... > You can TRY to execute a garbage file. ... > filename: Exec format error. ... - The shell will check whether this file has the executable flag set, ...
    (comp.unix.shell)