Uploaded image for project: 'SonarQube'
  1. SonarQube
  2. SONAR-12284

Remove incorrect call to /api/components/show to verify access

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 7.9.1
    • Fix Version/s: 8.0
    • Component/s: Web, Web API
    • Edition:
      Community
    • Production Notes:
      None

      Description

      When clicking on the available actions for a project under admin/project_management, an API call is made to /api/components/show to check if the user has access to this particular project. If the API call fails, a "Restore access" option is shown.

      However, because the call fails, it is also caught by the request handler, and an error message is shown. In this case, the WS failure is used as an indicator that the user has no access, but this is brittle: the call could fail for another reason (500), and showing a "Restore access" option wouldn't help.

      We should handle this properly instead, by checking the correct permissions, cleanly.

        Attachments

          Activity

            People

            Assignee:
            philippe.perrin Philippe Perrin
            Reporter:
            wouter.admiraal Wouter Admiraal
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Due:
              Created:
              Updated:
              Resolved: