Post a reply

Before posting, please read how to report bug or request support effectively.

Bug reports without an attached log file are usually useless.

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

berthierp

Re: setgid bit always unset when changing file permissions

martin wrote:

berthierp wrote:

I believe our server supports that bit very well, because we use that feature for years now (running Suse enterprise / openSuse).

I believe your server OS does, but your SFTP server does not.


Yes you are right, we were using a openssh 4.6 server, which is know to have this Bug ( https://bugzilla.mindrot.org/show_bug.cgi?id=1310 ). Using another openssh version 5.2 fixes the problem (apparently it has been fixed in 5.1).

Thanks for the help!
martin

Re: setgid bit always unset when changing file permissions

berthierp wrote:

I believe our server supports that bit very well, because we use that feature for years now (running Suse enterprise / openSuse).

I believe your server OS does, but your SFTP server does not.

Apparently does not ignore the request because the bit gets unset every time that I change any other permissions using WinSCP. If the bit was set, it gets unset, and if the bit was not set, no change. My thought was that WinSCP would force the bit to unset every time.

It does not.
berthierp

Re: setgid bit always unset when changing file permissions

martin wrote:

It is possible that your SFTP server does not support the setgit bit and silently ignores the request to set it.


I believe our server supports that bit very well, because we use that feature for years now (running Suse enterprise / openSuse).

Apparently does not ignore the request because the bit gets unset every time that I change any other permissions using WinSCP. If the bit was set, it gets unset, and if the bit was not set, no change. My thought was that WinSCP would force the bit to unset every time.
martin

Re: setgid bit always unset when changing file permissions

It is possible that your SFTP server does not support the setgit bit and silently ignores the request to set it.
berthierp

setgid bit always unset when changing file permissions

My Setup:
WinSCP 4.2.7 build 758 Running on Windows XP SP3.
SFTP session.

I am using directories with setgid bit set. I want to change the permissions of newly created directories to give write permission to the group (by default they have not). For this I right-click on the directory and change the permissions from the Properties dialog.

When I change the permissions of a directory that way, the setgid bit gets removed. In fact, there is no way to set the setgid bit, it just always gets turned off, whatever operation one does on permissions.

I have found a workaround by creating a custom command that executes chmod -R g+w "!" and applies on directories. This works fine.