Discuss this help topic in SecureBlackbox Forum

Tune up PGP protection

Besides providing access to general security settings, such as encryption algorithms, keys or passwords, TElPGPWriter also allows to fine-tune secondary protection properties. While not playing the main role in the protection routine, those settings may be helpful in adjusting the exact view of the message, making it conform to specific policies and requirements, and sometimes solving compatibility issues with legacy and non-compliant PGP applications.

  • Armor: if set to true, makes the component encode the binary output with text-friendly base64 encoding.
  • ArmorBoundary defines the header to put on top of the base64-encoded data. The default value is "PGP MESSAGE". This property is only considered if Armor is set to true.
  • ArmorHeaders allows to specify a collection of custom headers to be added to the header of the armoured message. These are supposed to be provided in the "Name: Value" form, e.g. "Version: SuperPGP", "Comment: the picture you requested". This property is only considered if Armor is set to true.
  • Compress: if set to true, the source file will be compressed prior to encryption. Use CompressionAlgorithm property to specify the exact compression algorithm (e.g. SBConstants.Unit.SB_PGP_ALGORITHM_CM_ZLIB) and CompressionLevel to provide the exact compression level (1 to 9).
  • Protection: one of ptLow, ptNormal or ptHigh. Specifies the sophistication level of password-to-key mechanism. Only applicable to password-based encryption. You might consider to try different Protection modes if a third-party software is struggling to decrypt your password-encrypted files.
  • SignBufferingMethod: either of sbmTemporaryStream or sbmRewind. Where the source file needs to be scanned two times (with certain signing modes), this property allows you to choose between rewinding the source stream and storing its contents in a temporary file. A temporary file-based solution is a good option where the source stream can't be rewound, e.g. the data is read from an unseekable network stream.
  • UseOldPackets makes TElPGPWriter use old (PGP 2.6.x) packet format. Setting this to true is a good choice where you need compatibility with legacy PGP 2.6.x software.
  • UseNewFeatures makes TElPGPWriter use newer PGP features, such as MDC packets and one-pass signatures. While utilizing modern protection techniques, this setting may result in incompatibility with older implementations.
  • InputIsText states that the input should be treated as text and not binary data.
  • PreserveFilePaths: when encrypting multiple files, makes TElPGPWriter preserve the complete paths of the source files.

How To articles about file encryption and signing with OpenPGP

Discuss this help topic in SecureBlackbox Forum