I am working on Blazor application where I have a form which take user input (form with some text boxes & text area). What is best approach to prevent it from cross site scripting and XSS attacks.
I am using Microsoft.AspNetCore.WebUtilities for other components for encoding and decoding html. Will encoding & decoding on user input suffice and prevent attacks, vulnerabilities etc.
Do I have to use some library such as Gans.XSS.HtmlSanitizer or is there some inbuilt feature in Blazor.
Thanks in Advance.