Uploaded image for project: 'Jira Service Management Data Center'
  1. Jira Service Management Data Center
  2. JSDSERVER-4726

Update of customer language setting fails when user is from an active directory

    XMLWordPrintable

Details

    Description

      As result of scala to java conversion https://jdog.jira-dev.com/browse/FREE-575
      updating of profile started unconditionally call crowdService.updateUser in CustomerProfileService#updateUserBasicInfo which fails if underline AD is read-only

      Should call it only if display name or email address is requested to change

      Steps to Reproduce.
      1. Connect JIRA to an Active Directory that is read-only
      2. Fetch your Service Desk customers from this active directory.
      3. Go to customer portal and attempt to change the customer's profile language to a different one.
      Expected

      JIRA would change the language and store the information in the database.

      Actual

      JIRA would attempt to update the active directory and throw an error that it cannot update the directory because of directory settings.

      Notes

      • Replicable using ApacheDirectory Studio with Read Only with Local Groups
      • Error in the logs will be:
        2017-02-08 18:55:03,733 http-nio-8730-exec-25 ERROR apache4 1135x245x1 1jeqvkj 10.60.6.142 /rest/servicedesk/1/customer/user [c.a.p.r.c.error.jersey.ThrowableExceptionMapper] Uncaught exception thrown by REST service: com.atlassian.crowd.exception.OperationNotPermittedException: com.atlassian.crowd.exception.ApplicationPermissionException: Cannot update user 'apache4' because directory 'Atlassian Test' does not allow updates.
        java.lang.RuntimeException: com.atlassian.crowd.exception.OperationNotPermittedException: com.atlassian.crowd.exception.ApplicationPermissionException: Cannot update user 'apache4' because directory 'Atlassian Test' does not allow updates.
        	at com.atlassian.servicedesk.internal.feature.customer.user.CustomerProfileService.updateUserWithValidatedRequest(CustomerProfileService.java:110)
        	at com.atlassian.servicedesk.internal.feature.customer.user.CustomerProfileService.lambda$updateProfile$0(CustomerProfileService.java:96)
        ...
         
      • It affects avatar as well.

      Workaround

      Use Read/Write LDAP Permission

      Not possible with a federated active directory configuration.

      Attachments

        1. screenshot-1.png
          screenshot-1.png
          35 kB
        2. screenshot-2.png
          screenshot-2.png
          184 kB

        Issue Links

          Activity

            People

              Unassigned Unassigned
              ijimoh Ismael Olusula Jimoh (Inactive)
              Votes:
              9 Vote for this issue
              Watchers:
              13 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Backbone Issue Sync