MS01-060: FIX: CRT string format functions may underwrite buffer (305601)



The information in this article applies to:

  • Microsoft Windows 2000 Server SP1
  • Microsoft Windows 2000 Server SP2
  • Microsoft Windows 2000 Advanced Server SP1
  • Microsoft Windows 2000 Advanced Server SP2
  • Microsoft Windows XP Professional
  • Microsoft Windows 2000 Professional SP1
  • Microsoft Windows 2000 Professional SP2
  • Microsoft Windows XP Home Edition
  • Microsoft Visual C++, 32-bit Editions 6.0
  • Microsoft Windows NT Server 4.0
  • Microsoft Windows NT Server 4.0 SP1
  • Microsoft Windows NT Server 4.0 SP2
  • Microsoft Windows NT Server 4.0 SP3
  • Microsoft Windows NT Server 4.0 SP4
  • Microsoft Windows NT Server 4.0 SP5
  • Microsoft Windows NT Server 4.0 SP6a
  • Microsoft Windows NT Server, Enterprise Edition 4.0
  • Microsoft Windows NT Server, Enterprise Edition 4.0 SP4
  • Microsoft Windows NT Server, Enterprise Edition 4.0 SP5
  • Microsoft Windows NT Server, Enterprise Edition 4.0 SP6a
  • Microsoft Windows NT Workstation 4.0
  • Microsoft Windows NT Workstation 4.0 SP1
  • Microsoft Windows NT Workstation 4.0 SP2
  • Microsoft Windows NT Workstation 4.0 SP3
  • Microsoft Windows NT Workstation 4.0 SP4
  • Microsoft Windows NT Workstation 4.0 SP5
  • Microsoft Windows NT Workstation 4.0 SP6a

This article was previously published under Q305601

SYMPTOMS

Some CRT string format functions may cause an access violation, stack overflow, or stack corruption due to buffer underwrites.

CAUSE

When a printf-style function performs integer or floating-point conversion, it uses an internal buffer to convert the number into a string. If the user-supplied Precision property is greater than the internal buffer size, the conversion writes outside the boundaries of that buffer because the values on the stack are always the same regardless of the underrun values, and these values cannot be changed.

RESOLUTION

Note All of the hotfixes listed below require you to restart the computer after installation.

Visual C++

The Visual C++ 6.0 version of this fix is available at the following Microsoft Developer Network (MSDN) Web site: The English version of this fix should have the following file attributes or later:
DateTimeVersionSizeNamePlatformLanguage
01-Oct-200113:276.00.9370.0278,581Msvcrt.dllx86ENU
01-Oct-200113:27none2,515,968Msvcrt.pdbx86ENU

Windows XP

To resolve this problem, obtain the latest service pack for Windows XP. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:

322389 How to obtain the latest Windows XP service pack

The following files are available for download from the Microsoft Download Center:

English (US): DownloadDownload Q305601_WXP_SP1_x86_EN.exe now
For additional information about how to download Microsoft Support files, click the following article number to view the article in the Microsoft Knowledge Base:

119591 How to Obtain Microsoft Support Files from Online Services

Microsoft scanned this file for viruses. Microsoft used the most current virus-detection software that was available on the date that the file was posted. The file is stored on security-enhanced servers that help to prevent any unauthorized changes to the file.

English (US) (64-bit): DownloadDownload Q305601_WXP_SP1_x86_EN.exe now

Chinese (Simplified): DownloadDownload Q305601_WXP_SP1_x86_CN.exe now

Chinese (Traditional): DownloadDownload Q305601_WXP_SP1_x86_TW.exe now

Czech: DownloadDownload Q305601_WXP_SP1_x86_CS.exe now

Danish: DownloadDownload Q305601_WXP_SP1_x86_DA.exe now

Dutch: DownloadDownload Q305601_WXP_SP1_x86_NL.exe now

Finnish: DownloadDownload Q305601_WXP_SP1_x86_FI.exe now

French: DownloadDownload Q305601_WXP_SP1_x86_FR.exe now

French (64-bit): DownloadDownload Q305601_WXP_SP1_x86_FR.exe now

German: DownloadDownload Q305601_WXP_SP1_x86_DE.exe now

German (64-bit): DownloadDownload Q305601_WXP_SP1_x86_DE.exe now

Greek: DownloadDownload Q305601_WXP_SP1_x86_EL.exe now

Hungarian: DownloadDownload Q305601_WXP_SP1_x86_HU.exe now

Italian: DownloadDownload Q305601_WXP_SP1_x86_IT.exe now

Japanese: DownloadDownload Q305601_WXP_SP1_x86_JA.exe now

Japanese (64-bit): DownloadDownload Q305601_WXP_SP1_x86_JA.exe now

Korean: DownloadDownload Q305601_WXP_SP1_x86_KO.exe now

Norwegian: DownloadDownload Q305601_WXP_SP1_x86_NO.exe now

Polish: DownloadDownload Q305601_WXP_SP1_x86_PL.exe now

Portuguese: DownloadDownload Q305601_WXP_SP1_x86_PT.exe now

Portuguese (Brazil): DownloadDownload Q305601_WXP_SP1_x86_BR.exe now

Russian: DownloadDownload Q305601_WXP_SP1_x86_RU.exe now

Spanish: DownloadDownload Q305601_WXP_SP1_x86_ES.exe now

Swedish: DownloadDownload Q305601_WXP_SP1_x86_SV.exe now

Turkish: DownloadDownload Q305601_WXP_SP1_x86_TR.exe now

The English version of this fix should have the following file attributes or later:
DateTimeVersionSizeNamePlatform
05-Oct-200107:547.0.2600.15 (xpclnt_qfe.010827-1803)322,560Msvcrt.dllx86
05-Oct-200107:54none353,280Msvcrt.pdbx86

Windows 2000

To resolve this problem, obtain the latest service pack for Windows 2000. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:

260910 How to obtain the latest Windows 2000 service pack

The following files are available for download from the Microsoft Download Center:
The English version of this fix should have the following file attributes or later:
DateTimeVersionSizeNamePlatformLanguage
08-Oct-200111:076.10.9359.0290,869Msvcrt.dllx86ENU
08-Oct-200111:08none451,584Msvcrt.pdbx86ENU

Windows NT 4.0

A supported hotfix is now available from Microsoft, but it is only intended to correct the problem that this article describes. Apply it only to systems that you determine are at risk of attack. Evaluate the computer's physical accessibility, network and Internet connectivity, and other factors to determine the degree of risk to the computer. See the associated Microsoft Security Bulletin to help determine the degree of risk. This hotfix may receive additional testing. If the computer is sufficiently at risk, we recommend that you apply this hotfix now.

To resolve this problem immediately, download the hotfix by following the instructions later in this article or contact Microsoft Product Support Services to obtain the hotfix. For a complete list of Microsoft Product Support Services telephone numbers and information about support costs, visit the following Microsoft Web site: Note In special cases, charges that are ordinarily incurred for support calls may be canceled, if a Microsoft Support Professional determines that a specific update will resolve your problem. The usual support costs will apply to additional support questions and issues that do not qualify for the specific update in question. The following files are available for download from the Microsoft Download Center:
For additional information about how to download Microsoft Support files, click the following article number to view the article in the Microsoft Knowledge Base:

119591 How to Obtain Microsoft Support Files from Online Services

Microsoft scanned this file for viruses. Microsoft used the most current virus-detection software that was available on the date that the file was posted. The file is stored on security-enhanced servers that help to prevent any unauthorized changes to the file.

STATUS

Windows XP

Microsoft has confirmed that this problem may cause a degree of security vulnerability in Microsoft Windows XP. This problem was first corrected in Windows XP Service Pack 1.

Windows 2000

Microsoft has confirmed that this problem may cause a degree of security vulnerability in Microsoft Windows 2000. This problem was first corrected in Windows 2000 Service Pack 3.

Windows NT 4.0

Microsoft has confirmed that this problem may cause a degree of security vulnerability in Microsoft Windows NT 4.0.

Visual C++

Microsoft has confirmed that this problem may cause a degree of security vulnerability in Microsoft Visual C++.

MORE INFORMATION

For more information about this vulnerability, see the following Microsoft Web site:

Modification Type:MajorLast Reviewed:2/6/2006
Keywords:kbHotfixServer kbQFE kbbug kbfix kbOSWin2000fix kbSecurity kbWin2000PreSP3Fix kbWin2000sp3fix kbWinXPsp1fix KB305601