我无法观看上传到 drupal 的视频

发布于 2024-09-28 07:29:00 字数 974 浏览 9 评论 0原文

我可以将视频上传到我的 drupal 实例,但是当我尝试查看该视频时,我无权这样做。我发现IIS_IUSR没有Read &即使 IIS_IUSR 对包含的目录执行权限,也对视频执行权限。

IIS_IUSR 有 Read &执行、列出文件夹内容以及对文件上传到的目录的读取权限。但是,当我查看上传的视频文件(something.mp4)的权限时,IIS_IUSR 仅具有列出文件夹/读取数据权限,Windows 表示这些权限是从父对象继承的。包括可从对象的父级选项继承的权限已选中。

以下是一些可能有用的更多信息。
如果我尝试直接通过网址访问视频,则会收到此错误:
HTTP 错误 500.50 - URL 重写模块错误。
由于发生内部服务器错误,页面无法显示。

模块RewriteModule
通知BeginRequest
处理程序StaticFile
错误代码 0x80070005

这似乎是某个地方的配置问题,即 Drupal、IIS 或 Windows。

有什么想法。

我的环境:

  • Windows 2008 R2
  • IIS 7.5
  • Drupal 6.19
  • MySQL 5.1.49
  • PHP 5.2.14

有人要求我发布我的.htaccess。该网站有几个,但这里是视频上传到的文件目录的一个。

SetHandler Drupal_Security_Do_Not_Remove_See_SA_2006_006
选项 无
选项 +FollowSymLinks

但是 .htaccess 不是仅与 Apache 一起使用吗?我使用的是 IIS,那么是否使用了 .htaccess?

I can upload a video to my drupal instance, but when I try to view the video I don't have rights to do so. I discovered that the IIS_IUSR doesn't have Read & Execute rights on the video even though the IIS_IUSR does on the containing directory.

IIS_IUSR has Read & Execute, List folder contents, and Read rights to the directory where files are uploaded to. However when I look at the rights of the uploaded video file (something.mp4), IIS_IUSR only has List folder/read data rights and Windows says these are inherited from the parent object. Include inheritable permissions from the object's parent option is checked.

Here's some more information that may be helpful.
If I try to access a video directly via a url I get this error:
HTTP Error 500.50 - URL Rewrite Module Error.
The page cannot be displayed because an internal server error has occurred.

Module RewriteModule
Notification BeginRequest
Handler StaticFile
Error Code 0x80070005

This seems like a configuration issue someplace, i.e. Drupal, IIS, or Windows.

Any thoughts.

My environment:

  • Windows 2008 R2
  • IIS 7.5
  • Drupal 6.19
  • MySQL 5.1.49
  • PHP 5.2.14

Someone requested that I post my .htaccess. There are several for the site, but here is the one for the files directory where the videos are uploaded to.

SetHandler Drupal_Security_Do_Not_Remove_See_SA_2006_006
Options None
Options +FollowSymLinks

But isn't .htaccess only used with Apache? I'm using IIS, so is the .htaccess even used?

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

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

发布评论

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

评论(1

七婞 2024-10-05 07:29:00

在将文件移动到 Web 目录之前,通过更改 Windows 将文件上传到的临时上传目录来使视频正常工作。默认情况下,Windows 使用 C:\Windows\Temp,在我的例子中,当文件从 Temp 移动到 Web 目录时,文件上设置的权限将被保留。我不想在此文件夹上设置 IIS_IUSR 权限,因此我在 C 驱动器下创建了一个不同的目录,并为其授予 IIS_IUSR 读取/执行权限。然后我更新了 php.ini 文件以指向这个新目录。现在一切正常。我认为关键是将这个临时目录放在 Inetpub 之外,因为我尝试了相同的设置,但使用 Inetpub 内的临时目录,但它不起作用。

Got the videos to work by changing the temp upload directory that Windows uploads files to before they're moved the web directory. By default Windows uses C:\Windows\Temp and in my case the permissions set on the file were kept when they were moved from Temp to the web directory. I didn't want to set IIS_IUSR permissions on this folder, so I created a different directory right under the C drive and gave it IIS_IUSR read/execute perms. Then I updated my php.ini file to point to this new directory. All's working well now. I think the key was to put this temporary directory outside of Inetpub because I tried this same set up but with the temp directory within Inetpub and it didn't work.

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