Creating App Firewall profiles
You can create an App Firewall profile in one of two ways: by using the command line, and by using the GUI. Creating a profile by using the command line requires that you specify options on the command line. The process is similar to that of configuring an existing profile, and with a few exceptions the two commands take the same parameters.
Creating a profile by using the GUI requires that you specify only two options. You specify basic or advanced defaults, the default configuration for the various security checks and settings that are part of a profile, and choose the profile type to match the type of content that the profile is intended to protect. You can also, optionally, add a comment. After you create the profile, you must then configure it by selecting it in the data pane, and then clicking Edit.
If you plan to use the learning feature or to enable and configure a large number of advanced protections, you should choose advanced defaults. In particular, if you plan to configure either of the SQL injection checks, either of the cross-site scripting checks, any check that provides protection against Web form attacks, or the cookie consistency check, you should plan to use the learning feature. Unless you include the proper exceptions for your protected Web sites when configuring these checks, they can block legitimate traffic. Anticipating all of the necessary exceptions without creating any that are too broad is difficult. The learning feature makes this task much easier. Otherwise, basic defaults are quick and should provide the protection that your web applications need.
There are three profile types:
- HTML. Protects standard HTML-based web sites.
- XML. Protects XML-based web services and web sites.
- Web 2.0 (HTML XML). Protects sites that contain both HTML and XML elements, such as ATOM feeds, blogs, and RSS feeds.
There are also a few restrictions on the name that you can give to a profile. A profile name cannot be the same as the name assigned to any other profile or action in any feature on the NetScaler appliance. Certain action or profile names are assigned to built-in actions or profiles, and can never be used for user profiles. A complete list of disallowed names can be found in the App Firewall ProfileSupplemental Information. If you attempt to create a profile with a name that has already been used for an action or a profile, an error message is displayed and the profile is not created.
To create an App Firewall profile by using the command line interface
At the command prompt, type the following commands:
add appfw profile <name> [-defaults ( basic | advanced )]
set appfw profile <name> -type ( HTML | XML | HTML XML )
set appfw profile <name> -comment "<comment>"
save ns config
The following example adds a profile named pr-basic, with basic defaults, and assigns a profile type of HTML. This is the appropriate initial configuration for a profile to protect an HTML Web site.
add appfw profile pr-basic -defaults basic -comment "Simple profile for web sites." set appfw profile pr-basic -type HTML save ns config
To create an App Firewall profile by using the GUI
Creating an App Firewall profile requires that you specify only a few configuration details.
Navigate to Security > Citrix Web App Firewall > Profiles.
In the details pane, click Add.
In the Create App Firewall Profile dialog box, type a name for your profile.
The name can begin with a letter, number, or the underscore symbol, and can consist of from one to 31 letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore (_) symbols.
Choose the profile type from the drop-down list.
Click Create, and then click Close.