GUACAMOLE-195: Remove call to getRemoteUser() and just use the configured HTTP header.
This commit is contained in:
1 parent
96fb8a9c6b
commit
8eb33b5ca6
1 file changed
+3
-6
+3
-6
@@ -70,13 +70,10 @@ public class AuthenticationProviderService {
|
||||
// Pull HTTP header from request if present
|
||||
HttpServletRequest request = credentials.getRequest();
|
||||
if(request != null) {
|
||||
// Try getRemoteUser(), first
|
||||
String username = request.getRemoteUser();
|
||||
// Check if that worked, if not, try the configured header.
|
||||
if(username == null)
|
||||
username = request.getHeader(confService.getHttpAuthHeader());
|
||||
// Get the username from the header configured in guacamole.properties
|
||||
String username = request.getHeader(confService.getHttpAuthHeader());
|
||||
|
||||
if (username != null) {
|
||||
if(username != null) {
|
||||
AuthenticatedUser authenticatedUser = authenticatedUserProvider.get();
|
||||
authenticatedUser.init(username, credentials);
|
||||
return authenticatedUser;
|
||||
|
||||
Reference in new issue
Block a user