Node MongoClient connection issue

I have a simple connection setup to MongoLab:

var MongoClient = require('mongodb').MongoClient;
MongoClient.connect('mongodb://USER:PASSWORD@ds012345.mongolab.com:12345/DATABASE', function(err, db) {
  if (err) {
    throw err;
  }
...

I can connect fine to the database through GUI and CLI clients, however with the above I get a connection error:

Error: failed to connect to [rm:27017]

Clearly not the correct port as specified by the connection and I'm not sure what rm is...