diff options
author | RĂ¼diger Timm <rt@openoffice.org> | 2005-11-11 08:20:03 +0000 |
---|---|---|
committer | RĂ¼diger Timm <rt@openoffice.org> | 2005-11-11 08:20:03 +0000 |
commit | 1139ced54fa574098c714407ade3a0ad3bca0d28 (patch) | |
tree | e7a548c29e4d46bc9764ea56adcb91f706bac1c4 /xmlsecurity/source/xmlsec/mscrypt/xmlencryption_mscryptimpl.cxx | |
parent | 813e1f5a8ae4800e8a11c612de4e3b0a97f1368d (diff) |
INTEGRATION: CWS xmlsec13 (1.4.28); FILE MERGED
2005/10/31 13:41:10 jl 1.4.28.2: RESYNC: (1.4-1.5); FILE MERGED
2005/10/25 08:19:20 jl 1.4.28.1: #54495# #54047# extra verification of certificates, better errorhandling
Diffstat (limited to 'xmlsecurity/source/xmlsec/mscrypt/xmlencryption_mscryptimpl.cxx')
-rw-r--r-- | xmlsecurity/source/xmlsec/mscrypt/xmlencryption_mscryptimpl.cxx | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/xmlsecurity/source/xmlsec/mscrypt/xmlencryption_mscryptimpl.cxx b/xmlsecurity/source/xmlsec/mscrypt/xmlencryption_mscryptimpl.cxx index 184d26711084..46b772d6aa1b 100644 --- a/xmlsecurity/source/xmlsec/mscrypt/xmlencryption_mscryptimpl.cxx +++ b/xmlsecurity/source/xmlsec/mscrypt/xmlencryption_mscryptimpl.cxx @@ -4,9 +4,9 @@ * * $RCSfile: xmlencryption_mscryptimpl.cxx,v $ * - * $Revision: 1.5 $ + * $Revision: 1.6 $ * - * last change: $Author: rt $ $Date: 2005-09-09 17:31:29 $ + * last change: $Author: rt $ $Date: 2005-11-11 09:20:03 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -184,7 +184,7 @@ SAL_CALL XMLEncryption_MSCryptImpl :: encrypt( isParentRef = sal_False; } - setErrorRecorder( aTemplate ); + setErrorRecorder( ); pMngr = pSecEnv->createKeysManager() ; //i39448 if( !pMngr ) { @@ -203,14 +203,13 @@ SAL_CALL XMLEncryption_MSCryptImpl :: encrypt( //Encrypt the template if( xmlSecEncCtxXmlEncrypt( pEncCtx , pEncryptedData , pContent ) < 0 ) { + aTemplate->setStatus(::com::sun::star::xml::crypto::SecurityOperationStatus_UNKNOWN); xmlSecEncCtxDestroy( pEncCtx ) ; pSecEnv->destroyKeysManager( pMngr ) ; //i39448 - - //throw XMLEncryptionException() ; clearErrorRecorder(); return aTemplate; } - + aTemplate->setStatus(::com::sun::star::xml::crypto::SecurityOperationStatus_OPERATION_SUCCEEDED); xmlSecEncCtxDestroy( pEncCtx ) ; pSecEnv->destroyKeysManager( pMngr ) ; //i39448 @@ -292,7 +291,7 @@ XMLEncryption_MSCryptImpl :: decrypt( isParentRef = sal_False; } - setErrorRecorder( aTemplate ); + setErrorRecorder( ); pMngr = pSecEnv->createKeysManager() ; //i39448 if( !pMngr ) { @@ -311,6 +310,7 @@ XMLEncryption_MSCryptImpl :: decrypt( //Decrypt the template if( xmlSecEncCtxDecrypt( pEncCtx , pEncryptedData ) < 0 || pEncCtx->result == NULL ) { + aTemplate->setStatus(::com::sun::star::xml::crypto::SecurityOperationStatus_UNKNOWN); xmlSecEncCtxDestroy( pEncCtx ) ; pSecEnv->destroyKeysManager( pMngr ) ; //i39448 @@ -318,6 +318,7 @@ XMLEncryption_MSCryptImpl :: decrypt( clearErrorRecorder(); return aTemplate; } + aTemplate->setStatus(::com::sun::star::xml::crypto::SecurityOperationStatus_OPERATION_SUCCEEDED); /*---------------------------------------- if( pEncCtx->resultReplaced != 0 ) { pContent = pEncryptedData ; |