public OutputStream getOutputStream() throws IOException {
    if (!saslClient.isComplete()) {
      throw new IOException("Sasl authentication exchange hasn't completed yet");
    }
    // If Crypto AES is enabled, return cryptoOutputStream which wrap the data with Crypto AES.
    if (cryptoAesEnable && cryptoOutputStream != null) {
      return cryptoOutputStream;
    }
    return saslOutputStream;
  }
Get a SASL wrapped OutputStream. Can be called only after saslConnect() has been called.
@return a SASL wrapped OutputStream
hbase-client/src/main/java/org/apache/hadoop/hbase/security/HBaseSaslRpcClient.java