aboutsummaryrefslogtreecommitdiffstats
path: root/src/core/function/gpg/GpgKeyOpera.h
diff options
context:
space:
mode:
authorsaturneric <[email protected]>2023-12-03 12:28:46 +0000
committersaturneric <[email protected]>2023-12-03 12:28:46 +0000
commit883db05d54510e76b6548e107593187e1306117d (patch)
treea4de9d60d3bfeb69ba443129d208feef65250b2c /src/core/function/gpg/GpgKeyOpera.h
parentfeat: improve memory security of function framework (diff)
downloadGpgFrontend-883db05d54510e76b6548e107593187e1306117d.tar.gz
GpgFrontend-883db05d54510e76b6548e107593187e1306117d.zip
feat: general improvements of aync execution and memory security
Diffstat (limited to 'src/core/function/gpg/GpgKeyOpera.h')
-rw-r--r--src/core/function/gpg/GpgKeyOpera.h13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/core/function/gpg/GpgKeyOpera.h b/src/core/function/gpg/GpgKeyOpera.h
index dd2ee60d..34bcd976 100644
--- a/src/core/function/gpg/GpgKeyOpera.h
+++ b/src/core/function/gpg/GpgKeyOpera.h
@@ -31,7 +31,6 @@
#include <functional>
#include "core/function/gpg/GpgContext.h"
-#include "core/function/result_analyse/GpgResultAnalyse.h"
#include "core/typedef/GpgTypedef.h"
namespace boost::posix_time {
@@ -100,7 +99,7 @@ class GPGFRONTEND_CORE_EXPORT GpgKeyOpera
* @param key
* @return GpgFrontend::GpgError
*/
- void ModifyPassword(const GpgKey& key, std::function<void(gpgme_error_t)>);
+ void ModifyPassword(const GpgKey& key, const GpgOperationCallback&);
/**
* @brief
@@ -118,8 +117,8 @@ class GPGFRONTEND_CORE_EXPORT GpgKeyOpera
* @param result
* @return GpgFrontend::GpgError
*/
- auto GenerateKey(const std::unique_ptr<GenKeyInfo>& params,
- GpgGenKeyResult& result) -> GpgFrontend::GpgError;
+ void GenerateKey(const std::shared_ptr<GenKeyInfo>&,
+ const GpgOperationCallback&);
/**
* @brief
@@ -128,9 +127,9 @@ class GPGFRONTEND_CORE_EXPORT GpgKeyOpera
* @param params
* @return GpgFrontend::GpgError
*/
- auto GenerateSubkey(const GpgKey& key,
- const std::unique_ptr<GenKeyInfo>& params)
- -> GpgFrontend::GpgError;
+ void GenerateSubkey(const GpgKey& key,
+ const std::shared_ptr<GenKeyInfo>& params,
+ const GpgOperationCallback&);
private:
GpgContext& ctx_ =