AntiXssLibrary 64 bit version

Feb 4, 2010 at 4:18 AM

I have Window 7 Enterprise and VS Team System2008 Development editon with .Net Framework 3.5SP1 installed on ThinkPad x64 machine.  When I compile my web application, I am getting following error message: "Could not load file or assembly 'AntiXssLibrary, Version=3.1.3524.16873, Culture=neutral, PublicKeyToken=d127efab8a9c114f' or one of its dependencies. Failed to grant minimum permission requests. (Exception from HRESULT: 0x80131417)''

AntiXssLibrary.dll is 32bit.  It depends on  gpsvc.dll, sysntfy.dll and IEShims.dll which on my machine is 64bits.

In order to work on x64 machine, do I need to download AntiXssLibrary source file and change Target platform to Any CPU?

 

Coordinator
Apr 14, 2010 at 7:24 PM

That's not a bit issue I'm afraid, well, kind of - it's more to do with the HtmlSanitization parts and the pointer manipulation they do for speed purposes. The error you're getting is because the code is unsafe, and your application doesn't like that.

So you have a couple of options - compile, but remove the HTML sanitization, in which case the unsafe code goes away, or widen the permissions granted to your ASP.NET application. The next version will separate out the bits into separate assemblies so you can use AntiXSS in medium trust environments,