diff options
author | Vasily Melenchuk <vasily.melenchuk@cib.de> | 2019-09-03 21:08:34 +0300 |
---|---|---|
committer | Thorsten Behrens <Thorsten.Behrens@CIB.de> | 2020-05-25 10:04:15 +0200 |
commit | b9353394f46e46485fd148f2842f0c1e8e5322e3 (patch) | |
tree | bf3dcc20cafbc00275c7154858379361b5147ff9 /unotools | |
parent | 2f17679a46ca1336cb82ef652e09f423c5b8923d (diff) |
[MS-OFFCRYPTO] convert oox implementation into UNO service
To permit pluggable crypto services, abstract existing
implementation behind an XPackageEncryption API.
Previous code already had two halfway-polymorphic classes (agile and
standard 2007 engine), so we're not adding much additional layers.
As MS crypto always uses OLE storage to wrap content into one single
file, current implementation passes all substorage names down into
XPackageEncryption APi, so different downstream implementations (e.g.
for MS RMS, or Azure AIP) are possible.
Because OleStorage classes are internal to LibO core, access is provided
via XInput/XOutput stream API function.
Change-Id: Icc32a4e0ce215090c3b739f1dcaa0654b36b7f08
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/84436
Tested-by: Jenkins
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Diffstat (limited to 'unotools')
-rw-r--r-- | unotools/source/misc/mediadescriptor.cxx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/unotools/source/misc/mediadescriptor.cxx b/unotools/source/misc/mediadescriptor.cxx index 1b830fb4e7d9..7f8f4e3c3785 100644 --- a/unotools/source/misc/mediadescriptor.cxx +++ b/unotools/source/misc/mediadescriptor.cxx @@ -473,8 +473,9 @@ css::uno::Sequence< css::beans::NamedValue > MediaDescriptor::requestAndVerifyDo erase( PROP_PASSWORD() ); erase( PROP_ENCRYPTIONDATA() ); - // insert valid password into media descriptor (but not a default password) - if( aEncryptionData.hasElements() && !bIsDefaultPassword ) + // insert encryption info into media descriptor + // TODO + if( aEncryptionData.hasElements() ) (*this)[ PROP_ENCRYPTIONDATA() ] <<= aEncryptionData; return aEncryptionData; |