[Samba] Restricting file types

Hamish captainmish at gmx.net
Fri Jul 9 09:41:37 GMT 2004


This works well for file servers only, but there is a way round it which 
might be good to bear in mind -
Say you have blocked /*.php/*.asp/ to prevent samba users making scripts 
on your web server (i am guessing that you have shared your webroot?)
Now make a php file, rename it to file.txt and move it to the server - 
no problem. Once it is on the server, rename it to file.php. The file 
disappears, but only to samba users - the file is still there named 
file.php and can be accessed by anything other than samba (ie apache)

Mike Stewart wrote:

>Yes, and very useful it is too :-)
>
>In the Globals section I put this to stop all users cluttering up the server
>with mp3 files. You can put it in each required share definition rather than
>globals though.
>
>veto files = /*.mp3/
>
>basically it starts with a / then file name and type and then ends with /
>
>so,  veto files = /*.bat/*.scr/mike.*/
>
>would stop all bat and scr files, and any file called mike with any ext.
>
>I use SWAT for configuring my Samba shares and the help file explains it
>well.
>
>HTH
>
>Mike
>
>
>----- Original Message ----- 
>From: "Bruce Embrey" <embrey at hood.edu>
>To: <samba at lists.samba.org>
>Sent: Thursday, July 08, 2004 2:36 PM
>Subject: [Samba] Restricting file types
>
>
>Samba List:
>
>
>
>Is it possible to limit what filename extensions can be stored in a
>samba share? We use samba to allow our windows web designers to use drag
>and drop when deploying new pages on our website. We want to be able to
>limit which filename extensions can be saved to these shares. Is this
>possible and if not and alternatives?
>
>
>
>Bruce Embrey
>
>
>
>  
>


More information about the samba mailing list