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

Extend KMSService to support BSONObj cmks

    XMLWordPrintableJSON

Details

    • Icon: Task Task
    • Resolution: Fixed
    • Icon: Major - P3 Major - P3
    • 4.9.0
    • None
    • Shell
    • None
    • Fully Compatible
    • Security 2020-12-14

    Description

      Today, KMSService only supports encryptDataKey where a cmk is identified by a string. This does not support the needs of Azure and GCP which need their key information defined by BSON.

      KMService should be extended as follows:

      • add virtual StringData name() const = 0;
      • add virtual BSONObj encryptDataKey(ConstDataRange cdr, BSONObj keyId);
      • change the existing encryptDataKey to be non-abstract
      • create default implementations of encryptDataKey that throw errors saying the key format is unsupported.

      change EncryptedDBClientBase::generateDataKey to dispatch to the right encryptDataKey depending on type of the parameter, and adjust the type checking in KeyVault::_createKey.

      Attachments

        Activity

          People

            mark.benvenuto@mongodb.com Mark Benvenuto
            mark.benvenuto@mongodb.com Mark Benvenuto
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: