MBS Xojo Developer Conference and Training
Join us from 11th to 14th September 2013 in Koblenz.
Join us from 11th to 14th September 2013 in Koblenz.
Platforms to show: All Mac Windows Linux Cross-Platform
WindowsWMIMBS class
Super class: WMIObjectMBS
class, Windows,
MBS Real Studio Win Plugin
(WindowsWMI),
class WindowsWMIMBS,
Plugin version: 7.4, Mac: No, Win: Yes, Linux: No, Console & Web: Yes, Feedback.
Function: A class to run queries in the Windows Management Interface.
Example:
Notes:
Subclass of the WMIObjectMBS class.
Plugin version: 7.4, Mac: No, Win: Yes, Linux: No, Console & Web: Yes, Feedback.
Function: A class to run queries in the Windows Management Interface.
Example:
dim w as WindowsWMIMBS
w=new WindowsWMIMBS
if w.ConnectServer("root\cimv2") then
MsgBox "ConnectServer: ok"
if w.query("WQL","SELECT * FROM Win32_Processor") then
MsgBox "query: ok"
if w.NextItem then
MsgBox "NextItem: ok"
MsgBox w.GetPropertyString("Name") // string
MsgBox str(w.GetPropertyInteger("MaxClockSpeed")) // uint32
MsgBox str(w.GetPropertyInteger("ProcessorType")) // uint16
else
MsgBox "NextItem: fail"
end if
else
MsgBox "query: fail"
end if
else
MsgBox "ConnectServer: fail"
end if
- property EnumeratorHandle as Integer
- property LocatorHandle as Integer
- property ServiceHandle as Integer
- method CancelAsyncCall as boolean
- method ConnectServer(NetworkResource as string, Username as string="", Password as string="", Locale as string="", Authority as string="") as boolean
- method Constructor
- method ExecNotificationQueryAsync(QueryLanguage as string, QueryText as string) as boolean
- method InitAuthentication(User as string, Domain as string, Password as string) as boolean
- shared method InitSecurity(AuthnLevel as integer, ImpLevel as integer) as boolean
- shared method InitSecurity(remote as boolean) as boolean
- method NextItem as boolean
- method Query(QueryLanguage as string, QueryText as string) as boolean
Authentication Level
| Constant | Value | Description |
|---|---|---|
| kAuthenticationLevelCall | 3 |
Authenticates only at the beginning of each remote procedure call when the server receives the request. Datagram transports use kAuthenticationLevelPaket instead. |
| kAuthenticationLevelConnect | 2 |
Authenticates the credentials of the client only when the client establishes a relationship with the server. Datagram transports always use kAuthenticationLevelPacket instead. |
| kAuthenticationLevelDefault | 0 |
Tells DCOM to choose the authentication level using its normal security blanket negotiation algorithm. For more information, see Security Blanket Negotiation. |
| kAuthenticationLevelNone | 1 |
Performs no authentication. |
| kAuthenticationLevelPacket | 4 |
Authenticates that all data received is from the expected client. |
| kAuthenticationLevelPacketIntegrity | 5 |
Authenticates and verifies that none of the data transferred between client and server has been modified. |
| kAuthenticationLevelPacketPrivacy | 6 |
Authenticates all previous levels and encrypts the argument value of each remote procedure call. |
Impersonation Level Constants
| Constant | Value | Description |
|---|---|---|
| kImpersonationLevelAnonymous | 1 |
The client is anonymous to the server. The server process can impersonate the client, but the impersonation token will not contain any information and cannot be used. |
| kImpersonationLevelDefault | 0 |
DCOM can choose the impersonation level using its normal security blanket negotiation algorithm. For more information, see Security Blanket Negotiation. |
| kImpersonationLevelDelegate | 4 |
The server process can impersonate the client's security context while acting on behalf of the client. The server process can also make outgoing calls to other servers while acting on behalf of the client, using cloaking. The server may use the client's security context on other machines to access local and remote resources as the client. When impersonating at this level, the impersonation token can be passed across any number of computer boundaries. |
| kImpersonationLevelIdentity | 2 |
The server can obtain the client's identity. The server can impersonate the client for ACL checking, but it cannot access system objects as the client. |
| kImpersonationLevelImpersonate | 3 |
The server process can impersonate the client's security context while acting on behalf of the client. This level of impersonation can be used to access local resources such as files. When impersonating at this level, the impersonation token can only be passed across one machine boundary. The Schannel authentication service only supports this level of impersonation. |
Super class WMIObjectMBS
- property Handle as Integer
- property Lasterror as Integer
- method GetNames as string()
- method GetProperty(Name as string) as variant
- method GetPropertyDouble(Name as string) as double
- method GetPropertyInt64(Name as string) as Int64
- method GetPropertyInteger(Name as string) as integer
- method GetPropertyObject(Name as string) as WMIObjectMBS
- method GetPropertyString(Name as string) as string
- method GetPropertyStringArray(Name as string) as string()
- method GetPropertyType(Name as string) as integer
- method GetPropertyTypeString(Name as string) as string
This class has no sub classes.
Some examples which use this class:
- /Win/WMI Process Creation Events via Remote
- /Win/WMI/WMI File Events
- /Win/WMI/WMI HDD Info
- /Win/WMI/WMI Network Test
- /Win/WMI/WMI Process Creation Events
- /Win/WMI/WMI Processor
- /Win/WMI/WMI Query
- /Win/WMI/WMI Recent Windows Events
- /Win/WMI/WMI Recent Windows Events Web
- /Win/WMI/WMI Wireless LAN Signal Strength
The items on this page are in the following plugins: MBS Real Studio Win Plugin.
Links
MBS Xojo Plugins