diff --git a/xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.cxx b/xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.cxx index cad73681efff..68b29fd2d3c7 100644 --- a/xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.cxx +++ b/xmlsecurity/source/xmlsec/mscrypt/securityenvironment_mscryptimpl.cxx @@ -584,8 +584,7 @@ uno::Sequence< uno::Reference < XCertificate > > SecurityEnvironment_MSCryptImpl chainPara.cbSize = sizeof( CERT_CHAIN_PARA ) ; chainPara.RequestedUsage = certUsage ; - uno::Reference< XUnoTunnel > xCertTunnel( begin, uno::UNO_QUERY_THROW ) ; - const auto* xcert = comphelper::getFromUnoTunnel(xCertTunnel); + const auto* xcert = dynamic_cast(begin.get()); if( xcert == nullptr ) { throw uno::RuntimeException() ; } @@ -805,11 +804,9 @@ sal_Int32 SecurityEnvironment_MSCryptImpl::verifyCertificate( PCCERT_CHAIN_CONTEXT pChainContext = nullptr; PCCERT_CONTEXT pCertContext = nullptr; - uno::Reference< XUnoTunnel > xCertTunnel( aCert, uno::UNO_QUERY_THROW ) ; - SAL_INFO("xmlsecurity.xmlsec", "Start verification of certificate: " << aCert->getSubjectName()); - const auto* xcert = comphelper::getFromUnoTunnel(xCertTunnel); + const auto* xcert = dynamic_cast(aCert.get()); if( xcert == nullptr ) { throw uno::RuntimeException() ; } @@ -973,8 +970,7 @@ sal_Int32 SecurityEnvironment_MSCryptImpl::getCertificateCharacters( const css:: sal_Int32 characters ; PCCERT_CONTEXT pCertContext ; - uno::Reference< XUnoTunnel > xCertTunnel( aCert, uno::UNO_QUERY_THROW ) ; - const auto* xcert = comphelper::getFromUnoTunnel(xCertTunnel); + const auto* xcert = dynamic_cast(aCert.get()); if( xcert == nullptr ) { throw uno::RuntimeException() ; } diff --git a/xmlsecurity/source/xmlsec/mscrypt/x509certificate_mscryptimpl.cxx b/xmlsecurity/source/xmlsec/mscrypt/x509certificate_mscryptimpl.cxx index 88bf6169bf11..9c671d0c21c0 100644 --- a/xmlsecurity/source/xmlsec/mscrypt/x509certificate_mscryptimpl.cxx +++ b/xmlsecurity/source/xmlsec/mscrypt/x509certificate_mscryptimpl.cxx @@ -457,9 +457,6 @@ void X509Certificate_MSCryptImpl::setRawCert( Sequence< sal_Int8 > const & rawCe } } -/* XUnoTunnel */ -UNO3_GETIMPLEMENTATION_IMPL(X509Certificate_MSCryptImpl); - static OUString findOIDDescription(char const *oid) { OUString ouOID = OUString::createFromAscii( oid ); diff --git a/xmlsecurity/source/xmlsec/mscrypt/x509certificate_mscryptimpl.hxx b/xmlsecurity/source/xmlsec/mscrypt/x509certificate_mscryptimpl.hxx index 9bd6a34ce68e..ba02281794f6 100644 --- a/xmlsecurity/source/xmlsec/mscrypt/x509certificate_mscryptimpl.hxx +++ b/xmlsecurity/source/xmlsec/mscrypt/x509certificate_mscryptimpl.hxx @@ -30,7 +30,6 @@ #include #include #include -#include #include #include #include @@ -39,7 +38,6 @@ class X509Certificate_MSCryptImpl : public ::cppu::WeakImplHelper< css::security::XCertificate , - css::lang::XUnoTunnel, css::lang::XServiceInfo > , public xmlsecurity::Certificate { private: @@ -72,9 +70,6 @@ class X509Certificate_MSCryptImpl : public ::cppu::WeakImplHelper< virtual sal_Int32 SAL_CALL getCertificateUsage( ) override; - //Methods from XUnoTunnel - UNO3_GETIMPLEMENTATION_DECL(X509Certificate_MSCryptImpl) - /// @see xmlsecurity::Certificate::getSHA256Thumbprint(). virtual css::uno::Sequence getSHA256Thumbprint() override;