Hi
I'm developing a webservice which is supposed to creat a file in c:\program
files\. This ends up with this error:
UfsNotisDb.Upload: System.Web.Services.Protocols.SoapException: Server was
unable to process request. --> Access to the path "c:\program
files\UfsNotis_20041124_073435.mdf" is denied.
at
System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)
at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String
methodName, Object[] parameters)
at NotisUttagWeb.WebReference.Service1.UploadDb(Byte[] DbFile) in
D:\Lasse\VStudioNet\NotisUttagWeb\NotisUttagWeb\Web
References\WebReference\Reference.vb:line 42
at NotisUttagWeb.UfsNotisDb.Upload() in
D:\Lasse\VStudioNet\NotisUttagWeb\NotisUttagWeb\UfsNotisDb.vb:line 172
If the service is modified to create the file in c:\sjov\, it works ok. The
service has the anonymous access enabled using an account in the local
administrators group. According to the file security the account have full
control in both dirs.
Is there any settings in XP which overrides the file security for a
webservice and protect the c:\program files\?
Someone out there, please help
//jozzler
Hayato Iriumi - 27 Nov 2004 08:03 GMT
Hello jozzler,
You probably need to give IIS_WPG group Modify permission to C:\Program Files\,
but I wouldn't recommend you do that. I'd create another subfolder and give
that folder the permission.
> Hi
> I'm developing a webservice which is supposed to creat a file in
[quoted text clipped - 26 lines]
> Someone out there, please help
> //jozzler
Dan Rogers - 02 Dec 2004 21:17 GMT
Hi,
Yes, there is code in Windows XP that make the program files section
protected. The web service will not have the full trust permissions it
requires to create a new file in this area. There are a few work arounds,
but it is inadvisable to expose a web service call that can write to
C:\program files because this is an easy way to corrupt or trick the user
into running malicious code.
What is the context that makes you want to do this?
Regards
Dan Rogers
Microsoft Corporation
--------------------
Thread-Topic: Access denied
thread-index: AcTSA4/waIqlPwMHTamEYilpwtJWpw==
X-WBNR-Posting-Host: 161.54.134.253
From: "=?Utf-8?B?am96emxlcg==?=" <jozzler@hotmail.com.(donotspam)>
Subject: Access denied
Date: Wed, 24 Nov 2004 00:57:01 -0800
Lines: 26
Message-ID: <89430986-934C-4B30-BAFF-0FEDEC615A8F@microsoft.com>
MIME-Version: 1.0
Content-Type: text/plain;
charset="Utf-8"
Content-Transfer-Encoding: 7bit
X-Newsreader: Microsoft CDO for Windows 2000
Content-Class: urn:content-classes:message
Importance: normal
Priority: normal
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
Newsgroups: microsoft.public.dotnet.framework.webservices
NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.1.29
Path: cpmsftngxa10.phx.gbl!TK2MSFTNGXA01.phx.gbl!TK2MSFTNGXA03.phx.gbl
Xref: cpmsftngxa10.phx.gbl
microsoft.public.dotnet.framework.webservices:7611
X-Tomcat-NG: microsoft.public.dotnet.framework.webservices
Hi
I'm developing a webservice which is supposed to creat a file in c:\program
files\. This ends up with this error:
UfsNotisDb.Upload: System.Web.Services.Protocols.SoapException: Server was
unable to process request. --> Access to the path "c:\program
files\UfsNotis_20041124_073435.mdf" is denied.
at
System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClient
Message message, WebResponse response, Stream responseStream, Boolean
asyncCall)
at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String
methodName, Object[] parameters)
at NotisUttagWeb.WebReference.Service1.UploadDb(Byte[] DbFile) in
D:\Lasse\VStudioNet\NotisUttagWeb\NotisUttagWeb\Web
References\WebReference\Reference.vb:line 42
at NotisUttagWeb.UfsNotisDb.Upload() in
D:\Lasse\VStudioNet\NotisUttagWeb\NotisUttagWeb\UfsNotisDb.vb:line 172
If the service is modified to create the file in c:\sjov\, it works ok. The
service has the anonymous access enabled using an account in the local
administrators group. According to the file security the account have full
control in both dirs.
Is there any settings in XP which overrides the file security for a
webservice and protect the c:\program files\?
Someone out there, please help
//jozzler