Uploaded image for project: 'Documentation'
  1. Documentation
  2. DOCS-15163

[Drivers] Errors in Doc

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major - P3
    • Resolution: Done
    • None
    • None
    • drivers
    • None

    Description

      https://docs.mongodb.com/drivers/security/client-side-field-level-encryption-local-key-to-kms/

      Section 4 - "Create a New Data Encryption Key" 

      Java Sync instructions missing

       
      String keyVaultNamespace = "admin.datakeys";
      ClientEncryption clientEncryption = ClientEncryptions.create(ClientEncryptionSettings.builder() ...
       
      and wrong parenthesis and comma positioning:
       

      BsonString masterKeyArn = new BsonString("<Master Key ARN>"); // e.g. "arn:aws:kms:us-east-2:111122223333:alias/test-key"
      BsonString masterKeyRegion = new BsonString("<Master Key Region>")
      DataKeyOptions dataKeyOptions = new DataKeyOptions().masterKey(
      new BsonDocument()
      .append("key", masterKeyArn));
      .append("region", masterKeyRegion)

      should be

      BsonString masterKeyArn = new BsonString("<Master Key ARN>"); // e.g. "arn:aws:kms:us-east-2:111122223333:alias/test-key"
      BsonString masterKeyRegion = new BsonString("<Master Key Region>")
      DataKeyOptions dataKeyOptions = new DataKeyOptions().masterKey(
      new BsonDocument()
      .append("key", masterKeyArn)
      .append("region", masterKeyRegion));

      Attachments

        Activity

          People

            jordan.smith@mongodb.com Jordan Smith
            greg.cox@mongodb.com Greg Cox
            Githook User Githook User
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              20 weeks, 5 days ago