summaryrefslogtreecommitdiff
path: root/xmlsecurity/source/helper/xsecsign.cxx
diff options
context:
space:
mode:
authorThorsten Behrens <Thorsten.Behrens@CIB.de>2017-06-20 23:52:18 +0200
committerThorsten Behrens <Thorsten.Behrens@CIB.de>2017-06-21 22:16:55 +0200
commit891d4b5d91c86951bb06d413808f75a3f4e6cb28 (patch)
tree675fa84bc74ae6f2dccf67e591e17e1d6b2facb4 /xmlsecurity/source/helper/xsecsign.cxx
parented92db7a50be36fcfe6e9b316f4b7f7570060c0d (diff)
gpg4libre: write PGPData info, get more metadata out for gpg key
Change-Id: Ia560869ec02fca7fe4219136e1fe939e13f1e4c2
Diffstat (limited to 'xmlsecurity/source/helper/xsecsign.cxx')
-rw-r--r--xmlsecurity/source/helper/xsecsign.cxx23
1 files changed, 23 insertions, 0 deletions
diff --git a/xmlsecurity/source/helper/xsecsign.cxx b/xmlsecurity/source/helper/xsecsign.cxx
index 092b8fb001e6..452613b4d10b 100644
--- a/xmlsecurity/source/helper/xsecsign.cxx
+++ b/xmlsecurity/source/helper/xsecsign.cxx
@@ -239,6 +239,29 @@ void XSecController::setX509Certificate(
}
}
+void XSecController::setGpgCertificate(
+ sal_Int32 nSecurityId,
+ const OUString& ouCertDigest,
+ const OUString& ouCert)
+{
+ int index = findSignatureInfor( nSecurityId );
+
+ if ( index == -1 )
+ {
+ InternalSignatureInformation isi(nSecurityId, nullptr);
+ isi.signatureInfor.ouGpgCertificate = ouCert;
+ isi.signatureInfor.ouCertDigest = ouCertDigest;
+ m_vInternalSignatureInformations.push_back( isi );
+ }
+ else
+ {
+ SignatureInformation &si
+ = m_vInternalSignatureInformations[index].signatureInfor;
+ si.ouGpgCertificate = ouCert;
+ si.ouCertDigest = ouCertDigest;
+ }
+}
+
void XSecController::setDate(
sal_Int32 nSecurityId,
const css::util::DateTime& rDateTime )