Subdirectory install web.config problems

Topics: ASP.NET 2.0
Oct 13, 2007 at 1:55 AM
Hello,
I am trying to install BE on a shared host environment - www.ixwebhosting.com.
I have created a subdirectory off of my main application directory.
I copied over BE files, made sure that had r/w access, and defined the subdir as a web application directory. It is setup to be a ASP NET 2.0 application.

I get an error when running concerning the authorization being a locked location.
I am a newbie at this stuff - anyone have any ideas to fix?
I am not sure what to ask here - maybe there is something that I have to tell the admin at ixwebhosting to do - flick the authorization ok switch.

Your help is appreciated.

Regards,
bruce

here is the error message ------------------------

Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: This configuration section cannot be used at this path. This happens when the site administrator has locked access to this section using <location allowOverride="false"> from an inherited configuration file.

Source Error:
Line 3: <system.web>
Line 4: <pages enableSessionState="true" />
Line 5: <authorization>
Line 6: <deny users="?" />
Line 7: </authorization>

Source File: D:\hshome\sguffanti\drdyslexic.com\blog\admin\web.config Line: 5
Oct 13, 2007 at 2:38 PM
I'm having the same issue and a newbie as well...
Oct 14, 2007 at 2:59 PM

I was thinking of commenting out this authorization section in the config file.
My webhost environment must set this in machine.config.

Are there any consequences to doing this otherwise?
Oct 15, 2007 at 3:32 AM
Commenting out the authorization section in the \admin\web.config & \admin\pages\web.config files does the trick.

Luckily, I don't have any "roles" to cover for this blog.


Oct 15, 2007 at 5:28 PM
There's a single line in the Web.Config file that looks like this:

<trust level="High" />

Just comment that out.

It's a core setting to the server and the hosting provider has locked it down that it cannot be overridden. If you run into more issues with access problems, you might want to ask them what Trust Level they set their shared hosting accounts to. I don't think you'll run into any issues with BE other than that one unless you start writting your own controls (I ran into it when I was trying to read a file and not using Server.MapPath). You can find Microsoft's security recommendations doc here(http://msdn2.microsoft.com/en-us/library/52kd59t0(VS.71).aspx) which explains what the various settings limit.
Oct 16, 2007 at 1:26 PM
That was it! Thanks for your help.
Oct 23, 2007 at 6:13 PM
I am having the following problems with Verio web hosting and blogengine: I have the App_Data folder set to write. I am newbie and I need a little push -- not looking for a direct answer. Any help would be greatly appreciated.
-------------------------------------------------------------------------------------------------------------------------
Server Error in '/' Application.
Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: This configuration section cannot be used at this path. This happens when the site administrator has locked access to this section using <location allowOverride="false"> from an inherited configuration file.

Source Error:

Line 32: <globalization requestEncoding="utf-8" responseEncoding="utf-8" culture="auto" uiCulture="auto" />
Line 33: <httpRuntime enableVersionHeader="false" useFullyQualifiedRedirectUrl="true" maxRequestLength="16384" requestLengthDiskThreshold="16384" />
Line 34: <trust level="High" />
Line 35:
Line 36:
Oct 23, 2007 at 10:23 PM
11murray, the answer is just above, in this thread.

comment out line 34, the one which says:

<trust level="High" />
Oct 24, 2007 at 2:29 PM
Edited Oct 24, 2007 at 10:26 PM

dunc85 wrote:
11murray, the answer is just above, in this thread.

comment out line 34, the one which says:

<trust level="High" />



I commented out the previous line and now I get the following error:

Server Error in '/' Application.
Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: The connection name 'LocalSqlServer' was not found in the applications configuration or the connection string is empty.

Source Error:

Line 164: <roleManager>
Line 165: <providers>
Line 166: <add name="AspNetSqlRoleProvider" connectionStringName="LocalSqlServer" applicationName="/" type="System.Web.Security.SqlRoleProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
Line 167: <add name="AspNetWindowsTokenRoleProvider" applicationName="/" type="System.Web.Security.WindowsTokenRoleProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
Line 168: </providers>


Source File: C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Config\machine.config Line: 166

I am on a shared host and I simply want to use XML as a database for starters (they charge more for SQL).
Oct 30, 2007 at 11:48 AM
That one's been done before - search here and you'll find it, but from memory... stick
<clear />

In that list of <providers> you posted, as the first entry, before the "<add" lines. The LocalSQLProvider string is defined somewhere else, either in your website's web.config (which I think is inherited by the applications), or in the machine.config. Anyway, you don't need it as you point out, so the way to get rid if it is to "clear" it.
Dec 8, 2007 at 2:55 PM
The problem requires some looking into... I have a post at http://www.codeplex.com/blogengine/Thread/View.aspx?ThreadId=18836 related. (full error message posted there)
My environment is as a virtual on a hosted site (similar to others above) and I am blowing on a line in the web.config under my <http Modules>
My site uses the compositeWeb stuff from MS and originally I thought the conflict was there, but looks like (from above) that there are some other conflict problems related to the BE web.config being 'under' the host web.config? Taking a line out here and a reference out there really was no help. Really wish somebody could address this problem as a category and give us all a fix :)
John