Threat Level: green Handler on Duty: Johannes Ullrich

SANS ISC: IE 0-day using .hlp files - SANS Internet Storm Center SANS ISC InfoSec Forums

Participate: Learn more about our honeypot network

Sign Up for Free!   Forgot Password?
Log In or Sign Up for Free!
IE 0-day using .hlp files

A POC has been posted which outlines how to use VBScript in a .HLP file to invoke winhlp32.exe in Windows 2000, Windows XP SP2, SP3 & Windows 2003 SP2. A malicious page is needed to trick the user into pressing the F1 button which invokes the help function,arbitrary commands can then be executed. The attack works in IE 6, 7, & 8. 

A work around is to disable active scripting in Internet Explorer.  A second work around is to change the permission on winhlp32.exe  as shown in the advisory.

Microsoft has posted an advisory  here

Whilst we haven't seen any attacks based on this just yet, if you do please let us know. 


(Thanks David & Pholder)



392 Posts
ISC Handler
Mar 1st 2010
Maurycy Prodeus has published 2 POCs, one that executes abitrary code, and one that just crashes WinHlp32.

The first POC published, remote code exec (literally), downloads a malicious help file, using:

Best practice is to not only block ingress-, but also egress CIFS/SMB connections at your perimeter (ports 135-139 and 445 both tcp and udp). This is a good idea anyway, because for example Word documents may reference templates using an UNC path.

Note that this may not prevent all attacks; an intranet file could be referenced. A malicious file could be planted on any device on your lan which happens to be in control by an attacker, but also legitimate files on your LAN (or even the local PC) may provide attack vectors.

Futher note that *any* Windows version that has WinHlp32.exe installed is probably vulnerable to this type of attack.

The POC author, Maurycy Prodeus, mentions (in that .hlp files can contain DLL's and therefore should be treated as executable files.

However, as an anonymous commentor points out (in in Dutch), .chm files are probably equally dangerous. I don't know if this attack also affects HTML help.

Furthermore, the second POC supposedly crashes WinHlp32 by feeding it with a too long commandline parameter (no CIFS/SMB file-I/O is necessary). According to Maurycy Prodeus, Microsoft has compiled the XP version of WinHlp32.exe using the /GS flag which effectively guards the stack. It is likely that older versions of WinHlp32.exe are vulnerable.
Erik van Straten

129 Posts
Note: in my post above the UNC path to <external-ip-address> obviously should begin with 2 backslashes, but one of them was removed while posting my comment.
Erik van Straten

129 Posts
Microsoft provides more details here:
This page also mentions the use of WebDav instead of SMB.

Erik van Straten

129 Posts

Sign Up for Free or Log In to start participating in the conversation!