package uk.ac.cam.gpe21.droidssl.mitm.crypto;

import javax.net.ssl.X509TrustManager;
import java.security.cert.CertificateException;
import java.security.cert.X509Certificate;

public final class PermissiveTrustManager implements X509TrustManager {
	@Override
	public void checkClientTrusted(X509Certificate[] chain, String authType) throws CertificateException {
		/* empty */
	}

	@Override
	public void checkServerTrusted(X509Certificate[] chain, String authType) throws CertificateException {
		/* empty */
	}

	@Override
	public X509Certificate[] getAcceptedIssuers() {
		return new X509Certificate[0];
	}
}

@@ -61,32 +61,96 @@
 net.ssl.
-X509TrustManager
+SSLEngine;%0Aimport javax.net.ssl.X509ExtendedTrustManager;%0Aimport java.net.Socket
 ;%0Aimport
@@ -281,23 +281,28 @@
 ger 
-implement
+extend
 s X509
+Extended
 Trus
@@ -638,16 +638,16 @@
 ers() %7B%0A
-
 %09%09return
@@ -673,11 +673,609 @@
 e%5B0%5D;%0A%09%7D
+%0A%0A%09@Override%0A%09public void checkClientTrusted(X509Certificate%5B%5D chain, String authType, Socket socket) throws CertificateException %7B%0A%09%09/* empty */%0A%09%7D%0A%0A%09@Override%0A%09public void checkServerTrusted(X509Certificate%5B%5D chain, String authType, Socket socket) throws CertificateException %7B%0A%09%09/* empty */%0A%09%7D%0A%0A%09@Override%0A%09public void checkClientTrusted(X509Certificate%5B%5D chain, String authType, SSLEngine engine) throws CertificateException %7B%0A%09%09/* empty */%0A%09%7D%0A%0A%09@Override%0A%09public void checkServerTrusted(X509Certificate%5B%5D chain, String authType, SSLEngine engine) throws CertificateException %7B%0A%09%09/* empty */%0A%09%7D
 %0A%7D%0A

Make PermissiveTrustManager extend X509ExtendedTrustManager.