Code example for GeneralSecurityException

Methods: getMessage

0
    public Socket createSocket(String host, int port) throws IOException {
        try { 
            SSLSocketFactory factory = SSLUtil.getSSLSocketFactory();
            return factory.createSocket(host, port);
        } catch (GeneralSecurityException e) {
            Debug.logError(e, module);
            throw new IOException(e.getMessage());
        } catch (GenericConfigException e) {
            throw new IOException(e.getMessage());
        } 
    } 
}