all groups > dotnet security > october 2006 >
You're in the

dotnet security

group:

Why am I not trusted?


Why am I not trusted? Sid DeLuca
10/12/2006 8:53:01 AM
dotnet security:
I am trying to secure an Excel smart document using WSE3 and VSTO. I have
Office 2003 Pro, VS 2005, WSE3, and VSTO installed (not SE).

I have downloaded the Excel Invoice Sample application and modified it to
work with a web service I developed that is secured using WSE3 extensions and
the wse3policyCache file.

The web service works as expected from my Windows Forms smart client.
However, when I try to configure the proxy class in the excel document I get
the following error at runtime:

WSE032: There was an error loading the microsoft.web.services3 configuration
section.


************** Exception Text **************
System.Configuration.ConfigurationErrorsException: WSE032: There was an
error loading the microsoft.web.services3 configuration section. --->
System.Configuration.ConfigurationErrorsException: An error occurred creating
the configuration section handler for microsoft.web.services3: That assembly
does not allow partially trusted callers. ( ....

(remaining error text omitted)

I am developing on my local machine. All of the files are local, except the
web service, which is on another server in the same domain. Can someone tell
me why my Excel document is a "partially trusted caller" instead of a "fully
trusted" caller?
RE: Why am I not trusted? Claus Konrad
10/12/2006 11:05:02 AM
It seems to be a local setting. The assembly calling into WSE must be fully
trusted to avoid the CAS exception you are seeing here.

Make sure your own managed assembly, hosted by Excel in turn creating the
AppDomain in action, is fully trusted. To make absolutely sure - sign your
assembly to give it a strongname and trust that strongname using .NET 2.0
Administration from Windows giving it fulltrust. Make sure the trust is set
at the Machine Level and at the "My_Computer_Zone" group.

/Claus Konrad


[quoted text, click to view]
RE: Why am I not trusted? Sid DeLuca
10/12/2006 4:11:01 PM
Thanks for your post, Claus. This was helpful.

I also found selecting "Evaluate Assembly" from the Runtime Security Policy
node to view "code groups that grant permissions to the assembly" helpful in
determining the problem.

[quoted text, click to view]
AddThis Social Bookmark Button