diff options
-rw-r--r-- | core/java/android/webkit/BrowserFrame.java | 5 | ||||
-rw-r--r-- | core/java/android/webkit/SslCertLookupTable.java | 7 |
2 files changed, 5 insertions, 7 deletions
diff --git a/core/java/android/webkit/BrowserFrame.java b/core/java/android/webkit/BrowserFrame.java index c107aeb..8c22da0 100644 --- a/core/java/android/webkit/BrowserFrame.java +++ b/core/java/android/webkit/BrowserFrame.java @@ -471,8 +471,6 @@ class BrowserFrame extends Handler { /** * We have received an SSL certificate for the main top-level page. - * - * !!!Called from the network thread!!! */ void certificate(SslCertificate certificate) { if (mIsMainFrame) { @@ -1186,12 +1184,11 @@ class BrowserFrame extends Handler { SslErrorHandler handler = new SslErrorHandler() { @Override public void proceed() { - SslCertLookupTable.getInstance().setIsAllowed(sslError, true); + SslCertLookupTable.getInstance().setIsAllowed(sslError); nativeSslCertErrorProceed(handle); } @Override public void cancel() { - SslCertLookupTable.getInstance().setIsAllowed(sslError, false); nativeSslCertErrorCancel(handle, certError); } }; diff --git a/core/java/android/webkit/SslCertLookupTable.java b/core/java/android/webkit/SslCertLookupTable.java index 06d54be..a06836c 100644 --- a/core/java/android/webkit/SslCertLookupTable.java +++ b/core/java/android/webkit/SslCertLookupTable.java @@ -25,7 +25,8 @@ import java.net.URL; /** * Stores the user's decision of whether to allow or deny an invalid certificate. * - * This class is not threadsafe. It is used only on the WebCore thread. + * This class is not threadsafe. It is used only on the WebCore thread. Also, it + * is used only by the Chromium HTTP stack. */ final class SslCertLookupTable { private static SslCertLookupTable sTable; @@ -42,11 +43,11 @@ final class SslCertLookupTable { table = new Bundle(); } - public void setIsAllowed(SslError sslError, boolean allow) { + public void setIsAllowed(SslError sslError) { // TODO: We should key on just the host. See http://b/5409251. String errorString = sslErrorToString(sslError); if (errorString != null) { - table.putBoolean(errorString, allow); + table.putBoolean(errorString, true); } } |