server: add support for user authentication

Signed-off-by: Valentina Manea <valentina.manea.m@gmail.com>