(PuTTYユーザマニュアル) 9.5 セキュリティの考慮 - 9.5 Security considerations

http://the.earth.li/~sgtatham/putty/0.60/htmldoc/Chapter9.html#pageant-securityの日本語訳です。<< 9.4 エージェント転送を使う - 目次に戻る - 10章: 共通のエラーメッセージ >>

訳文

公開キー認証にPageantを使うと、SSHセッション開始時に毎回パスフレーズを入力しなくてもすむので便利です。また、復号化された秘密キーをディスクに置く必要がないため安全です。セキュリティと利便性を適切な妥協だと思う人も多いでしょう。

Using Pageant for public-key authentication gives you the convenience of being able to open multiple SSH sessions without having to type a passphrase every time, but also gives you the security benefit of never storing a decrypted private key on disk. Many people feel this is a good compromise between security and convenience.

しかし、これは妥協なのです。復合化された秘密キーはディスク上のファイルに置くよりもPageantの中に置く方が見つかりづらいです。しかし、どこかに置く以上安全ではありません。これには二つの理由があります。

It is a compromise, however. Holding your decrypted private keys in Pageant is better than storing them in easy-to-find disk files, but still less secure than not storing them anywhere at all. This is for two reasons:

  • 残念なことにWindowsがメモリの内容をシステムスワップに書き込のを防ぐことはできません。したがってPageantが秘密キーを長時間保持していると、復号化された秘密キーがシステムスワップファイルに書き込まれることがあります。そうすると、そのデータはハードディスクにアクセスした攻撃者によって復元されるかもしれません。(暗号化していないキーをディスクファイルに保存している場合、攻撃者はキーを確実に復元できます。)
  • 最近の多くのオペレーティングシステム同様、Windowsではプログラムが誤って他のプログラムのメモリ領域にアクセスすることを防ぎます。しかし、デバッグ等の特殊な用途で意図的にほかのプログラムにアクセスすることができます。つまり、Pageantを実行するWindowsシステムにウィルスやトロイの木馬、その他の悪意のあるプログラムが含まれる場合、これらのプログラムがPageantプロセスのメモリにアクセスして復号化された認証キーを抜き出し、プログラムの作成者に送信するかもしれません。
  • Windows unfortunately provides no way to protect pieces of memory from being written to the system swap file. So if Pageant is holding your private keys for a long period of time, it's possible that decrypted private key data may be written to the system swap file, and an attacker who gained access to your hard disk later on might be able to recover that data. (However, if you stored an unencrypted key in a disk file they would certainly be able to recover it.)
  • Although, like most modern operating systems, Windows prevents programs from accidentally accessing one another's memory space, it does allow programs to access one another's memory space deliberately, for special purposes such as debugging. This means that if you allow a virus, trojan, or other malicious program on to your Windows system while Pageant is running, it could access the memory of the Pageant process, extract your decrypted authentication keys, and send them back to its master.

同様に、ワンタッチ認証のセキュリティを向上させるための方法としてエージェント転送がありますが、これも完ぺきではありません。リモートサーバマシン(のエージェント内、あるいは、暗号化しないディスク上)にキーを置くのは、WindowsPageant内にキーを置くよりもセキュリティ上のデメリットになります。というのは、サーバマシンから暗号化していない秘密キーを見れる場合、そのマシンのシステム管理者やそのマシンをクラックした者はキーを盗んで好きなだけなりすましを行えるからです。

Similarly, use of agent forwarding is a security improvement on other methods of one-touch authentication, but not perfect. Holding your keys in Pageant on your Windows box has a security advantage over holding them on the remote server machine itself (either in an agent or just unencrypted on disk), because if the server machine ever sees your unencrypted private key then the sysadmin or anyone who cracks the machine can steal the keys and pretend to be you for as long as they want.

サーバマシンのシステム管理者はそのマシン上でいつでもなりすましを行えます。したがって、サーバマシンにエージェントを転送している場合、システム管理者は転送されたエージェント接続へアクセスして秘密キーによる署名を要求し、なりすましを行って他のマシンにログインできます。なりすましを行えるのはエージェント転送が行われている間だけですが、Pageantを使用してもサーバのシステム管理者(やハッカー)によるなりすましを防ぐことはできないのです。

However, the sysadmin of the server machine can always pretend to be you on that machine. So if you forward your agent to a server machine, then the sysadmin of that machine can access the forwarded agent connection and request signatures from your private keys, and can therefore log in to other machines as you. They can only do this to a limited extent - when the agent forwarding disappears they lose the ability - but using Pageant doesn't actually prevent the sysadmin (or hackers) on the server from doing this.

したがって、サーバマシンのシステム管理者を信頼できない場合、そのマシンに対してエージェント転送を行うべきではありません。(もちろん、そのマシンに秘密キーを置いたり、パスフレーズを入力したり、そのマシンから何らかの方法でほかのマシンにログインするのも避けるべきです。これはPageantに限ったことではありません。)

Therefore, if you don't trust the sysadmin of a server machine, you should never use agent forwarding to that machine. (Of course you also shouldn't store private keys on that machine, type passphrases into it, or log into other machines from it in any way at all; Pageant is hardly unique in this respect.)

<< 9.4 エージェント転送を使う - 目次に戻る - 10章: 共通のエラーメッセージ >>