summaryrefslogtreecommitdiff
path: root/xmlsecurity
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.co.uk>2018-05-03 22:18:25 +0200
committerMiklos Vajna <vmiklos@collabora.co.uk>2018-05-04 17:14:28 +0200
commit53a0298667172bfdab22fd969f2bb319a59938e4 (patch)
treeee9200647f9c600beb47ccbf461a1367cce43081 /xmlsecurity
parente51e0279e88dbb542518df93d86f8bb0d0a43e89 (diff)
xmlsecurity windows: stop using the "xmlSec" prefix for own code
xmlSec is the prefix for symbols from libxmlsec, it's confusing if our own code uses that as well. Change-Id: I3b003d2de067ba85e9f092c3c6aeac00dd4b1784 Reviewed-on: https://gerrit.libreoffice.org/53820 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Diffstat (limited to 'xmlsecurity')
-rw-r--r--xmlsecurity/source/xmlsec/mscrypt/akmngr.cxx15
-rw-r--r--xmlsecurity/source/xmlsec/mscrypt/akmngr.hxx13
-rw-r--r--xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.cxx10
3 files changed, 24 insertions, 14 deletions
diff --git a/xmlsecurity/source/xmlsec/mscrypt/akmngr.cxx b/xmlsecurity/source/xmlsec/mscrypt/akmngr.cxx
index b6c8a00dec98..778cb93e3f38 100644
--- a/xmlsecurity/source/xmlsec/mscrypt/akmngr.cxx
+++ b/xmlsecurity/source/xmlsec/mscrypt/akmngr.cxx
@@ -28,14 +28,17 @@
#include <xmlsec/mscrypto/keysstore.h>
#include <xmlsec/mscrypto/x509.h>
+namespace xmlsecurity
+{
+
/**
- * xmlSecMSCryptoAppliedKeysMngrCreate:
+ * MSCryptoAppliedKeysMngrCreate:
*
* Create and load key store and certificate database into keys manager
*
* Returns keys manager pointer on success or NULL otherwise.
*/
-xmlSecKeysMngrPtr xmlSecMSCryptoAppliedKeysMngrCreate()
+xmlSecKeysMngrPtr MSCryptoAppliedKeysMngrCreate()
{
xmlSecKeysMngrPtr keyMngr = nullptr ;
xmlSecKeyStorePtr keyStore = nullptr ;
@@ -120,7 +123,7 @@ xmlSecKeysMngrPtr xmlSecMSCryptoAppliedKeysMngrCreate()
}
int
-xmlSecMSCryptoAppliedKeysMngrAdoptKeyStore(
+MSCryptoAppliedKeysMngrAdoptKeyStore(
xmlSecKeysMngrPtr mngr,
HCERTSTORE keyStore
)
@@ -155,7 +158,7 @@ xmlSecMSCryptoAppliedKeysMngrAdoptKeyStore(
}
int
-xmlSecMSCryptoAppliedKeysMngrAdoptTrustedStore(
+MSCryptoAppliedKeysMngrAdoptTrustedStore(
xmlSecKeysMngrPtr mngr,
HCERTSTORE trustedStore
)
@@ -190,7 +193,7 @@ xmlSecMSCryptoAppliedKeysMngrAdoptTrustedStore(
}
int
-xmlSecMSCryptoAppliedKeysMngrAdoptUntrustedStore(
+MSCryptoAppliedKeysMngrAdoptUntrustedStore(
xmlSecKeysMngrPtr mngr,
HCERTSTORE untrustedStore
)
@@ -224,4 +227,6 @@ xmlSecMSCryptoAppliedKeysMngrAdoptUntrustedStore(
return 0 ;
}
+}
+
/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */
diff --git a/xmlsecurity/source/xmlsec/mscrypt/akmngr.hxx b/xmlsecurity/source/xmlsec/mscrypt/akmngr.hxx
index 670c80928f0a..04b94244bb01 100644
--- a/xmlsecurity/source/xmlsec/mscrypt/akmngr.hxx
+++ b/xmlsecurity/source/xmlsec/mscrypt/akmngr.hxx
@@ -29,26 +29,31 @@
#include <xmlsec/keys.h>
#include <xmlsec/transforms.h>
-xmlSecKeysMngrPtr xmlSecMSCryptoAppliedKeysMngrCreate();
+namespace xmlsecurity
+{
+
+xmlSecKeysMngrPtr MSCryptoAppliedKeysMngrCreate();
int
-xmlSecMSCryptoAppliedKeysMngrAdoptKeyStore(
+MSCryptoAppliedKeysMngrAdoptKeyStore(
xmlSecKeysMngrPtr mngr,
HCERTSTORE keyStore
) ;
int
-xmlSecMSCryptoAppliedKeysMngrAdoptTrustedStore(
+MSCryptoAppliedKeysMngrAdoptTrustedStore(
xmlSecKeysMngrPtr mngr,
HCERTSTORE trustedStore
) ;
int
-xmlSecMSCryptoAppliedKeysMngrAdoptUntrustedStore(
+MSCryptoAppliedKeysMngrAdoptUntrustedStore(
xmlSecKeysMngrPtr mngr,
HCERTSTORE untrustedStore
) ;
+}
+
#endif // INCLUDED_XMLSECURITY_SOURCE_XMLSEC_MSCRYPT_AKMNGR_HXX
/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */
diff --git a/xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.cxx b/xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.cxx
index 9f164d62e803..ecfdd15d1895 100644
--- a/xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.cxx
+++ b/xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.cxx
@@ -1021,7 +1021,7 @@ xmlSecKeysMngrPtr SecurityEnvironment_MSCryptImpl::createKeysManager() {
/*-
* The following lines is based on the of xmlsec-mscrypto crypto engine
*/
- pKeysMngr = xmlSecMSCryptoAppliedKeysMngrCreate() ;
+ pKeysMngr = xmlsecurity::MSCryptoAppliedKeysMngrCreate() ;
if( pKeysMngr == nullptr )
throw uno::RuntimeException() ;
@@ -1032,7 +1032,7 @@ xmlSecKeysMngrPtr SecurityEnvironment_MSCryptImpl::createKeysManager() {
//Add system key store into the keys manager.
m_hMySystemStore = CertOpenSystemStoreW( 0, L"MY" ) ;
if( m_hMySystemStore != nullptr ) {
- if( xmlSecMSCryptoAppliedKeysMngrAdoptKeyStore( pKeysMngr, m_hMySystemStore ) < 0 ) {
+ if( xmlsecurity::MSCryptoAppliedKeysMngrAdoptKeyStore( pKeysMngr, m_hMySystemStore ) < 0 ) {
CertCloseStore( m_hMySystemStore, CERT_CLOSE_STORE_CHECK_FLAG ) ;
m_hMySystemStore = nullptr;
throw uno::RuntimeException() ;
@@ -1042,7 +1042,7 @@ xmlSecKeysMngrPtr SecurityEnvironment_MSCryptImpl::createKeysManager() {
//Add system root store into the keys manager.
m_hRootSystemStore = CertOpenSystemStoreW( 0, L"Root" ) ;
if( m_hRootSystemStore != nullptr ) {
- if( xmlSecMSCryptoAppliedKeysMngrAdoptTrustedStore( pKeysMngr, m_hRootSystemStore ) < 0 ) {
+ if( xmlsecurity::MSCryptoAppliedKeysMngrAdoptTrustedStore( pKeysMngr, m_hRootSystemStore ) < 0 ) {
CertCloseStore( m_hRootSystemStore, CERT_CLOSE_STORE_CHECK_FLAG ) ;
m_hRootSystemStore = nullptr;
throw uno::RuntimeException() ;
@@ -1052,7 +1052,7 @@ xmlSecKeysMngrPtr SecurityEnvironment_MSCryptImpl::createKeysManager() {
//Add system trusted store into the keys manager.
m_hTrustSystemStore = CertOpenSystemStoreW( 0, L"Trust" ) ;
if( m_hTrustSystemStore != nullptr ) {
- if( xmlSecMSCryptoAppliedKeysMngrAdoptUntrustedStore( pKeysMngr, m_hTrustSystemStore ) < 0 ) {
+ if( xmlsecurity::MSCryptoAppliedKeysMngrAdoptUntrustedStore( pKeysMngr, m_hTrustSystemStore ) < 0 ) {
CertCloseStore( m_hTrustSystemStore, CERT_CLOSE_STORE_CHECK_FLAG ) ;
m_hTrustSystemStore = nullptr;
throw uno::RuntimeException() ;
@@ -1062,7 +1062,7 @@ xmlSecKeysMngrPtr SecurityEnvironment_MSCryptImpl::createKeysManager() {
//Add system CA store into the keys manager.
m_hCaSystemStore = CertOpenSystemStoreW( 0, L"CA" ) ;
if( m_hCaSystemStore != nullptr ) {
- if( xmlSecMSCryptoAppliedKeysMngrAdoptUntrustedStore( pKeysMngr, m_hCaSystemStore ) < 0 ) {
+ if( xmlsecurity::MSCryptoAppliedKeysMngrAdoptUntrustedStore( pKeysMngr, m_hCaSystemStore ) < 0 ) {
CertCloseStore( m_hCaSystemStore, CERT_CLOSE_STORE_CHECK_FLAG ) ;
m_hCaSystemStore = nullptr;
throw uno::RuntimeException() ;