
CScript execution privileges on WinNT4.0
CScript and WScript both run in the same security context of whatever starts them. It doesn't
change the security context in any way. Scripts executed by an interactive user can do whatever
that user's security credentials allow. Scripts executed by any sort of scheduling tool (the AT
command, Scheduled Tasks, Norton Scheduler, etc.) run either under a fixed account (e.g., At command
and Norton's scheduler are like this, using the local SYSTEM account by default) but Schedule Tasks
lets you configure each task with different credentials. AFAIK, under NT, newly created
folders/files inherit the ACLs of the parent folder. The script hosts themselves don't have any
effect on that.
--
Michael Harris
MVP Scripting
Hi,
I have a Jscript script file that I run using cscript at a DOS prompt in
WinNt4.0. The script creates a directory at runtime. This directory is
used to store log files generated by a program that the script starts.
However, the program fails because it cannot save files in the directory
that has been created.
On further investigation, I discovered that the permissions on the
generated directory were insufficient for the called program to create
files in it. What I want to know is:
What privileges is cscript being run under?
How do they affect the permissions attached to folders/files created
by a script?
How can I change those privileges to allow me to create files in my
generated directory?
Any help would be much appreciated.