* external mount utilities and utab
@ 2013-11-01 19:21 Phillip Susi
2013-11-04 10:07 ` Karel Zak
` (2 more replies)
0 siblings, 3 replies; 10+ messages in thread
From: Phillip Susi @ 2013-11-01 19:21 UTC (permalink / raw)
To: util-linux
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
When mount runs mount.cifs, /run/mount/utab is not updated, so the
user mount flag is lost and thus, I can't umount as the user. Running
mount -i works correctly. Is this a bug in mount.cifs, or should
mount be recording these options whether it runs the external helper
or not?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (MingW32)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/
iQEcBAEBAgAGBQJSc/8pAAoJEJrBOlT6nu75ybMH/jtQUtC2FJ78ohCc7jsFYh6u
UU+lL4K4AdUQBZ44/cW23N8KV1fNppeF4JhYeHaIiCv0DWw4pglMsMN2HhCJuY01
8rYXRo5MVvvO/TpZlomm5JPIbuTaAyCChgU7doQXCyVTzXSi+On8KOFpXachqMiq
fPWL1wBQpSCS11n3+f4O7trkg8pB8pXuNYk+TcUEzRM11yEpu0Q+XvYN6po9faZc
YDJKyb4Zq2+b3Xp3jbfa15wMQ01hpVG6XZBFeBkmOdvdMmHvzO0Qgj1bYAPp+WEr
Ea4lDFtgedNlL0dGYmlyktywK8mkKTTMpq/dGE3ChTSZLl/DSFfx6s5nSQi5s5k=
=JvkV
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: external mount utilities and utab
2013-11-01 19:21 external mount utilities and utab Phillip Susi
@ 2013-11-04 10:07 ` Karel Zak
2013-11-04 13:36 ` Karel Zak
2013-11-04 13:37 ` Karel Zak
2 siblings, 0 replies; 10+ messages in thread
From: Karel Zak @ 2013-11-04 10:07 UTC (permalink / raw)
To: Phillip Susi; +Cc: util-linux
On Fri, Nov 01, 2013 at 03:21:13PM -0400, Phillip Susi wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> When mount runs mount.cifs, /run/mount/utab is not updated, so the
> user mount flag is lost and thus, I can't umount as the user. Running
> mount -i works correctly. Is this a bug in mount.cifs, or should
> mount be recording these options whether it runs the external helper
> or not?
This problem is fixed in mount.nfs where we use libmount. The question
is if really need to link all the helpers with libmount. I'll try to
play with that and prepare a solution.
Karel
--
Karel Zak <kzak@redhat.com>
http://karelzak.blogspot.com
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: external mount utilities and utab
2013-11-01 19:21 external mount utilities and utab Phillip Susi
2013-11-04 10:07 ` Karel Zak
@ 2013-11-04 13:36 ` Karel Zak
2013-11-04 13:37 ` Karel Zak
2 siblings, 0 replies; 10+ messages in thread
From: Karel Zak @ 2013-11-04 13:36 UTC (permalink / raw)
To: Phillip Susi; +Cc: util-linux
On Fri, Nov 01, 2013 at 03:21:13PM -0400, Phillip Susi wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> When mount runs mount.cifs, /run/mount/utab is not updated, so the
> user mount flag is lost and thus, I can't umount as the user. Running
> mount -i works correctly. Is this a bug in mount.cifs, or should
> mount be recording these options whether it runs the external helper
> or not?
Fixed, so if you have suid mount.cifs then you can use "user" mount
option and libmount will (after successful external helper) update
/run/mount/utab.
Karel
--
Karel Zak <kzak@redhat.com>
http://karelzak.blogspot.com
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: external mount utilities and utab
2013-11-01 19:21 external mount utilities and utab Phillip Susi
2013-11-04 10:07 ` Karel Zak
2013-11-04 13:36 ` Karel Zak
@ 2013-11-04 13:37 ` Karel Zak
2013-11-04 14:07 ` Phillip Susi
2 siblings, 1 reply; 10+ messages in thread
From: Karel Zak @ 2013-11-04 13:37 UTC (permalink / raw)
To: Phillip Susi; +Cc: util-linux
On Fri, Nov 01, 2013 at 03:21:13PM -0400, Phillip Susi wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> When mount runs mount.cifs, /run/mount/utab is not updated, so the
> user mount flag is lost and thus, I can't umount as the user. Running
> mount -i works correctly. Is this a bug in mount.cifs, or should
> mount be recording these options whether it runs the external helper
> or not?
ah.. note, that mount.cifs is not suid on Fedora, only suid mount
helper is mount.nfs on my machine.
Karel
--
Karel Zak <kzak@redhat.com>
http://karelzak.blogspot.com
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: external mount utilities and utab
2013-11-04 13:37 ` Karel Zak
@ 2013-11-04 14:07 ` Phillip Susi
2013-11-04 14:16 ` Karel Zak
2013-11-13 18:28 ` Phillip Susi
0 siblings, 2 replies; 10+ messages in thread
From: Phillip Susi @ 2013-11-04 14:07 UTC (permalink / raw)
To: Karel Zak; +Cc: util-linux
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Are you saying then that all of the helpers should now be using
libmount, and taking care of the utab updates themselves rather than
just having mount do it?
On 11/4/2013 8:37 AM, Karel Zak wrote:
> On Fri, Nov 01, 2013 at 03:21:13PM -0400, Phillip Susi wrote:
>> -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
>>
>> When mount runs mount.cifs, /run/mount/utab is not updated, so
>> the user mount flag is lost and thus, I can't umount as the user.
>> Running mount -i works correctly. Is this a bug in mount.cifs,
>> or should mount be recording these options whether it runs the
>> external helper or not?
>
> ah.. note, that mount.cifs is not suid on Fedora, only suid mount
> helper is mount.nfs on my machine.
>
> Karel
>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (MingW32)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/
iQEcBAEBAgAGBQJSd6oMAAoJEJrBOlT6nu759zQH/ApS7k10RDvYNgByirfu97gY
anSEcvn2nSBH4RXxiN2ugSlVtYPpr4HAZrxD0tYfb1BGH/0q1KI6RwlOlih9DSvf
kc6+iXRBU6eBVgaGWUeNWc9TVuSN9s/Ifw63dKkwppq6smLn4K6vnn1AcR3vy23c
BQw7wqdZZobsdMgiijDqKV0uT0VHEjH5lTDWkJ89fvJiC4/lvi1aL5AeKndOgusP
PuTrF9inji1lTbtK7r3gVoVPwl9b+YvzcsWG91OfbR77ACtM+OwC8kJZHxjI8AAu
4/x1OHI0yiz9kkMYDZDOfGj3lYrTc2aJ+tksDu89wFERnC8SOhv0HpsoY/6ANSw=
=0XY3
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: external mount utilities and utab
2013-11-04 14:07 ` Phillip Susi
@ 2013-11-04 14:16 ` Karel Zak
2013-11-13 18:28 ` Phillip Susi
1 sibling, 0 replies; 10+ messages in thread
From: Karel Zak @ 2013-11-04 14:16 UTC (permalink / raw)
To: Phillip Susi; +Cc: util-linux
On Mon, Nov 04, 2013 at 09:07:08AM -0500, Phillip Susi wrote:
> Are you saying then that all of the helpers should now be using
> libmount, and taking care of the utab updates themselves rather than
> just having mount do it?
That would be the best solution (and not only for utab, but also for
options parsing, userspace options, command line options used for
helpers, etc.). It's better to have all the things in one library.
Anyway, the change I did today allows to use "user" fstab mount
option also for non-libmount external helper.
It's already in my TODO list to write libmount patch for mount.cifs.
Karel
--
Karel Zak <kzak@redhat.com>
http://karelzak.blogspot.com
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: external mount utilities and utab
2013-11-04 14:07 ` Phillip Susi
2013-11-04 14:16 ` Karel Zak
@ 2013-11-13 18:28 ` Phillip Susi
2013-11-14 8:39 ` Karel Zak
1 sibling, 1 reply; 10+ messages in thread
From: Phillip Susi @ 2013-11-13 18:28 UTC (permalink / raw)
To: Karel Zak; +Cc: util-linux
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 11/4/2013 9:07 AM, Phillip Susi wrote:
> Are you saying then that all of the helpers should now be using
> libmount, and taking care of the utab updates themselves rather
> than just having mount do it?
ping... still wondering if the proper fix for this is to link
mount.cifs with libmount and make it suid, or if mount needs fixed to
do the utab update?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (MingW32)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/
iQEcBAEBAgAGBQJSg8TMAAoJEJrBOlT6nu75vV0H/RfDGiv5oPR+R2TsaABnd/GV
HMJ8AZfS322qdYjeMMyMTCTx9y/cy6fKzfW9q/JqyvQy6JNBq8LSFEve0Z298dwf
4JNvImDO1pjnXedMEvtN9X5NwxJbYpkY+LP9owg4LWP6d0RnLu8uwxNDHDpLp2Oi
PX2nbXHoUm8r8r6a3FfN1mVDqExhMbc5nJP7RCD6AqYzJ8ARz6x5/z3ei9u8UsT9
tctApV8wEvnGqdQufLXtP236pOplWnTMJ32RfIe7chM86T88MRheC5Mxq2MHjtZ4
slDJptr6dcTHAz8lY12J6mIZPpbLrb0mT9xOKmalivk8PJj0jkhj2/Fm9ejp87E=
=V2jT
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: external mount utilities and utab
2013-11-13 18:28 ` Phillip Susi
@ 2013-11-14 8:39 ` Karel Zak
2013-11-14 16:17 ` Phillip Susi
0 siblings, 1 reply; 10+ messages in thread
From: Karel Zak @ 2013-11-14 8:39 UTC (permalink / raw)
To: Phillip Susi; +Cc: util-linux
On Wed, Nov 13, 2013 at 01:28:28PM -0500, Phillip Susi wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> On 11/4/2013 9:07 AM, Phillip Susi wrote:
> > Are you saying then that all of the helpers should now be using
> > libmount, and taking care of the utab updates themselves rather
> > than just having mount do it?
>
> ping... still wondering if the proper fix for this is to link
> mount.cifs with libmount and make it suid, or if mount needs fixed to
> do the utab update?
I have improved libmount (in git tree) and now it updates utab for the
helpers.
Anyway if your mount.cifs is not suid then user= does not make sense
and you also don't have to care about utab at all. For example on
Fedora we don't have suid mount.cifs for years.
IMHO it's better to minimize number of suid binaries. I guess that
the user= functionality has been introduced to mount regular
filesystems (ext2, ...) from removable devices.
Karel
--
Karel Zak <kzak@redhat.com>
http://karelzak.blogspot.com
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: external mount utilities and utab
2013-11-14 8:39 ` Karel Zak
@ 2013-11-14 16:17 ` Phillip Susi
2013-11-14 22:24 ` Karel Zak
0 siblings, 1 reply; 10+ messages in thread
From: Phillip Susi @ 2013-11-14 16:17 UTC (permalink / raw)
To: Karel Zak; +Cc: util-linux
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 11/14/2013 3:39 AM, Karel Zak wrote:
> I have improved libmount (in git tree) and now it updates utab for
> the helpers.
But does that mean that the helper has to use libmount?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (MingW32)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/
iQEcBAEBAgAGBQJShPetAAoJEJrBOlT6nu75L6MIAMFbmidwDH1TUo7mjc5rw0d+
d3MMCkrGQ0ZW1ddv6iJvs/uAFBC/59leN2S7VrTN2wPHf5VKc1+4I4MVow/V/0eS
VQ8rrWCkGlayIM0+bghI8JflV8wL4zd2E2z8bqIyOzZm3sbVkjIcpi8UC4R0iDtU
BusDfS/bbVKoFARJz81GMyoq7l5WVSphuWGfpdjxi//4dWfvh2I5/I0Q9Wh/Q4ls
F/jxRo35IRPoi2kriOMQb1SdYu+jv2umpf1EYgc7XgJF8txPiW2XsSc+v4j117hG
1Lz2lRgDmJjXSInD4tGgN6/zXmD8HC2ptRgps0j9Y7ZhgsddTq9Hy9WElxFG4mc=
=wWrk
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: external mount utilities and utab
2013-11-14 16:17 ` Phillip Susi
@ 2013-11-14 22:24 ` Karel Zak
0 siblings, 0 replies; 10+ messages in thread
From: Karel Zak @ 2013-11-14 22:24 UTC (permalink / raw)
To: Phillip Susi; +Cc: util-linux
On Thu, Nov 14, 2013 at 11:17:49AM -0500, Phillip Susi wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> On 11/14/2013 3:39 AM, Karel Zak wrote:
> > I have improved libmount (in git tree) and now it updates utab for
> > the helpers.
>
> But does that mean that the helper has to use libmount?
No, after successful helper execution (helper has to return 0) the
library checks utab and update the file if there is user= mount option
and the mountpoint is not in the file.
Karel
--
Karel Zak <kzak@redhat.com>
http://karelzak.blogspot.com
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2013-11-14 22:24 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-11-01 19:21 external mount utilities and utab Phillip Susi
2013-11-04 10:07 ` Karel Zak
2013-11-04 13:36 ` Karel Zak
2013-11-04 13:37 ` Karel Zak
2013-11-04 14:07 ` Phillip Susi
2013-11-04 14:16 ` Karel Zak
2013-11-13 18:28 ` Phillip Susi
2013-11-14 8:39 ` Karel Zak
2013-11-14 16:17 ` Phillip Susi
2013-11-14 22:24 ` Karel Zak
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox