Consume isMemberOf attribute as single value with semi-colon delimited list of manifest groups
In the List Library application, which is attempting to consume Manifest groups as UW Spring Security authorities, we discovered that multiple Manifest groups are not provided by the login server as multiple isMemberOf headers but as one string with the Manifest groups delimited by semi-colons.
This PR revises the default Preauth mapper to split the isMemberOf string apart into a Java collection, which is the correct format for the authorities argument to the UWUserDetailsImpl constructor.
Notify: @paul.erickson @ahoffmann @gutkowski @bkeen
Merge request reports
Activity
Build finished. Tests PASSED. Build results available at: https://ia-builds.doit.wisc.edu:8443/job/uw-spring-security-master-pull-requests/92/
mentioned in commit 13fd19b4
85 85 String emplid = request.getHeader(isisEmplidHeader); 86 86 Collection<String> uddsMembership = safeGetHeaders(request, uddsHeader); 87 87 String email = request.getHeader(emailAddressHeader); 88 Collection<String> manifestGroups = safeGetHeaders(request, manifestHeader); 88 89 Collection<String> manifestGroups = new ArrayList<>(); 90 String manifestValue = request.getHeader(manifestHeader); 91 if (manifestValue != null) { 92 String[] manifestGroupStrings = manifestValue.split(";"); 93 for (String manifestGroupString : manifestGroupStrings) { Target is currently set to java7, but I totally agree. #insert-crossing-the-streams-reference
MyUW should be going to Java 8 very very soon.
Edited by Tim Levett