AcSignXxx DLL Memory Allocation TechNote


 Product:MicroStation
 Version:All
 Environment:N\A
 Area:Configuration
 Subarea:Projects

If you are using all of the following:

We have discovered that any combination of those may be the cause of two memory allocation issues that ultimately result in Windows programs exiting ungracefully. One of the memory allocation issues is most evident in processes for which Microsoft page heap memory debugging is enabled. Another, more serious memory allocation issue can result in data loss and has been observed to occur more frequently when running on 64-bit operating systems.

Technical Details:

AcSignIcon.dll is a COM component (CLSID {36A21736-36C2-4C11-8ACB-D4136F2B57BD}) delivered in many versions of various Autodesk products. This COM component is registered both as a shell extension (HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Shell Extensions\Approved) and as a shell icon overlay identifier (HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ShellIconOverlayIdentifiers\AutoCAD Digital Signatures Icon Overlay Handler). Thus the component gets loaded into any process address space using certain common dialogs (e.g. comdlg32!GetOpenFileName). The AcSignOpt program does not unregister the AcSignIcon COM component, nor remove its CLSID from shell extensions or shell icon overlays

The memory allocation issue that is more evident with page heap enabled consists of a read reference to a stale (i.e. deleted) C++ object. The more serious issue in AcSignCore.dll is the VirtualFree of an incorrect address (i.e. an address VirtualAlloc'ed by non-Autodesk code). How such an incorrect address is introduced in AcSignCore is unknown, but investigation has determined this DLL frees addresses that it has never allocated. When any of those addresses reference memory the host process is using, a memory error is likely to occur when they get accessed.

As such, it is highly recommended that you use the following recommendations to prevent the more serious VirtualFree memory issue as well as the less serious stale pointer read issue.

Recommendation:

To avoid the more serious issue:

  1. Run the AcSignOpt.exe program, and uncheck the dialog box labeled "Validate digital signatures and display special icons".

    OR

  2. *Use the Windows registry editor to manually add the same registry value that AcSignOpt would add

To avoid the less serious stale pointer read issue:

  1. Remove the CLSID for AcSignIcon.dll from the registry

    OR
  2. Rename the AcSignIcon.dll and reboot.

Note that Autodesk has recently posted a hotfix: "Open Close Save Hotfix".  We have not verified this hotfix yet, but the fix may also apply to above issues.

*The exact registry change is discussed in this article: http://hyperpics.blogs.com/beyond_the_ui/2004/05/followup_part_i.html.  Please use caution when editing the Windows Registry, and make sure to test in your own environment prior to mass implementation.

See also

Other language sources

 Original Author:Phil Chouinard