GNOME Bugzilla – Bug 346676
SFTP UID/GID shouldn't be authoritative
Last modified: 2006-12-29 01:16:10 UTC
Some time ago, I was able to modify the permissions of files on my university's home directory using "nautilus sftp://user@server/home/user".Then, during 2.13.x this broke and said something along the lins of "cannot get file permissions". Now I tested again with latest 2.15.x from CVS and while it shows owner and group ids now, as well as the permissions, i cannot change them. On the bottom, it says "You are not the owner, so you cannot change the permissions." But, i *am* the owner and I can edit permissions using chmod just fine when I log in with ssh. Also, I can open text files in gedit from the nautilus sftp window in read/write mode. Something is broken here...
I can confirm this bug. Nautilus should compare the UID/GID on files on remote filesystems with the UID/GID obtained when logging in (if the authentication subsystem supports it). If it's unsure it should not restrict the user from atleast trying I think ;)
Well.. do you think this works if local user == remote user? I havn't tested this yet.
(In reply to comment #2) > Well.. do you think this works if local user == remote user? I havn't tested > this yet. > Yes, if the remote UID is the same as the local user it works fine.
Thanks for your bug report! This is a GnomeVFS issue, which treats remote UID/GID info like local IDs. We just shouldn't set them, which pretends that you're allowed to chmod all files, at least until we parse SSH_FILEXFER_ATTR_OWNERGROUP specified in recent sftp drafts.
Created attachment 68836 [details] [review] Proposed patch Also submitted to the gnome-vfs mailing list for review.
Semi-fixed... I can change permissions now, but owner and group still say "unknown". I guess this should also be displayed correctly?
Btw there's also "SELinux context" and "last changed". At least the latter should also be displayed. I'm not sure if this is releated but I have another problem: Clicking on a text file for example gives me "Couldn't display [...]". Naturally, If I drag the file to gedit, it will open just fine. Locally, gedit opens text files just fine... but in the nautilus properties, the type filed on the first tab also says "unknown". I guess mime types are not detected over sftp... should I file another bug about this?
*** Bug 350038 has been marked as a duplicate of this bug. ***
*ping* What is holding this back? This really should have gone into 2.16 release because it is a very bad regression compared to the previous release where it worked...
Committed, closing. It will be included in GNOME 2.18.