Answered by:
SecurityAccessDeniedException-Access Denied -WCF Service

Question
-
Hi,
I have a IIS hosted WCF Service. I am accessing it from remote machine. I get the following error in my client application:
System.ServiceModel.Security.SecurityAccessDeniedException: Access is denied.
I use BasicHttpBinding. Authentication mode is set to "None" in web.config.
Please helpThursday, April 9, 2009 11:38 AM
Answers
-
This exception gets triggered when an "Access Denied" fault response is encountered. The most common reason for this is an unhandled SecurityException somewhere in your code.
Dominick Baier | thinktecture | http://www.leastprivilege.com- Marked as answer by Marco Zhou Friday, April 17, 2009 9:59 AM
Friday, April 10, 2009 1:26 PM
All replies
-
Hi Rajalakshmi,
I would suggest you to verify if the account under which your service runs has all the required privileges on the server. If you hosted your services on windows 2003, one way is to add the account under which your IIS application pool runs to IIS_WPG windows group so that all the required file system privileges will be granted ( ex: access privileges for Temp folder in windows etc)
I would suggest you to enable trace for WCF service to narrow down the issue. Please refer to the instructions given below to configure and view trace
http://msdn.microsoft.com/en-us/library/ms732023.aspx
http://blogs.msdn.com/madhuponduru/archive/2006/05/18/601458.aspx
http://msdn.microsoft.com/en-us/library/ms732023.aspx
This should give us more insight in to the issue...
Hari- Proposed as answer by Hari123 Monday, April 13, 2009 8:06 PM
Thursday, April 9, 2009 7:47 PM -
This exception gets triggered when an "Access Denied" fault response is encountered. The most common reason for this is an unhandled SecurityException somewhere in your code.
Dominick Baier | thinktecture | http://www.leastprivilege.com- Marked as answer by Marco Zhou Friday, April 17, 2009 9:59 AM
Friday, April 10, 2009 1:26 PM -
Thanks. The issue was the service account didnt have write permissions on a path. It is resolved.Monday, April 20, 2009 5:00 AM