在IIS 6中虚拟目录的目录列表否认ASP.Net MVC 4应用程序运行 [英] Directory listing denied on ASP.Net MVC 4 app running in IIS 6 Virtual Directory

查看:167
本文介绍了在IIS 6中虚拟目录的目录列表否认ASP.Net MVC 4应用程序运行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图让ASP.Net MVC 4 IIS6工作,正在运行到充满乐趣的目录列表被拒绝错误。

I am trying to get ASP.Net MVC 4 working on IIS6 and am running into the always fun Directory Listing Denied error.

开始之前张贴扩展名的URL,我怎么需要阅读Haacked博客帖子..我:)所以与离开这里的方法是设置:

Before you start posting about extensionless urls and how I need to read the Haacked blog post.. I have :) So with that out of the way here is the setup:

我创建了一个新的网站,并将其配置为使用ASP.Net 4.0。我不得不这样做,因为现有的默认Web站点配置为ASP.Net 2.0,这打破了扩展名的URL。根据新的网站我创建了一个虚拟目录具有读/写/日志Vists /索引选择此资源选项并执行设置为脚本的权限。

I have created a new Web Site and configured it to use ASP.Net 4.0. I had to do this because the existing Default Web Site is configured for ASP.Net 2.0 and this breaks extensionless urls. Under the new web site I created a Virtual Directory with Read/Write/Log Vists/Index this resource options selected and execute permissions set to Scripts.

我已经验证,ASP.Net v4.0.30319是在Web服务扩展列表,是允许的。我也验证了个.axd映射正确设置在我的虚拟目录映射配置。

I have verified that ASP.Net v4.0.30319 is in the Web Service Extensions list and is allowed. I have also verified that the .axd mapping is setup correctly in my virtual directories mapping configuration.

我完全,完全难倒..

I am completely and totally stumped..

琐事的侧面有点我有这个本网站直接在我的ASP.Net 4 web应用程序指向工作,但我们需要这是通过一个虚拟目录来完成吧。我有这个工作事实上应该意味着EnableExtensionlessUrl注册表设置是没有问题的。

As a side bit of trivia I had this working with the web site pointing directly at my ASP.Net 4 web app but we need this to be done via a virtual directory instead. The fact I had this working should mean that the EnableExtensionlessUrl registry setting is not a problem.

推荐答案

我曾面临同样的问题,当我说通配符应用程序映射(。* ),以 ASPNET_ISAPI.DLL 确认文件是否存在

I had faced the same problem and it got cleared when I added "Wildcard application mapping" (.*) to aspnet_isapi.dll with unchecked option "Verify that file exists"

应用程序 - >属性 - >目录 - >配置 - >映射 - >
  插入 - >浏览
  C:\\ WINDOWS \\ Microsoft.NET \\框架\\ v4.0.30319 \\ ASPNET_ISAPI.DLL - >
  取消确认文件是否存在 - >确定

Application -> Properties -> Directory -> Configuration -> Mappings -> Insert -> Browse to C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll -> Uncheck "Verify that file exists" -> Ok

现在该网站是没有任何问题打开罚款。

Now the site is opening fine without any issues.

这篇关于在IIS 6中虚拟目录的目录列表否认ASP.Net MVC 4应用程序运行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆