Add a Core Platform API to change the default hostname verifier.

Allows vendor code in frameworks to install the strict instance
of OKHostnameVerifier in a less brittle way than reflecting for it
themselves.

Bug: 144694112
Test: atest CtsLibcoreTestCases:org.apache.harmony.tests.javax.net.ssl.HostnameVerifierTest
    # With and without http://r.android.com/1174149 applied.

Change-Id: Ife7a4644b632908b3c79e5c3f6ace709b43afd09
2 files changed