digest-auth fixes

1. The provided username was not checked, only the password leading to false positives.
2. Making a basic authentication request against the digest route would cause a 500 error to be returned.