Mac OS Sierra and srm

6

0

I had a script for securely emptying my trash bin from time to time and I was using srm. I suppose people would still have uses for srm. However, it appears that srm no longer ships with mac os. Are you aware of a candidate alternative to srm? Any word by anyone at all?

P.S. For example, here is random example where srm is used for securely emptying the trash bin. Notice that the example is for El Capitan, so srm disappeared in mac os Sierra (or at least, this appears to be the case).

MightyMouse

Posted 2016-09-22T06:56:20.607

Reputation: 183

1The reason it was removed is that it's not secure. Why not use erase free space instead, or use FileVault? – Tetsujin – 2016-09-22T07:35:41.993

2

The Mac Security Blog you mentioned says, "When OS X saves a copy of a file, it doesn't write that file to the same part of the disk. In layman's terms, what this means is that while you may be able to securely delete a file or folder, you cannot be certain that other copies of that file are not recoverable. As such, securely emptying the Trash is not reliable. While many Mac users miss this option, Apple felt it's better to be safe and not offer it if the feature isn't 100% reliable." See CVE-2015-5901.

– creidhne – 2016-09-22T07:53:31.347

Answers

12

You can use rm -P

     -P          Overwrite regular files before deleting them.  Files are overwritten three times, first with the byte pattern 0xff, then 0x00, and then 0xff again, before they are deleted.

Matteo

Posted 2016-09-22T06:56:20.607

Reputation: 6 553

0

  1. Install MacPorts and ...
  2. Find ports: srm
  3. Terminal: sudo port install srm

Z-N

Posted 2016-09-22T06:56:20.607

Reputation: 11

0

Apple removed srm because they felt it didn't work well enough and because using it on a SSD decreases the overall life of the drive. If you really want to use it you can download the source, unzip it, and then compile it yourself.

$ ./configure
$ make
$ make install

Patrick Mullins

Posted 2016-09-22T06:56:20.607

Reputation: 17

Have you got any sources backing up these claims why Apple removed srm? – idmean – 2017-02-16T12:43:58.353

@idmean "With an SSD drive, Secure Erase and Erasing Free Space are not available in Disk Utility. These options are not needed for an SSD drive because a standard erase makes it difficult to recover data from an SSD." https://support.apple.com/en-us/HT201949

– Molomby – 2017-05-14T05:08:22.250

This no longer works; the srm formulae has been removed. There's a 3rd party tap for it here; install with brew install khell/homebrew-srm/srm then srm secrets.txt, etc. Better to not though.. see this related question.

– Molomby – 2017-05-14T05:14:56.487

Removed the section on installing from Homebrew. – Patrick Mullins – 2018-02-01T16:15:43.123