avoid rebuilding the Basic Authentication header for each request

The username and password never change, so there is no need to re-encode
them in Base64 for each request. We can juste compute the header value
once and reuse it to save time.
Merge pull request #616 from jpatte/basicAuth

avoid rebuilding the Basic Authentication header for each request