--------------------------------------------------------------------------------------------------------------
 0-day EDraw Office Viewer Component 5.2 (officeviewer.ocx v. 5.2.218.1) "HttpDownloadFileToTempDir()"
 Remote Buffer Overflow
 url: http://www.ocxt.com/officeviewer.php

 author: shinnai
 mail: shinnai[at]autistici[dot]org
 site: http://shinnai.altervista.org
 
 This was written for educational purpose. Use it at your own risk.
 Author will be not be responsible for any damage.
 
 Tested on Windows XP Professional SP2 all patched, with Internet Explorer 7
 all software that use this ocx are vulnerable to this exploits.

 This ActiveX is marked as:
 RegKey Safe for Script: True
 RegKey Safe for Init: True
 Implements IObjectSafety: True
 IDisp Safe: Safe for untrusted: caller, data
 IPStorage Safe: Safe for untrusted: caller, data
 KillBitSet: False

 Even this time, shinnai is not credited for bug finding but they wrote:
 "3. Changes the Insecure Method .void HttpDownloadFile(WebUrl, LocalFile, WebUsername, WebPassword).
  to .BSTR HttpDownloadFileToTempDir(WebUrl, WebUsername, VARIANT WebPassword);
  Now the component can only download the file to .Internet temporary file directory\OA\..
  So anybody can.t use the method to download a file then conver a good system file."

 mmm... sure but, guys, take a look to SEH chain and you'll find this:

 SEH chain of thread 000011A0, item 0
  Address=0172F284
  SE handler=iexplore.00410041

 SEH chain of thread 000011A0, item 1
  Address=00410041
  SE handler=00844E79

 do you know what I mean ;)

 P.S.
 encrease the number of buffer to see everything freezed
--------------------------------------------------------------------------------------------------------------