fstab and cifs mounting, possible to store authentication information outside of fstab?

Posted by tj111 on Server Fault See other posts from Server Fault or by tj111
Published on 2011-01-13T16:07:25Z Indexed on 2011/01/13 16:55 UTC
Read the original article Hit count: 225

Filed under:
|
|
|

I am currently using cifs to mount some network shares (that require authentication) in /etc/fstab. It works excellently, but I would like to move the authentication details (username/pass) outside of fstab and be able to chmod it 600 (as fstab can have issues if I were to change its permissions). I was wondering if it is possible to do this (many-user system, don't want these permissions to be viewable by all users).

from:

//server/foo/bar /mnt/bar cifs username=user,password=pass,r 0 0

to:

//server/foo/bar /mnt/bar cifs <link to permissions>,r 0 0

(or something analogous to this). Thanks.

© Server Fault or respective owner

Related posts about linux

Related posts about permissions