Bug 1982058 - Adding groups with space using ovirt_permission fails with error "Group was not found"
Summary: Adding groups with space using ovirt_permission fails with error "Group was n...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-ansible-collection
Version: 4.4.6
Hardware: All
OS: Linux
low
medium
Target Milestone: ovirt-4.4.8
: 4.4.8
Assignee: Martin Necas
QA Contact: Pavol Brilla
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-07-14 06:12 UTC by nijin ashok
Modified: 2022-08-07 10:06 UTC (History)
3 users (show)

Fixed In Version: ovirt-ansible-collection-1.5.4
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-09-08 14:12:21 UTC
oVirt Team: Infra
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github oVirt ovirt-ansible-collection pull 318 0 None open ovirt_permission: fix group search that has space in it's name 2021-07-14 06:33:57 UTC
Red Hat Product Errata RHBA-2021:3461 0 None None None 2021-09-08 14:12:26 UTC

Description nijin ashok 2021-07-14 06:12:29 UTC
Description of problem:

While adding a group with space using ovirt_permission module fails with error "Group was not found".

Version-Release number of selected component (if applicable):

ovirt-ansible-collection-1.2.4-1.el8ev.noarch

How reproducible:

100%

Steps to Reproduce:
1. Create a group with space.

# ovirt-aaa-jdbc-tool group add 'group with space' --attribute="description=group with space"

2. Use the below task to assign permission to a group.

  - name: assign permissions
    redhat.rhv.ovirt_permission:
       state: present
       auth: "{{ ovirt_auth }}"
       group_name: "group with space"
       authz_name: internal-authz
       object_type: template
       object_name: template1
       role: TemplateOwner


3. Playbook fails with below error.

    "msg": "Group 'group with space' was not found."


Actual results:

Adding groups with space using ovirt_permission fails with error "Group was not found"

Expected results:

Groups with space should work with ovirt_permission.

Additional info:

Comment 1 Martin Perina 2021-07-14 06:28:41 UTC
Space inside group name or user name seems very strange to me. What's the AAA provider (LDAP server) which supports this? Is there a specific customer case?

Comment 6 Pavol Brilla 2021-08-24 09:38:13 UTC
# ovirt-aaa-jdbc-tool group show "group with space"
Picked up JAVA_TOOL_OPTIONS: -Dcom.redhat.fips=false
-- Group group with space(0e903a5c-dd87-4f97-a18f-37ddfe6c2283) --
Namespace: *
Name: group with space
ID: 0e903a5c-dd87-4f97-a18f-37ddfe6c2283
Display Name: 
Description: group with space

Getting still same result: FAILED! => {"changed": false, "msg": "Group 'group with space' was not found."}


group is not visible through API


devel investigating

Comment 7 Pavol Brilla 2021-08-24 10:07:17 UTC
Group with spaces properly managed by playbook


Just small note: ovirt-aaa-jdbc-tool will not propagate group to engine, for engine to see group you have to create it through UI

Comment 12 errata-xmlrpc 2021-09-08 14:12:21 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (RHV Engine and Host Common Packages security update [ovirt-4.4.8]), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2021:3461

Comment 13 meital avital 2022-08-07 10:06:59 UTC
Due to QE capacity, we are not going to cover this issue in our automation


Note You need to log in before you can comment on or make changes to this bug.