?TC 8.51rc1 NTFS Permissions when moving files
Moderators: Hacker, petermad, Stefan2, white
- ghisler(Author)
- Site Admin
- Posts: 50541
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
This is controlled by XPMoveMethod= option. From the help:
1: When moving files within a drive, the permissions of the target folder are used
2: As 1, but when moving folders, all files and subfolders in them are changed to the target permissions too
0: The permissions of the files are kept
Default: XP:1, other systems: 0
1: When moving files within a drive, the permissions of the target folder are used
2: As 1, but when moving folders, all files and subfolders in them are changed to the target permissions too
0: The permissions of the files are kept
Default: XP:1, other systems: 0
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
- ghisler(Author)
- Site Admin
- Posts: 50541
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
So where is the problem?
Moving a file is just moving a pointer in the file system, which also moves all the permissions (which are just in the metadata of the file).
Moving a file is just moving a pointer in the file system, which also moves all the permissions (which are just in the metadata of the file).
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
Permissions may be own and inherited, and own ones are kept in file metadata while inherited ones come from parent folder (but there is a flag to disable inheritance).
Actually I've tried to move file between two folders with different permissions, and TC really keeps file permissions on move with 'copy permissions' option, it copies permissions that I set for file, it even copies inherited permissions that are missed in target folder. E.g. I've set 'deny write for administrators' for file and 'deny write for local_service' for folder - and TC have copied both! Tested with non-elevated TC 8.51RC1x32 with default value of XPMoveMethod (it is not set). While moving via tcmadmin, permissions were not kept, however after adding XPMoveMethodAdmin=0 all work fine, move keeps inheritance and additional permissions, just like in case of copy.
BTW default value for XPMoveMethod is not specified in help. And I don't understand why default values for XPMoveMethod and XPMoveMethodAdmin are different.
Actually I've tried to move file between two folders with different permissions, and TC really keeps file permissions on move with 'copy permissions' option, it copies permissions that I set for file, it even copies inherited permissions that are missed in target folder. E.g. I've set 'deny write for administrators' for file and 'deny write for local_service' for folder - and TC have copied both! Tested with non-elevated TC 8.51RC1x32 with default value of XPMoveMethod (it is not set). While moving via tcmadmin, permissions were not kept, however after adding XPMoveMethodAdmin=0 all work fine, move keeps inheritance and additional permissions, just like in case of copy.

BTW default value for XPMoveMethod is not specified in help. And I don't understand why default values for XPMoveMethod and XPMoveMethodAdmin are different.
- ghisler(Author)
- Site Admin
- Posts: 50541
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
It's not specified on the left because it's system-dependent. That's described on the right side.BTW default value for XPMoveMethod is not specified in help.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
- ghisler(Author)
- Site Admin
- Posts: 50541
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
It's XP or newer - the help entry was created when XP was the latest Windows version.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
- ghisler(Author)
- Site Admin
- Posts: 50541
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
I cannot reproduce this, I do not get a folder with a padlock.
When you set XPMoveMethod=0, TC will just move the folder without trying to change any permissions. When you set XPMoveMethod=1, TC will change the permissions to inherit from parent, like the Explorer does it.
When you set XPMoveMethod=0, TC will just move the folder without trying to change any permissions. When you set XPMoveMethod=1, TC will change the permissions to inherit from parent, like the Explorer does it.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
- ghisler(Author)
- Site Admin
- Posts: 50541
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Can you give me more information, please? What are the permissions of:
1. The source file
2. The target directory
3. The file after COPYING it to the target (please give it a different name so you can still do step 4)
4. The file after MOVING it to the target with "Copy NTFS..." NOT checked?
1. The source file
2. The target directory
3. The file after COPYING it to the target (please give it a different name so you can still do step 4)
4. The file after MOVING it to the target with "Copy NTFS..." NOT checked?
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com