Uploaded image for project: 'WildFly Core'
  1. WildFly Core
  2. WFCORE-5271

NullPointerException creating new KeyStore without type

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 15.0.0.Final
    • None
    • Security
    • None
    • Undefined

      The "type" attribute when adding a new KeyStore has been made optional, this is so that is the KeyStore already exists we can dynamically discover the type.

      If however the KeyStore does not exist this leads to a NullPointerException as it is never created:

      /subsystem=elytron/key-store=test:add(relative-to=jboss.server.config.dir, path=test1.keystore, credential-reference={clear-text="${ENC:AAA}"})
      {
          "outcome" => "failed",
          "failure-description" => {"WFLYCTL0080: Failed services" => {"org.wildfly.security.key-store.test" => "WF
      LYELY00004: Unable to start the service.
          Caused by: java.lang.NullPointerException"}},
          "rolled-back" => true
      } 

       

      If it doesn't exist we should likely create it using the default from KeyStore.getDetaultType()

      Caused by: java.lang.NullPointerExceptionCaused by: java.lang.NullPointerException at org.wildfly.extension.elytron@15.0.0.Beta1-SNAPSHOT//org.wildfly.extension.elytron.KeyStoreService.start(KeyStoreService.java:180) ... 8 more 

       

              lvydra Lukas Vydra
              darran.lofthouse@redhat.com Darran Lofthouse
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: