mirror of
https://github.com/gotenberg/gotenberg.git
synced 2026-08-08 00:22:14 +01:00
feat: add PDF encryption feature (#1217)
* Adding PDF encryption option * LibreOffice * QPDF * PDFtk * pdfcpu * Update pkg/modules/pdfengines/pdfengines.go Co-authored-by: Julien Neuhart <neuhart.julien@gmail.com> * npx prettier * go fmt * PR comments * Update test/integration/scenario/scenario.go Co-authored-by: Julien Neuhart <neuhart.julien@gmail.com> * renamed ProtectWithPassword to encrypt * more clean up * Use the same input path as requested * This commit completes the encryption implementation * Clean up. Added webhook, disable route and download from tests --------- Co-authored-by: Julien Neuhart <neuhart.julien@gmail.com>
This commit is contained in:
committed by
Julien Neuhart
parent
638c4e6b23
commit
99307befdd
@@ -176,6 +176,11 @@ func (engine *ExifTool) WriteMetadata(ctx context.Context, logger *zap.Logger, m
|
||||
return nil
|
||||
}
|
||||
|
||||
// Encrypt is not available in this implementation.
|
||||
func (engine *ExifTool) Encrypt(ctx context.Context, logger *zap.Logger, inputPath, userPassword, ownerPassword string) error {
|
||||
return fmt.Errorf("encrypt PDF using ExifTool: %w", gotenberg.ErrPdfEncryptionNotSupported)
|
||||
}
|
||||
|
||||
// Interface guards.
|
||||
var (
|
||||
_ gotenberg.Module = (*ExifTool)(nil)
|
||||
|
||||
Reference in New Issue
Block a user