This Just In: MAPI and Windows Server 2008 Now Get Along

The MAPI/CDO download package now works on Windows Server 2008 and Vista. The main blocker to getting this to work was the fact that in Windows Server 2008 and Vista, mapi32.dll was marked as a system file. Any attempt to replace it would be blocked or undone. Exchange's MAPI has always replaced mapi32.dll with its own version, so it couldn't work on those operating systems.

The fix is modify Exchange's MAPI to take advantage of the MAPI Stub Library mechanism. We moved Exchange's MAPI binaries out of system32/syswow64 and placed them under C:Program FilesExchangeMAPI ("Program Files (x86)" on a 64 bit machine). We also renamed Exchange's mapi32.dll binary. It's now called ExMAPI32.dll.

Some notes:

  • If you've installed an earlier version of this download on a machine and wish to upgrade, you must uninstall the earlier version first. It will not upgrade in place, and may even claim to have successfully installed.
  • Mapi32.dll in the system directory should be version 1.0.xxxx. If it's 6.5.xxxx, then the stub is not in place. Use FixMAPI.exe to correct this before installing the updated MAPI download.
  • The version number of the Windows Server 2008/Vista compatible download is 06.05.8022.0.
  • MAPI and CDO are still 32 bit only - it will install and work on a 64 bit machine, but only when used from a 32 bit program.
  • MAPISVC.inf in the system directory will be updated with Exchange's providers, but the date may not be changed. I just noticed this when testing the installer on a machine here.
  • The installer adds the MAPI install directory to the PATH statement. This MUST NOT be removed. It is required to allow DLL dependencies to work correctly.
  • Session 0 Isolation causes problems with our fix to the deleted profile issue. With that fix in place, a normal user (who lacks SeCreateGlobalPrivilege) wouldn't be able to use MAPI at all. So we modified the fix to attempt the global namespace first (which will fail for a normal user), then fall back to a local namespace. This means it is possible for a normal user to log on to a server twice with Terminal Services and delete a profile from one session that is in use under another session. To help identify this scenario, there's a new error code which will be seen by MAPI applications if this happens: MAPI_E_PROFILE_DELETED (0x80040204).
  • The download enters Extended Support in April 2009. That doesn't mean the download will be removed then, but don't expect updates to it.

Update: Looks like the Ehlo blog picked this up. Welcome Ehlo readers! I was involved in getting this update done, so lemme know if you have any questions.