Ticket #3009 (new defect) — at Initial Version

Opened 12 years ago

Last modified 6 years ago

mc don't respect SGID bit while copying

Reported by: slavazanko Owned by:
Priority: major Milestone: Future Releases
Component: mc-vfs Version: master
Keywords: Cc:
Blocked By: Blocking:
Branch state: no branch Votes for changeset:

Description

Originally posted at: http://translate.google.com/translate?sl=ru&tl=en&js=n&prev=_t&hl=ru&ie=UTF-8&eotf=1&u=http%3A%2F%2Fwww.linux.org.ru%2Fforum%2Fmidnight%2F9181654%3Flastmod%3D1369124726869

Steps to reproduce:
1) As root, run:

  • mkdir test
  • chown :apache test
  • chmod g+=rwxs test

2) As root, run mc;
3) try to copy any file/dir to the /tmp/test directory, swotch off the 'Preserve attributes' option on the copy dialog;

  • for example, try to copy /etc/cron.d

4) type:

  • ls -la /tmp/test

Actual result:

# ls -la /tmp/test
total 48
drwxrwsr-x.  3 root apache  4096 May 21 14:06 .
drwxrwxrwt. 26 root root   36864 May 21 14:01 ..
drwxr-xr-x.  2 root root    4096 Jan 18 16:31 cron.d

Expected result:

# ls -la /tmp/test
total 48
drwxrwsr-x.  3 root apache  4096 May 21 14:06 .
drwxrwxrwt. 26 root root   36864 May 21 14:01 ..
drwxr-sr-x.  2 root apache  4096 Jan 18 16:31 cron.d
Note: See TracTickets for help on using tickets.