Much as described in this blog post by Jeff Robbins, I have a situation where two sftp users in the same group are both uploading files to an Ubuntu 10.04 server using Dreamweaver. The issue is that by default the permissions are 755, so even though both users are in the same group, only the file owner has write permissions. Since the users need to be able to overwrite each other’s files I needed a way to have the default permissions be 775.
Subsystem sftp /usr/lib/openssh/sftp-server -u 0002
Subsystem sftp /bin/sh -c ‘umask 0002; /usr/lib/openssh/sftp-server’