diff options
author | Jay Berkenbilt <ejb@ql.org> | 2022-01-26 19:17:57 +0100 |
---|---|---|
committer | Jay Berkenbilt <ejb@ql.org> | 2022-01-30 19:11:03 +0100 |
commit | 700dfa40d3d2c5b60bf5937f74c0ab59561115f8 (patch) | |
tree | 223b31e15b2778482105fc83330555a5af1826cf /include | |
parent | b5d41b16b874e322befbd3fa2dde07714f7090a3 (diff) | |
download | qpdf-700dfa40d3d2c5b60bf5937f74c0ab59561115f8.tar.zst |
QPDFJob: convert encryption handlers
Diffstat (limited to 'include')
-rw-r--r-- | include/qpdf/QPDFJob.hh | 20 | ||||
-rw-r--r-- | include/qpdf/auto_job_c_enc.hh | 19 |
2 files changed, 39 insertions, 0 deletions
diff --git a/include/qpdf/QPDFJob.hh b/include/qpdf/QPDFJob.hh index 9f4a1e70..cd83723c 100644 --- a/include/qpdf/QPDFJob.hh +++ b/include/qpdf/QPDFJob.hh @@ -217,6 +217,22 @@ class QPDFJob Config& config; }; + class EncConfig + { + friend class QPDFJob; + friend class Config; + public: + QPDF_DLL EncConfig& path(char const* parameter); + +# include <qpdf/auto_job_c_enc.hh> + + private: + EncConfig(Config&); + EncConfig(PagesConfig const&) = delete; + + Config& config; + }; + // Configuration is performed by calling methods XXX QXXXQ document class Config { @@ -228,6 +244,10 @@ class QPDFJob std::shared_ptr<PagesConfig> pages(); std::shared_ptr<UOConfig> overlay(); std::shared_ptr<UOConfig> underlay(); + std::shared_ptr<EncConfig> encrypt( + int keylen, + std::string const& user_password, + std::string const& owner_password); # include <qpdf/auto_job_c_main.hh> diff --git a/include/qpdf/auto_job_c_enc.hh b/include/qpdf/auto_job_c_enc.hh new file mode 100644 index 00000000..e808de6c --- /dev/null +++ b/include/qpdf/auto_job_c_enc.hh @@ -0,0 +1,19 @@ +// +// This file is automatically generated by generate_auto_job. +// Edits will be automatically overwritten if the build is +// run in maintainer mode. +// +QPDF_DLL Config& end(); +QPDF_DLL EncConfig& extract(char const* parameter); +QPDF_DLL EncConfig& annotate(char const* parameter); +QPDF_DLL EncConfig& print(char const* parameter); +QPDF_DLL EncConfig& modify(char const* parameter); +QPDF_DLL EncConfig& cleartextMetadata(); +QPDF_DLL EncConfig& forceV4(); +QPDF_DLL EncConfig& accessibility(char const* parameter); +QPDF_DLL EncConfig& assemble(char const* parameter); +QPDF_DLL EncConfig& form(char const* parameter); +QPDF_DLL EncConfig& modifyOther(char const* parameter); +QPDF_DLL EncConfig& useAes(char const* parameter); +QPDF_DLL EncConfig& forceR5(); +QPDF_DLL EncConfig& allowInsecure(); |