summaryrefslogtreecommitdiff
path: root/xmlsecurity
diff options
context:
space:
mode:
Diffstat (limited to 'xmlsecurity')
-rw-r--r--xmlsecurity/source/xmlsec/mscrypt/sanextension_mscryptimpl.cxx7
-rw-r--r--xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.cxx7
-rw-r--r--xmlsecurity/source/xmlsec/mscrypt/seinitializer_mscryptimpl.cxx3
-rw-r--r--xmlsecurity/source/xmlsec/mscrypt/x509certificate_mscryptimpl.cxx5
4 files changed, 13 insertions, 9 deletions
diff --git a/xmlsecurity/source/xmlsec/mscrypt/sanextension_mscryptimpl.cxx b/xmlsecurity/source/xmlsec/mscrypt/sanextension_mscryptimpl.cxx
index fbff7f04f588..54eaafbfc036 100644
--- a/xmlsecurity/source/xmlsec/mscrypt/sanextension_mscryptimpl.cxx
+++ b/xmlsecurity/source/xmlsec/mscrypt/sanextension_mscryptimpl.cxx
@@ -27,6 +27,7 @@
#include <com/sun/star/security/CertAltNameEntry.hpp>
#include <com/sun/star/beans/NamedValue.hpp>
#include <comphelper/sequence.hxx>
+#include <o3tl/char16_t2wchar_t.hxx>
#include "sanextension_mscryptimpl.hxx"
@@ -93,11 +94,11 @@ css::uno::Sequence< css::security::CertAltNameEntry > SAL_CALL SanExtensionImpl:
}
case CERT_ALT_NAME_RFC822_NAME :
arrCertAltNameEntry[i].Type = ExtAltNameType_RFC822_NAME;
- arrCertAltNameEntry[i].Value <<= OUString(SAL_U(pEntry->pwszRfc822Name));
+ arrCertAltNameEntry[i].Value <<= OUString(o3tl::toU(pEntry->pwszRfc822Name));
break;
case CERT_ALT_NAME_DNS_NAME :
arrCertAltNameEntry[i].Type = ExtAltNameType_DNS_NAME;
- arrCertAltNameEntry[i].Value <<= OUString(SAL_U(pEntry->pwszDNSName));
+ arrCertAltNameEntry[i].Value <<= OUString(o3tl::toU(pEntry->pwszDNSName));
break;
case CERT_ALT_NAME_DIRECTORY_NAME :
{
@@ -106,7 +107,7 @@ css::uno::Sequence< css::security::CertAltNameEntry > SAL_CALL SanExtensionImpl:
}
case CERT_ALT_NAME_URL :
arrCertAltNameEntry[i].Type = ExtAltNameType_URL;
- arrCertAltNameEntry[i].Value <<= OUString(SAL_U(pEntry->pwszURL));
+ arrCertAltNameEntry[i].Value <<= OUString(o3tl::toU(pEntry->pwszURL));
break;
case CERT_ALT_NAME_IP_ADDRESS :
{
diff --git a/xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.cxx b/xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.cxx
index 32bb0a82f0a8..d7c41b731c11 100644
--- a/xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.cxx
+++ b/xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.cxx
@@ -50,6 +50,7 @@
#include <rtl/locale.h>
#include <osl/nlsupport.h>
#include <osl/process.h>
+#include <o3tl/char16_t2wchar_t.hxx>
using namespace ::com::sun::star::uno ;
using namespace ::com::sun::star::lang ;
@@ -299,7 +300,7 @@ static OUString get_system_name(const void *pvSystemStore,
{
ppwszSystemName = static_cast<LPCWSTR>(pvSystemStore);
}
- return SAL_U(ppwszSystemName);
+ return o3tl::toU(ppwszSystemName);
}
extern "C" BOOL WINAPI cert_enum_physical_store_callback(const void *,
@@ -309,7 +310,7 @@ extern "C" BOOL WINAPI cert_enum_physical_store_callback(const void *,
void *,
void *)
{
- OUString name(SAL_U(pwszStoreName));
+ OUString name(o3tl::toU(pwszStoreName));
if (dwFlags & CERT_PHYSICAL_STORE_PREDEFINED_ENUM_FLAG)
name += " (implicitly created)";
SAL_INFO("xmlsecurity.xmlsec", " Physical store: " << name);
@@ -433,7 +434,7 @@ Reference< XCertificate > SecurityEnvironment_MSCryptImpl::getCertificate( const
encoding = osl_getTextEncodingFromLocale( pLocale ) ;
//Create cert info from issue and serial
- LPCWSTR pszName = SAL_W( issuerName.getStr() );
+ LPCWSTR pszName = o3tl::toW( issuerName.getStr() );
if( ! ( CertStrToNameW(
X509_ASN_ENCODING | PKCS_7_ASN_ENCODING ,
diff --git a/xmlsecurity/source/xmlsec/mscrypt/seinitializer_mscryptimpl.cxx b/xmlsecurity/source/xmlsec/mscrypt/seinitializer_mscryptimpl.cxx
index 6fd3bdc85c24..2c3357e7fd9e 100644
--- a/xmlsecurity/source/xmlsec/mscrypt/seinitializer_mscryptimpl.cxx
+++ b/xmlsecurity/source/xmlsec/mscrypt/seinitializer_mscryptimpl.cxx
@@ -28,6 +28,7 @@
#include <com/sun/star/xml/crypto/XMLSecurityContext.hpp>
#include <comphelper/processfactory.hxx>
#include <cppuhelper/supportsservice.hxx>
+#include <o3tl/char16_t2wchar_t.hxx>
namespace cssu = com::sun::star::uno;
namespace cssl = com::sun::star::lang;
@@ -57,7 +58,7 @@ cssu::Reference< cssxc::XXMLSecurityContext > SAL_CALL
{
sCertDir = OString(sCertDB.getStr(), sCertDB.getLength(), RTL_TEXTENCODING_ASCII_US);
n_pCertStore = sCertDir.getStr();
- n_hStoreHandle = CertOpenSystemStoreW( NULL, SAL_W(sCertDB.getStr())) ;
+ n_hStoreHandle = CertOpenSystemStoreW( NULL, o3tl::toW(sCertDB.getStr())) ;
if( n_hStoreHandle == nullptr )
{
return nullptr;
diff --git a/xmlsecurity/source/xmlsec/mscrypt/x509certificate_mscryptimpl.cxx b/xmlsecurity/source/xmlsec/mscrypt/x509certificate_mscryptimpl.cxx
index c45b541cf3d7..a4069a91798a 100644
--- a/xmlsecurity/source/xmlsec/mscrypt/x509certificate_mscryptimpl.cxx
+++ b/xmlsecurity/source/xmlsec/mscrypt/x509certificate_mscryptimpl.cxx
@@ -31,6 +31,7 @@
#include <rtl/locale.h>
#include <osl/nlsupport.h>
#include <osl/process.h>
+#include <o3tl/char16_t2wchar_t.hxx>
#include <memory>
#include <utility>
@@ -228,7 +229,7 @@ OUString SAL_CALL X509Certificate_MSCryptImpl::getIssuerName() {
}
if(issuer.get()[cchIssuer -1] == 0) cchIssuer--; //delimit the last 0x00;
- OUString xIssuer(SAL_U(issuer.get()), cchIssuer) ;
+ OUString xIssuer(o3tl::toU(issuer.get()), cchIssuer) ;
return replaceTagSWithTagST(xIssuer);
} else {
@@ -265,7 +266,7 @@ OUString SAL_CALL X509Certificate_MSCryptImpl::getSubjectName()
throw RuntimeException() ;
}
- OUString xSubject(SAL_U(subject.get()));
+ OUString xSubject(o3tl::toU(subject.get()));
return replaceTagSWithTagST(xSubject);
} else