If JSSE doesn't work for you (it may be hard to find documentation from @skaffman's answer), you might want to take a look at some kind of proxy. You can configure a daemon running on the same local computer (or trusted network), which then forwards requests via HTTPS to the endpoint. You can write this proxy using a more modern JVM. Then your legacy system points to a proxy server, not a real service.
Of course, if, by chance, you also have control over the endpoint, you could just put both servers in a VPN.
source share