Date: Fri, 30 Aug 2002 17:30:14 +0200 From: Thomas Spreng <spreng@insomniac.ch> To: Oscar Ricardo Silva <oscars@mail.utexas.edu> Cc: freebsd-questions@freebsd.org Subject: Re: secure transfer without shell? Message-ID: <20020830173014.A50458@rock.stable.ch> In-Reply-To: <5.1.0.14.2.20020830100300.026c4610@mail.utexas.edu>; from oscars@mail.utexas.edu on Fri, Aug 30, 2002 at 10:04:45AM -0500 References: <5.1.0.14.2.20020830100300.026c4610@mail.utexas.edu>
next in thread | previous in thread | raw e-mail | index | archive | help
> Is there a way to allow people to use scp or sftp to copy files to a > machine but not giving them a shell? > > Any information would be appreciated. > > > > Thanks, > > Oscar Hello Oscar, this is one thing i wanted to do as well and i just have figured a way to do so. It seems that the shell opened on a sftp or scp connect doesn't read the user's startup script for login shells (.profile for Bourne shells like bash). So if you put an exit into that script, login shells will be immediatly closed while other shells like the one from the scp or sftp session remain. Of course you have to chown/chmod that login script so that it cant be modified by the user. I'm not sure how safe this is but it could be an easy way to solve that problem. Bye, Thomas To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020830173014.A50458>