-1

We have a .NET library that platform invokes native code, specifically we call LoadLibrary(). This code has been in place for a while, but a new user has noticed when running as a Terminal Services user of a Windows Server 2008 R2 machine that it fails to run (apparently when LoadLibrary is called). This happens when run as a Standard User but not when run as an admin which is suspicious. Also it works when run on a Windows Server 2003 machine.

Now we've tested running on a Windows Server 2008 R2 machine and not had any issues before.

I'm suspicious that UAC is at play here. We had them use Process Monitor and I noticed the result INVALID PARAMETER when DeviceIOControl() is called with the control code IOCTL_MOUNTDEV_QUERY_DEVICE_NAME. Which also makes me suspicious of a mapped drive, though running the same code on a mapped drive on my machine works just fine.

Anybody have suggestions about what to try short of standing up a similar machine but the chances of us being able to replicate this in house are looking slim.

JosephA
  • 1,187
  • 3
  • 13
  • 27
  • Do they really mean "when run as a standard user" or do they mean "when run as an administrative user but without elevation" ? If they really do mean a standard user, UAC isn't involved. (Have you tried Server 2003 as a standard user?) If you can add diagnostics to your application, it would be useful to double-check the path being passed to LoadLibrary() as well as the error code it returns. – Harry Johnston Jan 22 '15 at 03:30

1 Answers1

0

For others who find themselves in a similar situation, the user was able to resolve the issue by altering their Software Restriction Group Policy.

JosephA
  • 1,187
  • 3
  • 13
  • 27