|
From: Hans B. <han...@gm...> - 2013-12-11 13:53:29
|
On Wed, Dec 11, 2013 at 1:56 PM, Miklos Szeredi <mi...@sz...> wrote: > On Thu, Nov 28, 2013 at 9:56 PM, Arthur van Dongen > <sou...@av...> wrote: >> Hello all, >> >> In the Unanswered Questions section in the Wiki there is the question to >> pass fuse helper script options from fstab. I think I've found a way to >> implement this, without breaking existing configurations. >> >> My configuration, which triggered me to solve this, is to automount an >> encrypted directory using fuse.encfs. The password for the encrypted >> volume can be supplied by an executable which is indicated by the >> --extpass option to fuse.encfs. (That the password is stored on this >> system is not an issue, the encrypted directory is to be protected when >> stored off-site) >> >> The current mount.fuse usage says: >> mount.fuse source destination -t type [-o opt[,opt...]] >> Every option given is added to the -o opt,opts list passed to the >> mount.type command. >> >> I modified the mount.fuse source code so the options provided can be >> treated in two ways. Options without starting dash are added to the >> comma-separated options list as normal. Options with a starting dash are >> added to the command line as separate command line parameters. >> >> This way I can provide the necessary command line options for >> mount.encfs on the options list of the autofs configuration. Haven't >> tried it, but options in fstab should be possible now too. >> >> I've made a fork in sourceforge, see >> http://sourceforge.net/u/afvandongen/fuse/ci/master/tree/ . The only >> file I changed is util/mount.fuse.c, the diff can be found under >> http://sourceforge.net/u/afvandongen/fuse/ci/master/tree/util/mount.fuse.c?diff=e6e7a249c5c70187144dd9cd3767801ed05a1763 >> >> Please have a look at it, any feedback about this idea and my >> implementation is welcome. > > Why not fix encfs instead to allow the "-oextpass=..." form too? > Seems less hackish to me. > > I see that you are trying to find a generic solution, but I don't > think this is a problem, except for a handfull of cases. > I second Miklos thoughts here. Actually, I received various proposals on how to make my fuse mount properly through /etc/fstab. I soon realized that this was not a fuse problem but rather a problem in my own fs implementation. I did not properly take use of the argument parsing functions as provided by the fuse API. When I did, I got all this support for free. Actually, you do not need to add explicit support for eg. -oextpass in encfs! When using the fuse API routines for this also constructs like this "-o ro,--extpass,..." work just as well. I believe fuse is treating its native switches (like -f) in the same way. I would report this issue upstream towards encfs instead and let it improve its argument parsing logic. Hans > Thanks, > Miklos > > ------------------------------------------------------------------------------ > Rapidly troubleshoot problems before they affect your business. Most IT > organizations don't have a clear picture of how application performance > affects their revenue. With AppDynamics, you get 100% visibility into your > Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro! > http://pubads.g.doubleclick.net/gampad/clk?id=84349831&iu=/4140/ostg.clktrk > _______________________________________________ > fuse-devel mailing list > fus...@li... > https://lists.sourceforge.net/lists/listinfo/fuse-devel |