...

Text file src/go.mongodb.org/mongo-driver/testdata/client-side-encryption/legacy/getMore.json

Documentation: go.mongodb.org/mongo-driver/testdata/client-side-encryption/legacy

     1{
     2  "runOn": [
     3    {
     4      "minServerVersion": "4.1.10"
     5    }
     6  ],
     7  "database_name": "default",
     8  "collection_name": "default",
     9  "data": [
    10    {
    11      "_id": 1,
    12      "encrypted_string": {
    13        "$binary": {
    14          "base64": "AQAAAAAAAAAAAAAAAAAAAAACwj+3zkv2VM+aTfk60RqhXq6a/77WlLwu/BxXFkL7EppGsju/m8f0x5kBDD3EZTtGALGXlym5jnpZAoSIkswHoA==",
    15          "subType": "06"
    16        }
    17      }
    18    },
    19    {
    20      "_id": 2,
    21      "encrypted_string": {
    22        "$binary": {
    23          "base64": "AQAAAAAAAAAAAAAAAAAAAAACDdw4KFz3ZLquhsbt7RmDjD0N67n0uSXx7IGnQNCLeIKvot6s/ouI21Eo84IOtb6lhwUNPlSEBNY0/hbszWAKJg==",
    24          "subType": "06"
    25        }
    26      }
    27    },
    28    {
    29      "_id": 3,
    30      "encrypted_string": {
    31        "$binary": {
    32          "base64": "AQAAAAAAAAAAAAAAAAAAAAACQ76HWOut3DZtQuV90hp1aaCpZn95vZIaWmn+wrBehcEtcFwyJlBdlyzDzZTWPZCPgiFq72Wvh6Y7VbpU9NAp3A==",
    33          "subType": "06"
    34        }
    35      }
    36    }
    37  ],
    38  "json_schema": {
    39    "properties": {
    40      "encrypted_w_altname": {
    41        "encrypt": {
    42          "keyId": "/altname",
    43          "bsonType": "string",
    44          "algorithm": "AEAD_AES_256_CBC_HMAC_SHA_512-Random"
    45        }
    46      },
    47      "encrypted_string": {
    48        "encrypt": {
    49          "keyId": [
    50            {
    51              "$binary": {
    52                "base64": "AAAAAAAAAAAAAAAAAAAAAA==",
    53                "subType": "04"
    54              }
    55            }
    56          ],
    57          "bsonType": "string",
    58          "algorithm": "AEAD_AES_256_CBC_HMAC_SHA_512-Deterministic"
    59        }
    60      },
    61      "random": {
    62        "encrypt": {
    63          "keyId": [
    64            {
    65              "$binary": {
    66                "base64": "AAAAAAAAAAAAAAAAAAAAAA==",
    67                "subType": "04"
    68              }
    69            }
    70          ],
    71          "bsonType": "string",
    72          "algorithm": "AEAD_AES_256_CBC_HMAC_SHA_512-Random"
    73        }
    74      },
    75      "encrypted_string_equivalent": {
    76        "encrypt": {
    77          "keyId": [
    78            {
    79              "$binary": {
    80                "base64": "AAAAAAAAAAAAAAAAAAAAAA==",
    81                "subType": "04"
    82              }
    83            }
    84          ],
    85          "bsonType": "string",
    86          "algorithm": "AEAD_AES_256_CBC_HMAC_SHA_512-Deterministic"
    87        }
    88      }
    89    },
    90    "bsonType": "object"
    91  },
    92  "key_vault_data": [
    93    {
    94      "status": 1,
    95      "_id": {
    96        "$binary": {
    97          "base64": "AAAAAAAAAAAAAAAAAAAAAA==",
    98          "subType": "04"
    99        }
   100      },
   101      "masterKey": {
   102        "provider": "aws",
   103        "key": "arn:aws:kms:us-east-1:579766882180:key/89fcc2c4-08b0-4bd9-9f25-e30687b580d0",
   104        "region": "us-east-1"
   105      },
   106      "updateDate": {
   107        "$date": {
   108          "$numberLong": "1552949630483"
   109        }
   110      },
   111      "keyMaterial": {
   112        "$binary": {
   113          "base64": "AQICAHhQNmWG2CzOm1dq3kWLM+iDUZhEqnhJwH9wZVpuZ94A8gEqnsxXlR51T5EbEVezUqqKAAAAwjCBvwYJKoZIhvcNAQcGoIGxMIGuAgEAMIGoBgkqhkiG9w0BBwEwHgYJYIZIAWUDBAEuMBEEDHa4jo6yp0Z18KgbUgIBEIB74sKxWtV8/YHje5lv5THTl0HIbhSwM6EqRlmBiFFatmEWaeMk4tO4xBX65eq670I5TWPSLMzpp8ncGHMmvHqRajNBnmFtbYxN3E3/WjxmdbOOe+OXpnGJPcGsftc7cB2shRfA4lICPnE26+oVNXT6p0Lo20nY5XC7jyCO",
   114          "subType": "00"
   115        }
   116      },
   117      "creationDate": {
   118        "$date": {
   119          "$numberLong": "1552949630483"
   120        }
   121      },
   122      "keyAltNames": [
   123        "altname",
   124        "another_altname"
   125      ]
   126    }
   127  ],
   128  "tests": [
   129    {
   130      "description": "getMore with encryption",
   131      "clientOptions": {
   132        "autoEncryptOpts": {
   133          "kmsProviders": {
   134            "aws": {}
   135          }
   136        }
   137      },
   138      "operations": [
   139        {
   140          "name": "find",
   141          "arguments": {
   142            "batchSize": 2,
   143            "filter": {}
   144          },
   145          "result": [
   146            {
   147              "_id": 1,
   148              "encrypted_string": "string0"
   149            },
   150            {
   151              "_id": 2,
   152              "encrypted_string": "string1"
   153            },
   154            {
   155              "_id": 3,
   156              "encrypted_string": "string2"
   157            }
   158          ]
   159        }
   160      ],
   161      "expectations": [
   162        {
   163          "command_started_event": {
   164            "command": {
   165              "listCollections": 1,
   166              "filter": {
   167                "name": "default"
   168              }
   169            },
   170            "command_name": "listCollections"
   171          }
   172        },
   173        {
   174          "command_started_event": {
   175            "command": {
   176              "find": "default",
   177              "batchSize": 2
   178            },
   179            "command_name": "find"
   180          }
   181        },
   182        {
   183          "command_started_event": {
   184            "command": {
   185              "find": "datakeys",
   186              "filter": {
   187                "$or": [
   188                  {
   189                    "_id": {
   190                      "$in": [
   191                        {
   192                          "$binary": {
   193                            "base64": "AAAAAAAAAAAAAAAAAAAAAA==",
   194                            "subType": "04"
   195                          }
   196                        }
   197                      ]
   198                    }
   199                  },
   200                  {
   201                    "keyAltNames": {
   202                      "$in": []
   203                    }
   204                  }
   205                ]
   206              },
   207              "$db": "keyvault",
   208              "readConcern": {
   209                "level": "majority"
   210              }
   211            },
   212            "command_name": "find"
   213          }
   214        },
   215        {
   216          "command_started_event": {
   217            "command": {
   218              "getMore": {
   219                "$$type": "long"
   220              },
   221              "collection": "default",
   222              "batchSize": 2
   223            },
   224            "command_name": "getMore"
   225          }
   226        }
   227      ],
   228      "outcome": {
   229        "collection": {
   230          "data": [
   231            {
   232              "_id": 1,
   233              "encrypted_string": {
   234                "$binary": {
   235                  "base64": "AQAAAAAAAAAAAAAAAAAAAAACwj+3zkv2VM+aTfk60RqhXq6a/77WlLwu/BxXFkL7EppGsju/m8f0x5kBDD3EZTtGALGXlym5jnpZAoSIkswHoA==",
   236                  "subType": "06"
   237                }
   238              }
   239            },
   240            {
   241              "_id": 2,
   242              "encrypted_string": {
   243                "$binary": {
   244                  "base64": "AQAAAAAAAAAAAAAAAAAAAAACDdw4KFz3ZLquhsbt7RmDjD0N67n0uSXx7IGnQNCLeIKvot6s/ouI21Eo84IOtb6lhwUNPlSEBNY0/hbszWAKJg==",
   245                  "subType": "06"
   246                }
   247              }
   248            },
   249            {
   250              "_id": 3,
   251              "encrypted_string": {
   252                "$binary": {
   253                  "base64": "AQAAAAAAAAAAAAAAAAAAAAACQ76HWOut3DZtQuV90hp1aaCpZn95vZIaWmn+wrBehcEtcFwyJlBdlyzDzZTWPZCPgiFq72Wvh6Y7VbpU9NAp3A==",
   254                  "subType": "06"
   255                }
   256              }
   257            }
   258          ]
   259        }
   260      }
   261    }
   262  ]
   263}

View as plain text