I've created a sandboxed AppDomain with limited permissions and granted the full trust to my assembly. However, I'm not able to get a custom attribute applied on a type from another assembly (not fully trusted). The attribute type resides in my trusted assembly.
I've done many assertions but I'm unable to determine what permissions Type.IsDefine method requires. The call does not return false only when the domain gets unlimited permissions. Even unlimited security & reflection permissions do not help.
Can you help me? Thanks a lot.
I came accross
this earlier but I didn't think it was exactly my case, but (unfortunately) applying
APTCA solved my situation. I'm not so happy I have to use this attribute, but there is probably no other way...
It's also really weird Type.IsDefined does not throw an exception and still doesn't work even when I'm able to execute code from that partially trusted assembly...
Comments have been closed since this content was published more than 30 days ago, but if you'd like to continue the conversation, please create a new thread in our Forums, or Contact Us and let us know.