Hi, After some googling I've found that there's very little said about the possibility of using WMI from Wine. Has someone done any progress about it? I find this subject very important; if you feel interested here's why: One may think this is a somehow fanciful intention, after all WMI exists for the purpouse of administering Windows, and no doubt that's best done from Windows. But, there are some applications that are best run under Linux and need or would benefit from having this kind of control over Windows. Think of the bunch of security services that run on Linux trying to give business class open source security solutions (snort, nessus, ipchains, etc.), and also one that I'm involved with now: Security Event Monitoring. They could do much more if they could natively reach the Windows systems they are inspecting and protecting. SEM solutions can't only be a place to collect logs, that's of very little use. They have to be able to rise alerts correlating events from the different logs, and should as well be able to act on an alert to protect against a "confirmed" attack (maybe temporarily disabling a Windows use account, or shutting down an unauthorized process, etc.). In the real world every organization has a bunch of Windows systems which are usually numerous and a special security concern, so if we want to see business class SEM solutions running on Linux, we need a straightforward way to monitor and act on Windows. Linux is a best fit platform for a SEM system, WINE runs WSH so we can run Windows native scripts from which to invoke Windows native commands; so we are only a step away from opening a lot of insteresting possibilities. Thanks a lot for your attention. Juan Alvarez __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com
On Wed, 01 Jun 2005 04:06:38 -0700, Juan Alvarez wrote:> After some googling I've found that there's very > little said about the possibility of using WMI from > Wine.IIRC WMI is based on DCOM, so our DCOM code would need a lot more work.
Hi Juan, this just worked by executing wine wscript test.vbs It showed me the desired four dialogs with version numbers only complaining that ADSI (Active Directory Scripting Interface?) is not installed. Tried also sokme other script from the scriptcenter which worked also. Regards Joachim von Thadden Am Mi, Jun 01, 2005 at 11:11:50 -0700 schrieb Juan Alvarez:> Simplest way to test WMI is running a simple script > with MSH (Microsoft Scripting Host). There are plenty > at MS scriptcenter > (http://www.microsoft.com/technet/scriptcenter/default.mspx). > This one here will check the version of WMI, and other > Windows components: > > (taken from > http://www.computerperformance.co.uk/Logon/WSH_Simple.htm): > > 'Script to display WSH, VBScript, WMI, and ADSI > versions > 'Script created by Guy Thomas > > On Error Resume Next > > WScript.Echo "WSH Version: " & WScript.Version > > Wscript.Echo "VBScript Version: " & > ScriptEngineMajorVersion _ > & "." & ScriptEngineMinorVersion > > strComputer = "." > Set objWMIService = GetObject("winmgmts:" _ > & "{impersonationLevel=impersonate}!\\" & strComputer > _ > & "\root\cimv2") > Set colWMISettings = objWMIService.ExecQuery _ > ("Select * from Win32_WMISetting") > For Each objWMISetting in colWMISettings > Wscript.Echo "WMI Version: " & > objWMISetting.BuildVersion > Next > > Set objShell = CreateObject("WScript.Shell") > strAdsiVersion = _ > objShell.RegRead("HKLM\SOFTWARE\Microsoft\Active > Setup\Installed > Components\{E92B03AB-B707-11d2-9CBD-0000F87A369E}\Version") > If strAdsiVersion = vbEmpty Then > strAdsiVersion > objShell.RegRead("HKLM\SOFTWARE\Microsoft\ADs\Providers\LDAP\") > If strAdsiVersion = vbEmpty Then > strAdsiVersion = "ADSI is not installed." > Else > strAdsiVersion = "2.0" > End If > End If > WScript.Echo "ADSI Version: " & strAdsiVersion > > > --- Joachim von Thadden <thadden@web.de> wrote: > > > Am Mi, Jun 01, 2005 at 01:25:17 +0100 schrieb Mike > > Hearn: > > > On Wed, 01 Jun 2005 04:06:38 -0700, Juan Alvarez > > wrote: > > > > After some googling I've found that there's very > > > > little said about the possibility of using WMI > > from > > > > Wine. > > > > > > IIRC WMI is based on DCOM, so our DCOM code would > > need a lot more work. > > > > I just made a short test (WineTools, native DCOM98) > > and with a little > > bit of luck it is installable and the testing app is > > running. But as I > > don't have any apps using the API I do not know > > whether it really works > > good. > > > > Regards > > Joachim von Thadden > > -- > > "Never touch a running system! Never run a touching > > system? > > Never run a touchy system!!!" > > > > > __________________________________________________ > Do You Yahoo!? > Tired of spam? Yahoo! Mail has the best spam protection around > http://mail.yahoo.com-- "Never touch a running system! Never run a touching system? Never run a touchy system!!!"