Title: [202361] trunk/Source/WebKit2
- Revision
- 202361
- Author
- [email protected]
- Date
- 2016-06-22 17:19:53 -0700 (Wed, 22 Jun 2016)
Log Message
Add SPI to allow creating a WKCertificateInfoRef from a SecTrustRef
https://bugs.webkit.org/show_bug.cgi?id=159025
Patch by Sam Weinig <[email protected]> on 2016-06-22
Reviewed by Tim Horton.
* Shared/API/c/mac/WKCertificateInfoMac.h:
* Shared/API/c/mac/WKCertificateInfoMac.mm:
(WKCertificateInfoCreateWithServerTrust):
Modified Paths
Diff
Modified: trunk/Source/WebKit2/ChangeLog (202360 => 202361)
--- trunk/Source/WebKit2/ChangeLog 2016-06-23 00:14:45 UTC (rev 202360)
+++ trunk/Source/WebKit2/ChangeLog 2016-06-23 00:19:53 UTC (rev 202361)
@@ -1,3 +1,14 @@
+2016-06-22 Sam Weinig <[email protected]>
+
+ Add SPI to allow creating a WKCertificateInfoRef from a SecTrustRef
+ https://bugs.webkit.org/show_bug.cgi?id=159025
+
+ Reviewed by Tim Horton.
+
+ * Shared/API/c/mac/WKCertificateInfoMac.h:
+ * Shared/API/c/mac/WKCertificateInfoMac.mm:
+ (WKCertificateInfoCreateWithServerTrust):
+
2016-06-22 Brady Eidson <[email protected]>
DatabaseProcess doesn't handle WebProcesses going away uncleanly.
Modified: trunk/Source/WebKit2/Shared/API/c/mac/WKCertificateInfoMac.h (202360 => 202361)
--- trunk/Source/WebKit2/Shared/API/c/mac/WKCertificateInfoMac.h 2016-06-23 00:14:45 UTC (rev 202360)
+++ trunk/Source/WebKit2/Shared/API/c/mac/WKCertificateInfoMac.h 2016-06-23 00:19:53 UTC (rev 202361)
@@ -34,6 +34,7 @@
extern "C" {
#endif
+WK_EXPORT WKCertificateInfoRef WKCertificateInfoCreateWithServerTrust(SecTrustRef serverTrust);
WK_EXPORT WKCertificateInfoRef WKCertificateInfoCreateWithCertficateChain(CFArrayRef certificateChain);
WK_EXPORT SecTrustRef WKCertificateInfoGetServerTrust(WKCertificateInfoRef certificateInfo);
Modified: trunk/Source/WebKit2/Shared/API/c/mac/WKCertificateInfoMac.mm (202360 => 202361)
--- trunk/Source/WebKit2/Shared/API/c/mac/WKCertificateInfoMac.mm 2016-06-23 00:14:45 UTC (rev 202360)
+++ trunk/Source/WebKit2/Shared/API/c/mac/WKCertificateInfoMac.mm 2016-06-23 00:19:53 UTC (rev 202361)
@@ -32,6 +32,16 @@
using namespace WebCore;
using namespace WebKit;
+WKCertificateInfoRef WKCertificateInfoCreateWithServerTrust(SecTrustRef serverTrust)
+{
+#if HAVE(SEC_TRUST_SERIALIZATION)
+ RefPtr<WebCertificateInfo> certificateInfo = WebCertificateInfo::create(CertificateInfo(serverTrust));
+ return toAPI(certificateInfo.leakRef());
+#else
+ return nullptr;
+#endif
+}
+
WKCertificateInfoRef WKCertificateInfoCreateWithCertficateChain(CFArrayRef certificateChain)
{
RefPtr<WebCertificateInfo> certificateInfo = WebCertificateInfo::create(CertificateInfo(certificateChain));
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes