Uploaded image for project: 'OCMUI - OpenShift Cluster Manager UI'
  1. OCMUI - OpenShift Cluster Manager UI
  2. OCMUI-3288

[HTPasswd IDP] IDP username can't be created with whitespaces from UI and not aligned with ROSA CLI requirements.

XMLWordPrintable

    • Quality / Stability / Reliability
    • True
    • Hide

      We need to determine what the correct behavior should be in the UI - right now we have conflicting defects.

      Show
      We need to determine what the correct behavior should be in the UI - right now we have conflicting defects.
    • False

      Description of the Problem
      Currently OCM UI restricted users from creating an HTPasswd IDP username with whitespaces. For example "jaya testing". Unfortunalty this is not aligned the ROSA CLI definition. i.e. ROSA CLI still support users from creating an HTPasswd IDP username with whitespaces.  See the example below.

      % rosa create idp -c popies-testing-2ndapril-ocmui
      W: The current version (1.2.51) is not up to date with latest rosa cli released version (1.2.52).
      W: It is recommended that you update to the latest version.
      I: Interactive mode enabled.
      Any optional fields can be left empty and a default will be selected.
      ? Type of identity provider (default = 'github'): htpasswd
      ? Identity provider name: htpasswd-1
      ? Configure users from HTPasswd file (optional): 
      I: At least one valid user and password is required to create the IDP.
      ? Username: jaya testing
      ? Password: [? for help] ***************
      I: Configuring IDP for cluster 'popies-testing-2ndapril-ocmui'
      I: Identity Provider 'htpasswd-1' has been created.
         It may take several minutes for this access to become active.
         To add cluster administrators, see 'rosa grant user --help'.
      I: To log in to the console, open https://console-openshift-console.apps.k1k1g4x0m9m2a0i.suvd.s1.devshift.org and click on 'htpasswd-1'.
      ? Add another user: No

      UI behavior should be aligned appropriately with ROSA CLI. As a consequence of this, 
      A username having white spaces can't be allowed to change the password from HTPasswd IDP page. The "Edit user" button is always disabled for such users from the model
      See below:-

      Steps to Reproduce:

      1. Open the OCM UI staging.
      2. Select a ready rosa cluster.
      3. Run the "rosa create idp" command against the cluster.
      4. Add a new HTPasswd IDP with a username contains whitespace (as mentioned in description)
      5. Go to OCM UI and navigate to cluster's Access control tab.
      6. Select newly added HTPasswd IDP and click kebab icon.
      7. Click "Edit" context menu.
      8. Select the username and click kebab icon associated to the same.
      9. Click "Change password" context menu.
      10. Input suggested password definition from both password fields
      11. Observe the behavior of "Edit user" button.

      Actual Results:

      "Edit user" button disabled from the model and user can't change the password for the same user when the username contains whitespace.

      Expected results:

      The support for whitespace (or any characters) in usernames should be aligned between both the OCM UI and the ROSA CLI. Currently, the ROSA CLI allows usernames with whitespace, while the OCM UI does not. This discrepancy is causing the issue described above and needs to be addressed.
      Usernames with whitespace should be allowed to change their passwords without any issues from UI.

              Unassigned Unassigned
              jmekkatt@redhat.com Jayakrishnan Mekkattillam
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated: