Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

23 lines
502 B

use OLE;
use Win32;
$locator = CreateObject OLE 'WbemScripting.SWbemLocator';
$services = $locator->ConnectServer();
$enumerator = $services->InstancesOf("Win32_process");
use Win32::OLE::Enum;
$processes = Win32::OLE::Enum->new ($enumerator);
while ($process = $processes->Next()) {
print "Process: $process->{Name}\n";
$derivation = $process->{Derivation_};
$len = @$derivation;
print "The length of array: $len\n";
foreach $x (@$derivation) {
print "$x\n";
}
}