Ken Kolda
9/20/2004 10:10:00 PM
It looks like you're passing a WindowsPrincipal object to your server, which
is a Serializable object. When the object's embedded WindowsIdentity
instance is deserialized, you get the security exception. According to the
MSDN docs, deserializing a WindowsIdentity object requires ControlPrincipal
permission to be set. Is your server code running under a policy which does
not permit Principal Control (e.g. Internet or Local Intranet)?
Ken
"Gary A. Bushey [MVP]" <bushey@mindspring.com.REMOVETOSEND> wrote in message
news:%23RTCKX0nEHA.2096@TK2MSFTNGP15.phx.gbl...
> I am (very) new to .Net Remoting. I am trying to pass in a IPrincipal
> object to a .Net remote object but everytime I try I get an "Exception has
> been thrown by the target of an invocation" error which goes into more
> detail to tell me that:
>
> System.Security.SecurityException: Request failed. at
> System.Security.SecurityRuntime.FrameDescSetHelper(FrameSecurityDescriptor
> secDesc, PermissionSet demandSet, PermissionSet& alteredDemandSet) at
> System.Security.Principal.WindowsIdentity..ctor(SerializationInfo info,
> StreamingContext context) --- End of inner exception stack trace ---
Server
> stack trace: at
> System.Reflection.RuntimeConstructorInfo.SerializationInvoke(Object
target,
> SerializationInfo info, StreamingContext context) at
>
System.Runtime.Serialization.ObjectManager.CompleteISerializableObject(Objec
t
> obj, SerializationInfo info, StreamingContext context) at
> System.Runtime.Serialization.ObjectManager.FixupSpecialObject(ObjectHolder
> holder) at System.Runtime.Serialization.ObjectManager.DoFixups() at
>
System.Runtime.Serialization.Formatters.Binary.ObjectReader.Deserialize(Head
erHandler
> handler, __BinaryParser serParser, Boolean fCheck, IMethodCallMessage
> methodCallMessage) at
>
System.Runtime.Serialization.Formatters.Binary.BinaryFormatter.Deserialize(S
tream
> serializationStream, HeaderHandler handler, Boolean fCheck,
> IMethodCallMessage methodCallMessage) at
>
System.Runtime.Remoting.Channels.CoreChannel.DeserializeBinaryRequestMessage
(String
> objectUri, Stream inputStream, Boolean bStrictBinding, TypeFilterLevel
> securityLevel) at
>
System.Runtime.Remoting.Channels.BinaryServerFormatterSink.ProcessMessage(IS
erverChannelSinkStack
> sinkStack, IMessage requestMsg, ITransportHeaders requestHeaders, Stream
> requestStream, IMessage& responseMsg, ITransportHeaders& responseHeaders,
> Stream& responseStream) Exception rethrown at [0]: at
> System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage
> reqMsg, IMessage retMsg) at
> System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData&
> msgData, Int32 type) at MYCODENAME
>
>
> Is what I am trying even possible? If so, any ideas what I am doing
wrong?
> --
> Gary A. Bushey
> SPS MVP
> bushey@mindspring.com
>
>