USB SD card write-protect tab

I want to use an SD card for keeping some secure binary files (like aide, chkrootkit, etc) since it has a write-protect tab on it. I thought this would be less wasteful than using CDs for files that may change (like the aide.db) but write protection is important since I didn’t want a hacker to be able to modify them. (its a web server and I am paranoid :slight_smile:

However I seem to be able to write even when I move the tab to “protect”. I thought this was a hardware protection so i was very surprised when i still had R+W access. Any suggestions?

Thanks!

I don’t know why this would be. You can check how the OS sees the write protect status by inserting it, then have a look at kernel message output:

dmesg|tail

You would normally expect a line like:

sd 2:0:0:0: [sdb] Write Protect is on

Not sure what answer will be though. I would have thought this will come down to the device itself. The OS just acts on the data its given.

Similar thread here.

You’ve got me intrigued now… :slight_smile:

Your post spurred me on to some new testing and I think I made a NOOB mistake.

I thought my SD was showing up under /mnt/usbkey since it was a USB device. But actually it is showing up under /media/disk/. As an aside /mnt/usbkey actually is on my primary HD…

The write protect tab seems to work correctly - thanks (and sorry).

No worries. Mystery sorted. :slight_smile: