Block certain file extensions on samba linux
If you are using Samba server in your organization and want to restrict some file types to upload in shared directory. then you can use veto file to block certain file type in samba, You can restrict to upload mp3, mp3, exe, or any file types using it.
Here i have shared a directory name
"vishal"
and block some file extentions using veto file in samba.
Open samba config file and added veto file to last line of your shared block.
$ vim /etc/samba/smb.conf
[Vishal]
comment = vishalvyas
Path = /home/vishal
public = yes
writable = yes
browseable = yes
read only = no
valid user = vishal
create mask = 0775
Veto files = /*.exe/*.com/*.dll/*.bat/*.vbs/*.tmp/*.mp3/*.avi/*.mp4/*.wmv/*.wma/
Tags
Linux
ReplyDeleteThat is very interesting; you are a very skilled blogger. I have shared your website in my social networks..!
Informatica Training in Chennai
how if i want just one files type allowed on samba share
ReplyDeleteI am using samba server and shares are mapped in windows. Will veto files restrict from copying files from windows samba share
ReplyDeleteyes, It works with windows also.
Delete