Kaydet (Commit) 32f42d09 authored tarafından himajin100000's avatar himajin100000 Kaydeden (comit) Thorsten Behrens

tdf#116351: fix re-use of AttributeList on PGP manifest

multiple attributes of the same name on the same element,
because AttributeList was wrongly re-used

Change-Id: I29b2317ce3d836d7349fa0474709726bed2c5ad4
Reviewed-on: https://gerrit.libreoffice.org/51087Reviewed-by: 's avatarThorsten Behrens <Thorsten.Behrens@CIB.de>
Tested-by: 's avatarThorsten Behrens <Thorsten.Behrens@CIB.de>
üst fd67ee14
......@@ -232,8 +232,6 @@ ManifestExport::ManifestExport( uno::Reference< xml::sax::XDocumentHandler > con
{
// yeah, so that goes directly below the manifest:manifest
// element
::comphelper::AttributeList * pNewAttrList = new ::comphelper::AttributeList;
uno::Reference < xml::sax::XAttributeList > xNewAttrList (pNewAttrList);
OUStringBuffer aBuffer;
xHandler->ignorableWhitespace ( sWhiteSpace );
......@@ -268,6 +266,8 @@ ManifestExport::ManifestExport( uno::Reference< xml::sax::XDocumentHandler > con
xHandler->startElement( sEncryptedKeyElement, nullptr );
xHandler->ignorableWhitespace ( sWhiteSpace );
::comphelper::AttributeList * pNewAttrList = new ::comphelper::AttributeList;
uno::Reference < xml::sax::XAttributeList > xNewAttrList (pNewAttrList);
// TODO: the algorithm should rather be configurable
pNewAttrList->AddAttribute ( sAlgorithmAttribute, sCdataAttribute,
"http://www.w3.org/2001/04/xmlenc#rsa-oaep-mgf1p" );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment