Framework 1.0 to 1.1 Security Change

  • Thread starter Thread starter Mike Bird
  • Start date Start date
M

Mike Bird

I have a .NET pooled COM object written in C#. The component is derived
from System.EnterpriseServices.ServicedComponent. Everything was working
fine with the old Visual Studio. I recompiled it with the new VS.NET 2003
and now I get an access violation when I try to create an instance of the
object. I can only assume that default security was tightened up since the
last version.

Can anyone point me to some documentation/examples describing:
1) What attributes I put into the COM object to set up the security
required to use the object.
2) What attributes I put into the code calling the COM object to provide
the security needed.

Thanks.
 
I have more info. I found that if I add this to the AssemblyInfo of the COM
object, it won't enforce any access security and things work fine. This was
the security change from 1.0 to 1.1 of the Framework.

[assembly: ApplicationAccessControlAttribute(false)]



What I would prefer to do however, is add whatever is needed to the program
using the COM object so that it works with access security turned on.
Trying to find this information in the documentation has proved very hard.
I tried using the .NET Framework Configuration tool and giving full trust to
the application that uses the COM object, but this didn't help. Anyone have
any ideas?

Thanks
 
Back
Top