Spring Security
  1. Spring Security
  2. SEC-1355

Sample OpenID code in reference docs does not compile

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Trivial Trivial
    • Resolution: Fixed
    • Affects Version/s: 3.0.0
    • Fix Version/s: 3.0.1
    • Component/s: Docs and Website
    • Labels:
      None

      Description

      Section 2.3.4 of the reference docs (http://static.springsource.org/spring-security/site/docs/3.0.x/reference/ns-config.html#ns-openid) contains this code:

      OpenIDAuthenticationToken token = SecurityContextHolder.getContext().getAuthentication();

      This code doesn't compile; it should contain a cast as follows:

      OpenIDAuthenticationToken token = (OpenIDAuthenticationToken) ecurityContextHolder.getContext().getAuthentication();

        Activity

        Hide
        Andrew Swan added a comment -

        Sorry, I dropped a character by accident; it should of course be:

        OpenIDAuthenticationToken token = (OpenIDAuthenticationToken) SecurityContextHolder.getContext().getAuthentication();

        Show
        Andrew Swan added a comment - Sorry, I dropped a character by accident; it should of course be: OpenIDAuthenticationToken token = (OpenIDAuthenticationToken) SecurityContextHolder.getContext().getAuthentication();
        Hide
        Luke Taylor added a comment -

        Thanks. I've added the cast.

        Show
        Luke Taylor added a comment - Thanks. I've added the cast.

          People

          • Assignee:
            Luke Taylor
            Reporter:
            Andrew Swan
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: