Re: set umask for sftp connection
From: Pat Buerki (bpm13_at_gmx.net)
Date: 05/27/04
- Previous message: Darren Tucker: "Re: sshd pam_setcred problem"
- In reply to: Pat Buerki: "set umask for sftp connection"
- Next in thread: Darren Tucker: "Re: set umask for sftp connection"
- Reply: Darren Tucker: "Re: set umask for sftp connection"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: 27 May 2004 02:39:15 -0700
bpm13@gmx.net (Pat Buerki) wrote in message news:<5e909902.0405250654.4fb8711@posting.google.com>...
> However, when copying files, these have a
> permission of 644, which imho is not set by the unix system.
ssh takes the umask of the parent sshd process, which would normally
be inherited from init, unless restarted by hand.
So probably since sshd runs as root it's taking the default umask from
root, and not the user in the session.
> Therefore, it must be the sftp program, which sets this mask. Although
> there should be a possibility to change file permissions in WSFtp
> (according to the manual), this doesn't work. I neither don't want to
> change permissions of all my files after uploading; this would be to
> much useless work.
Some clients give the option to set default permissions for uploads,
or to preserve permissions for uploaded files from the client; most of
them don't.
> Question: Is there a possibility to override the umask of WSFtp by the
> solaris system? Maybe in ssh or sftp config file? If this is possible,
> how exactly is it done?
> I have scrutinized all manuals of WSftp pro (they don't seem to be
> satisfying) and also the Google Groups. None of the hints I got are
> working.
As stated above, the client takes the umask from the ssh daemon. So
just insert the command 'umask 002' (or the desired umaks value) into
start_service() routine in /etc/init.d/opensshd
At least this works. However, I'm not sure if this solution has any
severe disadvantages. If you know more, please let me know.
- Previous message: Darren Tucker: "Re: sshd pam_setcred problem"
- In reply to: Pat Buerki: "set umask for sftp connection"
- Next in thread: Darren Tucker: "Re: set umask for sftp connection"
- Reply: Darren Tucker: "Re: set umask for sftp connection"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|
|