Jump to content

Can I konw Process's User name


Recommended Posts

Hi!

Use "Processlist" function,I can know the image name and PID about runnning process.

But if i want to know "user name" of process ,what function i can use.

ps.

Svchost.exe mostly appears as Local Service or Network Services or System in Task manager.

I want to write a script to judge that "svchost.exe" 's user name is Current logon user or System .

So I can terminate the "svchost.exe " by the function "processclose".

Thanks for Everybody's Reply.

Link to comment
Share on other sites

Check This...

The wheel is already invented :D

Services UDF

Cheers

Old Scriptology

Visual Ping 1.8 - Mass Ping Program with export to txt delimited.

Desktop 2 RGB and YMCK - Pick a color in the desktop and get the RGB and YMCK code.

Desktop 2 RGB - Pick a color in the desktop and get the RGB code.

ShootIT 1.0 - Screen Capture full and partial screen

[font="'Arial Black';"]Remember Remember The Fifth of November.[/font]

Link to comment
Share on other sites

Hi!

Use "Processlist" function,I can know the image name and PID about runnning process.

But if i want to know "user name" of process ,what function i can use.

ps.

Svchost.exe mostly appears as Local Service or Network Services or System in Task manager.

I want to write a script to judge that "svchost.exe" 's user name is Current logon user or System .

So I can terminate the "svchost.exe " by the function "processclose".

Thanks for Everybody's Reply.

If you still want the owner of the process, try _ProcessListProperties(). It gives the owner in [n][3] of the array, or you can just study how it works and extract the usage of $oProc.GetOwner() from it.

:D

Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...