Re: Calling a batch file from IE using asp and vbscript
From: Aaron [SQL Server MVP] (ten.xoc_at_dnartreb.noraa)
Date: 12/29/04
- Next message: Bob Barrows [MVP]: "Re: DCom got error Overlapped I/O operation is in progress....."
- Previous message: Mark C.: "Re: Calling a batch file from IE using asp and vbscript"
- In reply to: Mark C.: "Re: Calling a batch file from IE using asp and vbscript"
- Next in thread: Mark C.: "Re: Calling a batch file from IE using asp and vbscript"
- Reply: Mark C.: "Re: Calling a batch file from IE using asp and vbscript"
- Messages sorted by: [ date ] [ thread ]
Date: Wed, 29 Dec 2004 18:04:40 -0500
Does your batch file call any code that raises a prompt or other kind of
visible GUI? Have you looked at http://www.aspfaq.com/2059 ?
I don't know if I can explain the scheduled task process better without
actually building it. That's on my to do list...
-- http://www.aspfaq.com/ (Reverse address to reply.) "Mark C." <MarkC@discussions.microsoft.com> wrote in message news:7413D8EC-576A-4D01-BE3F-5DB096A89BA4@microsoft.com... > Aaron, > > Thanks very much for your response. Unfortunately, I had already tried > using Windows Integrated Authentication while using a privileged account and > I tried changing the account from IUSR_MachineName to a privileged network > account and neither option worked. The app seems to run, the batch file is > created, but it fails to run. As a workaround I have been using a scheduled > task to run the file at the top of every hour but now a different sort of > security concern having to do w/ our portal software renders my scheduled > task obsolete. Could you be kind enough to elaborate on your solution w/ the > database/queue and the scheduled task. I'm not quite sure that I understand > what you're getting at. Thanks again. > > "Aaron [SQL Server MVP]" wrote: > > > The problem is that IIS runs ASP pages by default in the context of > > IUSR_machineName, a very low-level user with few privileges and virtually no > > system access. > > > > You need to either set the IIS application to run in the context of a > > privileged user, change the application to run as windows authenticated and > > not anonymous (and then authenticate as a privileged user), or add > > IUSR_machineName to a group with enough privileges to execute the batch > > file. > > > > Of course, each of these options can potentially become a security hole > > without proper precautions. > > > > So, what I tend to recommend in cases like this is to add the requested task > > to a queue (e.g. in a database), and have a scheduled task wake up and pick > > up new tasks from the queue. Then you don't have to worry about the > > privileges you're exposing directly to your web page, and you can easily set > > the job to run in the context of any user you like and on any schedule you > > like... > > > > -- > > http://www.aspfaq.com/ > > (Reverse address to reply.) > > > > > > > > > > "Mark C." <MarkC@discussions.microsoft.com> wrote in message > > news:73A73B56-C105-4B6C-98F5-E0C6B509AA38@microsoft.com... > > > I'm trying to call a batch file that I've built using the FileSystemObject > > > and CreateObject("Wscript.Shell"), oShell.Run... in an asp script. > > > Naturally, I can get the script to work from a command line but not from a > > > browser. The page does not throw an error but the oShell.Run... portion > > of > > > the script doesn't run. Any help would be appreciated. Thanks. > > > > > >
- Next message: Bob Barrows [MVP]: "Re: DCom got error Overlapped I/O operation is in progress....."
- Previous message: Mark C.: "Re: Calling a batch file from IE using asp and vbscript"
- In reply to: Mark C.: "Re: Calling a batch file from IE using asp and vbscript"
- Next in thread: Mark C.: "Re: Calling a batch file from IE using asp and vbscript"
- Reply: Mark C.: "Re: Calling a batch file from IE using asp and vbscript"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|