<berenger.morel <at> neutralite.org> writes:

> 
> If a partition is mounted as read-only, I think no software will be 
> able to write on it, because the kernel is responsible of what will 
> happen. Low level open&close functions just call kernel's API, so if the 
> kernel refuse writings, I can not see a solution to write.
> But I am not a kernel expert, I always prefer the standard C/C++ 
> functions instead of OS's dependent low-level feature.
> 

Hello,

Yes the above would work in most cases but in the case I am dealing
with, the filesystem is not mounted yet. For example, I plug in a USB
drive.  Before it is mounted, there is a /dev/sd[x] node. I can open
this node and write anything I want, thereby corrupting the filesystem
on that device.

Thanks,
Amit


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/loom.20121126t224347-...@post.gmane.org

Reply via email to