Uploaded image for project: 'Service Packs and Hot Fixes'
  1. Service Packs and Hot Fixes
  2. MNT-20158

Blank variables are not allowed in /usr/local/tomcat/shared/classes/alfresco/substitutor.sh

    Details

      Description

      Description

      Blank variables are not allowed in /usr/local/tomcat/shared/classes/alfresco/substitutor.sh

      Supporting evidence

      ACS 6 docker image alfresco-share:6.0, Line 19 of script
      /usr/local/tomcat/shared/classes/alfresco/substitutor.sh contains...

      if [ $CSRF_FILTER_REFERER != "" ] && [ $CSRF_FILTER_ORIGIN != "" ]; then

      ... this results in an error when running the container, i.e. ...

      line 19: [: !=: unary operator expected

      The line in the script should be ...

      if [ "$CSRF_FILTER_REFERER" != "" ] && [ "$CSRF_FILTER_ORIGIN" != "" ]; then

      or

      if [[ $CSRF_FILTER_REFERER != "" ]] && [[ $CSRF_FILTER_ORIGIN != "" ]]; then

      To allow for blank variables.

      Expected Behaviour

      The line in the script should be ...

      if [ "$CSRF_FILTER_REFERER" != "" ] && [ "$CSRF_FILTER_ORIGIN" != "" ]; then

      or

      if [[ $CSRF_FILTER_REFERER != "" ]] && [[ $CSRF_FILTER_ORIGIN != "" ]]; then

      To allow for blank variables.

      Observed Behaviour

      if [ $CSRF_FILTER_REFERER != "" ] && [ $CSRF_FILTER_ORIGIN != "" ]; then

      ... this results in an error when running the container, i.e. ...

      line 19: [: !=: unary operator expected

        Attachments

          Structure

            Activity

              People

              • Assignee:
                closedbugs Closed Bugs
                Reporter:
                hjanjua Hassan Janjua
              • Votes:
                0 Vote for this issue
                Watchers:
                9 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Structure Helper Panel