NT Help File Buffer Overflow Vulnerability
BID:261
Info
NT Help File Buffer Overflow Vulnerability
| Bugtraq ID: | 261 |
| Class: | Boundary Condition Error |
| CVE: | |
| Remote: | No |
| Local: | Yes |
| Published: | May 17 1999 12:00AM |
| Updated: | May 17 1999 12:00AM |
| Credit: | This vulnerability was discovered by David Litchfield <[email protected]>. |
| Vulnerable: |
Microsoft Windows NT 4.0 SP5 Microsoft Windows NT 4.0 SP4 Microsoft Windows NT 4.0 SP3 Microsoft Windows NT 4.0 SP2 Microsoft Windows NT 4.0 SP1 Microsoft Windows NT 4.0 |
| Not Vulnerable: | |
Discussion
NT Help File Buffer Overflow Vulnerability
Lax permission in the Windows NT help file folder and a buffer overflow in the Help utility may allow malicious users to gain Administrator privileges.
The Windows NT Help utility parses and displays help information for selected applications. The help files are stored in the %SystemRoot%\help directory. The default permissions in this directory allow any user to add new files.
A buffer overflow exists in the Help utility when it attempts to read a .cnt file with an overly long heading string. Content tab informaton files (".cnt") are generated when rich text format files (".rtf") are translated to help files (".hlp"). If the string is longer than 507 bytes winhlp32 truncates the entry and the buffer overflow does not occur.
A malicious user can create a custom .cnt help file with executable code in an entry string which when stored in the help directory and viewed by an unsuspecting user can grant them that users privileges.
The vulnerability is not limited by the permissions of the help file directory as the Help utility will search for a .cnt file first in its execution directory before looking in the help file directory.
Lax permission in the Windows NT help file folder and a buffer overflow in the Help utility may allow malicious users to gain Administrator privileges.
The Windows NT Help utility parses and displays help information for selected applications. The help files are stored in the %SystemRoot%\help directory. The default permissions in this directory allow any user to add new files.
A buffer overflow exists in the Help utility when it attempts to read a .cnt file with an overly long heading string. Content tab informaton files (".cnt") are generated when rich text format files (".rtf") are translated to help files (".hlp"). If the string is longer than 507 bytes winhlp32 truncates the entry and the buffer overflow does not occur.
A malicious user can create a custom .cnt help file with executable code in an entry string which when stored in the help directory and viewed by an unsuspecting user can grant them that users privileges.
The vulnerability is not limited by the permissions of the help file directory as the Help utility will search for a .cnt file first in its execution directory before looking in the help file directory.
Exploit / POC
NT Help File Buffer Overflow Vulnerability
NOTE: The attached exploit code has been compiled to run on Windows NT 4.0 SP4 with msvcrt.dll version 4.20.6201
NOTE: The attached exploit code has been compiled to run on Windows NT 4.0 SP4 with msvcrt.dll version 4.20.6201
Solution / Fix
NT Help File Buffer Overflow Vulnerability
Solution:
Apply the patches found at:
- X86 version: ftp://ftp.microsoft.com/bussys/winnt/winnt-public/fixes/usa/nt40/hotfixes-postSP5/winhlp32-fix/winhlp-i.exe
- Alpha version: ftp://ftp.microsoft.com/bussys/winnt/winnt-public/fixes/usa/nt40/hotfixes-postSP5/winhlp32-fix/winhlp-a.exe
Solution:
Apply the patches found at:
- X86 version: ftp://ftp.microsoft.com/bussys/winnt/winnt-public/fixes/usa/nt40/hotfixes-postSP5/winhlp32-fix/winhlp-i.exe
- Alpha version: ftp://ftp.microsoft.com/bussys/winnt/winnt-public/fixes/usa/nt40/hotfixes-postSP5/winhlp32-fix/winhlp-a.exe
References
NT Help File Buffer Overflow Vulnerability
References:
References: