summaryrefslogtreecommitdiffstats
path: root/src/main/java/nn/pp/rc/JSSE14_SSLConnector.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/nn/pp/rc/JSSE14_SSLConnector.java')
-rw-r--r--src/main/java/nn/pp/rc/JSSE14_SSLConnector.java26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/main/java/nn/pp/rc/JSSE14_SSLConnector.java b/src/main/java/nn/pp/rc/JSSE14_SSLConnector.java
new file mode 100644
index 0000000..487b1b9
--- /dev/null
+++ b/src/main/java/nn/pp/rc/JSSE14_SSLConnector.java
@@ -0,0 +1,26 @@
+package nn.pp.rc;
+
+import javax.net.ssl.SSLSocketFactory;
+
+import de.spline.kvm.utils.ReflectionUtils;
+import de.spline.kvm.utils.SSLUtils;
+
+/**
+ * We replace the JSSE14_SSLConnector with our own version.
+ *
+ * The default class from the applet uses a broken (outdated?)
+ * X509PluginTrustManager. So we simply use your own SSLSocketFactory here,
+ * that already has a correct setup for TLS connections of the remote console.
+ */
+public class JSSE14_SSLConnector extends aq
+{
+ public JSSE14_SSLConnector() {
+ // Just visual stuff to beautify the display name of this connector
+ ReflectionUtils.setField(aq.class, this, "do", "TLS");
+ }
+
+ public SSLSocketFactory a()
+ {
+ return SSLUtils.getSocketFactory();
+ }
+}