IIS Q: How can I configure IIS executable extensio

2019-06-10 08:19发布

Please don't blame this question and I would be grateful if you can give me a specific answer.

I'm using Windows Server 2008 6.0 x86 with MsSQL 08.

1. I want to limit the extension of IIS executable files on my web server.

ex:)

Before set limit.

Executable extension : *.asp | *.aspx ...

After set limit.

Executable extension : only *.asp

When I change values on column 'Path' with '*.cust', *.asp -> *.cust, *.cer -> *.cust, *.aspx -> *.cust on Handler Mappings like this, the browser always return 404 error.

Test file : '\wwwroot\main\test.asp' & '\wwwroot\main\test.cust'

When I call '/main/test.asp', browser returns 404.3 "Not found" error.

When I call '/main/test.cust', browser returns 404.0 "Not found" error.

Why this happens?

I don't know exactly what the Handler Mappings menu is.

2. How to set 404 custerr when I call specified file?

Test file on 'C:\inetpu\wwwroot\main\test.browser'.

When I call this file on browser, it returns 404.7

The request filtering module is configured to deny the file extension.

Why this happens? is there any way to see the content of 'test.browser'? or is it impossible?

Someone please help me. Thank you in advance.

1条回答
Fickle 薄情
2楼-- · 2019-06-10 08:36

1) You can customize executable extension on Handler Mappings pane.

enter image description here

2) You can customize specific error on Request Filtering pane & Error Pages pane.

enter image description here

If you call that URI on browser(Chrome) you will get HTTP Error 404.5 - Not Found.

查看更多
登录 后发表回答