Export (0) Print
Expand All
Expand Minimize
This topic has not yet been rated - Rate this topic

Using the SessionShim Fix

Published: June 11, 2010

Updated: June 11, 2010

Applies To: Windows 7, Windows Vista

This section includes information about using the SessionShim compatibility fix, including the associated issues, the intercepted APIs, the available command-line options and usage, and the recommended fix for a permanent solution.

SessionShim

SessionShim enables an application to function properly even if it is attempting to use the Session0 (Global Session) service, which is no longer available for use by applications in the Windows Vista operating system.

This compatibility fix attempts to resolve this issue by intercepting calls to create several common kernel-mode objects. SessionShim first attempts to open the object after specifying the Global\ namespace. If that fails, the fix tries again, by using the Local\ namespace. Finally, if that too fails, the fix will return the value from the original API, without any additional modification.

Investigating the Issue

The SessionShim compatibility fix should be considered as a possible resolution if an application is attempting to explicitly interact with a service by using kernel-mode objects and if the communication fails with Windows Vista.

Intercepted APIs

The following APIs are intercepted by the SessionShim compatibility fix.

  • OpenEventA

  • OpenEventW

  • OpenMutexA

  • OpenMutexW

  • OpenSemaphoreA

  • OpenSemaphoreW

  • OpenWaitableTimerA

  • OpenWaitableTimerW

  • OpenJobObjectA

  • OpenJobObjectW

  • OpenFileMappingA

  • OpenFileMappingW

Command-Line Options

If you create a "\\" delimited list of object names, then this compatibility fix will only apply the Global, Local, and Default logic to the specified objects. Otherwise, all objects will have this logic applied.

Fixing Your Code

Applications should be modified so that they use the client and server remote procedure call (RPC) mechanisms, such as RPC protocols or named pipes, to communicate between services and applications. If kernel-mode objects must be shared, you must explicitly create them by using the Global\ or Local\ namespace prefix, according to your requirements.

See Also

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.