Support for Basic auth

See diffs