Added login support with mongodb