added suport for mongo authentication