Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Edit an overwritten rule #1354

Closed
jesusgn90 opened this issue Apr 9, 2019 · 1 comment
Closed

Edit an overwritten rule #1354

jesusgn90 opened this issue Apr 9, 2019 · 1 comment
Assignees
Labels
type/bug Bug issue

Comments

@jesusgn90
Copy link
Contributor

jesusgn90 commented Apr 9, 2019

Hi team,

When we try to edit a custom rule that has been overwritten, the detail that is loaded is the detail of the original rule, so we can't edit it.

When we perform a GET /rules/:id we get the two, and we take the first one.

{
  "error": 0,
  "data": {
    "items": [
      {
        "level": 3,
        "pci": [
          "10.2.5"
        ],
        "id": 5715,
        "details": {
          "match": "^Accepted|authenticated.$",
          "if_sid": "5700"
        },
        "gdpr": [
          "IV_32.2"
        ],
        "groups": [
          "authentication_success",
          "gpg13_7.1",
          "gpg13_7.2",
          "syslog",
          "sshd"
        ],
        "status": "enabled",
        "description": "sshd: authentication success.",
        "path": "ruleset/rules",
        "file": "0095-sshd_rules.xml"
      },
      {
        "level": 3,
        "pci": [],
        "id": 5715,
        "details": {
          "overwrite": "yes",
          "if_sid": "5700",
          "options": "alert_by_email",
          "match": "^Accepted|authenticated.$"
        },
        "gdpr": [],
        "groups": [
          "authentication_success",
          "local",
          "syslog",
          "sshd"
        ],
        "status": "enabled",
        "description": "SSHD authentication success.",
        "path": "etc/rules",
        "file": "local_rules.xml"
      }
    ],
    "totalItems": 2
  }
}

We need to fix it.

Regards.

@jesusgn90 jesusgn90 added the type/bug Bug issue label Apr 9, 2019
@juankaromo juankaromo changed the title Edit an overwritten rule/decoder Edit an overwritten rule Apr 10, 2019
@juankaromo juankaromo self-assigned this Apr 15, 2019
@juankaromo
Copy link
Contributor

Solved here 29b797c

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/bug Bug issue
Projects
None yet
Development

No branches or pull requests

2 participants