zoukankan      html  css  js  c++  java
  • IIS下浏览指定文件(如:web.config)

    具体步骤如下:

    1、快捷键:Ctrl + R

    2、输入:%windir%System32inetsrvconfigapplicationHost.config

    3、注销:fileExtensions节下的:<!--<add fileExtension=".config" allowed="false" /> --> 和 hiddenSegments 节下的<!-- <add segment="web.config" /> -->。具体如下:

     <requestFiltering>
      <fileExtensions allowUnlisted="true" applyToWebDAV="true">
                        <add fileExtension=".asa" allowed="false" />
                        <add fileExtension=".asax" allowed="false" />
                        <add fileExtension=".ascx" allowed="false" />
                        <add fileExtension=".master" allowed="false" />
                        <add fileExtension=".skin" allowed="false" />
                        <add fileExtension=".browser" allowed="false" />
                        <add fileExtension=".sitemap" allowed="false" />
                        <!--<add fileExtension=".config" allowed="false" /> -->
                        <add fileExtension=".cs" allowed="false" />
                        <add fileExtension=".csproj" allowed="false" />
                        <add fileExtension=".vb" allowed="false" />
                        <add fileExtension=".vbproj" allowed="false" />
                        <add fileExtension=".webinfo" allowed="false" />
                        <add fileExtension=".licx" allowed="false" />
                        <add fileExtension=".resx" allowed="false" />
                        <add fileExtension=".resources" allowed="false" />
                        <add fileExtension=".mdb" allowed="false" />
                        <add fileExtension=".vjsproj" allowed="false" />
                        <add fileExtension=".java" allowed="false" />
                        <add fileExtension=".jsl" allowed="false" />
                        <add fileExtension=".ldb" allowed="false" />
                        <add fileExtension=".dsdgm" allowed="false" />
                        <add fileExtension=".ssdgm" allowed="false" />
                        <add fileExtension=".lsad" allowed="false" />
                        <add fileExtension=".ssmap" allowed="false" />
                        <add fileExtension=".cd" allowed="false" />
                        <add fileExtension=".dsprototype" allowed="false" />
                        <add fileExtension=".lsaprototype" allowed="false" />
                        <add fileExtension=".sdm" allowed="false" />
                        <add fileExtension=".sdmDocument" allowed="false" />
                        <add fileExtension=".mdf" allowed="false" />
                        <add fileExtension=".ldf" allowed="false" />
                        <add fileExtension=".ad" allowed="false" />
                        <add fileExtension=".dd" allowed="false" />
                        <add fileExtension=".ldd" allowed="false" />
                        <add fileExtension=".sd" allowed="false" />
                        <add fileExtension=".adprototype" allowed="false" />
                        <add fileExtension=".lddprototype" allowed="false" />
                        <add fileExtension=".exclude" allowed="false" />
                        <add fileExtension=".refresh" allowed="false" />
                        <add fileExtension=".compiled" allowed="false" />
                        <add fileExtension=".msgx" allowed="false" />
                        <add fileExtension=".vsdisco" allowed="false" />
                        <add fileExtension=".rules" allowed="false" />
                    </fileExtensions>
                    <verbs allowUnlisted="true" applyToWebDAV="true" />
                    <hiddenSegments applyToWebDAV="true">
                        <!-- <add segment="web.config" /> -->
                        <add segment="bin" />
                        <add segment="App_code" />
                        <add segment="App_GlobalResources" />
                        <add segment="App_LocalResources" />
                        <add segment="App_WebReferences" />
                        <add segment="App_Data" />
                        <add segment="App_Browsers" />
                    </hiddenSegments>
                </requestFiltering>

    4、点击网站XXX,在右侧的IIS栏里,双击MIME类型项,在新打开的对话框中右侧(右击)点击添加,类型如:.config MIME类型如:xml/txt

    完毕后就可以浏览web.config了,浏览其他后缀步骤更简单。。。
  • 相关阅读:
    当你不知道今天星期几,不妨在编辑器写下这段代码
    自定义注解!绝对是程序员装逼的利器!!
    什么是可串行化MVCC
    Jetpack新成员,一篇文章带你玩转Hilt和依赖注入
    连接真机开发安卓(Android)移动app MUI框架 添加购物车等——混合式开发(四)
    从前世今生聊一聊,大厂为啥亲睐时序数据库
    工作五年,面试官说我只会CRUD!竟然只给我10K!
    bootstrap知识总结
    数据处理的两个基本问题05 零基础入门学习汇编语言42
    转移指令的原理02 零基础入门学习汇编语言44
  • 原文地址:https://www.cnblogs.com/shenchao/p/3966640.html
Copyright © 2011-2022 走看看