Class FieldLevelDecryptionService

java.lang.Object
de.otto.kafka.messaging.e2ee.fieldlevel.FieldLevelDecryptionService

public final class FieldLevelDecryptionService extends Object
  • Constructor Details

    • FieldLevelDecryptionService

      public FieldLevelDecryptionService(DecryptionService decryptionService)
    • FieldLevelDecryptionService

      public FieldLevelDecryptionService(EncryptionKeyProvider encryptionKeyProvider)
  • Method Details

    • decryptFieldValue

      public String decryptFieldValue(String kafkaTopicName, String encryptedString)
      decrypts the given text (depending on the content).
      Parameters:
      kafkaTopicName - name of the Kafka Topic the field value is from.
      encryptedString - the (potentially) encrypted text value. Can be null.
      Returns:
      The plain text or null
    • decryptFieldValue

      public String decryptFieldValue(String kafkaTopicName, EncryptedString encryptedString)
      decrypts the given text (depending on the content).
      Parameters:
      kafkaTopicName - name of the Kafka Topic the field value is from.
      encryptedString - the (potentially) encrypted text value. Can be null.
      Returns:
      The plain text or null