Re: Prompting for passwords when mounting drives from /etc/fstab



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Alexander Larsson wrote:
> Why did you enable creating of GnomeVFSDrives from loopback mounts? We
> explicitly disabled this because things like iso loopback files were
> often in fstab, and people were badly confused by these showing up as
> cdrom drives in Computer. 

I see. I enabled them because for legacy crypto loop back setups this
allows the user to mount the drive and get prompted for a password. But
if this causes all sorts of undesirable things, then I guess I'd have to
find another solution.

However it does beg the question... If a drive is marked as user
mountable in /etc/fstab why not show it to the user? Note that as far as
I can see this will only occur in corporate environments, setup by an
administrator.

> Maybe you could reuse the _gnome_vfs_pty_open in modules/pty-open.c
> instead of using openpty. I'm not sure the exact details here, but maybe
> that code works on more systems? (We'd have to move the code of course.)

Will do.

> + if ((!invoke_fill_auth (info, &password) || password == NULL) &&
> +    (!invoke_full_auth (info, &password, &keyring, &save_password) || password == NULL)) {
> 
> This doesn't look really right. If the fill_auth succeeds, but the
> stored password is wrong you'll never get the password dialog.

Yes, agreed. This needs some work. Basically the legacy mount command
has no support for prompting a user again after an invalid password, and
it's hard to detect whether the mount failed because of the invalid
password. I'll think more about this.

> +  command = find_command (is_in_media ? PUMOUNT_COMMAND : UMOUNT_COMMAND);

pumount seems to have certain criteria for drives it will unmount. It
won't unmount /etc/fstab drives that are marked as user mountable.
umount unmounts these fine. Is there a way to tell if a drive has been
mounted with pmount?

Thanks,
Nate
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFDVSUQe/sRCNknZa8RAh+9AJwMZXAj+37i18wPguf0xsmeRIXlmQCeNLFp
hQljJT0ffrc3ZH+EHJPizwg=
=5SAE
-----END PGP SIGNATURE-----




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]