Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Security > web.config access problem

Reply
Thread Tools

web.config access problem

 
 
Microsoft
Guest
Posts: n/a
 
      09-03-2003
I'm trying to set up an application so that on first run/install it writes
to the web.config various values.

I have loaded the web.config into an xmldocument and have made the changes
but can't save the file back to disc i get an error similar to the
following:

Access to the path "C:\Source\myApp\web.config" is denied.

The web application is not in the inetpub folder.

How do i set the security/access etc so that the web.config file can be
written to.

The error page says:

"To grant ASP.NET write access to a file, right-click the file in Explorer,
choose "Properties" and select the Security tab. Click "Add" to add the
appropriate user or group. Highlight the ASP.NET account, and check the
boxes for the desired access."

I'm using windows xp pro and this option is not available where i can see
it.

I ideally would like to be able to do any settings at runtime in code but if
not possible any other suggested method would be appreciated.

barney nicholls



 
Reply With Quote
 
 
 
 
Barney Nicholls
Guest
Posts: n/a
 
      09-04-2003
Mary

I've created other folders and text files etc and i still can't get write
access to them.

I think i've iis5 up correctly but i must be a bit dim as i just can't get
it to let me write to a file.

any pointers on setting write access for asp.net to a file in a directory
with iis 5 and xp pro would be appreciated

"Mary Chipman" <> wrote in message
news:...
> Web.config is designed so that it can't be browsed to or written to at
> runtime. You'll need to modify it outside of ASP.NET.
>
> -- Mary
> MCW Technologies
> http://www.mcwtech.com
>
> On Wed, 3 Sep 2003 14:12:36 +0100, "Microsoft"
> <> wrote:
>
> >I'm trying to set up an application so that on first run/install it

writes
> >to the web.config various values.
> >
> >I have loaded the web.config into an xmldocument and have made the

changes
> >but can't save the file back to disc i get an error similar to the
> >following:
> >
> >Access to the path "C:\Source\myApp\web.config" is denied.
> >
> >The web application is not in the inetpub folder.
> >
> >How do i set the security/access etc so that the web.config file can be
> >written to.
> >
> >The error page says:
> >
> >"To grant ASP.NET write access to a file, right-click the file in

Explorer,
> >choose "Properties" and select the Security tab. Click "Add" to add the
> >appropriate user or group. Highlight the ASP.NET account, and check the
> >boxes for the desired access."
> >
> >I'm using windows xp pro and this option is not available where i can see
> >it.
> >
> >I ideally would like to be able to do any settings at runtime in code but

if
> >not possible any other suggested method would be appreciated.
> >
> >barney nicholls
> >
> >

>



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Very annoying error: Access to the path is denied. ASP.NET is not authorized to access the requested resource. Consider granting access rights to the resource to the ASP.NET request identity Jay ASP .Net 2 08-20-2007 07:38 PM
DS 4125 , web interface access, CLI access problem!!! zillah Cisco 0 11-27-2006 04:54 AM
403 Forbidden: You were denied access because: Access denied by access control list Southern Kiwi NZ Computing 6 03-19-2006 05:19 AM
Desktop can't access Laptop but Laptop can access desktop =?Utf-8?B?Qmx1Y2FkZHk3MQ==?= Wireless Networking 2 11-23-2004 01:52 AM
How do I let people access the internet via an access point but not allow them access to my network yar Wireless Networking 4 09-21-2004 03:48 AM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57