Uploaded image for project: 'Confluence Data Center'
  1. Confluence Data Center
  2. CONFSERVER-93655

Getting HTTP 400 while saving page by using the close button.

    XMLWordPrintable

Details

    Description

      Issue Summary

      This is reproducible on Data Center: (yes)

      If the page contains one of the following characters sets in the content the saving process gets a HTTP 400 message.

      ../ 
      ..\ 
      …/ 
      …\
      

      Steps to Reproduce

      1. Create a fresh instance with Confluence 7.19.17
      2. Create test space
      3. Create a test page
      4. Insert ../ to the page and save it
      5. Then edit the page again and add new content then click Close to save as a draft
      6. Gets HTTP 400

      Expected Results

      The saving process should be completed properly.

      Actual Results

      Getting HTTP 400 message after clicking the close button.

      Workaround

      Option 1 - Using Confluence Source Editor

      1. Install the Confluence Source Editor app (from Atlassian Labs) in your Confluence Server/Data Center.
      2. Navigate to the affected page and select Edit at the top of the page.
      3. Select the Open in source editor button ('<>' symbol in the upper-right corner).
      4. Replace the below characters with ./ and .\
        ../ 
        ..\ 
        …/ 
        …\
        
      5. Click Apply then Update
      6. Refresh the page.

      Option 2 - Database Manipulation

      1. Find the page ID via UI —> How to get Confluence page ID
      2. Stop Confluence
      3. Create a backup of Confluence's database. Save somewhere offsite for safekeeping.
      4. Execute the below query if the Collaborative Editing is enabled on Confluence;
        update CONTENTPROPERTIES set stringval='synchrony-recovery' where propertyname = 'sync-rev-source' and contentid=<Page Id>;
        
      5. Run the following SQL query on Confluence's database:
        select * from bodycontent b where b.contentid=<Page Id>;
        
      6. Get the bodycontent from the above query and open it in a text editor.
      7. Replace the below characters with ./ and .\
        ../ 
        ..\ 
        …/ 
        …\
        
      8. Execute the below query to update bodycontent
        update bodycontent set body='<Copy Edited Content Here>' where contentid=<Page Id>;
        
      9. Start Confluence

      Please apply the changes on the test or staging environment first to prevent any data loss.

      Attachments

        Issue Links

          Activity

            People

              8b5c2ab424ac Jing Zheng
              ae95049760ab Kaan Çalışkan
              Votes:
              39 Vote for this issue
              Watchers:
              64 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: