Uploaded image for project: 'OpenAM'
  1. OpenAM
  2. OPENAM-14369

Upgrading from OpenAM 13.5.0 with custom PAPs causes NPE failure

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 6.0.0.5
    • Fix Version/s: 6.5.1, 6.0.0.7, 6.0.1, 7.0.0, 5.5.2
    • Component/s: upgrade
    • Labels:
    • Environment:
      Upgrading from OpenAM 13.5.0 to AM 6.0.0.5
    • Target Version/s:
    • Sprint:
      AM Sustaining Sprint 59
    • Story Points:
      2
    • Needs backport:
      No
    • Support Ticket IDs:
    • Verified Version/s:
    • Needs QA verification:
      No
    • Functional tests:
      No
    • Are the reproduction steps defined?:
      Yes and I used the same an in the description

      Description

      Bug description

      Upgrading from OpenAM 13.5.0 to AM 6.0.0.5 with custom PAPs fails with a Null Pointer Exception, see the attached amUpgrade log for the exact error and stack traces.

      How to reproduce the issue

      The PAP classes must be present in a chain and the war file to be used for upgrading. Please see the support ticket referenced in the support section of this JIRA for the exact steps to reproduce.

      Expected behaviour
      Upgrade to AM 6.0.0.5 is successful
      
      Current behaviour
      Upgrade fails with java.lang.NullPointerException

      Work around

      Remove custom PAPs, upgrade then add them back. This is fine if you only have a couple of upgrades to do, if you have 100's of servers this is far too much work.

      Code analysis

      OPTIONAL - If you already investigated the code, please share your finding here (remove this text)

      It looks like this issue is caused by this class with a hard-coded immutable map
      private final Map<String, String> postAuthPluginClassMapping = ImmutableMap.of(ORIGINAL_ADAPTIVE_PAP_CLASS_NAME,
                  NEW_ADAPTIVE_PAP_CLASS_NAME, ORIGINAL_PERSISTENT_COOKIE_PAP_CLASS_NAME,
                  NEW_PERSISTENT_COOKIE_PAP_CLASS_NAME);
      

        Attachments

          Activity

            People

            • Assignee:
              lawrence.yarham Lawrence Yarham
              Reporter:
              tom.jones Tom Jones
            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: