Interface EncryptablePropertyDetector

All Known Implementing Classes:
DefaultLazyPropertyDetector, DefaultPropertyDetector

public interface EncryptablePropertyDetector
Interface that provides the contract to detect an unwrap encrypted properties. For instance, if encrypted properties are to be prefixed with "ENC(" and suffixed with ")" then the implementation of isEncrypted(String) would return true when a property effectively enclosed in such prefix/suffix and unwrapEncryptedValue(String) would return the encrypted value, the portion of the property without the prefix and suffix.
Version:
$Id: $Id
Author:
Ulises Bocchio
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    isEncrypted(String property)
    Returns whether a property is encrypted or not.
    Returns the portion of the property that is actually the encrypted value without any extra metadata such as prefixes and suffixes.
  • Method Details

    • isEncrypted

      boolean isEncrypted(String property)
      Returns whether a property is encrypted or not. Usually based on prefixes and suffixes.
      Parameters:
      property - the property value to check whether is encrypted or not.
      Returns:
      true if the property is encrypted.
    • unwrapEncryptedValue

      String unwrapEncryptedValue(String property)
      Returns the portion of the property that is actually the encrypted value without any extra metadata such as prefixes and suffixes.
      Parameters:
      property - the property value to extract the encrypted value.
      Returns:
      the encrypted portion of the property value.