Skip to content

gmp.create_ticket adds ACL to ticket without verifying if permission already exists #1165

Open
@frakbe

Description

@frakbe

Expected behavior

When creating a new ticket with function gmp.create_ticket it should verify if the assigned user has already read permission to the task

Current behavior

When creating a new ticket with function gmp.create_ticket it adds a new ACL on ticket with read permission to user, without verifying if the user had already read permission to the task.

Steps to reproduce

  1. Give read permission to USER1 for task TASK1
  2. Run task TASK1
  3. Pick a result (UUIDRES1) of TASK1 and use the function gmp.create_ticket (gmp.create_ticket(result_id = UUIDRES1, assigned_to_user_id = USER1)
  4. Go to permission tab of TASK1 and observe a new read ACL for user USER1 with label "Automatically created for ticket"

GVM versions

gsa: (gsad --version)

gvm: (gvmd --version)

openvas-scanner: (openvassd --version)

gvm-libs:

gvm-tools: (gvm-cli --version)

gvm-cli 24.1.0 (API version 24.1.0)

Environment

Operating system:

RHEL8.10

Installation method / source: (packages, source installation)

Installed from pip

Logfiles


Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions