Walter.BOM Namespace
Walter.Web.FireWall Namespace
ASP-WAF | .Net API for WAF Systems

GuardActionEventArgs Class

Guard events being raised by the firewall when an GuardAction is anything but NoAction

Namespace:  Walter.Web.FireWall.EventArguments
Assembly:  Walter.Web.FireWall (in Walter.Web.FireWall.dll)

Syntax


public class GuardActionEventArgs

Examples


You can interact with the action based on your own application work-flows. the bellow sample shows that users that are found to be spoofing are blocked for at-least 1 year
C#
private void FireWall_OnGuardAction(object sender, GuardActionEventArgs e)
   {
       if (e.Page.User.AsFirewallUser().IsSpoofing)
       {
           foreach (var item in e.Page.Incidents())
           {
               item.Expires = DateTime.UtcNow.AddDays(300);
           }
       }
       e.AllowGuardAction = true;
   }