大网数据广告活动
Web服务器与PHP

Enable Schannel event logging in Windows

· 52CE 我爱测

This article describes how to enable schannel event logging in Windows and Windows Server.

This article introduces how to enable schannel event logging in Windows and Windows Server.

Original product version:   Windows 7, Windows 8, Windows 10, Windows Server 2008 R2, Windows Server 2012 R2, Windows Server 2016, Windows Server 2019
Original KB number:   260729

Summary

When you enable Schannel event logging on a machine that is running any version of Windows listed in the Applies to section of this article, detailed information from Schannel events can be written to the Event Viewer logs, in particular the System event log. This article describes how to enable and configure Schannel event logging.

Enable logging

Warning: Serious problems might occur if you modify the registry incorrectly by using Registry Editor or by using another method. These problems might require that you reinstall your operating system. Microsoft cannot guarantee that these problems can be solved. Modify the registry at your own risk.

This registry key is present already in Windows and Windows Server.

  1. Start Registry Editor. To do this, click Start, click Run, type regedit, and then click OK.

  2. Locate the following key in the registry:

    HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\SecurityProviders\SCHANNEL

  3. Double-click the EventLogging key or right-click it and select Modify.

    • Value Name: EventLogging
    • Data Type: REG_DWORD
    • Value: See "Logging options" table below
  4. Exit Registry Editor.

  5. Reboot the machine (Logging does not take effect until after you restart the computer).

Logging options

The default value for Schannel event logging is 0x00000001 in Windows, which means that error messages are logged. Additionally, you can log multiple events by specifying the hexadecimal value that equates to the logging options that you want. This is a combination DWORD, which combines individual values for the desired result. For example, to log error messages (0x00000001) and warnings (0x00000002), set the value to 0x00000003.

Value Description
0x0000 Do not log
0x0001 Log error messages
0x0002 Log warnings
0x0003 Log warnings and error messages
0x0004 Log informational and success events
0x0005 Log informational, success events and error messages
0x0006 Log informational, success events and warnings
0x0007 Log informational, success events, warnings, and error messages (all log levels)

More information

Schannel event logging is different from schannel logging. Use schannel logging to enable Windows products to log debug information using the checked version of Schannel.dll.

Applies to

  • Windows 7
  • Windows 8
  • Windows 8.1
  • Windows 10
  • Windows Server 2008 R2
  • Windows Server 2012 R2
  • Windows Server 2016
  • Windows Server 2019

Source: Microsoft Learn / IT Pro troubleshooting by Microsoft and contributors. Documentation licensed CC BY 4.0. Code samples are covered by the MIT License. Converted from Markdown, with links normalized and embedded media omitted.

资料来源与适用范围

资料来源
Microsoft Learn / IT Pro troubleshooting
适用范围
See source applicability · Source date 12/11/2020
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY 4.0 (documentation), MIT (code samples)

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。