【问题标题】:Allow IIS virtual directory to pass through to a separate http.sys binding允许 IIS 虚拟目录传递到单独的 http.sys 绑定
【发布时间】:2017-02-24 02:07:53
【问题描述】:

底线:有没有办法让绑定的 IIS 站点的子路径通过直接绑定在 http.sys 中的非 IIS 应用程序?

我在 Windows Server 2008 上使用 IIS 7.5。我有一个绑定到特定根 URL 的现有 IIS 站点,例如 fooapps.bar.com。该站点下面有几个应用程序和目录。这一切都很好。问题是我现在想允许fooapps.bar.com 的子路径传递到另一个直接向 http.sys 注册自身的服务,而不是 IIS 应用程序。

所以这个服务在fooapps.bar.com/Services 绑定了自己的http.sys。如果我停止绑定到fooapps.bar.com 的 IIS 站点,那么 http.sys 绑定服务会成功接收和处理对fooapps.bar.com/Services 的请求。但是,如果 IIS 站点正在运行,那么所有对 fooapps.bar.com/Services/* 的请求都会被 IIS 拦截并返回错误,因为在相应的物理路径上实际上没有任何内容。我如何告诉 IIS 完全忽略 fooapps.bar.com/Services 而让对该路径的请求传递到 http.sys 中碰巧绑定的任何其他内容?

fooapps.bar.com (site)
   + Files (normal directory with static .html files)
   + SomeApp1 (application)
   + SomeApp2 (application)
   + nuget
       + Feed1 (application)
       + Feed2 (application)
       + Feed3 (application)
   + Services (??? How to make this pass through to separate http.sys binding?)

【问题讨论】:

    标签: iis iis-7.5 http.sys


    【解决方案1】:

    为所需的子树创建命名空间保留。 在具有管理权限的命令行中执行:

    netsh http add urlacl url=http://fooapps.bar.com:80/Services/ user=<samUserName>
    

    使用运行非 IIS 应用程序的用户名。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2011-02-12
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多