Is there any way to lock a file/folder of being deleted?

Please check the FAQ (https://www.xyplorer.com/faq.php) before posting a question...
Post Reply
cadu
Posts: 287
Joined: 18 Mar 2012 21:50

Is there any way to lock a file/folder of being deleted?

Post by cadu »

Hi,

I am dealing with some containers created by "truecrypt" and I am afraid they could be deleted casually, more than I was concerned when dealing just with simple files!

Is there any way to lock any type of file or folder of being deleted?

Thanks in advance!

Filehero
Posts: 2734
Joined: 27 Feb 2012 18:50
Location: Windows 11@100%

Re: Is there any way to lock a file/folder of being deleted?

Post by Filehero »

cadu wrote:Is there any way to lock any type of file or folder of being deleted?
Well, first of all assure you'll have proper backups any time!

Secondly, I would look at the NTFS attributes. Offhanded I'm not aware of a specific one serving your needs, but maybe making the file/folder hidden is a good way to start?


Cheers,
Filehero

admin
Site Admin
Posts: 67269
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Is there any way to lock a file/folder of being deleted?

Post by admin »

Generally I like the idea of supporting a blacklist of items that are protected from moving/copying/renaming/deleting/being overwritten. It could be part of Admin Settings (admin.ini). And it could be total protection or an inserted extra prompt (probably even with a password for extra security).

Marco
Posts: 2354
Joined: 27 Jun 2011 15:20

Re: Is there any way to lock a file/folder of being deleted?

Post by Marco »

Filehero wrote:Well, first of all assure you'll have proper backups any time!

Secondly, I would look at the NTFS attributes. Offhanded I'm not aware of a specific one serving your needs, but maybe making the file/folder hidden is a good way to start?


Cheers,
Filehero
Totally with Filehero.
In my specific case, the contents of my TC container is mirrored onto another TC container on another drive, and I'm planning to buy a third drive, just in case (beware, for security purposes you must not mirror the container itself, instead creating a new one and then mirroring the contents).
Then everything inside the container can be modified only by an administrator. I am a regular user with read permissions only, so whenever I try to do something I receive an access denied message.

Let me know if this answers the original question.
Tag Backup - SimpleUpdater - XYplorer Messenger - The Unofficial XYplorer Archive - Everything in XYplorer
Don sees all [cit. from viewtopic.php?p=124094#p124094]

Filehero
Posts: 2734
Joined: 27 Feb 2012 18:50
Location: Windows 11@100%

Re: Is there any way to lock a file/folder of being deleted?

Post by Filehero »

admin wrote:Generally I like the idea of supporting a blacklist of items that are protected from moving/copying/renaming/deleting/being overwritten.
Me too.

However, I'm afraid that the scope XY alone isn't suited to avoid accidental deletion of mission-critical items (e.g. it can happen from any file open/save dialogue, the shell etc.). It will surely add up to better overall safety, but one should be aware of the limits.


Cheers,
Filehero

eil
Posts: 1923
Joined: 13 Jan 2011 19:44

Re: Is there any way to lock a file/folder of being deleted?

Post by eil »

admin wrote:a blacklist of items that are protected from moving/copying/renaming/deleting/being overwritten. It could be part of Admin Settings (admin.ini).
i like this idea. :)
Win 7 SP1 x64 100% 1366x768|1900x1080

admin
Site Admin
Posts: 67269
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Is there any way to lock a file/folder of being deleted?

Post by admin »

Filehero wrote:
admin wrote:Generally I like the idea of supporting a blacklist of items that are protected from moving/copying/renaming/deleting/being overwritten.
Me too.

However, I'm afraid that the scope XY alone isn't suited to avoid accidental deletion of mission-critical items (e.g. it can happen from any file open/save dialogue, the shell etc.). It will surely add up to better overall safety, but one should be aware of the limits.
True, that makes it less appealing. "95% safety" sounds scaring.

cadu
Posts: 287
Joined: 18 Mar 2012 21:50

Re: Is there any way to lock a file/folder of being deleted?

Post by cadu »

Hi, thanks everybody for information!

Actually, I was (and I am) afraid of putting main part of my data into a container, and just by "del" key it be deleted. Even a child by chance could make it unintentionally.

a) If I understood your comments, the only way available for now (without much effort) is make attribute file (a) ready-only + hidden. Isn't it?

b) The suggested "blacklist of items that are protected from moving/copying/renaming/deleting/being overwritten" is just a idea, isn't it? I couldn't find path to "admin.ini"...

c) Sorry by asking things about truecrypt in XY forum, but I really have trust in XY users sharp software skills=> I create a large container hosted in C:, which opens by "Truecrypt" after login automatically. I put all my data there, including Outlook and other database files, that are accessed from apps installed outside container. Because the files are inside container, do you think it could bring some problem of accessing or performance? Or the usage should be seamless, without problem?

d) All software installation will be outside the container. No need of encryption all my operational system in my option. I think to software performance issues, it would be better to have the operational system / and software installation out of encryption. What do you think?

Ps.: here I found some useful tips to truecrypt at http://www.ghacks.net/2010/09/27/essent ... rypt-tips/

Bye!

PeterH
Posts: 2830
Joined: 21 Nov 2005 20:39
Location: DE W11Pro 24H2, 1920*1200*100% 3840*2160*150%

Re: Is there any way to lock a file/folder of being deleted?

Post by PeterH »

My thought about your usage scenario:

As long as a container is mounted, it's contents is unsecured, i.e. every program (be it malicious, or be it a user error) may read and write data. And your container is mounted as long as the PC is active...

For your idea of an "all-data" container I'd think about not using a big file, but a complete (additional) HD partition. One advantage: to delete it (by accident or however) someone has to delete the complete partition, not just a file. This is the same as for a normal data partition.

cadu
Posts: 287
Joined: 18 Mar 2012 21:50

Re: Is there any way to lock a file/folder of being deleted?

Post by cadu »

Thanks for the tip of creating a HD partion.
Do you recommend any tool to that?

PeterH
Posts: 2830
Joined: 21 Nov 2005 20:39
Location: DE W11Pro 24H2, 1920*1200*100% 3840*2160*150%

Re: Is there any way to lock a file/folder of being deleted?

Post by PeterH »

cadu wrote:Thanks for the tip of creating a HD partion.
Do you recommend any tool to that?
I think it's a bit a matter of personal taste.
And a matter of what you must do :shock:
for example: shrink one partition to make place for a new one.

Long ago I used Norton ghost: liked it much - but it costs...
...last times I used "GParted live" - that's free. (And can be booted an run from USB stick.)

Always think: partitioning is a risk for your data.
Though the only time I've lost data on partitioning was my own silly fault :oops:

eil
Posts: 1923
Joined: 13 Jan 2011 19:44

Re: Is there any way to lock a file/folder of being deleted?

Post by eil »

i'd advice to use EASEUS Partition Manager- it works right from Win, free, quite easy to work with. only be sure to deframent partition you're going to shrink, so that all available data be placed on start.

btw, i want to ask about True Crypt too =is there no option to make container read-only?(i didn't use it, but willing to try)
Win 7 SP1 x64 100% 1366x768|1900x1080

Marco
Posts: 2354
Joined: 27 Jun 2011 15:20

Re: Is there any way to lock a file/folder of being deleted?

Post by Marco »

eil wrote:btw, i want to ask about True Crypt too =is there no option to make container read-only?(i didn't use it, but willing to try)
Yes, there is such an option. Just look at the mount options.
Tag Backup - SimpleUpdater - XYplorer Messenger - The Unofficial XYplorer Archive - Everything in XYplorer
Don sees all [cit. from viewtopic.php?p=124094#p124094]

admin
Site Admin
Posts: 67269
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Is there any way to lock a file/folder of being deleted?

Post by admin »

admin wrote:Generally I like the idea of supporting a blacklist of items that are protected from moving/copying/renaming/deleting/being overwritten. It could be part of Admin Settings (admin.ini). And it could be total protection or an inserted extra prompt (probably even with a password for extra security).
Actually it already exists (at least for folders)! Check Help for Admin Settings / DisallowedDirs...

Post Reply