Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can't include Microsoft.Security.Application?

I can't include Microsoft.Security.Application

using Microsoft.Security.Application;

Gives this error:

The type or namespace name 'Security' does not exist in the namespace 'Microsoft' (are you missing an assembly reference?)

And yes, I clicked on Bin -> Add Reference... -> AntiXSSLibrary.dll and it added it to the Bin Folder including the AntiXSSLibrary.xml.

I rebuilt the whole website, and still nothing.

I'm using ASP .NET 3.5 C# - AntiXSSLibrary 4.0 Stable

like image 877
Danpe Avatar asked May 12 '11 14:05

Danpe


1 Answers

If you get this nuget all extention objects are visibles

Install-Package AntiXSS

it solves my problem.

html = Microsoft.Security.Application.Encoder.HtmlEncode(model.SiteName), model = Microsoft.Security.Application.Encoder.HtmlEncode(json),

like image 60
Jose Walter SANTAMARIA GARCIA Avatar answered Oct 02 '22 20:10

Jose Walter SANTAMARIA GARCIA