473,509 Members | 2,880 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Permissions Problem

I am trying to determine a permission problem trying to write a text file
from one web server to another.

Here is the situation:

We have two domains in place one is Active Directory and the other is an old
NT4 domain. These two domains have a trust between them.

On a 2003 server I am using the file system object to write a text file to a
NT4 web server. The folder on the NT 4 server currently is shared with open
security with control for everyone on Domain1 and Domain2. The 2003 server's
worker process is running under a domain account that has full access to the
folder.

I am able to map a drive to the share from the 2003 box to the NT4 box while
logged in with an admin account of the 2003 box. I am also able to run a
..vbs script on the 2003 box that is able to place a text file on the NT4
box. Of course, I do believe that script runs and creates the file system
object as the logged in user of the 2003 box.

Now to the non-working part. On my asp.net and classic asp page I am unable
to write a text file from the 2003 box to the NT4 box at all. The virtual
server(s) that are serving the pages have anon security turned on and use
the IUSR_MachineName account. Since I have every permission imaginable added
to the folder on the NT4 box for both domains at full control. My theory is
that possibly the IUSR account is the account that is actually creating the
object and trying to place the text file. I only theorize this because I can
not place the text file and that account seems to be the only one w/o
permissions to that folder since it is a local machine account and not a
domain account.

So my real question here is if my theory is right and/or what exactly is
going on here. After spending much too long on this problem and feeling like
a noob I am at a loss as to what to try next. Any suggestion would be
greatly appreciated.

Thank you)
Nov 18 '05 #1
2 1402
The crux of this is that the user under which you try to access the remote
dir must be the same user that your script is running as. This become a
real pain when you tie this in with permissions across domains. So, on your
win3k box you need to impersonate in asp.net the user with permissions and
allow asp.net to run on behlaf of that trusted user. I've not tried it
between trusted domains, but it will be a pain I expect.

Why dont you cut your losses and pass the text as a post request to your NT4
web server and have asp create the file for you on the NT 4 box.

--
Regards

John Timney
Microsoft Regional Director
Microsoft MVP
"Brian Cooper" <co*****@ingrambarge.com> wrote in message
news:Qt*****************@bignews4.bellsouth.net...
I am trying to determine a permission problem trying to write a text file
from one web server to another.

Here is the situation:

We have two domains in place one is Active Directory and the other is an old NT4 domain. These two domains have a trust between them.

On a 2003 server I am using the file system object to write a text file to a NT4 web server. The folder on the NT 4 server currently is shared with open security with control for everyone on Domain1 and Domain2. The 2003 server's worker process is running under a domain account that has full access to the folder.

I am able to map a drive to the share from the 2003 box to the NT4 box while logged in with an admin account of the 2003 box. I am also able to run a
.vbs script on the 2003 box that is able to place a text file on the NT4
box. Of course, I do believe that script runs and creates the file system
object as the logged in user of the 2003 box.

Now to the non-working part. On my asp.net and classic asp page I am unable to write a text file from the 2003 box to the NT4 box at all. The virtual
server(s) that are serving the pages have anon security turned on and use
the IUSR_MachineName account. Since I have every permission imaginable added to the folder on the NT4 box for both domains at full control. My theory is that possibly the IUSR account is the account that is actually creating the object and trying to place the text file. I only theorize this because I can not place the text file and that account seems to be the only one w/o
permissions to that folder since it is a local machine account and not a
domain account.

So my real question here is if my theory is right and/or what exactly is
going on here. After spending much too long on this problem and feeling like a noob I am at a loss as to what to try next. Any suggestion would be
greatly appreciated.

Thank you)

Nov 18 '05 #2
Hi,

ASP.NET by default does not impersonate the logged on user, but rather runs under the local ASPNET account, which is a least privliedged account. In order to have the ASP.NET application impersonate the original caller you must set imperonsation to true, and authorization mode to Windows in your Web.Config. You also have to set Windows Integrated Security in IIS. After this is done, if the logged on use has access to the shared folder, there should be no problem accessing it.

Another thing also, is that you mentioned you are using the File System Object in Classic asp to access the share. If this is the case, then this object does not understand UNC paths within a web application, this may be your problem. Try using another object if possible.

hope this helps,

sivilian

"Brian Cooper" wrote:
I am trying to determine a permission problem trying to write a text file
from one web server to another.

Here is the situation:

We have two domains in place one is Active Directory and the other is an old
NT4 domain. These two domains have a trust between them.

On a 2003 server I am using the file system object to write a text file to a
NT4 web server. The folder on the NT 4 server currently is shared with open
security with control for everyone on Domain1 and Domain2. The 2003 server's
worker process is running under a domain account that has full access to the
folder.

I am able to map a drive to the share from the 2003 box to the NT4 box while
logged in with an admin account of the 2003 box. I am also able to run a
..vbs script on the 2003 box that is able to place a text file on the NT4
box. Of course, I do believe that script runs and creates the file system
object as the logged in user of the 2003 box.

Now to the non-working part. On my asp.net and classic asp page I am unable
to write a text file from the 2003 box to the NT4 box at all. The virtual
server(s) that are serving the pages have anon security turned on and use
the IUSR_MachineName account. Since I have every permission imaginable added
to the folder on the NT4 box for both domains at full control. My theory is
that possibly the IUSR account is the account that is actually creating the
object and trying to place the text file. I only theorize this because I can
not place the text file and that account seems to be the only one w/o
permissions to that folder since it is a local machine account and not a
domain account.

So my real question here is if my theory is right and/or what exactly is
going on here. After spending much too long on this problem and feeling like
a noob I am at a loss as to what to try next. Any suggestion would be
greatly appreciated.

Thank you)

Nov 18 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

15
6828
by: lkrubner | last post by:
I want to give users the power to edit files from an easy interface, so I create a form and a PHP script called "fileUpdate". It does a reasonable about of error checking and prints out some...
0
2316
by: Fran Tirimo | last post by:
I am developing a small website using ASP scripts to format data retrieved from an Access database. It will run on a Windows 2003 server supporting FrontPage extensions 2002 hosted by the company...
2
3926
by: Fran Tirimo | last post by:
I am developing a small website using ASP scripts to format data retrieved from an Access database. It will run on a Windows 2003 server supporting FrontPage extensions 2002 hosted by the company...
2
2456
by: K Finegan | last post by:
I have an archival process on a large database that runs once a month. At the beginning of the process the triggers and indexes on the tables whose data is moved are dropped, the data is moved and...
1
4339
by: Chris | last post by:
I have seen the posts on various places on the internet about .NET framework mismatch issues and I don't think that is my problem. ; ) When I execute the following C++.NET code: String...
9
10860
by: Ben Dewey | last post by:
Project: ---------------------------- I am creating a HTTPS File Transfer App using ASP.NET and C#. I am utilizing ActiveDirectory and windows security to manage the permissions. Why reinvent...
3
4420
by: palepimp | last post by:
Hello all, I have searched far and wide for a solution to my issue. In short, here is the problem: 1. 3 PC's enter data into an Access 2003 database (PC's are running Vista w/ Office 2007...
3
12035
by: Mike | last post by:
Hi I have problem as folow: Caught Exception: System.Configuration.ConfigurationErrorsException: An error occurred loading a configuration file: Request for the permission of type...
6
3243
by: DotNetNewbie | last post by:
Hello, in my web application, I have to create permissions for each user. So what I am doing is that for each role (using sqlmembership in .net) I am creating a column in the database to hold a...
13
2639
by: eclipsme | last post by:
I thought I had this licked, but apparently not. I have a file upload script that attempts to upload a file to a directory in the public_html directory - www.domain.com/upload The permissions...
0
7237
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7137
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
1
7073
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
5656
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
4732
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3207
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1571
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
779
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
443
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.