環(huán)境說明
- samba4.6 (centos7)
- win7
- winxp
安裝配置samba4.6
-
安裝samba4.6
yum install samba
-
配置samba
修改/etc/samba/smb.conf文件如下文(共享用戶home目錄):
[global] workgroup = SAMBA security = user passdb backend = smbpasswd encrypt passwords = yes smb passwd file = /etc/samba/smbpasswd log file = /var/log/samba/log.%m ntlm auth = yes printing = cups printcap name = cups load printers = yes ups options = raw [homes] comment = Home Directories valid users = %S browseable = No writable = yes available = yes create mode = 0644 directory mode = 0755
添加samba賬戶并按提示輸入密碼:
smbpasswd -a user
重啟samba服務(wù)
systemctl restart smb
-
問題
-
描述
如果未在smb.conf中配置ntlm auth = yes猜煮,會(huì)導(dǎo)致winXP無法正常訪問samba服務(wù),win7訪問正常昧狮。
-
原因
samba4.5以后的版本不支持NTLMv1,而winXP默認(rèn)用的就是NTLMv1
NTLMv1 authentication disabled by default ----------------------------------------- In order to improve security we have changed the default value for the "ntlm auth" option from "yes" to "no". This may have impact on very old clients which doesn't support NTLMv2 yet. The primary user of NTLMv1 is MSCHAPv2 for VPNs and 802.1x. By default, Samba will only allow NTLMv2 via NTLMSSP now, as we have the following default "lanman auth = no", "ntlm auth = no" and "raw NTLMv2 auth = no".
-
解決方法
-
Samba服務(wù)器端smb.conf配置文件中添加“ntlm auth = yes”,并重啟smb服務(wù)脾歧。
或者
Windows XP客戶端修改組策略(gpedit.msc)本地安全設(shè)置仅政、安全選項(xiàng)吴侦、“網(wǎng)絡(luò)安全:LAN Manager身份驗(yàn)證級(jí)別”的值為“僅發(fā)送 NTLMv2響應(yīng)”央星。
-
-