Debian Samba - 受保护文件夹和公共文件夹的混合 - Win 7 客户端

发布于 2025-01-08 05:06:05 字数 1211 浏览 1 评论 0原文

我有一个在小型家庭网络上运行 samba 的 Debian 机器。

smb.conf 如下:

[global]

    workgroup = workgroup
    netbios name = loftserver
    security = user
    map to guest = bad user
    guest account = smbguest

[share]

    path = /storage/share
    writeable = yes
    guest ok = yes
    public = yes
    browseable = yes


[prot]
    path = /storage/prot
    read only = no
    browseable = yes
    guest ok = no
    create mask = 0666
    directory mask = 0777
    valid users = pwuser

对于 Linux 客户端来说,一切都运行良好。共享文件夹是公共的 - 没有问题。 prot(受保护)文件夹正常工作,系统会提示用户输入 pwuser 的用户名和密码。

我使用以下命令设置这些:

smbpasswd -a pwuser

然后使用以下命令更改文件夹的所有权:

chown -R pwuser:pwuser /storage/prot

正如所说,在 Linux 客户端上一切正常。

该问题发生在 Windows 7 客户端上。

他们可以毫无问题地浏览到 \\loftserver\share。浏览到 \\loftserver\prot 会出现密码提示。他们输入了正确的详细信息,但却收到身份验证错误(访问被拒绝)。

/var/log/samba/log.smbd 给出以下错误:

[2012/02/20 23:47:33.023285,  1] smbd/service.c:678(make_connection_snum)
   create_connection_server_info failed: NT_STATUS_ACCESS_DENIED

有什么建议吗?我确信这是我忽略的简单事情。

I have a Debian box running samba on a small home network.

The smb.conf is as follows:

[global]

    workgroup = workgroup
    netbios name = loftserver
    security = user
    map to guest = bad user
    guest account = smbguest

[share]

    path = /storage/share
    writeable = yes
    guest ok = yes
    public = yes
    browseable = yes


[prot]
    path = /storage/prot
    read only = no
    browseable = yes
    guest ok = no
    create mask = 0666
    directory mask = 0777
    valid users = pwuser

all works perfectly well for linux clients. The share folder is public - no issues. The prot (protected) folder works as it should, users are prompted for the username and password of pwuser.

I set these using:

smbpasswd -a pwuser

then changed ownership of the folder with:

chown -R pwuser:pwuser /storage/prot

As said all works fine with Linux clients.

The problem occurs on a Windows 7 client.

They can browse to \\loftserver\share without a problem. Browsing to \\loftserver\prot gives them the password prompt. They enter in the correct details -- yet get an authentication error (access denied).

/var/log/samba/log.smbd gives the following error:

[2012/02/20 23:47:33.023285,  1] smbd/service.c:678(make_connection_snum)
   create_connection_server_info failed: NT_STATUS_ACCESS_DENIED

Any suggestions? I'm sure its something simple I have overlooked.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

榆西 2025-01-15 05:06:05

问题解决了。

 valid users = pwuser

从配置中删除了这一行。

该文件夹仍然受到 pwuser 和密码身份验证的保护,但在 win7 和 XP 客户端上运行良好。

很奇怪,我不明白!

Problem solved.

I removed the line

 valid users = pwuser

From the config.

The folder remains protected by pwuser and password authentication, but works fine for win7 and XP clients.

A strange one, that I do not understand!

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文