public X509CertificateStructure server_cert = null;
- public SSLOutputStream os;
- public SSLInputStream is;
+ public SSLOutputStream os = null;
+ public SSLInputStream is = null;
String hostname;
/** true iff we're using SSL_RSA_EXPORT_WITH_RC4_40_MD5 */
boolean export = false;
- public InputStream getInputStream() { return is; }
- public OutputStream getOutputStream() { return os; }
+ public InputStream getInputStream() throws IOException { return is != null ? is : super.getInputStream(); }
+ public OutputStream getOutputStream() throws IOException { return os != null ? os : super.getOutputStream(); }
public TinySSL(String host, int port) throws IOException { this(host, port, true); }
public TinySSL(String host, int port, boolean negotiateImmediately) throws IOException {