allow http auth to work in curl mode; add tests for basic and digest auth; refactor...