查看“时间炸弹”的源代码
←
时间炸弹
跳转到导航
跳转到搜索
因为以下原因,你没有权限 编辑此页:
你请求的操作仅限属于此用户组的用户执行:
用户
你可以查看和复制此页面的源代码。
时间炸弹(或定时炸弹)是一种软件机制,在达到设定的时间段后使计算机程序无法使用。它常见于预发布软件中,用于阻止用户保留过时的测试版本。 == Windows == === Windows 9x === [[File:Win95-216-Timebomb.png|thumb|在 [[Windows 95 Build 216]] 中触发时间炸弹后出错]] 时间炸弹通过 {{code|IO.SYS}} 激活。触发时间炸弹后,Windows 将在启动时显示一条消息,指出预评估期已过期,然后立即关闭。除非使用正确的 BIOS 日期重新安装操作系统,否则操作系统将无法启动,因为 {{code|IO.SYS}} 会自行修补以进入无限循环。与 Windows NT 中的时间炸弹不同,Windows 9x 无法通过 [[winver|{{code|winver}}]] 找到到期日期。[[Windows 95 Build 216]] 是首个包含时间炸弹的已知版本。 从 [[Windows 98]] 开始,[[Windows 安装程序|安装程序]]还会检查日期,如果日期设置不正确,安装程序将拒绝安装。 === Windows NT === [[File:NTexpiredcrash.png|thumb|Windows 显示 {{code|END_OF_NT_EVALUATION_PERIOD}} [[蓝屏死机|错误检查]]]] 一旦触发时间炸弹,{{code|END_OF_NT_EVALUATION_PERIOD}} 错误检查将用于在一段时间后重新启动系统。第一个具有现代时间炸弹的版本是 Windows 2000 Build 1627.1,尽管 Windows NT 3.5 的[[Windows NT 3.5 Build 756.1#日语版本|日语]]和[[Windows NT 3.5 Build 807.1(朝鲜语 Beta)|朝鲜语]]预发布版本包含一个警告消息框,要求用户在特定日期之后安装 Windows 的零售副本,这与该时代的其他版本不同。 [[Windows 8]] 及更高版本的某些版本包含时间炸弹的较温和变体,如果安装内部版本时设置的日期早于假定的到期日期(例如,[[Windows 8 Build 8250.0.winmain win8beta.120217-1520|Windows 8 Build 8250]] 设置为在 2013 年 1 月 15 日 (UTC) 到期,并且用户的时钟甚至在安装之前就早于此日期)。相反,它会停用 Windows 并阻止访问电脑设置中的个性化选项。这些版本的某些副本甚至会阻止解锁 [[Windows 中的功能锁定|Redpill]] 锁定的功能,以及禁用在控制面板中更改桌面墙纸的功能,除非使用第三方工具。除此之外,水印上方的“Microsoft 机密”警告的位置将比平时略高,表明时间炸弹已被触发。这是因为其许可策略未正确安装。 从[[Windows 10 v1507|原始版本]]到[[Windows 10 v1703|创意者更新]]的大多数 [[Windows 10]] 内部版本都是外部测试签名的(文件签名检查会考虑证书到期时间)。当时间炸弹激活时,引导加载程序将因签名失效而无法正常工作。[[Windows 10 Build 14965.1001.rs prerelease.161104-1700|Build 14965]] 后,外部测试版签名的文件在证书过期后仍然有效。但是,当时钟早于到期日期时,某些需要管理权限的程序可能会被阻止。必须使用注册表禁用[[用户帐户控制]]才能运行这些程序,这可以通过应用以下注册表项来实现:<syntaxhighlight lang="registry"> Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System] "EnableLUA"=dword:00000000 </syntaxhighlight>但是,某些版本的 Windows 包含无法正常工作或损坏的时间炸弹,并且可以在当前日期安装。他们大多来自 Microsoft 生态系统工程访问计划(Ecosystem Engineering Access Program,EEAP)的一部分。其他一些内部版本包含测试签名证书,可以在当前日期安装。 ==== Detection ==== [[文件:NTexpiredcrash.png|thumb|Windows 显示 {{code|END_OF_NT_EVALUATION_PERIOD}} [[错误检查]]]] [[File:Windows-10-build-10074-Timebomb-expired.png|thumb|Error in [[Windows 10 build 10074]] after the timebomb was activated]] Once a timebomb is triggered, the <code>END_OF_NT_EVALUATION_PERIOD</code> [[bugcheck]] is used to reboot the system after a period of time has elapsed. The code for implementing timebombs was first added in [[Windows NT 4.0 build 1166]], which was used for evaluation releases of the final release. The first beta build to feature a modern timebomb was [[Windows 2000 build 1627|Windows 2000 build 1627.1]], although the [[Windows NT 3.5 build 756.1#Japanese version|Japanese]] and [[Windows NT 3.5 build 807.1 (Korean Beta)|Korean]] pre-release versions of [[Windows NT 3.5]] include a warning message box asking the user to install a retail copy of Windows after a certain date, unlike other builds from the era. On [[Windows XP]] betas, attempting to log on to a user account will cause an expiration message to appear. Closing it causes an instant system crash. However, on pre-reset [[Windows Vista|Windows Longhorn]] builds, when attempting to log on after the expiration date, the system kicks the user out and returns to the logon screen. On post-reset builds, such as [[Windows Vista build 5384.4|Windows Vista build 5384]], logging on will cause an activation message to appear. Closing it logs the user off. On [[Windows 7]] builds since [[Windows 7 build 6574|build 6574]], users can still log in to the system, but a 30-minute "reboot" cycle (that [[Blue screen of death|bugchecks]] the system) begins, so users have a chance to activate Windows or install a newer version. [[Windows 8]] and later versions include a milder variant of the timebomb; the current operating system install will be deactivated, access to personalization options in PC settings is disabled, and the reboot cycle has increased into an hour. In addition, certain builds may place the "[[Microsoft Confidential]]" disclosure warning slightly higher than usual to indicate that the timebomb has been triggered. Most [[Windows 10]] builds from the [[Windows 10 (original release)|original release]] to the [[Windows 10 Creators Update|Creators Update]] are flight-signed; binary signature checks take certificate expiry time into account. When the timebomb is activated, the [[Windows Boot Manager]] and related boot loaders will be rendered non-functional as a result of signature invalidation. Due to confusion arising from end-users who unknowingly installed public [[Windows Insider Program|Insider Preview]] builds that were redistributed across the Internet with little to no oversight (an issue that had persisted since [[Windows 10 build 9841]], the first Windows 10 Technical Preview release), the Windows cryptography library (<code>mincrypt</code>; statically linked to in the code integrity library and the Windows Boot Manager) was altered in [[Windows 10 build 14964 (rs_prerelease)|build 14964]] to allow expired flight code signing certificate chains and give users a chance to update to the most current Windows release. Numerous issues are caused when attempting to use builds beyond their expiry date due to flight code signing certificates being verified outside of their intended validity period. Examples of issues caused by running these builds under the current date and time are listed below: * Applications such as the legacy [[Windows Defender]] user interface and built-in Windows diagnostics tools will fail to start due to relevant signature checks failing; * [[User Account Control]] may complain about untrusted executables or prevent them from running, even if the applications themselves are signed by Microsoft. This is prevalent during the [[out-of-box experience]] and when launching certain system applications such as the [[Task Manager]]; * Non-critical system drivers, such as print spoolers, will not be available post-installation. Should these be required, both drivers can be manually installed, and a driver signature enforcement check must be overridden. ==== Detection ==== The expiration date and time of the timebomb can be retrieved by checking the value of the field <code>SystemExpirationDate</code> in the structure <code>KUSER_SHARED_DATA</code>,<ref>https://learn.microsoft.com/en-us/windows-hardware/drivers/ddi/ntddk/ns-ntddk-kuser_shared_data</ref> which is accessible at address <code>0x7FFE0000</code> from the user mode.<ref>https://www.geoffchappell.com/studies/windows/km/ntoskrnl/inc/api/ntexapi_x/kuser_shared_data/index.htm</ref> If no timebomb is present, the field is set to zero; otherwise, it will be set to the file time{{efn|A file time is a 64-bit value that represents the number of 100-nanosecond intervals that have elapsed since 12:00 A.M. January 1, 1601 Coordinated Universal Time (UTC).<ref>https://learn.microsoft.com/en-us/windows/win32/sysinfo/file-times</ref>}} of the expiration date and time in UTC. ==== Technical Details and Security Research ==== On 20 January 2026, a security research whitepaper about the Windows timebomb mechanism called "TimeDefuser" was released. From the document, internal workings of timebomb can be summarized as the following: # Upon system boot, <code>ExInitializeTimeRefresh</code> kernel function initializes hardware-system clock synchronization and retrieves expiration date using version-specific mechanisms (i.e. registry, Windows Product Activation data, product policies) and populates two private kernel globals called <code>ExpNtExpirationDate</code> and <code>ExpNtExpiratonData</code>, along with the <code>SystemExpirationDate</code> field in the <code>KUSER_SHARED_DATA</code> structure. On [[Windows Vista]] and later, this is done by a helper function called <code>ExGetExpirationDate</code>. # In each following hour, the kernel runs the <code>ExpTimeRefreshWork</code> routine that performs hardware-system clock synchronization and additionally compares current system time against the expiration date stored in kernel memory. On Windows Vista and later, it also calls <code>ExGetExpirationDate</code>again and repopulates the fields in kernel memory that holds expiration data. # If the expiration date has passed, it sets an internal flag called <code>ExpNextExpirationIsFatal</code> and on Windows XP and earlier, it displays an error message to the user by <code>NtRaiseHardError</code>, indicating that the build has expired. # On subsequent execution, <code>ExpTimeRefreshWork</code> halts the system with the <code>END_OF_NT_EVALUATION_PERIOD</code> bugcheck. == macOS == [[Mac OS X Public Beta]] 是唯一已知具有时间炸弹的 [[MacOS 通述|macOS]] 版本。虽然时间炸弹阻止了用户登录到桌面,但它不会影响 Darwin 内核的各个方面或与用户界面无关的任何其他组件。 Mac OS X 到 [[Mac OS X Snow Leopard|Snow Leopard]] 的多个服务器版本也有一个到期日期,这会导致[[全新安装体验]]拒绝任何超过到期日期的串行密钥。
此页使用的模板:
模板:Code
(
查看源代码
)
模板:Efn
(
查看源代码
)(受保护)
模板:IfPNS
(
查看源代码
)
模板:Main other
(
查看源代码
)
模板:Notelist
(
查看源代码
)
模板:Reflist
(
查看源代码
)
模板:Reflist/styles.css
(
查看源代码
)
模块:Arguments
(
查看源代码
)
模块:Check for unknown parameters
(
查看源代码
)
模块:Lan2
(
查看源代码
)
模块:Namespace
(
查看源代码
)
模块:Namespace/data
(
查看源代码
)
返回
时间炸弹
。
导航菜单
个人工具
登录
命名空间
页面
讨论
大陆简体
查看
阅读
查看源代码
查看历史
更多
搜索
导航
首页
最近更改
随机页面
批量上传文件
WinStory 门户
词条编写指南
深色模式
工具
链入页面
相关更改
特殊页面
页面信息
获取短URL