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

SD redirects calls to any plugin's REST endpoints to /servicedesk/customer/portal/1

      NOTE: This bug report is for JIRA Service Desk Server. Using JIRA Service Desk Cloud? See the corresponding bug report.

      We have a plugin that injects some javascript into SD customer portal. This plugin embellishes some custom fields with HTML generated based on REST calls to the plugin's REST endpoints.

      Our customer reported that their 'customer' users do not the proper embellishments, instead they get some Javascript error. It turned out that when a user who is not in jira-users (an SD 'customer') is accessing the page with our plugin on it, the plugin makes a REST call that gets 302-redirected to /servicedesk/customer/portal/1. Which means that everything gets broken. Adding @AnonymousAllowed annotation to the plugin's endpoint does not help, as it only works when the user is actually not logged-in. When they log in, apparently SD servlet filter (or whatever) redirects blindly to a bad place.

      This is breaking our plugin in very bad ways and we are likely losing sales because of this.

      Are there any workarounds for this behaviour? I have tried injecting a serlet filter, but it is not being invoked.

      The plugin in question is https://marketplace.atlassian.com/plugins/com.spartez.jira.plugins.ephor-for-jira, but the behaviour can be trivially reproduced with any plugin that has a REST endpoint. Just log in as an SD 'customer' and go to plugin's REST endpoint

          Form Name

            [JSDSERVER-1640] SD redirects calls to any plugin's REST endpoints to /servicedesk/customer/portal/1

            Owen made changes -
            Workflow Original: JSD Bug Workflow v5 - TEMP [ 2304557 ] New: JAC Bug Workflow v3 [ 3126116 ]
            Status Original: Done [ 10044 ] New: Closed [ 6 ]
            Owen made changes -
            Symptom Severity Original: Critical [ 14430 ] New: Severity 1 - Critical [ 15830 ]
            Katherine Yabut made changes -
            Workflow Original: JSD Bug Workflow v5 [ 2058392 ] New: JSD Bug Workflow v5 - TEMP [ 2304557 ]
            Katherine Yabut made changes -
            Workflow Original: JSD Bug Workflow v5 - TEMP [ 2055382 ] New: JSD Bug Workflow v5 [ 2058392 ]
            Katherine Yabut made changes -
            Workflow Original: JSD Bug Workflow v5 [ 1956180 ] New: JSD Bug Workflow v5 - TEMP [ 2055382 ]
            Katherine Yabut made changes -
            Workflow Original: JSD Bug Workflow v4 [ 1615437 ] New: JSD Bug Workflow v5 [ 1956180 ]
            jonah (Inactive) made changes -
            Description Original: We have a plugin that injects some javascript into SD customer portal. This plugin embellishes some custom fields with HTML generated based on REST calls to the plugin's REST endpoints.

            Our customer reported that their 'customer' users do not the proper embellishments, instead they get some Javascript error. It turned out that when a user who is not in jira-users (an SD 'customer') is accessing the page with our plugin on it, the plugin makes a REST call that gets 302-redirected to /servicedesk/customer/portal/1. Which means that everything gets broken. Adding @AnonymousAllowed annotation to the plugin's endpoint does not help, as it only works when the user is actually not logged-in. When they log in, apparently SD servlet filter (or whatever) redirects blindly to a bad place.

            This is breaking our plugin in very bad ways and we are likely losing sales because of this.

            Are there any workarounds for this behaviour? I have tried injecting a serlet filter, but it is not being invoked.

            The plugin in question is https://marketplace.atlassian.com/plugins/com.spartez.jira.plugins.ephor-for-jira, but the behaviour can be trivially reproduced with any plugin that has a REST endpoint. Just log in as an SD 'customer' and go to plugin's REST endpoint
            New: {panel:bgColor=#e7f4fa}
              *NOTE:* This bug report is for *JIRA Service Desk Server*. Using *JIRA Service Desk Cloud*? [See the corresponding bug report|http://jira.atlassian.com/browse/JSDCLOUD-1640].
              {panel}

            We have a plugin that injects some javascript into SD customer portal. This plugin embellishes some custom fields with HTML generated based on REST calls to the plugin's REST endpoints.

            Our customer reported that their 'customer' users do not the proper embellishments, instead they get some Javascript error. It turned out that when a user who is not in jira-users (an SD 'customer') is accessing the page with our plugin on it, the plugin makes a REST call that gets 302-redirected to /servicedesk/customer/portal/1. Which means that everything gets broken. Adding @AnonymousAllowed annotation to the plugin's endpoint does not help, as it only works when the user is actually not logged-in. When they log in, apparently SD servlet filter (or whatever) redirects blindly to a bad place.

            This is breaking our plugin in very bad ways and we are likely losing sales because of this.

            Are there any workarounds for this behaviour? I have tried injecting a serlet filter, but it is not being invoked.

            The plugin in question is https://marketplace.atlassian.com/plugins/com.spartez.jira.plugins.ephor-for-jira, but the behaviour can be trivially reproduced with any plugin that has a REST endpoint. Just log in as an SD 'customer' and go to plugin's REST endpoint
            jonah (Inactive) made changes -
            Link New: This issue relates to JSDCLOUD-1640 [ JSDCLOUD-1640 ]
            Matthew McMahon (Inactive) made changes -
            Status Original: Released to Cloud [ 11373 ] New: Done [ 10044 ]
            Lachlan G (Inactive) made changes -
            Fix Version/s New: 3.3.0 [ 61746 ]

              gjoseph Grégory Joseph (Inactive)
              eb21884a4418 Janusz Gorycki
              Affected customers:
              3 This affects my team
              Watchers:
              13 Start watching this issue

                Created:
                Updated:
                Resolved: