Skip to main content
QUICK REVIEW

[논문 리뷰] LazyFP: Leaking FPU Register State using Microarchitectural Side-Channels

Julian Stecklina, Thomas Prescher|arXiv (Cornell University)|2018. 06. 19.
Security and Verification in Computing참고 문헌 2인용 수 66
한 줄 요약

본 논문은 느린 FPU 컨텍스트 스위칭과 마이크로아키텍처 측면 채널을 악용하여 프로세스/가상 머신 경계에서 FPU/SIMD 레지스터 상태를 누출하는 실용적 공격을 시연하며, fault-based, TSX 기반, 또는 retpoline 기반 예외 억제를 이용합니다.

ABSTRACT

Modern processors utilize an increasingly large register set to facilitate efficient floating point and SIMD computation. This large register set is a burden for operating systems, as its content needs to be saved and restored when the operating system context switches between tasks. As an optimization, the operating system can defer the context switch of the FPU and SIMD register set until the first instruction is executed that needs access to these registers. Meanwhile, the old content is left in place with the hope that the current task might not use these registers at all. This optimization is commonly called lazy FPU context switching. To make it possible, a processor offers the ability to toggle the availability of instructions utilizing floating point and SIMD registers. If the instructions are turned off, any attempt of executing them will generate a fault. In this paper, we present an attack that exploits lazy FPU context switching and allows an adversary to recover the FPU and SIMD register set of arbitrary processes or VMs. The attack works on processors that transiently execute FPU or SIMD instructions that follow an instruction generating the fault indicating the first use of FPU or SIMD instructions. On operating systems using lazy FPU context switching, the FPU and SIMD register content of other processes or virtual machines can then be reconstructed via cache side effects. With SIMD registers not only being used for cryptographic computation, but also increasingly for simple operations, such as copying memory, we argue that lazy FPU context switching is a dangerous optimization that needs to be turned off in all operating systems, if there is a chance that they run on affected processors.

연구 동기 및 목표

  • 느린 FPU 컨텍스트 스위칭이 경계 간 FPU 상태 누출을 어떻게 가능하게 하는지 설명합니다.
  • 사전 예측 실행을 재사용해 FPU/SIMD 레지스터를 읽는 다수의 공격 변형을 특징지립니다.
  • 다양한 예외 억제 방법의 실용성과 성능을 평가합니다.
  • AES-NI 같은 암호 원칙에 대한 영향을 평가하고 완화책을 논의합니다.
  • 느린 FPU 컨텍스트 스위칭을 피함으로써 보안을 향상시키는 운영 체제에 대한 지침을 제공합니다.

제안 방법

  • 느린 FPU 컨텍스트 스위칭 메커니즘과 #NM 예외가 FPU 사용을 어떻게 신호하는지 설명합니다.
  • 예측 실행 및 캐시 사이드 효과를 악용하여 한 비트 누출과 전체 레지스터 누출을 개발합니다.
  • 페이지 폴트 기반 억제, Intel TSX 기반 억제, 및 retpoline 기반 억제의 세 가지 공격 변형을 제안합니다.
  • 일정 스케줄링 시간 조각 내에서 전체 AVX 레지스터 세트의 실용적 누출을 보여줍니다.
  • AES-NI 키 물질에 대한 영향을 분석하고 완화 권고를 제공합니다.

실험 결과

연구 질문

  • RQ1느린 FPU 컨텍스트 스위칭이 예측 실행을 통해 피해자의 FPU/SIMD 레지스터 상태를 복구하도록 악용될 수 있나요?
  • RQ2OS 예외 처리 억제 또는 우회하여 FPU 레지스터를 누출하는 실용적인 공격 변형은 무엇인가요?
  • RQ3다양한 예외 억제 메커니즘(페이지 폴트, TSX, retpoline)에 따라 공격 성능은 어떻게 달라지나요?
  • RQ4누출된 FPU 상태가 AES-NI 같은 암호 원칙에 어떤 영향을 미치나요?

주요 결과

MethodCyclesEff. Throughput
Page fault359.9K0.22 MiB/s
Intel TSX25.4K3.12 MiB/s
Retpoline24.0K3.30 MiB/s
  • 간단한 한 비트 누출은 캐시 효과를 통해 피해자의 FPU 레지스터 비트를 추론하기 위해 예측 실행을 사용합니다.
  • 페이지 폴트, TSX, 또는 retpoline을 통해 NM 장애를 억제하면 스케줄링 시간 조각 내에서 FPU 상태의 전체 스냅샷이 가능해집니다.
  • 표로 제시된 결과는 256-bit AVX 레지스터 누출 시 페이지 폴트 방법에 비해 TSX 또는 retpoline 사용 시 상당한 속도 향상을 보입니다.
  • 누출 변형은 AES-NI 관련 레지스터를 노출시켜 SSE 레지스터에 보관된 암호 키를 손상시킬 수 있습니다.
  • 느린 FPU 컨텍스트 스위칭에서 적극적(eager)으로 전환하여 누출 위험을 줄이며, 일부 커널에서는 Linux 매개변수 eagerfpu=on이 해법을 제공합니다.
  • 저자에 의해 취약점 CVE-2018-3665 (INTEL-SA-00145)가 공개적으로 공개되었습니다.

더 나은 연구,지금 바로 시작하세요

연구 설계부터 논문 작성까지, 연구 시간을 획기적으로 줄여보세요.

카드 등록 없음 · 무료 플랜 제공

이 리뷰는 AI가 만들고, 인간 에디터가 검토했습니다.