WMI002-WMI学习笔记(二)——Win32_Account类
来源:互联网 发布:java开源的工作流引擎 编辑:程序博客网 时间:2024/06/05 19:34
原文链接:
http://msdn.microsoft.com/en-us/library/aa394061(v=vs.85).aspx
测试代码:
http://blog.csdn.net/eyuanatqqdotcom/article/details/7462720
Applies to: desktop apps only
应用于:桌面应用程序
The Win32_Account abstract WMI class contains information about user accounts and group accounts known to the computer system running Windows. User or group names recognized by a Windows NT domain are descendants (or members) of this class.
The following syntax is simplified from Managed Object Format (MOF) code and includes all of the inherited properties. Properties are listed in alphabetic order, not MOF order.
Win32_Account 包含关于用户账户和组(域)账户信息的信息。
以下是Managed Object Format (MOF)管理对象格式的原型,以及所有的属性,属性安装字母顺序列出。
Syntax
class Win32_Account : CIM_LogicalElement{ string Caption; string Description; string Domain; datetime InstallDate; boolean LocalAccount; string Name; string SID; uint8 SIDType; string Status;};
Members
The Win32_Account class has these types of members:
- Properties
Properties
The Win32_Account class has these properties.
包含以下属性:- Caption
- 标题
- Data type: string
- 数据类型:string
- Access type: Read-only
- 访问类型:只读
- Qualifiers: MaxLen (64)
Short description of the object. This property is inherited from the CIM_ManagedSystemElement class.
- Description
- 描述
- Data type: string
- 数据类型:string
- Access type: Read-only
- 访问类型:只读
Description of the object. This property is inherited from the CIM_ManagedSystemElement class.
- Domain
- 域
- Data type: string
- Access type: Read-only
- Qualifiers: Key
- 类型:键
Name of the Windows domain to which a group or user belongs.
用户或者用户组属于的Windows域
Example: "NA-SALES"
- InstallDate
- 安装日期(建立日期)
- Data type: datetime
- 数据类型:日期/时间
- Access type: Read-only
Date and time that the object was installed. This property does not require a value to indicate that the object is installed. This property is inherited from theCIM_ManagedSystemElement class.
- LocalAccount
- [是否是]本地账户
- Data type: boolean
- 数据类型:boolean
- Access type: Read-only
If TRUE, the account is defined on the local machine. To retrieve only accounts defined on the local machine, design a query that includes the condition "LocalAccount=TRUE".
如果值为真,则账号为本地账号。
仅仅检索本地账号时,可以在查询语句中加入条件"LocalAccount=TRUE"(是否是本地账户=是)。
Windows 2000 and Windows NT 4.0 with SP4 and later: This property is not available.- Name
- [账号]名称
- Data type: string
- Access type: Read-only
- Qualifiers: Key
- 类型:键
Name of the Windows system account on the domain specified by the Domain property of this class. This property overrides the Name property inherited fromCIM_ManagedSystemElement.
域中的Windows系统账号,由域属性指定。
- SID
- 安全ID
- Data type: string
- Access type: Read-only
Security identifier (SID) for this account. A SID is a string value of variable length used to identify a trustee. Each account has a unique SID issued by an authority (such as a Windows domain), stored in a security database. When a user logs on, the system retrieves the user's SID from the database and places it in the user's access token. The system uses the SID in the user's access token to identify the user in all subsequent interactions with Windows security. When a SID has been used as the unique identifier for a user or group, it cannot be used again to identify another user or group.
账号的安全标识符。
可变长的字符串值,用于标识账户。
每一个账号的SID值唯一,由认证者指定(例如Windows域),并被保存在安全数据库中。
- SIDType
- Data type: uint8
- Access type: Read-only
Enumerated values that specify the type of security identifier (SID).
SID的类型标识值的枚举。
- SidTypeUser (1)
- 用户
- SidTypeGroup (2)
- 组
- SidTypeDomain (3)
- 域
- SidTypeAlias (4)
- 别名
- SidTypeWellKnownGroup (5)
- 熟知域
- SidTypeDeletedAccount (6)
- 已删除账户
- SidTypeInvalid (7)
- 合法
- SidTypeUnknown (8)
- 未知
- SidTypeComputer (9)
- 计算机
- Status
- 状态
- Data type: string
- Access type: Read-only
Current status of the object. Various operational and nonoperational statuses can be defined. Operational statuses include: "OK", "Degraded", and "Pred Fail" (an element, such as a SMART-enabled hard disk drive, may be functioning properly but predicts a failure in the near future). Nonoperational statuses include: "Error", "Starting", "Stopping", and "Service". The latter, "Service", can apply during mirror-resilvering of a disk, reload of a user permissions list, or other administrative work. Not all such work is online, yet the managed element is neither "OK" nor in one of the other states.
This property is inherited from the CIM_ManagedSystemElement class.
对象的当前状态。
The values are:
"OK"
"Error"
"Degraded"
"Unknown"
"Pred Fail"
"Starting"
"Stopping"
"Service"
Remarks
The Win32_Account class is derived from CIM_LogicalElement.
Examples
For script code examples, see WMI Tasks for Scripts and Applications and the TechNet ScriptCenter Script Repository.
For C++ code examples, see WMI C++ Application Examples.
For script code examples, see WMI Tasks for Scripts and Applications and the TechNet ScriptCenter Script Repository.
For example code, see WMI C++ Application Examples.
Requirements
Minimum supported client
Minimum supported server
Namespace
\root\CIMV2
MOF
- Cimwin32.mof
DLL
- Cimwin32.dll
See also
- Operating System Classes
- WMI002-WMI学习笔记(二)——Win32_Account类
- WIM010-WIM学习笔记(十)——Win32_Account类属性(简单)
- WMI004-WMI学习笔记(四)——Managing Applications Using WMI(使用WMI管理应用程序)
- WMI005-WMI学习笔记(五)——Using WMI with the .NET Framework(.NET框架使用WMI)
- WMI001-WMI学习笔记(一)——引言
- WMI012-WMI学习笔记(十二)——Win32_ApplicationService
- WMI013-WMI学习笔记(十三)——Win32_Desktop
- WMI011-WMI学习笔记(十一)——Win32_ApplicationService(应用程序服务)类
- WMI012-WMI学习笔记(十二)——Win32_Desktop(桌面)类
- WMI006-WMI学习笔记(六)——Schemas(模式(.NET))
- WMI007-WMI学习笔记(七)——Queries(查询(.NET))
- WMI003-WMI学习笔记(三)——Windows Management Instrumentation(Windows管理工具)
- WMI008-WMI学习笔记(八)——Management Events(管理事件)
- 学习笔记-WMI了解
- wmi学习笔记
- WMI009-WMI学习笔记(九)——System.Management and System.Management.Instrumentation Namespaces(命名空间)
- wmi 学习笔记之获得系统版本
- wmi 学习笔记之获得系统版本
- vfork和fork的区别
- ubuntu8.04下安装sis661/741/760显卡驱动
- 数据对齐 posix_memalign 函数详解
- ubuntu修改mac地址
- 解决sqlite3插入数据很慢的问题
- WMI002-WMI学习笔记(二)——Win32_Account类
- 关闭ubuntu终端的BELL声音
- windows phone 7 长按listbox的item,并弹出菜单操作
- 实时连接器ld.so.1文件损坏或丢失后系统怎样恢复正常!
- STAThread和MTATHread
- 第九周 任务三
- 笔记本电脑键盘失效修复方法,我搞了好久
- Java核心技术 卷I 手记(二)
- TCP/IP