I have some web services that I've written and a forms application that calls
my web services and is deployed using ClickOnce. I don't want to run the
forms application in full trust but it doesn't work if I don't. The problem
is that some of the web service calls are returning a custom class. These
calls fail with the exception below if the app doesn't have full trust. Calls
that don't deal with custom classes work just fine. Is there any way to
resolve this problem other than not using custom classes or running in full
trust?
System.InvalidOperationException: There is an error in XML document (1,
290). ---> System.Security.SecurityException: Request failed.
at
Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReaderLogin.Read2_WorldInfo(Boolean isNullable, Boolean checkType)
at
Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReaderLogin.Read12_GetWorldsResponse()
at
Microsoft.Xml.Serialization.GeneratedAssembly.ArrayOfObjectSerializer17.Deserialize(XmlSerializationReader reader)
at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader
xmlReader, String encodingStyle, XmlDeserializationEvents events)
The action that failed was:
Demand
The type of the first permission that failed was:
System.Security.PermissionSet
The demand was for:
<PermissionSet class="System.Security.PermissionSet"
version="1"
Unrestricted="true"/>
nano2k - 29 Feb 2008 21:03 GMT
Richard
Sorry, can't help you out with your problem.
I'm now facing the challenge to return custom classes from the
webservice.
How do you do this?
I created a post on this subject here:
http://groups.google.ro/group/microsoft.public.dotnet.framework.webservices/brow
se_thread/thread/7e3d1f4feb45096d/69e2dc7fe1fcaa31?hl=ro#69e2dc7fe1fcaa31
If you can share this, please do.
Sorry again for not being able to help you.
Thanks.
> I have some web services that I've written and a forms application that calls
> my web services and is deployed using ClickOnce. I don't want to run the
[quoted text clipped - 23 lines]
> version="1"
> Unrestricted="true"/>