diff --git a/src/PdfSharp/Pdf.Internal/PdfEncoders.cs b/src/PdfSharp/Pdf.Internal/PdfEncoders.cs index 661d4dc6..a2fb9195 100644 --- a/src/PdfSharp/Pdf.Internal/PdfEncoders.cs +++ b/src/PdfSharp/Pdf.Internal/PdfEncoders.cs @@ -398,6 +398,7 @@ public static byte[] FormatStringLiteral(byte[] bytes, bool unicode, bool prefix } else { + securityHandler?.EncryptBytes(bytes); pdf.Append('<'); for (int idx = 0; idx < count; idx++) pdf.AppendFormat("{0:X2}", bytes[idx]);