The original usage case was to allow re-writing a CD/DVD-RW media. For an already written (non-blank) DVD-RW disc, there's all-or-none solution from pcmanfm currently: when the disc is inserted it gets mounted automatically, and there's only "eject" button, no way to umount but keep it inserted in order to re-write it.
I found a way around it by running my burning app from a separate text console so that pcmanfm does not have permissions from consolekit to mount the drive.
This very problem can be attacked from a different angle. I know growisofs tries to umount the device it is writing to if it's mounted - growisofs calls umount, but it does not work (it needs to connect to udisks instead of umounting directly). So the other solution is to teach either growisofs (and cdrecord/wodim) or umount to call udiskd (using dbus) to umount things as user.
But one - admittedly very rare - use case for such a feature - exists still. If we've a cd-rom with unknown, possible malicious content and want to inspect it (by a userspace app running in a sandbox) before actually mounting, since it may exploit kernel bugs by especially crafted filesystem for example. So we should have a way to bypass mounting still. I'm not sure it is at all possible currently - for example,. some udev/udisks util still tries to parse the filesystem. It's at least not the kernel, and the amount of parsing it does is minimal) so it's much better anyway.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I feel a little clarification is required. I was speaking of disabling the automount temporarily without having to go to the prefs.
The original usage case was to allow re-writing a CD/DVD-RW media. For an already written (non-blank) DVD-RW disc, there's all-or-none solution from pcmanfm currently: when the disc is inserted it gets mounted automatically, and there's only "eject" button, no way to umount but keep it inserted in order to re-write it.
I found a way around it by running my burning app from a separate text console so that pcmanfm does not have permissions from consolekit to mount the drive.
This very problem can be attacked from a different angle. I know growisofs tries to umount the device it is writing to if it's mounted - growisofs calls umount, but it does not work (it needs to connect to udisks instead of umounting directly). So the other solution is to teach either growisofs (and cdrecord/wodim) or umount to call udiskd (using dbus) to umount things as user.
But one - admittedly very rare - use case for such a feature - exists still. If we've a cd-rom with unknown, possible malicious content and want to inspect it (by a userspace app running in a sandbox) before actually mounting, since it may exploit kernel bugs by especially crafted filesystem for example. So we should have a way to bypass mounting still. I'm not sure it is at all possible currently - for example,. some udev/udisks util still tries to parse the filesystem. It's at least not the kernel, and the amount of parsing it does is minimal) so it's much better anyway.
It's implemented as an option to unmount volume without ejecting it.