Uploaded image for project: 'Couchbase Server'
  1. Couchbase Server
  2. MB-7631

Bodies for deleted documents shouldn't be read (causes garbage data to be read)

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Critical
    • 2.0.1
    • 2.0
    • storage-engine
    • Security Level: Public
    • None
    • Observed on Mac and Linux platforms

    Description

      Steps to reproduce:

      1. Set up XDCR (observed when sending to ElasticSearch but not believe to be related to this)
      2. Create JSON document
      3. Observe that document is replicated as expected to remote side

      [{meta=

      {id=2, rev=2-000015818d7d3c0a0000000000000000, expiration=0, flags=0}

      , base64=eyJjbGljayI6InRvIGVkaXQiLCJuZXcgaW4gMi4wIjoidGhlcmUgYXJlIG5vIHJlc2VydmVkIGZpZWxkIG5hbWVzIn0=}]

      in the _bulk_docs request the document appears to be JSON and the base64 data correctly represents the document

      4. Delete the document
      5. Observe that the document deletion is replicated across to remote side, but with some unusual settings:

      [{meta=

      {id=2, rev=3-000015818d7d3c0b0000000000000000, att_reason=non-JSON mode, expiration=0, flags=0, deleted=true}

      , base64=V1QBAOAAAENfbG9jYWwvdmJzdGF0ZXsiBQdoIjogImFjdGl2ZSIsICJjaGVja3BvaW50X2lkARsAMQEWXG1heF9kZWxldGVkX3NlcW5vIjogIjAifQ==}]

      Note that the document is indicated as binary (non-JSON mode) and that the the base64 encoded data appears to be some random memory on the server:

      echo "V1QBAOAAAENfbG9jYWwvdmJzdGF0ZXsiBQdoIjogImFjdGl2ZSIsICJjaGVja3BvaW50X2lkARsAMQEWXG1heF9kZWxldGVkX3NlcW5vIjogIjAifQ==" | base64 -D
      WT?C_local/vbstate

      {"h": "active", "checkpoint_id\max_deleted_seqno": "0"}

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            FilipeManana Filipe Manana (Inactive)
            mschoch Marty Schoch [X] (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            9 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty