RUNAS usage:
RUNAS [[/noprofile |/profile] [/env] [/savecred |/netonly]]
/user: & lt; UserName> The program
RUNAS [[/noprofile |/profile] [/env] [/savecred]]
[/user/smartcard: & lt; UserName>] The program
RUNAS/trustlevel: & lt; TrustLevel> The program
.
I don't know where there is a problem
CodePudding user response:
Runas/user: FABBY \ wm20201105 "netsh advfirewall firewall rule name=" add SNMP UDP Port 161 In \ "dir=In action=allow protocol=UDP localport=161"CodePudding user response:
D: \ test> runas/?RUNAS usage:
RUNAS [[/noprofile |/profile] [/env] [/savecred |/netonly]]
/user: & lt; UserName> The program
RUNAS [[/noprofile |/profile] [/env] [/savecred]]
[/user/smartcard: & lt; UserName>] The program
RUNAS/trustlevel: & lt; TrustLevel> The program
/noprofile specified should not load the user's profile,
This will accelerate the application load, but
May cause some abnormal application is running,
/profile specified should load the user's profile,
This is the default value,
/env to use current environment instead of user's environment,
/netonly only at the specified credentials are limited to a remote access to use,
/savecred users previously saved credentials,
/smartcard if the credential is a smart card, use this option,
/user & lt; UserName> Should use the @ DOMAIN or DOMAIN \ USER
/showtrustlevels display can be used as a/trustlevel parameter
Level of trust,
/trustlevel & lt; Level> Should be enumerated in the/showtrustlevels
A level of
The program EXE command line, please refer to the following example
Example:
Runas/noprofile/user: mymachine \ administrator CMD
Runas/profile/env/user: mydomain \ admin "MMC % windir % \ system32 \ dsa. The MSC"
Runas/env/user:[email protected] "notepad " my file. TXT \ ""
Note: only when prompted, enter the user's password,
Note:/profile/netonly incompatibilities,
Note: with//savecred smartcard incompatible,