Free DISA STIG and SRG Library | Vaulted

V-1030

The smb.conf file must use the hosts option to restrict access to Samba.

Finding ID
GEN006220
Rule ID
SV-35107r1_rule
Severity
Cat II
CCE
(None)
Group Title
GEN006220
CCI
CCI-000225
Target Key
(None)
Documentable
No
Discussion

Samba increases the attack surface of the system and must be restricted to communicate only with systems requiring access.

Fix Text

Edit the smb.conf file and set the hosts option to permit only authorized hosts access Samba. An example might be: hosts allow = 127.0.0.1 192.168.2.0/24 192.168.3.0/24 hosts deny = 0.0.0.0/0 The above will only allow SMB connections from the localhost and from the two private networks 192.168.2 and 192.168.3. All other connections will be refused as soon as the client sends its first packet.

Check Content

Examine the smb.conf file. # cat /etc/opt/samba/smb.conf | tr '\011' ' ' | tr -s ' ' | sed -e 's/^[ \t]*//' | grep -v "^#" | egrep "^hosts|^ hosts allow|^hosts deny" If the hosts option is not present to restrict access to a list of authorized hosts and networks, this is a finding.

Responsibility

System Administrator

IA Controls

ECSC-1