Bug 479393, move two functions within the file, no code change, rs=me

This commit is contained in:
Kai Engert 2011-05-05 22:41:40 +02:00
parent ea424a3b60
commit 01bf2a121b

View File

@ -670,34 +670,6 @@ nsNSSComponent::GetNSSBundleString(const char *name,
return rv;
}
NS_IMETHODIMP
nsNSSComponent::SkipOcsp()
{
nsNSSShutDownPreventionLock locker;
CERTCertDBHandle *certdb = CERT_GetDefaultCertDB();
SECStatus rv = CERT_DisableOCSPChecking(certdb);
return (rv == SECSuccess) ? NS_OK : NS_ERROR_FAILURE;
}
NS_IMETHODIMP
nsNSSComponent::SkipOcspOff()
{
nsNSSShutDownPreventionLock locker;
PRInt32 ocspEnabled;
if (NS_FAILED(mPrefBranch->GetIntPref("security.OCSP.enabled", &ocspEnabled)))
ocspEnabled = OCSP_ENABLED_DEFAULT;
// 0 = disabled, 1 = enabled,
// 2 = enabled with given default responder
setNonPkixOcspEnabled(ocspEnabled, mPrefBranch);
if (ocspEnabled)
SSL_ClearSessionCache();
return NS_OK;
}
void
nsNSSComponent::LaunchSmartCardThreads()
{
@ -1230,6 +1202,34 @@ void nsNSSComponent::setValidationOptions(nsIPrefBranch * pref)
SSL_ClearSessionCache();
}
NS_IMETHODIMP
nsNSSComponent::SkipOcsp()
{
nsNSSShutDownPreventionLock locker;
CERTCertDBHandle *certdb = CERT_GetDefaultCertDB();
SECStatus rv = CERT_DisableOCSPChecking(certdb);
return (rv == SECSuccess) ? NS_OK : NS_ERROR_FAILURE;
}
NS_IMETHODIMP
nsNSSComponent::SkipOcspOff()
{
nsNSSShutDownPreventionLock locker;
PRInt32 ocspEnabled;
if (NS_FAILED(mPrefBranch->GetIntPref("security.OCSP.enabled", &ocspEnabled)))
ocspEnabled = OCSP_ENABLED_DEFAULT;
// 0 = disabled, 1 = enabled,
// 2 = enabled with given default responder
setNonPkixOcspEnabled(ocspEnabled, mPrefBranch);
if (ocspEnabled)
SSL_ClearSessionCache();
return NS_OK;
}
nsresult
nsNSSComponent::PostCRLImportEvent(const nsCSubstring &urlString,
nsIStreamListener *listener)