Fix to work when upstream proxy require authentication on https