自定义登录Custom Logon

可使用“自定义登录”功能禁止与欢迎屏幕和关机屏幕相关的 Windows 10 UI 元素。You can use the Custom Logon feature to suppress Windows 10 UI elements that relate to the Welcome screen and shutdown screen. 例如,可以禁止欢迎屏幕 UI 的所有元素并提供自定义登录 UI。For example, you can suppress all elements of the Welcome screen UI and provide a custom logon UI. 还可以禁止阻止的关机解析器 (BSDR) 屏幕并自动结束应用程序,同时操作系统等待应用程序关闭后才关机。You can also suppress the Blocked Shutdown Resolver (BSDR) screen and automatically end applications while the OS waits for applications to close before a shutdown.

自定义登录设置不会修改 Winlogon 的凭据行为,因此你可以使用与 Windows 10 兼容的任何凭据提供程序为设备提供自定义登录体验。Custom Logon settings do not modify the credential behavior of Winlogon , so you can use any credential provider that is compatible with Windows 10 to provide a custom sign-in experience for your device.

要求Requirements

Windows 10 企业版或 Windows 10 教育版。Windows 10 Enterprise or Windows 10 Education.

术语Terminology

启用 ,启用: 使该设置可用于设备,并(可选)将设置应用到设备。Turn on, enable: To make the setting available to the device and optionally apply the settings to the device. 通常在用户界面或控制面板中 使用,而 enable 用于命令行。Generally turn on is used in the user interface or control panel, whereas enable is used for command line.

配置: 自定义设置或子设置。Configure: To customize the setting or sub-settings.

嵌入的登录: 此功能在 Windows 10 版本1511中称为嵌入的登录。Embedded Logon: This feature is called Embedded Logon in Windows 10, version 1511.

自定义登录: 此功能在 Windows 10 版本1607及更高版本中称为 "自定义登录"。Custom Logon: This feature is called Custom Logon in Windows 10, version 1607 and later.

启用自定义登录Turn on Custom Logon

自定义登录是一个可选组件,在 Windows 10 中默认情况下不启用。Custom Logon is an optional component and is not turned on by default in Windows 10. 在配置之前,必须打开它。It must be turned on prior to configuring. 如果尚未安装 Microsoft Windows,可以在自定义的 Windows 10 映像 ( .wim) 中启用和配置自定义登录。You can turn on and configure Custom Logon in a customized Windows 10 image (.wim) if Microsoft Windows has not been installed. 如果 Windows 已安装,并且你要应用设置包来配置自定义登录,则必须首先启用自定义登录,以便成功应用预配包。If Windows has already been installed and you are applying a provisioning package to configure Custom Logon, you must first turn on Custom Logon in order for a provisioning package to be successfully applied.

"控制面板" 中提供了自定义登录功能。The Custom Logon feature is available in the Control Panel. 可以通过以下步骤设置自定义登录:You can set Custom Logon by following these steps:

在控制面板中打开 "自定义登录"Turn on Custom Logon in Control Panel

  1. 在 " 搜索 web 和 Windows " 字段中,键入 "打开或关闭 windows 功能 "。In the Search the web and Windows field, type Turn Windows features on or off.
  2. 在 " Windows 功能 " 窗口中,展开 " 设备锁定 " 节点,并选中或清除 " 自定义登录 " 复选框。In the Windows Features window, expand the Device Lockdown node, and select or clear the checkbox for Custom Logon.

使用 DISM 打开和配置自定义登录Turn on and configure Custom Logon using DISM

  1. 使用管理员权限打开命令提示符。Open a command prompt with administrator rights.

  2. 将 install 复制到硬盘上的临时文件夹 (在以下步骤中,我们假定它称为 C: \ wim) 。Copy install.wim to a temporary folder on hard drive (in the following steps, we'll assume it's called C:\wim).

  3. 创建一个新目录。Create a new directory.

    md c:\wim
    
  4. 装载映像Mount the image.

    dism /mount-wim /wimfile:c:\bootmedia\sources\install.wim /index:1 /MountDir:c:\wim
    
  5. 启用该功能。Enable the feature.

    dism /image:c:\wim /enable-feature /featureName:Client-EmbeddedLogon
    
  6. 提交更改。Commit the change.

    dism /unmount-wim /MountDir:c:\wim /Commit
    

使用无人参与配置自定义登录设置Configure Custom Logon settings using Unattend

你可以在 "设计" 或 "映像" 阶段配置 EmbeddedLogon 组件中的无人参与设置,以将自定义登录功能添加到映像。You can configure the Unattend settings in the Microsoft-Windows-Embedded-EmbeddedLogon component to add custom logon features to your image during the design or imaging phase. 可以手动创建无人参与应答文件或使用 Windows 系统映像管理器 (Windows SIM) 将相应的设置添加到答案文件中。You can manually create an Unattend answer file or use Windows System Image Manager (Windows SIM) to add the appropriate settings to your answer file. 有关自定义登录设置和 XML 示例的详细信息,请参阅 EmbeddedLogon 中的设置。For more information about the custom logon settings and XML examples, see the settings in Microsoft-Windows-Embedded-EmbeddedLogon.

下面的示例演示如何禁用所有 "欢迎屏幕 UI" 元素和 " 切换用户 " 按钮。The following example shows how to disable all Welcome screen UI elements and the Switch user button.

<settings pass="specialize">
    <component name="Microsoft-Windows-Embedded-EmbeddedLogon" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
      <BrandingNeutral>17</BrandingNeutral>
      <AnimationDisabled>1</AnimationDisabled>
      <NoLockScreen>1</NoLockScreen>
      <UIVerbosityLevel>1</UIVerbosityLevel>
      <HideAutoLogonUI>1</HideAutoLogonUI>
    </component>
</settings>

本节内容In this section

无品牌启动Unbranded Boot

Shell 启动程序Shell Launcher