November 2017
Intermediate to advanced
542 pages
14h 24m
English
As previously discussed, Spring Security's involvement in certificate exchange is to pick up information from the presented certificate and map the user's credentials to a user service. What we did not see in the use of the .x509() method was the magic that makes this happen. Recall that when we set the client certificate up, a DN similar to an LDAP DN was associated with the certificate:
Owner: CN=admin@example.com, OU=JBCP Calendar, O=JBCP, L=Park City, ST=UT, C=US
Spring Security uses the information in this DN to determine the actual username of the principal and it will look for this information in UserDetailsService. In particular, it allows for the specification of a regular expression, ...
Read now
Unlock full access