diff --git a/lang/cpp/src/context.cpp b/lang/cpp/src/context.cpp index 11211048..ada7bead 100644 --- a/lang/cpp/src/context.cpp +++ b/lang/cpp/src/context.cpp @@ -466,6 +466,16 @@ Error Context::setEngineHomeDirectory(const char *home_dir) return Error(gpgme_ctx_set_engine_info(d->ctx, gpgme_get_protocol(d->ctx), filename, home_dir)); } +Error Context::setSender (const char *sender) +{ + return Error(gpgme_set_sender(d->ctx, sender)); +} + +const char *Context::getSender () +{ + return gpgme_get_sender(d->ctx); +} + // // // Key Management diff --git a/lang/cpp/src/context.h b/lang/cpp/src/context.h index ab15a218..2c205b02 100644 --- a/lang/cpp/src/context.h +++ b/lang/cpp/src/context.h @@ -304,6 +304,10 @@ public: GpgME::Error startSigning(const Data &plainText, Data &signature, SignatureMode mode); SigningResult signingResult() const; + // wrapper for gpgme_set_sender + const char *getSender(); + GpgME::Error setSender(const char *sender); + // // Encryption //