Hi i have developer a little asp.net project using vs 2013 and sql server express2008r2. all work fine in local but when i publish on my hosting provider i get this error:
System.Security.SecurityException: Request for the permission of type 'System.Security.Permissions.FileIOPermission, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.
this is my web.config:
<?xml version="1.0"?>
<!--
For more information on how to configure your ASP.NET application, please visit
http://go.microsoft.com/fwlink/?LinkId=169433
-->
<configuration>
From the above error message, you need full trust permision to run your site. Does your hosting provider support
Full Trust? Please kindly ask their support team to setup full trust for you.
None
0 Points
1 Post
deploying problem
Mar 14, 2014 08:11 AM|leonep|LINK
Hi i have developer a little asp.net project using vs 2013 and sql server express2008r2. all work fine in local but when i publish on my hosting provider i get this error:
System.Security.SecurityException: Request for the permission of type 'System.Security.Permissions.FileIOPermission, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.
this is my web.config:
<?xml version="1.0"?>
<!--
For more information on how to configure your ASP.NET application, please visit
http://go.microsoft.com/fwlink/?LinkId=169433
-->
<configuration>
<connectionStrings>
<add name="PLURIMAPCDBConnectionString" connectionString="Data Source=62.149.153.39;Initial Catalog=MSSql92446;Integrated Security=no;uid=MSSql92446;pwd=***********" providerName="System.Data.SqlClient" />
</connectionStrings>
<location allowOverride="false">
<system.web>
<compilation debug="true" strict="false" explicit="true" targetFramework="4.0">
<assemblies>
<add assembly="Microsoft.Build.Framework, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A" />
</assemblies>
<buildProviders>
</buildProviders>
</compilation>
<globalization culture="it-IT" uiCulture="it-IT" />
<customErrors mode="Off"/>
<authentication mode="Forms">
<forms name=".ASPXFORMSDEMO" loginUrl="login.aspx" protection="All" path="/" timeout="30" />
</authentication>
<authorization>
<deny users="?" />
<allow users="*" />
</authorization>
</system.web>
<system.webServer>
<validation validateIntegratedModeConfiguration="false" />
</system.webServer>
</location >
</configuration>
I also read to add <trust level="Full"/> but not work for me. i want to know what kind of problem is. it's related to permission on database??
help me please , thank you very much
Participant
1930 Points
793 Posts
Re: deploying problem
Mar 14, 2014 11:48 PM|dotnetnerd|LINK
Hi leonep,
From the above error message, you need full trust permision to run your site. Does your hosting provider support Full Trust? Please kindly ask their support team to setup full trust for you.
Windows ASP.NET Hosting | Reseller Hosting | Cloud Hosting
All-Star
23975 Points
4084 Posts
Re: deploying problem
Mar 17, 2014 04:27 AM|Starain chen - MSFT|LINK
Hi leonep,
In my opinion, I think that isn’t the permission on the database.
Please set the full trust level in the IIS instead of in the web.config and check the result.
On the other hand, please provide the detail error message that you get. (E.g. which line of code that you get the error)
Thanks
Best Regards