title: Smack API, connect() exception
body: <p>I'm trying to connect to my company XMPPServer and get the following exception:</p>
  
  <pre><code>java.io.EOFException: input contained no data
  at org.xmlpull.mxp1.MXParser.fillBuf(MXParser.java:3003)
  at org.xmlpull.mxp1.MXParser.more(MXParser.java:3046)
  at org.xmlpull.mxp1.MXParser.parseProlog(MXParser.java:1410)
  at org.xmlpull.mxp1.MXParser.nextImpl(MXParser.java:1395)
  at org.xmlpull.mxp1.MXParser.next(MXParser.java:1093)
  at org.jivesoftware.smack.PacketReader.parsePackets(PacketReader.java:325)
  at org.jivesoftware.smack.PacketReader.access$000(PacketReader.java:43)
  at org.jivesoftware.smack.PacketReader$1.run(PacketReader.java:70)
  </code></pre>
  
  <p>My code is really basic...</p>
  
  <pre><code>System.setProperty("smack.debugEnabled", "true");
  XMPPConnection.DEBUG_ENABLED = true;
  ConnectionConfiguration config = new ConnectionConfiguration("xxx", 5223);
  config.setSecurityMode(SecurityMode.enabled);
  config.setSASLAuthenticationEnabled(true);
  config.setDebuggerEnabled(true);
  config.setCompressionEnabled(false);
  XMPPConnection connection = new XMPPConnection(config);
  connection.connect();
  </code></pre>
  
  <p>What am I doing wrong?<br>
  The "Raw Sent Packets" from the Smack Debug window seem to display the right xml flow:</p>
  
  <pre><code>&lt;stream:stream to="xxx" xmlns="jabber:client" xmlns:stream="http://etherx.jabber.org/streams" version="1.0"&gt;
  &lt;presence id="3347O-0" type="unavailable"&gt;&lt;/presence&gt;
  &lt;/stream:stream&gt;
  </code></pre>
  
  <p>---- UPDATE ----</p>
  
  <p>I found the issue.<br>
  For SSL connection the following code is needed:</p>
  
  <pre><code>config.setSecurityMode(ConnectionConfiguration.SecurityMode.enabled);
  config.setSocketFactory(new DummySSLSocketFactory());
  </code></pre>
  
  <p>The DummySSLSocketFactory class can be found in Spark or directly here:</p>
  
  <p><a href="http://svn.igniterealtime.org/svn/repos/spark/trunk/src/java/org/jivesoftware/spark/util/DummySSLSocketFactory.java" rel="nofollow">http://svn.igniterealtime.org/svn/repos/spark/trunk/src/java/org/jivesoftware/spark/util/DummySSLSocketFactory.java</a></p>