Skip to main content
QUICK REVIEW

[論文レビュー] A Lightweight Isolation Mechanism for Secure Branch Predictors

Lutan Zhao, Peinan Li|arXiv (Cornell University)|May 17, 2020
Security and Verification in Computing参考文献 35被引用数 6
ひとこと要約

本稿では、スレッド固有の乱数を用いて分岐予測子の内容とインデックスを符号化することで、クロスプライベージおよびクロススレッド攻撃を防ぐ、軽量なハードウェアベースの隔離メカニズムであるXOR-BPおよびNoisy-XOR-BPを提案する。この手法は、SMTアーキテクチャにおいてフラッシュベースの手法よりも優れた性能を示し、平均で5%未満のパフォーマンスオーバーヘッドで、悪意のあるトレーニングおよび認識攻撃に対して強力な保護を提供する。

ABSTRACT

Recently exposed vulnerabilities reveal the necessity to improve the security of branch predictors. Branch predictors record history about the execution of different programs, and such information from different processes are stored in the same structure and thus accessible to each other. This leaves the attackers with the opportunities for malicious training and malicious perception. Instead of flush-based or physical isolation of hardware resources, we want to achieve isolation of the content in these hardware tables with some lightweight processing using randomization as follows. (1) Content encoding. We propose to use hardware-based thread-private random numbers to encode the contents of the branch predictor tables (both direction and destination histories) which we call XOR-BP. Specifically, the data is encoded by XOR operation with the key before written in the table and decoded after read from the table. Such a mechanism obfuscates the information adding difficulties to cross-process or cross-privilege level analysis and perception. It achieves a similar effect of logical isolation but adds little in terms of space or time overheads. (2) Index encoding. We propose a randomized index mechanism of the branch predictor (Noisy-XOR-BP). Similar to the XOR-BP, another thread-private random number is used together with the branch instruction address as the input to compute the index of the branch predictor. This randomized indexing mechanism disrupts the correspondence between the branch instruction address and the branch predictor entry, thus increases the noise for malicious perception attacks. Our analyses using an FPGA-based RISC-V processor prototype and additional auxiliary simulations suggest that the proposed mechanisms incur a very small performance cost while providing strong protection.

研究の動機と目的

  • 共有分岐予測子のセキュリティ脆弱性(悪意あるトレーニングおよび認識攻撃を可能にする)を解消すること。
  • ソフトウェアベースのフラッシュ(高いオーバーヘッド)や物理的隔離(高コストかつ複雑)といった既存の解決策の限界を克服すること。
  • 顕著なパフォーマンスまたは面積のペナルティを伴わずに、スレッドおよび特権レベル間で強い論理的隔離を達成すること。
  • 従来のフラッシュベースの防御が著しくパフォーマンスを低下させるSMTアーキテクチャにおいて、安全な分岐予測を実現すること。
  • 現代のプロセッサ設計にスムーズに統合可能な実用的でハードウェア効率の良い防御を提供すること。

提案手法

  • 分岐予測子テーブル内の方向および宛先履歴エントリの両方を、ハードウェアで生成されたスレッド固有の乱数を用いてXOR符号化する。
  • 読み出し操作時に同じ乱数キーを適用して格納データを復号し、正しく予測を行う一方で、不正アクセスからの内容を隠蔽する。
  • 分岐予測子インデックスの計算に、もう一つのスレッド固有の乱数を導入することで、分岐アドレスとテーブルエントリの間の決定的マッピングを崩す。
  • コンテキストスイッチや特権レベルの変更に伴い、動的に乱数キーを再生成することで、セキュリティドメイン間での隔離を確保する。
  • FPGAベースのRISC-Vプロセッサプロトタイプにこのメカニズムを実装し、実世界のワークロードを用いたシミュレーションにより検証する。
  • フラッシュベースおよび物理的隔離手法と比較して、パフォーマンス、面積、セキュリティのトレードオフを評価する。

実験結果

リサーチクエスチョン

  • RQ1スレッド固有のキーを用いたXOR符号化によるコンテンツレベルの隠蔽は、クロスプライベージおよびクロススレッドの分岐予測子分析を防げるか?
  • RQ2分岐予測子エントリのランダム化インデックス付けは、攻撃者が分岐アドレスと予測子状態の関連を相関させることを不可能にするか?
  • RQ3フラッシュベースまたは物理的隔離された分岐予測子設計と比較して、提案手法のパフォーマンスオーバーヘッドはどの程度低減されるか?
  • RQ4SMTプロセッサ環境において、Spectre V2やBranchScopeといった既知の攻撃を、このメカニズムはどの程度効果的に緩和できるか?
  • RQ5実ハードウェアにおいて、最小限の面積および遅延オーバーヘッドでこの隔離メカニズムを実装可能か?

主な発見

  • 提案されたXOR-BPおよびNoisy-XOR-BPメカニズムは、FPGAベースのRISC-Vプロトタイプで平均5%未満のパフォーマンス遅延を引き起こす。
  • 特にSMTアーキテクチャにおいて、フラッシュベース保護手法と比較して20~50%のパフォーマンスペナルティ低減を達成する。
  • 面積オーバーヘッドは最小限で、1024~4096エントリのPHT(TAGE)テーブルでは0.11%~0.13%の増加にとどまる。
  • コンテンツとインデックスの両方の符号化の組み合わせにより、予測子状態の相関を隠蔽することで、悪意あるトレーニングおよび認識攻撃の両方を効果的に遮断する。
  • 高い予測精度を維持しながら、スレッドおよび特権レベル間で強い論理的隔離を提供する。
  • 特にマルチスレッド環境において、物理的隔離やプライベート予測子と比較して、コスト効率が高くスケーラブルである。

より良い研究を、今すぐ始めましょう

論文の読解から最終レビューまで、研究時間を劇的に削減しましょう。

クレジットカード登録不要

このレビューはAIが作成し、人間の編集者が確認しました。