发新话题
打印

[转载]AspEnableParentPaths MetaBase Property Should Be Set To False

[转载]AspEnableParentPaths MetaBase Property Should Be Set To False

信息来源:http://support.microsoft.com/kb/q184717/

On this page
SYMPTOMS
CAUSE
WORKAROUND
STATUS
APPLIES TO

SYMPTOMS
Active Server Pages (ASP) code that uses the following parent directory notation is enabled by default:
<!-- #include file="..\default.htm"-->
               
Back to the top

CAUSE
The AspEnableParentPaths property in the MetaBase specifies whether an ASP can allow paths relative to the current directory (using the ..\ notation). This may be a security risk.

In a security-enhanced environment, the AspEnableParentPaths property should be set to False, but the default installation of Internet Information Server version 4.0 sets it to True.

NOTE: Disabling ASP Parent Paths will only affect the execution of dynamic content on .asp pages. This does not affect the server&#39;s ability to reference static content using HTML code (whether it is called from .htm, .html or .asp files). The following line in a default.asp would properly display the image without returning an ASP 0131 error, even after AspEnableParentPaths = False:
<img src="../images/logo.jpg">
Back to the top

WORKAROUND
To work around this problem, perform the following steps:
1. Open the Internet Service Manager in the Microsoft Management Console.  
2. Right-click on the Web server in question.  
3. Select Properties on the pop-up menu.  
4. Click the Home Directory tab.  
5. Select Configuration in the Application Settings box.  
6. Click the App Options tab.  
7. Clear the Enable Parent Paths option.  
8. Click OK twice to return to the Microsoft Management Console.  

Back to the top

STATUS
Microsoft has confirmed this to be a problem in IIS versions 4.0 and 5.0.
曾几何时,有人对我说:装B遭雷劈。我说:去你妈的。于是,这个人又对我说:如果再说脏话,上帝会惩罚你的。我说:我操上帝。结论:彪悍的人生不需要上帝。

TOP

发新话题