|
| 1 | +# Managing Parameters in NAP Policy |
| 2 | +Parameters can be configured and managed directly within the policy editor by selecting the **Parameters** option. |
| 3 | + |
| 4 | +## Parameter Properties and Types |
| 5 | +Each parameter configuration includes: |
| 6 | +- `Parameter Type`: `Explicit` or `Wildcard`. For details on explicit and wildcard matching, see the [Matching Types: Explicit vs Wildcard]({{< ref "/nginx-one/nap-policy-matching-types.md" >}}) section. |
| 7 | +- `Name`: The name of the parameter |
| 8 | +- `Location`: Where the parameter is expected (URL query string, POST data, etc.) |
| 9 | +- `Value Type`: The expected type of the parameter value (e.g., alpha-numeric, integer, email) |
| 10 | +- `Attack Signatures`: Whether attack signature checking is enabled for this parameter |
| 11 | +- `Mask Value in Logs`: When enabled, the parameter's value will be masked in the request log for enhanced security and privacy |
| 12 | + |
| 13 | + |
| 14 | +For a complete list of configurable cookie properties and options, see the [Parameter Configuration Parameters]({{< ref "/waf/policies/parameter-reference.md" >}}) documentation under the `parameters` section. |
| 15 | + |
| 16 | +## Parameter Violations |
| 17 | +Click on **Edit Configuration** to configure parameter violations. The following violations can be configured for parameters: |
| 18 | + |
| 19 | +- `VIOL_PARAMETER`: Triggered when an illegal parameter is detected |
| 20 | +- `VIOL_PARAMETER_ARRAY_VALUE`: Triggered when an array parameter value is illegal |
| 21 | +- `VIOL_PARAMETER_DATA_TYPE`: Triggered when parameter data type doesn't match configuration |
| 22 | +- `VIOL_PARAMETER_EMPTY_VALUE`: Triggered when a parameter value is empty but shouldn't be |
| 23 | +- `VIOL_PARAMETER_LOCATION`: Triggered when a parameter is found in wrong location |
| 24 | +- `VIOL_PARAMETER_NAME_METACHAR`: Triggered when illegal meta characters are found in parameter name |
| 25 | +- `VIOL_PARAMETER_NUMERIC_VALUE`: Triggered when numeric parameter value is outside allowed range |
| 26 | +- `VIOL_PARAMETER_REPEATED`: Triggered when a parameter name is repeated illegally |
| 27 | +- `VIOL_PARAMETER_STATIC_VALUE`: Triggered when a static parameter value doesn't match configuration |
| 28 | +- `VIOL_PARAMETER_VALUE_LENGTH`: Triggered when parameter value length exceeds limits |
| 29 | +- `VIOL_PARAMETER_VALUE_METACHAR`: Triggered when illegal meta characters are found in parameter value |
| 30 | +- `VIOL_PARAMETER_VALUE_REGEXP`: Triggered when parameter value doesn't match required pattern |
| 31 | + |
| 32 | +For each violation type, you can: |
| 33 | +- Set the enforcement action |
| 34 | +- Toggle `alarm` and `block` settings |
| 35 | + |
| 36 | +For more details about enforcement modes, see the [Glossary]({{< ref "/nginx-one/glossary.md#nginx-app-protect-waf-terminology" >}}), specifically the entry: **Enforcement mode**. |
| 37 | + |
| 38 | +# Adding a Parameter to Your Policy |
| 39 | + |
| 40 | +1. Choose Parameter Type: |
| 41 | + - Select either `Explicit` for exact parameter matching or `Wildcard` for pattern-based matching |
| 42 | + |
| 43 | +2. Configure Basic Properties: |
| 44 | + - Enter the parameter `Name` |
| 45 | + - Select the `Location` where the parameter is expected |
| 46 | + - Choose the `Value Type` (alpha-numeric, integer, email, etc.) |
| 47 | + - Set the `Data Type` if applicable |
| 48 | + |
| 49 | +3. Set Security Options: |
| 50 | + - Choose whether to enable attack signatures |
| 51 | + - Decide if parameter value should be masked in logs which sets `sensitiveParameter` in [Parameter Configuration Reference]({{< ref "/waf/policies/parameter-reference.md" >}}) |
| 52 | + |
| 53 | +4. Optional: Configure Attack Signatures |
| 54 | + - If enabled, you can overwrite attack signatures for this specific parameter |
| 55 | + - For details on signature configuration, refer to the documentation on [Add Signature Sets]({{< ref "/nginx-one/nap-integration/add-signature-sets.md/" >}}) |
| 56 | + |
| 57 | +5. Click **Add Parameter** to save your configuration |
0 commit comments