mirror of
https://github.com/gyurix1968/guacamole-client.git
synced 2025-09-06 13:17:41 +00:00
GUACAMOLE-641: Index records by username ONLY if not related to a hostname.
Doing otherwise would mean that a particular user would never be able to be associated with a specific password/key by their username if they have any explicit server-specific account.
This commit is contained in:
@@ -238,10 +238,14 @@ public class KsmClient {
|
||||
// Store based on UID ...
|
||||
cachedRecordsByUid.put(record.getRecordUid(), record);
|
||||
|
||||
// ... and hostname/address ...
|
||||
addRecordForHost(record, recordService.getHostname(record));
|
||||
// ... and hostname/address
|
||||
String hostname = recordService.getHostname(record);
|
||||
addRecordForHost(record, hostname);
|
||||
|
||||
// ... and username
|
||||
// Store based on username ONLY if no hostname (will otherwise
|
||||
// result in ambiguous entries for servers tied to identical
|
||||
// accounts)
|
||||
if (hostname == null)
|
||||
addRecordForLogin(record, recordService.getUsername(record));
|
||||
|
||||
});
|
||||
|
Reference in New Issue
Block a user