[Samba] Veto files applied per group

David Wilson dave at dcdata.co.za
Wed Feb 2 07:05:47 GMT 2005


Hi Malte,

Unfortunately still no luck with this one.
Any ideas why ?

Thanks for your help.

Kindest regards
David Wilson
_______________________________
D c D a t a
Tel +27 33 342 7003
Fax +27 33 345 4155
Cell +27 82 4147413
http://www.dcdata.co.za
support at dcdata.co.za
Powered by Linux, driven by passion !
_______________________________

"Computers are not intelligent. They only think they are."

----- Original Message ----- 
From: "David Wilson" <dave at dcdata.co.za>
To: ""M. Müller"" <malte.mueller at ewetel.net>; <samba at lists.samba.org>
Sent: Monday, January 31, 2005 8:44 PM
Subject: Re: [Samba] Veto files applied per group


> Hi Malte,
>
> Sorry to bug you with this, but I've tried it and it does not seem to 
> work - perhaps something I've missed ?
> Running "testparm" gives me the following error:
> "Can't find include file /usr/local/samba/lib/%g-smb.conf"
>
> In my smb.conf I have the following:
> comment = Home Directories
> read only = no
> create mask = 0600
> directory mask = 0700
> browseable = no
> include = /usr/local/samba/lib/%g-smb.conf
>
> In the /usr/local/samba/lib/students-smb.conf file I have only the 
> following:
> veto files = /*.mp3/*.avi/*.mpg/
>
> Running smbmount and mounting the share as the user who is a student and 
> writing a .mp3 file to the share works perfectly when it should be denied.
> When I do this I get the same "can't find include file..." error before 
> smbmount actually mounts the share.
>
> I've tried various things including "%G" instead of "%g" etc. It just 
> seems that Samba is not expanding the %G or %g variables.
> Any ideas ?
>
> Thank you for your assistance.
>
>
> Kindest regards
> David Wilson
> _______________________________
> D c D a t a
> Tel +27 33 342 7003
> Fax +27 33 345 4155
> Cell +27 82 4147413
> http://www.dcdata.co.za
> support at dcdata.co.za
> Powered by Linux, driven by passion !
> _______________________________
>
> "Computers are not intelligent. They only think they are."
>
> ----- Original Message ----- 
> From: ""M. Müller"" <malte.mueller at ewetel.net>
> To: "David Wilson" <dave at dcdata.co.za>; <samba at lists.samba.org>
> Sent: Monday, January 31, 2005 11:56 AM
> Subject: Re: [Samba] Veto files applied per group
>
>
>> ReHi,
>> You could also include just a students.conf or students-home.conf in the 
>> [home] Definition:
>> [home]
>> path=/home
>> ...
>> include %G-home.conf
>>
>> If there is no %G-home.conf e.g. teachers-home.conf, then nothing is 
>> included. Otherwise the definitions are overwritten or extended by the 
>> %G-home.conf.
>> You just have to write less lines.
>>
>> HTH,
>> Malte Mueller
>>
>> David Wilson schrieb:
>>
>>>Hi guys,
>>>
>>>I use "veto files = /.mp3/.mpg/" etc. on the [homes] share to prevent 
>>>users from storing media files on a Samba server in the home directories.
>>>My client now wishes to make this restriction apply to users who are 
>>>members of only certain groups.
>>>E.g. This restriction must apply to users who are members of the 
>>>"Students" group and not apply to users in the "Teachers" group.
>>>
>>>I was thinking of having a blank smb.conf file with only the following in 
>>>it:
>>>include = /etc/samba/smb.conf.%G
>>>
>>>Then having two smb.conf files, namely smb.conf.Teachers and 
>>>smb.conf.Students.
>>>The smb.conf.Students file would have the entire config file and the 
>>>"veto files" parameter.
>>>The smb.conf.Teachers file would have the entire config file but without 
>>>the "veto files" parameter.
>>>
>>>Makes sense ? Is there perhaps a better way to do this ?
>>>
>>>Many thanks
>>>
>>>Kindest regards
>>>David Wilson
>>>_______________________________
>>>D c D a t a
>>>Tel +27 33 342 7003
>>>Fax +27 33 345 4155
>>>Cell +27 82 4147413
>>>http://www.dcdata.co.za
>>>support at dcdata.co.za
>>>Powered by Linux, driven by passion ! _______________________________
>>>
>>>"Computers are not intelligent. They only think they are."
>>>
>>
> 



More information about the samba mailing list