帐户配置服务提供程序Accounts Configuration Service Provider

企业 (1) 使用帐户配置服务提供程序 (CSP) 重命名设备 (2) 以创建新的本地 Windows 帐户并将其加入本地用户组。The Accounts configuration service provider (CSP) is used by the enterprise (1) to rename a device, (2) to create a new local Windows account and join it to a local user group. 此 CSP 已添加到 Windows 10 版本 1803 中。This CSP was added in Windows 10, version 1803.

下面以树格式显示 Accounts 配置服务提供程序。The following shows the Accounts configuration service provider in tree format.

./Device/Vendor/MSFT
Accounts
----Domain
--------ComputerName
----Users
--------UserName
------------Password
------------LocalUserGroup

./Device/Vendor/MSFT/Accounts./Device/Vendor/MSFT/Accounts
根节点。Root node.

Domain
帐户域信息的内部节点。Interior node for the account domain information.

Domain/ComputerNameDomain/ComputerName
此节点指定设备的 DNS 主机名。This node specifies the DNS hostname for a device. 此设置可以远程管理,但请注意,加入 Azure Active Directory 和本地 Active Directory 的设备混合不支持此设置。This setting can be managed remotely, but note that this not supported for devices hybrid joined to Azure Active Directory and an on-premises Active directory. 服务器必须显式重新启动设备,此值才能生效。The server must explicitly reboot the device for this value to take effect. 可以在值中嵌入几个宏以用于动态替换。A couple of macros can be embedded within the value for dynamic substitution. 使用这些宏之一将新名称限制为 15 个字符。Using any of these macros will limit the new name to 15 characters.

可用的命名宏:Available naming macros:

Macro 说明Description 示例Example 生成的名称Generated Name
%RAND:<位的>%RAND:<# of digits> 生成指定数量的随机数字。Generates the specified number of random digits. Test%RAND:6%Test%RAND:6% Test123456Test123456
%SERIAL%%SERIAL% 生成从设备派生的序列号。Generates the serial number derived from the device. 如果序列号导致新名称超出 15 个字符的限制,则序列号将被从序列的开头截断。If the serial number causes the new name to exceed the 15 character limit, the serial number will be truncated from the beginning of the sequence. Test-Device-%SERIAL%Test-Device-%SERIAL% Test-Device-456Test-Device-456

支持的操作是 Add。Supported operation is Add.

备注

对于 Windows 10 版本 2004 或更高版本上的桌面电脑,请使用DevDetail CSP中的Ext/Microsoft/DNSComputerName节点。For desktop PCs on Windows 10, version 2004 or later, use the Ext/Microsoft/DNSComputerName node in DevDetail CSP.

用户Users
用户帐户信息的内部节点。Interior node for the user account information.

Users/UserNameUsers/UserName
此节点指定新本地用户帐户的用户名。This node specifies the username for a new local user account. 此设置可以远程管理。This setting can be managed remotely.

用户/用户名/密码Users/UserName/Password
此节点指定新本地用户帐户的密码。This node specifies the password for a new local user account. 此设置可以远程管理。This setting can be managed remotely.

支持的操作是 Add。Supported operation is Add. 不支持 GET 操作。GET operation is not supported. 从终结点管理器部署时,此设置将报告为失败。This setting will report as failed when deployed from the Endpoint Manager.

Users/UserName/LocalUserGroupUsers/UserName/LocalUserGroup
此可选节点指定应加入本地用户帐户的本地用户组。This optional node specifies the local user group that a local user account should be joined to. 如果未设置节点,则新的本地用户帐户将仅加入标准用户组。If the node is not set, the new local user account is joined just to the Standard Users group. 将此值设置为 2 管理员组。Set the value to 2 for Administrators group. 此设置可以远程管理。This setting can be managed remotely.

支持的操作是 Add。Supported operation is Add.