PxPlus User Forum

Twitter Twitter Twitter

Author Topic: INVOKE/SYS() rights on Windows  (Read 1145 times)

ChrisKCAi

  • Silver Member
  • ***
  • Posts: 38
    • View Profile
INVOKE/SYS() rights on Windows
« on: July 22, 2020, 02:08:05 PM »
Consider:
1.   I am logged on to a Windows server (via RDP) with an account that has admin rights.
2.   UAC is turned off.
3.   I run PxPlus (inside my RDP session) and use either INVOKE or the SYS function.
4.   Is the resultant operating system command run with my elevated/admin rights?
Anecdotal evidence would seem to indicate "yes" but I'm looking for a more definitive answer.

Mike King

  • Diamond Member
  • *****
  • Posts: 3810
  • Mike King
    • View Profile
    • BBSysco Consulting
Re: INVOKE/SYS() rights on Windows
« Reply #1 on: July 22, 2020, 04:41:19 PM »
Technically the INVOKE command will be run using the same userid as you logged on with and with the same rights.

This is much like if you run the Windows command mode from an admin userid.  To get full administrative rights you have to right click the shortcut and select 'Run as Administrator'.  Now if you started PxPlus with a "Run as Administrator" then anything you spawn will also be running as administrator.

If you want to be sure you are launching a system command in administrator mode try:

INVOKE CONTROL "command"

If PxPlus is not already running in Administrator mode the system will ask before running command.  If it is running in administrator mode, the command will simply be executed.
Mike King
President - BBSysco Consulting
eMail: mike.king@bbsysco.com

ChrisKCAi

  • Silver Member
  • ***
  • Posts: 38
    • View Profile
Re: INVOKE/SYS() rights on Windows
« Reply #2 on: July 24, 2020, 12:07:07 PM »
Does the SYS function have an equivalent to CONTROL? (doesn't appear to)

Mike King

  • Diamond Member
  • *****
  • Posts: 3810
  • Mike King
    • View Profile
    • BBSysco Consulting
Re: INVOKE/SYS() rights on Windows
« Reply #3 on: July 24, 2020, 02:13:40 PM »
No -- only the INVOKE provides for a CONTROL option.
Mike King
President - BBSysco Consulting
eMail: mike.king@bbsysco.com