Any idea why the basicauth / name pass config directive produces the following error 401 in error log before getting user input?
BasicAuth: user "" was not found or password was incorrect
I tried it with Chrome, Safari, FF and Edge getting exactly the same behavior. When authentication dialog is displayed and before entering anything the error 401 is logged.
Update: I read in http.basicauth docs about this 401 error but still have to consider this as an issue since never experienced such a basicauth behavior using other servers.
I wish I could at least avoid logging this specific pre-auth 401 error not filling error log with useless noise.
example.com
root /usr/local/www
index index.html
basicauth / username password
gzip {
level 6
min_length 100
}
errors /var/log/caddy-error.log {
rotate_size 1
rotate_age 1
rotate_keep 0
404 404.html
}
log /var/log/caddy-access.log {
rotate_size 1
rotate_age 1
rotate_keep 0
}
Thanks for any help!