Unencode usernames and passwords taken from URLs.

Fixes #1767.