메뉴
BL
Ars Technica 14일 전

마이크로소프트 '시큐어 부트', 10년간 뚫려 있었다

IMP
9/10
핵심 요약

마이크로소프트가 펌웨어 악성코드로부터 시스템을 보호하기 위해 도입한 보안 표준인 '시큐어 부트(Secure Boot)'가 13년 동안 취약한 상태로 방치되어 왔습니다. 보안업체 ESET 연구원들은 오래전 취약점이 발견되었음에도 서명이 취소되지 않은 11개의 리눅스용 '심(Shim)' 펌웨어를 악용하면 초보 해커도 쉽게 이 보안 기능을 우회할 수 있음을 발견했습니다. 이는 윈도우와 리눅스 환경 모두에서 악성코드의 근본적인 감염을 유발할 수 있는 심각한 보안 문제입니다.

번역된 본문

마이크로소프트가 윈도우 기기와 훗날 리눅스 기기를 펌웨어 감염으로부터 보호하기 위해 고안한 업계 표준은, 도입된 지 14년 중 13년 동안 아주 쉽게 우회할 수 있었던 것으로 밝혀졌다. 이 사실은 보안 업체 ESET의 연구원들이 결함이 있는 것으로 알려졌음에도 불구하고 소프트웨어 회사로부터 여전히 서명을 받아 사용 중인 11개의 펌웨어 이미지(최소 하나는 2013년산)를 식별한 후 발견되었다. 이 이미지들은 '심(Shim)'이라 불리며, 리눅스 기기 및 유틸리티 소프트웨어로 시큐어 부트를 확장하기 위해 고안되었다. 초보 해커도 수행할 수 있을 정도로 단순한 기법을 사용하여, 이 오래되고 잊혀진 심들을 이용하면 기기 메인보드의 UEFI(통일 확장 펌웨어 인터페이스)에 내장된 보호 기능을 완전히 우회할 수 있다. 이런 어처구니없는 일이 발생한 이유는 심 서명을 감독하는 마이크로소프트가 이들에서 취약점이 발견된 후에도 공개적으로 사용 가능한 이미지들의 서명을 취소하는 데 실패했기 때문이다.

위협은 윈도우 및 리눅스 사용자 모두에게 미친다

이 심은 두 운영체제가 실행되는 기기에 모두 설치될 수 있기 때문에 위협은 윈도우 및 리눅스 사용자 모두에게 미친다. 여기서 공격자는 필수적인 디지털 서명된 펌웨어 체인을 파괴하고, 부팅 과정 초기에 로드되어 운영체제를 재설치하거나 하드 드라이브를 교체한 후에도 남아있는 악성 펌웨어를 설치할 수 있다. ESET 연구원인 마르틴 스몰라르(Martin Smolár)는 화요일에 다음과 같이 작성했다. "이 오래된 심들을 위험하게 만드는 것은 새로운 취약점이 아닙니다. UEFI 시큐어 부트를 우회하는 데 어떠한 새로운 취약점도 필요하지 않다는 점입니다. 공격자는 복잡한 익스플로잇 기술이 필요 없습니다. 오래되었고 여전히 신뢰할 수 있지만 서명이 취소되지 않은 심 바이너리 사본과 UEFI 심이 어떻게 작동하는지에 대한 기본적인 이해만 있으면 됩니다. 그것만으로 UEFI 시큐어 부트와 같은 핵심 보안 기능을 우회하기에 충분합니다."

시큐어 부트는 부트킷(악성 펌웨어를 지칭하는 용어)의 위협을 줄이기 위해 2012년에 도입되었다. 시큐어 부트가 없다면, 기기가 꺼져 있을 때도 짧은 시간 동안 물리적 접근 권한을 확보한 공격자는 2018년 러시아 국가 해커들이 사용한 LoJax, 2020년에 발견된 MosaicRegressor, 2022년 CosmicStrand, 2023년 BlackLotus와 유사한 부트킷을 설치할 수 있다. 실제 환경에서 발견된 소수의 다른 부트킷들은 ESpecter, FinSpy, MoonBounce 등의 이름으로 추적되고 있다. 모든 것은 아니지만 대부분의 부트킷 악성코드는 공격자가 표적 기기에 물리적으로 접근할 것을 요구한다. 이러한 접근은 시큐어 부트가 명시적으로 보호해야 하는 위협 모델 중 하나이다.

CERT가 작성한 11개의 모든 심 목록은 일부가 Redhat, OpenSuse, Oracle과 같은 리눅스 배포판에서 사용되었음을 보여준다. 다른 것들은 PC-Doctor Finland의 Matriculation Examination Board와 같은 타사 소프트웨어의 일부였다. 이들 중 상당수는 SBAT 및 MOK 거부 목록과 같은 특정 보호 기능이 존재하기 전에 제작되었다. 나머지는 코드나 이들이 승인하는 2단계 바이너리에 축적된 버그를 포함하고 있다.

마이크로소프트가 디지털 서명한 윈도우용 UEFI 부트로더는 윈도우 머신에서 유일한 신뢰 앵커(Anchor of trust)이다. 부팅 과정 중에 컴포넌트가 로드되려면, 인증서가 부팅 중에 실행되는 다른 모든 코드에 명시적으로 서명해야 한다. 심은 다르게 작동한다. 그들은 보조 신뢰 앵커이며, 마이크로소프트의 다른 UEFI 인증서 중 하나를 사용하여 서명된다. 거기에서 심에 내장된 마이보드 또는 소프트웨어 제조업체의 인증서가 이후에 로드되는 모든 소프트웨어를 승인한다. 심에서 취약점이 발견되면 마이크로소프트는 이들의 서명을 취소한다. 이 11개의 심의 경우, 회사는 그렇게 하는 데 실패했으며 어떤 경우에는 10년 이상이 걸리기도 했다. ESET가 이 문제를 CERT와 마이크로소프트의 주의를 환기시킨 후, 이 회사는 마침내 6월 정기 월간 패치 릴리스에서 이들을 취소했다.

복잡성은 실행의 적이다

마이크로소프트는 아직 이러한 실수가 어떻게, 왜 발생했는지 설명하지 않았다. 한 가지 가능한 원인은 시큐어 부트가 작동하는 매우 복잡한 방식일 수 있다. 윈도우 부트 매니저와 UEFI 심은 모두 두 개의 데이터(본문 누락)를 로드한다.

원문 보기
원문 보기 (영어)
Text settings Story text Size Small Standard Large Width * Standard Wide Links Standard Orange * Subscribers only Learn more Minimize to nav An industry-wide standard Microsoft invented to protect Windows, and later Linux, devices from firmware infections has been trivial to bypass for 13 of its 14 years of existence. The discovery was made by researchers at security firm ESET after identifying 11 firmware images, at least one from 2013, that were known to be defective but remained signed by the software company anyway. The images are known as shims , which were invented to extend Secure Boot to Linux devices and utility software. Using a technique simple enough to be performed by novice hackers, these old, forgotten shims can be used to completely circumvent the protection, which is embedded into the UEFI (Unified Extensible Firmware Interface) of the device’s motherboard. The gaffe is the result of Microsoft, which oversees the signing of shims, failing to revoke the publicly available images once vulnerabilities were found in them. Threat extends to Windows and Linux users The threat extends to Windows and Linux users alike, since the shim can be installed on devices running both operating systems. From there, an attacker can subvert the mandated chain of digitally signed firmware to install malicious firmware that loads early in the boot process and persists after either the OS is reinstalled or a hard drive is replaced. “What makes these old shims dangerous is not a novel vulnerability,” ESET researcher Martin Smolár wrote Tuesday . “It’s that no new vulnerability is needed to bypass UEFI Secure Boot. An attacker needs no complicated exploitation primitives—only a copy of an old, still-trusted, but unrevoked shim binary and a basic understanding of how UEFI shims work. That is enough to bypass such an essential security feature as UEFI Secure Boot.” Secure boot was introduced in 2012 to blunt the threat of bootkits, the term for such malicious firmware. Without Secure Boot, attackers with brief physical access to a device—even when it’s turned off—can install bootkits similar to LoJax used by Russia state hackers in 2018, MosaicRegressor found in 2020, CosmicStrand in 2022, and BlackLotus in 2023. A handful of other in-the-wild bootkits are tracked under names including ESpecter, FinSpy, and MoonBounce . Most but not all bootkit malware requires attackers to have physical access to targeted devices. Such access is one of the threat models Secure Boot is explicitly required to protect against. A list of all 11 shims compiled by CERT shows that some were used by Linux distributors such as Redhat, OpenSuse, and Oracle. Others were part of third-party software such as PC-Doctor Finland’s Matriculation Examination Board. Many of them were built before certain protections, including SBAT and MOK deny lists, existed. Others contain accumulated bugs in their code or in second-stage binaries they authorize. Microsoft’s digitally signed UEFI bootloader for Windows is the sole anchor of trust on Windows machines. For a component to load during the boot process, the certificate must explicitly sign all other code executed during bootup. Shims work differently. They’re a secondary trust anchor, and they’re signed by Microsoft using one of its other UEFI certificates. From there, a certificate belonging to the motherboard or software maker that is embedded into the shim authorizes all software that’s subsequently loaded. When vulnerabilities are found in shims, Microsoft revokes them. In the case of the 11 shims, the company failed to do so, in some cases for more than a decade. The company finally revoked them in its regular monthly patch release in June, after ESET brought them to CERT’s and Microsoft’s attention. Complexity is the enemy of execution Microsoft has yet to explain how or why the lapse occurred. One possible cause is the highly complex way that Secure Boot works. Both the Windows Boot Manager and UEFI shims load two databases. The db database lists all allowed signing certificates and Authenticode hashes. The dbx contains certificates and hashes that are no longer trusted. For a component to be loaded, it must be authorized through the db and not revoked in the dbx. Given the high number of Linux components executed during bootup, listing each of them in these databases isn’t possible, since the dbx is allotted only 32kb of space. So Microsoft has resorted to other revocation methods, specifically SBAT (Secure Boot Advanced Targeting) and Secure Boot Security Version Number (SVN). “In short, where dbx revokes binaries, SBAT and Microsoft’s Secure Boot SVN revoke versions,” Smolár explained. “When a vulnerability is found in a UEFI application supporting one of these version-based revocation mechanisms, what really needs to be kept out is every build up to and including the broken one—and that can be captured by a version number much easier than by a long list of hashes.” Each component in the UEFI loader carries metadata that is signed by the same certificate authenticating the binary itself. This metadata names the component and assigns it a generation number that is incremented each time a new security fix ships. A boot-only variable in the UEFI stores the minimum acceptable generation number allowed for each component. The variable number is enforced by the shim rather than the firmware. The shim also embeds the policy so enforcement doesn’t rely exclusively on the external variable. This allows the incorporation of new policy through a mechanism known as the SbatLevel. “At every boot, the shim first verifies its own SBAT metadata against the policy—so an outdated shim can be made to reject itself—and then applies the same test to every binary it loads, refusing anything whose generation number falls below the minimum that the policy demands,” the researcher wrote. The complexity of the process doesn’t stop there. The upshot is that shims embed both a vendor-managed and built-in shim certificate that authorize all bootloaders and utilities loaded subsequently. Readers who want a more thorough description can consult this section of Tuesday’s post. Further complicating the process, even the expiration of the Microsoft certificate that signed the shims, which took place late last month , isn’t enough to revoke the ones ESET identified. A rogue’s gallery of defective shims The shims identified by ESET authorize secondary components that are known to be vulnerable to various exploits. The Oracle shim, for instance, signs a binary vulnerable to CVE-2015-5381 . Smolár said the skill required to exploit the vulnerability is low. Other vulnerable shims fail to support protections, such as MOK deny-list enforcement and SBAT enforcement, both of which came into effect after the affected shim was released. Still other identified shims contain vulnerabilities in their own code. In the interest of brevity, many additional details included in Tuesday’s report are omitted from this article. An unsettling prospect As noted, these vulnerable shims can be used against Windows and Linux machines alike, although likely not Windows 11 Secured-core PCs in their default state. Any Windows user who has installed Microsoft’s June update batch is no longer vulnerable. Linux users should check the Linux Vendor Firmware Service or consult their distributor. Revocation statuses are available using the uefi-dbx-audit script. The prospect that attackers have had the means to bypass Secure Boot for more than a decade through what amounts to hack-by-numbers scripts isn’t much of an endorsement of the mechanism proposed by Microsoft in partnership with hardware makers. As mentioned earlier, a key contributor to this debacle is its complexity. “This is a solid rebuke of the entire secure boot model,” HD Moore, a firmware security expert, CEO and founder of runZero, and a long-time critic of Secure Boot, said in an interview. His complaints include Microsoft being the de fa