A somewhat kludgey solution is to specify URLs with the username and
password in them:
http://user:password@www.example.com/private/pages/
This is kludgey because links within the returned document do not
have your username and password encoded in them. Solutions that rely
entirely on URL-encoded usernames and passwords often quickly
degenerate into code that wishes it had used
credentials to begin with.