[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Emergency Unmount...
Hi guys. In the kernel module I'm writing, I must unmount all the devices
before call the panic() function when an illegal root tryies to rmmod my
module. I'm dealing with security questions such as bof preventions, and I
don't want that someone gaining root privileges ( e.g. with a compromise )
could remove my module without entering a password in a char device.
The password locking is already done, but I want to halt the machine if the
password mismatched and the illegal root call "rmmod".
So my question is: how can I walk throught the mounted block devices in order
to unmount them fairly? I've alredy called sys_sync() to sync all the disks.
Another question: Why the sys_reboot system called doesn't work if I choose
LINUX_REBOOT_CMD_HALT as command?
Thnx a lot, and happy coding... :)
--
$>cd /pub
$>more beer
(0>
//\ Perego Paolo <sponge@tiscalinet.it> Tutor at D.S.I. University of Milan
V_/_ 'The future will not remember, the past doesn't forget.'
I'm Linux zion 2.4.2 #12 mar feb 27 11:10:40 CET 2001 i586
PGP signature