handled basic authentication