Skip to content

[NGINX App Protect] Override-rules schema mismatch: override documented as string but examples use object (Invalid Policy error) #1689

@GagalKoding

Description

@GagalKoding

Describe the bug

There is an inconsistency between the documented schema ( https://docs.nginx.com/waf/policies/parameter-reference/#policy/override-rules ) and the official sample JSON for override-rules ( https://docs.nginx.com/waf/policies/override-rules/ )
The documentation states that the override attribute is of type string, but the official sample policy provided on the same page uses override as a JSON object.
When the documented sample policy is used in NGINX Instance Manager, the policy fails validation and cannot be saved.


To reproduce

  1. Open the documentation page:
    https://docs.nginx.com/waf/policies/override-rules/
  2. Copy the official sample policy JSON that contains override-rules
  3. Paste the policy into NGINX Instance Manager
  4. Attempt to save the policy

Expected behavior

The official sample policy from the documentation should be valid and accepted by NGINX Instance Manager.


Actual behavior

NGINX Instance Manager rejects the policy with the following error:
"Invalid Policy
The policy could not be saved. Please fix all issues in the policy JSON and try again."
Image


Relevant documentation

https://docs.nginx.com/waf/policies/parameter-reference/#policy/override-rules

The documentation defines:

override | string | The overriding security policy definition |

However, the https://docs.nginx.com/waf/policies/override-rules/ page provides sample JSON that defines override as an object:

"override": {
  "policy": {
    "enforcementMode": "transparent"
  }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2 - Important (TTR: 2 weeks)Impacts user success or adoption, causes support tickets, or fills a high-value content need.bugSomething isn't workingproduct/wafIssues related to F5 WAF for NGINX

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions