From 16b91e13c726b5b3f43c1aafde6fb8c4c18e3c77 Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Sat, 9 Nov 2013 16:24:56 +0100 Subject: Converge on SvtSecurityOptions::isTrustedLocation Change-Id: Ibcf4b7d9d11295c7679637a37d41dc2960e04f8f --- xmlsecurity/source/component/documentdigitalsignatures.cxx | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) (limited to 'xmlsecurity') diff --git a/xmlsecurity/source/component/documentdigitalsignatures.cxx b/xmlsecurity/source/component/documentdigitalsignatures.cxx index ceb76148066e..39095604ad3f 100644 --- a/xmlsecurity/source/component/documentdigitalsignatures.cxx +++ b/xmlsecurity/source/component/documentdigitalsignatures.cxx @@ -36,12 +36,10 @@ #include #include #include -#include #include #include #include #include -#include #include "comphelper/documentconstants.hxx" #include "com/sun/star/lang/IllegalArgumentException.hpp" @@ -439,17 +437,7 @@ Reference< css::security::XCertificate > DocumentDigitalSignatures::chooseCertif ::sal_Bool DocumentDigitalSignatures::isLocationTrusted( const OUString& Location ) throw (RuntimeException) { - sal_Bool bFound = sal_False; - INetURLObject aLocObj( Location ); - INetURLObject aLocObjLowCase( Location.toAsciiLowerCase() ); // will be used for case insensitive comparing - - Sequence< OUString > aSecURLs = SvtSecurityOptions().GetSecureURLs(); - const OUString* pSecURLs = aSecURLs.getConstArray(); - const OUString* pSecURLsEnd = pSecURLs + aSecURLs.getLength(); - for ( ; pSecURLs != pSecURLsEnd && !bFound; ++pSecURLs ) - bFound = ::utl::UCBContentHelper::IsSubPath( *pSecURLs, Location ); - - return bFound; + return SvtSecurityOptions().isTrustedLocationUri(Location); } void DocumentDigitalSignatures::addAuthorToTrustedSources( -- cgit v1.2.3