 |
SoftTree Technologies
Technical Support Forums
|
|
Author |
Message |
blang5
Joined: 30 Jun 2009 Posts: 3
|
|
Runas - Error #1314: A required privilege is not held.... |
|
Hi
I get this error,
Error #1314: A required privilege is not held by the client.
and it tells me to assign user account to certain rights..
I have added both source and target user accounts, (I know i didn't have to do both)
To all these rights in Local security policy (they are local accounts by the way, not network accounts)
"Act as part of the operating system"
"Create a token object"
"Log on as a batch job"
and I also added them to
"Replace a process level token"
even though that one wasn't listed as required.
But I still get the error.
%po% is the path to the program
C:\crp>runas \phil pwd %po%
RunAs version 2.2.1
Copyright (c) 2003-2007 SoftTree Technologies, Inc.
Logging in as \phil...
Setting user environment...
Logged in. Impersonating...
Starting process c:\program files\opera\opera.exe...
Error #1314: A required privilege is not held by the client.
Note: User account running RunAs must be assigned "Act as part of the operation
system" rights and also have "Create token" rights. User account used to run the
process must be assigned "Logon as a batch job" rights.
Last edited by blang5 on Wed Jul 01, 2009 6:03 pm; edited 1 time in total |
|
Tue Jun 30, 2009 8:35 pm |
|
 |
SysOp
Site Admin
Joined: 26 Nov 2006 Posts: 7949
|
|
|
|
Have you restarted the computer after changes in privileges?
|
|
Tue Jun 30, 2009 10:10 pm |
|
 |
blang5
Joined: 30 Jun 2009 Posts: 3
|
|
RunAs Parameter problem |
|
that solved that.. , thanks.
Though now I have some other problems with RunAs..
C:\Program Files>runas \phil pwd /V "opera\opera.exe"
that^^ it's ok with
it messes up the following, perhaps with the space in "program files"
C:\Program Files>runas \phil pwd /V "\program files\opera\opera.exe"
..
opera loads, but it tries to open http://files/opera/opera.exe so it's almost like it was passed something like files\opera\opera.exe
I had to do
C:\crp>runas \phil pwd /V "c:\progra~1\opera\opera.exe"
that works, though strange that spaces aren't recognized.
And here, this file, pera.bat, it's just empty, but whatever is in it, it doesn't load. To do with the space in "program files". Though it fails in a different way to program files opera. The bat doesn't load at all.
C:\Program Files>runas \phil pwd /I "\program files\opera\pera.bat"
..
'\program' is not recognized as an internal or external command,
operable program or batch file.
Process completed with exit code 1
With no space, it does work
C:\crp>runas \phil pwd /I "c:\progra~1\opera\pera.bat"
strange that they don't work and behave differntly too.. looks like space is just not meant to be used, not predictable. btw, is there another way to send a space, such that it is accepted?
Last edited by blang5 on Wed Jul 01, 2009 6:03 pm; edited 1 time in total |
|
Wed Jul 01, 2009 11:49 am |
|
 |
SysOp
Site Admin
Joined: 26 Nov 2006 Posts: 7949
|
|
|
|
You need to escape spaces. The value between double quotes repsent the entire command line with all the paramters if any. From RunAs point of view the first element in that command is the program name, the rest are parameters to be passed to that program.
If getting the complete command line properly escaped is difficult, please use an easy method - changing the current directory and running RunAs from there.
CD "c:\program files\opera"
C:\crp\runas .\phil password /V "opera.bat"
|
|
Wed Jul 01, 2009 1:35 pm |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|