Since I can't leave you like this,
Here's an example that uses the sys.COM object to interact with WMI :
local sys = require "sys"
local locator = sys.COM("WbemScripting.SWbemLocator")
local wmi = locator:ConnectServer(".", "root\\cimv2")
if wmi then
local results = wmi:ExecQuery("SELECT * FROM Win32_Processor")
print("Number of processors found: " .. tostring(results.Count))
print(results:ItemIndex(0).Name)
end