summaryrefslogtreecommitdiffstats
path: root/testprogs/win32/wmi
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2005-04-12 01:14:54 +0000
committerJelmer Vernooij <jelmer@samba.org>2005-04-12 01:14:54 +0000
commit817b356a381b8cdc49b05e4923010957e399b422 (patch)
treee502c8affcf3b90850d24e08ca6334948764c86b /testprogs/win32/wmi
parentdff3497147166a2417a37246a646a180fa216ffa (diff)
downloadsamba-817b356a381b8cdc49b05e4923010957e399b422.tar.gz
samba-817b356a381b8cdc49b05e4923010957e399b422.tar.xz
samba-817b356a381b8cdc49b05e4923010957e399b422.zip
r6306: Add simple WMI client test script
Diffstat (limited to 'testprogs/win32/wmi')
-rwxr-xr-xtestprogs/win32/wmi/echoprocessor.vbs10
1 files changed, 10 insertions, 0 deletions
diff --git a/testprogs/win32/wmi/echoprocessor.vbs b/testprogs/win32/wmi/echoprocessor.vbs
new file mode 100755
index 00000000000..8ce6f7adcd1
--- /dev/null
+++ b/testprogs/win32/wmi/echoprocessor.vbs
@@ -0,0 +1,10 @@
+For Each Host In WScript.Arguments
+ Set WMIservice = GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & host & "\root\cimv2")
+
+ Set colsettings = WMIservice.ExecQuery("SELECT * FROM Win32_Processor")
+
+
+ For Each proc In colsettings
+ Wscript.Echo(host & ": " & proc.description)
+ Next
+Next