File mode should be an integer
Added support for http proxy