You cannot validate S/MIME messages by using Cdosys.dll in Windows XP (895931)



The information in this article applies to:

  • Microsoft Windows XP Professional
  • Microsoft Windows XP Home Edition
  • Microsoft Windows XP Professional 64-Bit Edition (Itanium)

SYMPTOMS

If you use Microsoft Collaboration Data Objects (CDO) and the COM version of the Cryptography API (CAPICOM) to validate Secure/Multipurpose Internet Mail Extensions (S/MIME) signatures, the validation does not succeed.

The following sample code demonstrates how this validation typically occurs.
Sub Command1_Click (ByVal eventSender As System.Object, ByVal eventArgs As System.EventArgs) Handles Command1.Click 
Dim oCDO As New CDO.Message  
Dim oST As ADODB.Stream 
Dim sContent, sSignature As String  

oST = oCDO.GetStream 
oST.Type = ADODB.StreamTypeEnum.adTypeText  
oST.LoadFromFile("Test.eml") 
oST.Flush() 

sContent =oCDO.BodyPart.BodyParts(1).GetStream.ReadText 
sSignature = oCDO.BodyPart.BodyParts(2).GetEncodedContentStream.ReadText 

Dim oC As  New CAPICOM.SignedData oC.Content = sContent 
oC.Verify(sSignature, True,CAPICOM.CAPICOM_SIGNED_DATA_VERIFY_FLAG.CAPICOM_VERIFY_SIGNATURE_ONLY)  
MsgBox("done") 
End Sub 

The steps that occur in the sample code are as follows:
  • The caller requests the message content that is stored in the first body part of the message.
  • The caller requests the S/MIME signature that is stored in the second body part of the message.
  • The caller sends each body part to CAPICOM for signature validation.

RESOLUTION

Hotfix information

A supported hotfix is now available from Microsoft, but it is only intended to correct the problem that is described in this article. Only apply it to systems that are experiencing this specific problem. This hotfix may receive additional testing. Therefore, if you are not severely affected by this problem, we recommend that you wait for the next Windows XP service pack that contains this hotfix.

To resolve this problem immediately, 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.

File information

The English version of this hotfix has the file attributes (or later file attributes) that are listed in the following table. The dates and times for these files are listed in Coordinated Universal Time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time tool in Control Panel.Microsoft Windows XP, 32-bit editions
   Date         Time   Version         Size       File name
   --------------------------------------------------------------
   18-Mar-2005  17:14  6.1.1000.0      2,025,472  Cdosys.dll       
   25-Feb-2005  03:53  6.1.22.4          371,936  Updspapi.dll

Microsoft Windows XP, 64-bit editions for Itanium-based computers
   Date         Time   Version         Size       File name	 Platform
   ---------------------------------------------------------------------
   18-Mar-2005  17:11  6.1.1000.0      3,646,976  Cdosys.dll     IA-64
   18-Mar-2005  17:14  6.1.1000.0      2,025,472  Wcdosys.dll    x86
   25-Feb-2005  03:50  6.1.22.4          639,712  Updspapi.dll   IA-64

STATUS

Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.

MORE INFORMATION

For more information, click the following article number to view the article in the Microsoft Knowledge Base:

824684 Description of the standard terminology that is used to describe Microsoft software updates


Modification Type:MinorLast Reviewed:6/1/2006
Keywords:kbQFE kbHotfixServer kbWinXPsp2fix kbWinXPpreSP2fix kbfix kbbug KB895931 kbAudDeveloper