首页 > 解决方案 > 在 IIS 上使用 Windows 身份验证的 PHP opendir() 授权问题

问题描述

我在 IIS 上有一个启用了 Windows 身份验证的站点,我正在尝试使用 opendir() 函数访问目录。

一旦通过具有目录 opendir() 权限的域用户进行身份验证,我就会返回Warning: opendir(\\myserver\myshare\mydirectory): Access is denied. (code: 5).

我无法理解的是,如果在该站点上的 IIS 上我设置了物理路径: > Connect as...设置为特定用户而不是应用程序用户它可以工作

我注意到 get_current_user() 返回Myuser使用application usermyuser使用application user

为什么我不能访问目录?

标签: phpwindowsiiswindows-authenticationopendir

解决方案


推荐阅读