mike-jumper commented on a change in pull request #454: GUACAMOLE-793: CAS
Provider returns Group - like LDAP Provider
URL: https://github.com/apache/guacamole-client/pull/454#discussion_r383641413
##########
File path:
extensions/guacamole-auth-cas/src/main/java/org/apache/guacamole/auth/cas/AuthenticationProviderService.java
##########
@@ -81,11 +86,13 @@ public CASAuthenticatedUser authenticateUser(Credentials
credentials)
if (request != null) {
String ticket =
request.getParameter(CASTicketField.PARAMETER_NAME);
if (ticket != null) {
- Map<String, String> tokens =
ticketService.validateTicket(ticket, credentials);
+ TokensAndGroups tokensAndGroups =
ticketService.validateTicket(ticket, credentials);
Review comment:
I'm not a fan of defining a new class just for the sake of returning a pair
of values when there's no higher level concept behind that class besides being
a pair. `TokensAndGroups` is a type-specific pair, but that's about it. There
has to be a better way.
Perhaps `validateTicket()` should return the `CASAuthenticatedUser` instance?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services