title: Unable to authenticate using nodejs with ssh2 module, even though manual ssh works
body: <p>I am trying to use nodejs (v0.8.2) with the ssh2 module to grab some files from a remote machine (using sftp). I am able to ssh to the remote machine by hand using either a password or rsa keys, but somehow the following code fails to yield a successful authentication. Any ideas about what might be going wrong?</p>
  
  <p>Here is a code snippet (I've stripped out the code that does the sftp to make it easier to understand -- all I care about here is that I'm failing to authenticate.)</p>
  
  <pre><code>var express = require('express'),
      fs = require('fs'),
      Connection = require('ssh2');
  
  var c = new Connection();
  c.on('connect', function() {
    console.log('Connection :: connect');
  });
  c.on('ready', function() {
    console.log('Connection :: ready');
  });
  c.on('error', function(err) {
    console.log('Connection :: error :: ' + err);
  });
  c.on('end', function() {
    console.log('Connection :: end');
  });
  c.on('close', function(had_error) {
    console.log('Connection :: close');
  });
  c.on('keyboard-interactive', function() {
    console.log('Connection :: keyboard-interactive');
  });
  c.connect({
    host: '9.xx.yy.zzz',
    port: 22,
    username: 'my_username_on_remote_machine',
    password: 'my_password_on_remote_machine'
  });
  </code></pre>
  
  <p>When I run this code, I get a 'Connection :: connect' response, but nothing further until the ssh times out and I get the Connection :: end and Connection :: close in rapid succession:</p>
  
  <pre><code>node testssh.js
  Connection :: connect
  Connection :: end
  Connection :: close
  </code></pre>