ER_NOT_SUPPORTED_AUTH_MODE - MySQL server

I figured that in some MySQL versions they have the authentication for the establishment of a connection a bit messed. All I had to do was add the line "insecureAuth : true" to my connection attempt.

var connection = mysql.createConnection({
  host     : 'localhost',
  user     : 'root',
  password : '********',
  database : 'vod_bill_database',
  insecureAuth : true
}); 

It is working fine now.