taskManeage - Tasks: task #15997, safe-rm - a safe front end to rm...


You are not allowed to post comments on this tracker with your current authentication level.

task #15997: safe-rm - a safe front end to rm using perl

Submitter:  Boud Roukema <boud>
Submitted:  Fri 25 Jun 2021 08:40:14 PM UTC
Should Start On:  Fri 25 Jun 2021 12:00:00 AM UTC Should be Finished on:  Fri 25 Jun 2021 12:00:00 AM UTC
Category:  Analysis Priority:  5 - Normal
Status:  None Privacy:  Public
Assigned to:  None Percent Complete:  0%
Open/Closed:  Open Effort:  0.00

Fri 25 Jun 2021 10:55:05 PM UTC, comment #2: 

We can set this as an optional package in 'high-level.mk' so if a user wants they can activate it. Perl is installed within 'basic.mk', so it will be easy to add as a high-level package.

Mohammad Akhlaghi <makhlaghi>
Group administrator
Fri 25 Jun 2021 08:42:23 PM UTC, comment #1: 

I'm setting this to the 'analysis' category, because I tend to think that users are more likely to do risky 'rm' commands in the analysis side of Maneage than in software . Though I could be wrong...

Boud Roukema <boud>
Group Member
Fri 25 Jun 2021 08:40:14 PM UTC, original submission:  

The program safe-rm [1] is a perl script which acts as a front end to rm to reduce the chance of catastrophic results of using recursive, forced remove commands. This could provide an alternative to set -u (see task 15996 [2]) for this purpose.

The disadvantage is that this depends on perl, adding in an extra dependence. Installing as a step after the installation of perl might be reasonable.

Another disadvantage is that users of the safe-rm package might not realise that the rm command has been symlinked to the safe-rm front-end script, and may not learn the danger of true rm.

In version 0.12-2+deb9u1, the script itself is only 228 lines, so should not be too difficult to check. The script checks a default list of directories which safe-rm will refuse to recursively delete, such as /, /home, /bin, /boot, /usr/bin. For root-protected directories, this is (in principle) irrelevant for Maneage. However, /home is relevant.

I think that this is worth considering, but more arguments and for and against are needed.

[1] https://tracker.debian.org/pkg/safe-rm
[2] https://savannah.nongnu.org/task/index.php?15996

Boud Roukema <boud>
Group Member


(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -email is unavailable- added by makhlaghi (Posted a comment)
  • -email is unavailable- added by boud (Submitted the item)

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.


    Follows 1 latest change.

    Date Changed by Updated Field Previous Value => Replaced by
    2021-06-25 boud CategoryNone Analysis

    Back to the top

    Powered by Savane 3.13-7c56.
    Corresponding source code