Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-8542

Delete character is allowed by JSON to BSON parser

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Minor - P4 Minor - P4
    • None
    • None
    • None
    • None
    • ALL
    • Hide

      add the following test to jsontests.cpp

      class QuotedFieldName7 : public Bad {
      virtual string json() const {
      return "

      { \"del\\u007Fdel\" : \"b\" }

      ";
      }
      };

      and the output is

      JsonTests::FromJsonTests::QuotedFieldName7 Expected expression fromjson( json() ) to throw MsgAssertionException but it threw nothing. @src/mongo/dbtests/jsontests.cpp:447

      Show
      add the following test to jsontests.cpp class QuotedFieldName7 : public Bad { virtual string json() const { return " { \"del\\u007Fdel\" : \"b\" } "; } }; and the output is JsonTests::FromJsonTests::QuotedFieldName7 Expected expression fromjson( json() ) to throw MsgAssertionException but it threw nothing. @src/mongo/dbtests/jsontests.cpp:447

    Attachments

      Activity

        People

          andrew.emil@10gen.com Andrew Emil (Inactive)
          andrew.emil@10gen.com Andrew Emil (Inactive)
          Votes:
          0 Vote for this issue
          Watchers:
          3 Start watching this issue

          Dates

            Created:
            Updated:
            Resolved: