I want to block access to some Samba shares from a certain machine, but somehow I can't get it to work: the machine can still access the shares, and I did restart and reload the samba daemon.
Here is a part of my configuration:
security = share
hosts allow = 127.0.0.1 192.168.1.0/24
interfaces = 127.0.0.1 eth1 192.168.1.2
bind interfaces only = yes
hosts deny = 192.168.1.251
encrypt passwords = yes
guest ok = yes
The shares themselves look like this:
[examples]
comment = Example
path = /foo/bar
read only = No
guest ok = yes
What am I doing wrong here?
Found the answer, at least a working solution:
I removed the hosts deny line, and changed that hosts allow as follows:
Correction: For the machines you want to block access to set the "browseable= no". This field may vary depending on the version of Samba your using