diff options
Diffstat (limited to 'sc/source/filter/inc/xestream.hxx')
-rw-r--r-- | sc/source/filter/inc/xestream.hxx | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/sc/source/filter/inc/xestream.hxx b/sc/source/filter/inc/xestream.hxx index 3308827441dd..38acef2783e8 100644 --- a/sc/source/filter/inc/xestream.hxx +++ b/sc/source/filter/inc/xestream.hxx @@ -30,6 +30,8 @@ #ifndef SC_XESTREAM_HXX #define SC_XESTREAM_HXX +#include <com/sun/star/beans/NamedValue.hpp> + #include <map> #include <stack> #include <string> @@ -216,13 +218,14 @@ private: class XclExpBiff8Encrypter { public: - explicit XclExpBiff8Encrypter( const XclExpRoot& rRoot, const sal_uInt8 nDocId[16], - const sal_uInt8 nSalt[16] ); + explicit XclExpBiff8Encrypter( const XclExpRoot& rRoot ); ~XclExpBiff8Encrypter(); bool IsValid() const; - void GetSaltDigest( sal_uInt8 nSaltDigest[16] ) const; + void GetSaltDigest( sal_uInt8 pnSaltDigest[16] ) const; + void GetSalt( sal_uInt8 pnSalt[16] ) const; + void GetDocId( sal_uInt8 pnDocId[16] ) const; void Encrypt( SvStream& rStrm, sal_uInt8 nData ); void Encrypt( SvStream& rStrm, sal_uInt16 nData ); @@ -238,17 +241,16 @@ public: void EncryptBytes( SvStream& rStrm, ::std::vector<sal_uInt8>& aBytes ); private: - void Init( const String& aPass, const sal_uInt8 nDocId[16], - const sal_uInt8 nSalt[16] ); + void Init( const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::NamedValue >& aEncryptionData ); sal_uInt32 GetBlockPos( sal_Size nStrmPos ) const; sal_uInt16 GetOffsetInBlock( sal_Size nStrmPos ) const; private: ::msfilter::MSCodec_Std97 maCodec; /// Crypto algorithm implementation. - sal_uInt16 mnPassw[16]; /// Cached password data for copy construction. - sal_uInt8 mnDocId[16]; /// Cached document ID for copy construction. - sal_uInt8 mnSaltDigest[16]; + sal_uInt8 mpnDocId[16]; + sal_uInt8 mpnSalt[16]; + sal_uInt8 mpnSaltDigest[16]; const XclExpRoot& mrRoot; sal_Size mnOldPos; /// Last known stream position |