Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b890e758 authored by Iain Merrick's avatar Iain Merrick
Browse files

Add BrowserFrame.setCertificate() method.

This is needed for the Chrome HTTP stack to report SSL
certificates to WebView, in order to pass the CTS.

Change-Id: I0752a836ebaea21eae2084f037b18de4168f271f
parent 7450a32b
Loading
Loading
Loading
Loading
+11 −0
Original line number Diff line number Diff line
@@ -1177,6 +1177,17 @@ class BrowserFrame extends Handler {
                contentDisposition, mimeType, contentLength);
    }

    /**
     * Called by JNI when we load a page over SSL.
     */
    private void setCertificate(String issuedTo, String issuedBy,
            long validNotBeforeMillis, long validNotAfterMillis) {
        Date validNotBefore = new Date(validNotBeforeMillis);
        Date validNotAfter = new Date(validNotAfterMillis);
        mCallbackProxy.onReceivedCertificate(new SslCertificate(
                issuedTo, issuedBy, validNotBefore, validNotAfter));
    }

    //==========================================================================
    // native functions
    //==========================================================================