Article ID: 114567, created on Aug 15, 2012, last review on May 8, 2014

  • Applies to:
  • Sitebuilder 4.5 for Windows


ImageGallery or another module page cannot be opened in Sitebuilder Wizard. The following error is shown in Sitebuilder Wizard:

Internal System error. Please contact administrator if the problem persists

The following error is shown in Application.log:

<SITEBUILDER ROOT>\_logs\Application.log
 Exception message: raw###System.Security.SecurityException
Request for the permission of type 'System.Data.OleDb.OleDbPermission, System.Data, Version=, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.
   at System.Security.CodeAccessSecurityEngine.Check(Object demand, StackCrawlMark& stackMark, Boolean isPermSet)
   at System.Security.PermissionSet.Demand()
   at System.Data.Common.DbConnectionOptions.DemandPermission()
   at System.Data.OleDb.OleDbConnection.PermissionDemand()
   at System.Data.OleDb.OleDbConnectionFactory.PermissionDemand(DbConnection outerConnection)
   at System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory)
   at System.Data.OleDb.OleDbConnection.Open()
   at SWsoft.SiteBuilder.Modules.Storage.Connector.Connectivity.DatabaseConnector.GetConnection()
   at SWsoft.SiteBuilder.Modules.Storage.Connector.LocalDataFacade.FillData(IList`1 executeBefore, DataSet emptyData, IList`1 queries, IList`1 executeAfter)
   at SWsoft.SiteBuilder.Modules.Storage.Connector.WebServices.DataFacadeService.<>c__DisplayClassa.<FillData>b__9()
   at SWsoft.SiteBuilder.Modules.Storage.Connector.WebServices.Services.Invoke[T](ObjectMethodInvoker fun, SiteIdHeader siteId)

Also the site cannot be published with this error:

Code access security permissions(s) denied on the publishing location. OleDbPermission(Unrestricted)

Also published site does not work. An error is shown on the ImageGallery page.


OleDbPermission is missing on the publishing host.


Publishing server works in the Medium Trust mode at least. If a server works in the Medium Trust mode, it must be granted with OleDbPermission for accessing Microsoft Access database and with WebPermission for some of the modules to work correctly.

1. In IIS verify published site uses ASP.NET 2.0.50727

2. Find trust level mode used by the publishing site. Open the site and change to the ImageGallery page. Find Trust level in the Event Log. For example:

Trust level: Medium


Trust level: High

3. Find configuration of Trust level mode in web.config:

     <trustLevel name="High" policyFile="web_hightrust.config" />         
     <trustLevel name="Medium" policyFile="web_mediumtrust.config" />  

4. Change web_mediumtrust.config or web_hightrust.config from directory C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\CONFIG\ depending on trust level mode used on the server. Add the highlighted records:

      <SecurityClass Name="OleDbPermission" Description="System.Data.OleDb.OleDbPermission, System.Data, Version=, Culture=neutral, PublicKeyToken=b77a5c561934e089
<PermissionSet class="NamedPermissionSet" ...>
      <IPermission class="OleDbPermission" version="1" Unrestricted="true" />
      <IPermission class="WebPermission" version="1" Unrestricted="true" />


5. Restart IIS with "iisreset".

For details refer to chapter Requirements to Publishing Location (page #37) of Parallels Sitebuilder 4.5 for Windows Site Owner's Guide

4d336e73be6d8fa81454b57cedf8e2bb 56797cefb1efc9130f7c48a7d1db0f0c fad6dc0c8e983c17ae70a51ac7952cd0 2a62cbceb986d1b8f45bcd3ff4cb29a5 45e8c8798afdb3e279a2f84bd498d19e

Email subscription for changes to this article
Save as PDF