Fixed
Status Update
Comments
lu...@gmail.com <lu...@gmail.com> #2
da...@gmail.com <da...@gmail.com>
ap...@google.com <ap...@google.com> #4
Project: gerrit
Branch: stable-3.6
commit c97605f4308da5d5aff5acf76dfd239fc46c8aa0
Author: Darius Jokilehto <dariusjokilehto@gmail.com>
Date: Wed Sep 20 11:55:22 2023
Fix NPE when remote display name unset
Fix a NullPointerException thrown when `auth.httpDisplaynameHeader` is
configured, but the header isn't set.
Bug: Issue 300976121
Release-Notes: Fix NPE when auth.httpDisplaynameHeader is configured but header is unset
Change-Id: Ib92fea2f29092d096dc03f232c47ca0661b23864
M java/com/google/gerrit/httpd/auth/container/HttpAuthFilter.java
A javatests/com/google/gerrit/httpd/auth/container/HttpAuthFilterTest.java
https://gerrit-review.googlesource.com/387017
Branch: stable-3.6
commit c97605f4308da5d5aff5acf76dfd239fc46c8aa0
Author: Darius Jokilehto <dariusjokilehto@gmail.com>
Date: Wed Sep 20 11:55:22 2023
Fix NPE when remote display name unset
Fix a NullPointerException thrown when `auth.httpDisplaynameHeader` is
configured, but the header isn't set.
Bug:
Release-Notes: Fix NPE when auth.httpDisplaynameHeader is configured but header is unset
Change-Id: Ib92fea2f29092d096dc03f232c47ca0661b23864
M java/com/google/gerrit/httpd/auth/container/HttpAuthFilter.java
A javatests/com/google/gerrit/httpd/auth/container/HttpAuthFilterTest.java
Description
STR
Expected output
Login should succeed, even if the Non-existent-header is not present. The display name should not be set.
Actual output
Login fails with NPE
This has been introduced by Change 94918 because of the lack of null check. This can catch Gerrit admins unawares as they could update the plugin and not notice that
httpDisplaynameHeader
should not be configured anymore.