Skip to content

Commit a41638b

Browse files
bagipriyankPriyank Bagrecha
andauthored
Change log message from warning to trace on WWW-Authenticate challenge (#3364)
### Description Change warning message No 'Basic Authorization' header, send 401 and 'WWW-Authenticate Basic' to trace ### Issues Resolved - Resolves #3273 ### Check List - [ ] New functionality includes testing - [ ] New functionality has been documented - [X] Commits are signed per the DCO using --signoff By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. For more information on following Developer Certificate of Origin and signing off your commits, please check [here](https://github.com/opensearch-project/OpenSearch/blob/main/CONTRIBUTING.md#developer-certificate-of-origin). --------- Signed-off-by: Priyank Bagrecha <pbagrecha@roku.com> Co-authored-by: Priyank Bagrecha <pbagrecha@roku.com>
1 parent 5e0ab68 commit a41638b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/main/java/org/opensearch/security/auth/BackendRegistry.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -282,7 +282,9 @@ && isBlocked(((InetSocketAddress) request.getHttpChannel().getRemoteAddress()).g
282282

283283
if (authDomain.isChallenge() && httpAuthenticator.reRequestAuthentication(channel, null)) {
284284
auditLog.logFailedLogin("<NONE>", false, null, request);
285-
log.warn("No 'Authorization' header, send 401 and 'WWW-Authenticate Basic'");
285+
if (isTraceEnabled) {
286+
log.trace("No 'Authorization' header, send 401 and 'WWW-Authenticate Basic'");
287+
}
286288
return false;
287289
} else {
288290
// no reRequest possible

0 commit comments

Comments
 (0)