Re: ASP.Net 1.1, Win 2003, IIS6, System.Diagnostics.Process, run notep
- From: Dominick Baier [DevelopMentor] <dbaier@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Tue, 14 Mar 2006 13:16:47 +0000 (UTC)
hi,
so what are you expecting to see?
Notepad popping up on the server?
This won't work - service demons run in a so called "WindowsStation" and are not allowed to display an UI or similar...normal non UI processing should work...
---------------------------------------
Dominick Baier - DevelopMentor
http://www.leastprivilege.com
There are tons of posts on this and I have read them all at least
twice, but still am having trouble. For now, never mind security, if I
can get this to work, I'll start re-applying restrictions.
Goal: Run an exe file, like Notepad.exe, from ASP.NET 1.1, on a Win
2003 Server
I have:
Set the application Pool identity to LocalSystem (I am running in
native
IIS6 worker Process Isolation mode)
Set the user in machine.config to "SYSTEM" (Yeah, I know this is
ignored
under native IIS6)
Set the Anonymous user to Administrator (bad, I know, just show me
notepad)
Set the IIS Service to "Allow service to interact with desktop"
Given Everyone (and their brother) full access to system32
Made IUSER_machinename a member of Administrators
Is there some way to just turn freakin secruity OFF?
I CAN:
Start Notepad on my XP development box, using the code below in the
"I
CAN'T section", no problemo.
on 2003, Successfully Run the testexe.bat directly from the OS,
starting
Notepad.
On 2003, Successfully run a .BAT file that copys a file. VB.net
snippet
below
Dim oProcess As New System.Diagnostics.Process
oProcess.StartInfo.WorkingDirectory = "C:\inetpub\wwwroot\TestBed"
'set working dir
oProcess.StartInfo.FileName =
"C:\Inetpub\wwwroot\TestBed\testcopy.bat"
'filespec of the bat file
oProcess.StartInfo.Arguments = Now().Ticks
'for unique filename
oProcess.StartInfo.UseShellExecute = False
'runs in background
oProcess.Start()
'runs the process
oProcess.Close()
I CAN'T
Get Notepad (or the exe I really want) to run on 2003, using the VB
code
below:
Dim oProcess As New System.Diagnostics.Process
Dim sCommand As String = "testexe.bat" 'this file just
has:
notepad.exe testfile.txt
oProcess.StartInfo.WorkingDirectory = "C:\inetpub\wwwroot\TestBed"
'set working dir
oProcess.StartInfo.FileName = sCommand
oProcess.Start()
oProcess.Close()
I am so close, yet so far! Any help will be very much appreciated.
My next step is to pay for and MS support issue, which, actually
sounds like a great idea right now!
TIA,
Tracy Spratt
.
- Follow-Ups:
- Prev by Date: Re: Extracting certificate from the smart card thru cryptoApi in c#
- Next by Date: Re: FileLoadException when running app with Impersonate from network folder.
- Previous by thread: Re: Extracting certificate from the smart card thru cryptoApi in c#
- Next by thread: Re: ASP.Net 1.1, Win 2003, IIS6, System.Diagnostics.Process, run notep
- Index(es):
Relevant Pages
|