From ede293946c2ae49a7868e4513dd8c1325b3f898d Mon Sep 17 00:00:00 2001 From: Aleksander Machniak <alec@alec.pl> Date: Sat, 02 Apr 2016 03:39:50 -0400 Subject: [PATCH] Merge branch 'attach-pgp-key' of https://github.com/guitarmanusa/roundcubemail-1 into guitarmanusa-attach-pgp-key --- plugins/enigma/lib/enigma_driver_gnupg.php | 11 +++++++++++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/plugins/enigma/lib/enigma_driver_gnupg.php b/plugins/enigma/lib/enigma_driver_gnupg.php index 5ddf724..ab4aa45 100644 --- a/plugins/enigma/lib/enigma_driver_gnupg.php +++ b/plugins/enigma/lib/enigma_driver_gnupg.php @@ -339,6 +339,17 @@ } } + public function pubkey_for_attach($email) + { + try { + $pubkey = $this->gpg->exportPublicKey($email, true); + return $pubkey; + } + catch (Exception $e) { + return $this->get_error_from_exception($e); + } + } + /** * Converts Crypt_GPG exception into Enigma's error object * -- Gitblit v1.9.1