Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   ASP .Net Security (http://www.velocityreviews.com/forums/f62-asp-net-security.html)
-   -   Security trimming problem with not absolute path (http://www.velocityreviews.com/forums/t770173-security-trimming-problem-with-not-absolute-path.html)

Alexj 02-23-2010 08:14 AM

Security trimming problem with not absolute path
 
Hello, I have a problem that for many of you will surely be trivial, I wanted
to enable the security trimming by xml, everything works if I insert full
address in the sitemap.
But if I put the ~ as shown below does not work the disappearance of the
menu items to unauthorized persons:

xml version = "1.0" encoding = "utf-8"?
<siteMap xmlns="http://schemas.microsoft.com/AspNet/SiteMap-File-1.0">
<siteMapNode url="#" title="Start" description="Inizio" roles="*">
<siteMapNode url="~/CreazioneDocumentale/antfattStep1.aspx?enc=99999"
title="Creazione Distinta" roles="Domain\0001" />
<siteMapNode url="~/CreazioneDocumentale/antfattStep1.aspx?enc=3333333"
title="Pred. Request "description="Pred. Request BO" roles="Domain\0002" />

</ siteMapNode>
</ siteMap>

Below a part of web.config:

<authentication mode="Windows"/>

<siteMap defaultProvider="xmlSite" enabled="true">
<providers>
<clear/>
<add name="xmlSite" type="System.Web.XmlSiteMapProvider"
siteMapFile="~/Sitemap/filename.sitemap" securityTrimmingEnabled="true"/>
</providers>
</siteMap>
<roleManager enabled="true"
defaultProvider="AspNetWindowsTokenRoleProvider">
<providers>
<clear/>
<add name="AspNetWindowsTokenRoleProvider"
type="System.Web.Security.WindowsTokenRoleProvider "/>
</providers>
</roleManager>

<authorization>
<deny users="?"/>
<allow roles="Domain\0001"/>
</authorization>


Thanks in advance for answers.




All times are GMT. The time now is 09:50 PM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.