[java-idp-plugin-metadatagen] 01/01: Update plugin to V5.

Scott Cantor cantor.2 at osu.edu
Tue Jun 27 16:30:42 UTC 2023


This is an automated email from the git hooks/post-receive script.

scantor pushed a commit to branch dev/JMETAGEN-5
in repository java-idp-plugin-metadatagen.

View the commit online:
http://git.shibboleth.net/view/?p=java-idp-plugin-metadatagen.git;a=commit;h=cc5e15ded72f432e9fddd77ee72bc86455c6f79e

commit cc5e15ded72f432e9fddd77ee72bc86455c6f79e
Author: Scott Cantor <cantor.2 at osu.edu>
AuthorDate: Tue Jun 27 12:30:38 2023 -0400

    Update plugin to V5.
---
 metadatagen-api/pom.xml                            |  8 +-
 metadatagen-dist/pom.xml                           |  2 +-
 metadatagen-impl/pom.xml                           | 24 +++++-
 .../plugin/metadatagen/impl/MetadataGenCLI.java    | 56 +++++++------
 .../impl/MetadataGenCommandLineArguments.java      | 77 ++++++++++--------
 .../plugin/metadatagen/impl/MetadataGenModule.java |  3 +-
 .../metadatagen/impl/MetadataGenParameters.java    |  7 +-
 .../plugin/metadatagen/impl/MetadataGenPlugin.java | 11 +--
 .../idp/plugin/metadatagen/impl/package-info.java  |  5 +-
 .../plugin/metadatagen/impl/MetadataGenTest.java   |  8 +-
 pom.xml                                            | 94 +++++++++++++---------
 11 files changed, 174 insertions(+), 121 deletions(-)

diff --git a/metadatagen-api/pom.xml b/metadatagen-api/pom.xml
index 6fdd8c0..7212b38 100644
--- a/metadatagen-api/pom.xml
+++ b/metadatagen-api/pom.xml
@@ -6,7 +6,7 @@
     <parent>
         <groupId>net.shibboleth.idp.plugin.metadatagen</groupId>
         <artifactId>idp-plugin-metadatagen-parent</artifactId>
-        <version>1.0.2-SNAPSHOT</version>
+        <version>2.0.0-SNAPSHOT</version>
     </parent>
 
     <artifactId>idp-plugin-metadatagen-api</artifactId>
@@ -20,12 +20,6 @@
     </properties>
 
     <dependencies>
-        <!-- Provided dependencies -->
-        <dependency>
-            <groupId>com.google.code.findbugs</groupId>
-            <artifactId>jsr305</artifactId>
-            <scope>provided</scope>
-        </dependency>
     </dependencies>
 
     <build>
diff --git a/metadatagen-dist/pom.xml b/metadatagen-dist/pom.xml
index 27444a7..7e9dfbb 100644
--- a/metadatagen-dist/pom.xml
+++ b/metadatagen-dist/pom.xml
@@ -5,7 +5,7 @@
     <parent>
         <groupId>net.shibboleth.idp.plugin.metadatagen</groupId>
         <artifactId>idp-plugin-metadatagen-parent</artifactId>
-        <version>1.0.2-SNAPSHOT</version>
+        <version>2.0.0-SNAPSHOT</version>
     </parent>
 
     <artifactId>idp-plugin-metadatagen-dist</artifactId>
diff --git a/metadatagen-impl/pom.xml b/metadatagen-impl/pom.xml
index 0f12ef1..c5d3207 100644
--- a/metadatagen-impl/pom.xml
+++ b/metadatagen-impl/pom.xml
@@ -5,7 +5,7 @@
     <parent>
         <groupId>net.shibboleth.idp.plugin.metadatagen</groupId>
         <artifactId>idp-plugin-metadatagen-parent</artifactId>
-        <version>1.0.2-SNAPSHOT</version>
+        <version>2.0.0-SNAPSHOT</version>
     </parent>
 
     <artifactId>idp-plugin-metadatagen-impl</artifactId>
@@ -35,6 +35,28 @@
             <artifactId>idp-admin-impl</artifactId>
             <scope>provided</scope>
         </dependency>
+        <dependency>
+            <groupId>${idp.groupId}</groupId>
+            <artifactId>idp-cli</artifactId>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>${shib-shared.groupId}</groupId>
+            <artifactId>shib-profile-api</artifactId>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>${shib-shared.groupId}</groupId>
+            <artifactId>shib-cli</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>${shib-shared.groupId}</groupId>
+            <artifactId>shib-support</artifactId>
+            <scope>provided</scope>
+        </dependency>
     
     </dependencies>
 
diff --git a/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenCLI.java b/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenCLI.java
index 2446bda..bdc718b 100644
--- a/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenCLI.java
+++ b/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenCLI.java
@@ -60,16 +60,16 @@ import org.springframework.core.env.Environment;
 import org.springframework.core.io.ClassPathResource;
 import org.springframework.core.io.Resource;
 
-import net.shibboleth.ext.spring.cli.AbstractCommandLine;
 import net.shibboleth.idp.Version;
 import net.shibboleth.idp.cli.AbstractIdPHomeAwareCommandLine;
 import net.shibboleth.idp.saml.xmlobject.ExtensionsConstants;
 import net.shibboleth.idp.saml.xmlobject.Scope;
-import net.shibboleth.utilities.java.support.annotation.constraint.NonnullElements;
-import net.shibboleth.utilities.java.support.annotation.constraint.NotEmpty;
-import net.shibboleth.utilities.java.support.primitive.StringSupport;
-import net.shibboleth.utilities.java.support.xml.DOMTypeSupport;
-import net.shibboleth.utilities.java.support.xml.XMLConstants;
+import net.shibboleth.shared.annotation.constraint.NotEmpty;
+import net.shibboleth.shared.cli.AbstractCommandLine;
+import net.shibboleth.shared.collection.CollectionSupport;
+import net.shibboleth.shared.primitive.StringSupport;
+import net.shibboleth.shared.xml.DOMTypeSupport;
+import net.shibboleth.shared.xml.XMLConstants;
 
 /**
  * Command Line to generate Metadata.
@@ -89,7 +89,7 @@ public final class MetadataGenCLI extends AbstractIdPHomeAwareCommandLine<Metada
     private MetadataGenCommandLineArguments args;
     
     /** The DnsName (cached because we need it often). */
-    private String dnsName;
+    @Nullable private String dnsName;
     
     /** {@inheritDoc} */
     @Override
@@ -97,23 +97,24 @@ public final class MetadataGenCLI extends AbstractIdPHomeAwareCommandLine<Metada
         if (log == null) {
             log = LoggerFactory.getLogger(MetadataGenCLI.class);
         }
+        assert log != null;
         return log;
     }
 
     /** {@inheritDoc} */
-    @Override @Nonnull protected Class<MetadataGenCommandLineArguments> getArgumentClass() {
+    @Override
+    @Nonnull protected Class<MetadataGenCommandLineArguments> getArgumentClass() {
         return MetadataGenCommandLineArguments.class;
     }
 
     /** {@inheritDoc} */
-    protected String getVersion() {
+    @Nonnull protected String getVersion() {
         return Version.getVersion();
     }
 
     /** {@inheritDoc} */
-    @Nonnull @NonnullElements protected List<Resource> getAdditionalSpringResources() {
-        return List.of(
-               new ClassPathResource("net/shibboleth/idp/plugin/metadatagen/metadatagen.xml"));
+    @Nonnull protected List<Resource> getAdditionalSpringResources() {
+        return CollectionSupport.singletonList(new ClassPathResource("net/shibboleth/idp/plugin/metadatagen/metadatagen.xml"));
     }
 
     /**
@@ -122,14 +123,16 @@ public final class MetadataGenCLI extends AbstractIdPHomeAwareCommandLine<Metada
      */
     private void outputKeyDescriptors(final boolean outputBackChannel) {
         final List<List<String>> signing = new ArrayList<>(2);
-        if (outputBackChannel &&
-            parameters.getBackchannelCert() != null &&
-            !parameters.getBackchannelCert().isEmpty()) {
-            output.format("        <!--  First signing certificate is BackChannel, the Second is FrontChannel -->\n");
-            signing.add(parameters.getBackchannelCert());
+        if (outputBackChannel) {
+            final List<String> backCert = parameters.getBackchannelCert();
+            if (backCert != null && !backCert.isEmpty()) {
+                output.format("        <!--  First signing certificate is BackChannel, the Second is FrontChannel -->\n");
+                signing.add(backCert);
+            }
         }
-        if (parameters.getSigningCert() != null && !parameters.getSigningCert().isEmpty()) {
-            signing.add(parameters.getSigningCert());
+        final List<String> signCert = parameters.getSigningCert();
+        if (signCert != null && !signCert.isEmpty()) {
+            signing.add(signCert);
         }
         outputKeyDescriptors(signing, "signing");
         outputKeyDescriptors(Collections.singletonList(parameters.getEncryptionCert()), "encryption");
@@ -257,7 +260,8 @@ public final class MetadataGenCLI extends AbstractIdPHomeAwareCommandLine<Metada
                 SAMLConstants.SAML2_POST_SIMPLE_SIGN_BINDING_URI,
                 getDnsName());
 
-        if (parameters.getBackchannelCert() != null && !parameters.getBackchannelCert().isEmpty()) {
+        final List<String> backCert = parameters.getBackchannelCert();
+        if (backCert != null && !backCert.isEmpty()) {
             output.format("        <%s Binding=\"%s\""
                     + " Location=\"https://%s:8443/idp/profile/SAML2/SOAP/SLO\"/>\n",
                     SingleLogoutService.DEFAULT_ELEMENT_LOCAL_NAME,
@@ -459,6 +463,7 @@ public final class MetadataGenCLI extends AbstractIdPHomeAwareCommandLine<Metada
                     getEnvironment().
                     getProperty(MetadataGenCommandLineArguments.DNS_NAME_PROPERTY, "idp.example.org");
         }
+        assert dnsName != null;
         return dnsName;
     }
 
@@ -476,8 +481,9 @@ public final class MetadataGenCLI extends AbstractIdPHomeAwareCommandLine<Metada
             getLogger().error("Could not locate IdPConfiguration");
             return false;
         }
-        final boolean hasBackChannel = parameters.getBackchannelCert() != null 
-                && !parameters.getBackchannelCert().isEmpty();
+        
+        final List<String> backCert = parameters.getBackchannelCert();
+        final boolean hasBackChannel = backCert != null && !backCert.isEmpty();
         boolean worked = true;
         if (args.isArtifact() && !hasBackChannel) {
             getLogger().error("Must specify --backChannel <path> if +artifact speificied");
@@ -535,7 +541,8 @@ public final class MetadataGenCLI extends AbstractIdPHomeAwareCommandLine<Metada
         return i;
     }
 
-    /** Shim for CLI entry point: Allows the code to be run from a test.
+    /** 
+    * Shim for CLI entry point: Allows the code to be run from a test.
     *
     * @return one of the predefines {@link AbstractCommandLine#RC_INIT},
     * {@link AbstractCommandLine#RC_IO}, {@link AbstractCommandLine#RC_OK}
@@ -556,4 +563,5 @@ public final class MetadataGenCLI extends AbstractIdPHomeAwareCommandLine<Metada
    public static void main(@Nonnull final String[] args) {
        System.exit(runMain(args));
    }
-}
+   
+}
\ No newline at end of file
diff --git a/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenCommandLineArguments.java b/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenCommandLineArguments.java
index f695529..99dd42b 100644
--- a/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenCommandLineArguments.java
+++ b/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenCommandLineArguments.java
@@ -21,10 +21,10 @@ import java.io.FileOutputStream;
 import java.io.IOException;
 import java.io.PrintStream;
 import java.util.ArrayList;
-import java.util.Collections;
 import java.util.List;
 import java.util.Properties;
 
+import javax.annotation.Nonnull;
 import javax.annotation.Nullable;
 
 import org.slf4j.Logger;
@@ -33,6 +33,10 @@ import org.slf4j.LoggerFactory;
 import com.beust.jcommander.Parameter;
 
 import net.shibboleth.idp.cli.AbstractIdPHomeAwareCommandLineArguments;
+import net.shibboleth.shared.annotation.constraint.NotEmpty;
+import net.shibboleth.shared.annotation.constraint.NotLive;
+import net.shibboleth.shared.annotation.constraint.Unmodifiable;
+import net.shibboleth.shared.collection.CollectionSupport;
 
 /**
  * Command line arguments for Metadata Generation.
@@ -40,59 +44,59 @@ import net.shibboleth.idp.cli.AbstractIdPHomeAwareCommandLineArguments;
 public class MetadataGenCommandLineArguments extends AbstractIdPHomeAwareCommandLineArguments {
     
     /** Property name for the back channel certificate. */
-    public static final String BACKCHANNEL_PROPERTY = "idp.metadata.backchannel.cert";
+    @Nonnull @NotEmpty public static final String BACKCHANNEL_PROPERTY = "idp.metadata.backchannel.cert";
     
     /** Property name for the back channel certificate. */
-    public static final String DNS_NAME_PROPERTY = "idp.metadata.dnsname";
+    @Nonnull @NotEmpty public static final String DNS_NAME_PROPERTY = "idp.metadata.dnsname";
 
     /** Property name for the MDUI languages. */
-    public static final String MDUI_LANGS_PROPERTY = "idp.metadata.idpsso.mdui.langs";
+    @Nonnull @NotEmpty public static final String MDUI_LANGS_PROPERTY = "idp.metadata.idpsso.mdui.langs";
 
     /** Property prefix for DisplayName. */
-    public static final String MDUI_DISPLAY_NAME_PREFIX = "idp.metadata.idpsso.mdui.displayname.";
+    @Nonnull @NotEmpty public static final String MDUI_DISPLAY_NAME_PREFIX = "idp.metadata.idpsso.mdui.displayname.";
 
     /** Property prefix for Description. */
-    public static final String MDUI_DESCRIPTION_PREFIX = "idp.metadata.idpsso.mdui.description.";
+    @Nonnull @NotEmpty public static final String MDUI_DESCRIPTION_PREFIX = "idp.metadata.idpsso.mdui.description.";
 
     /** Property for logo y. */
-    public static final String MDUI_LOGO_HEIGHT = "idp.metadata.idpsso.mdui.logo.height";
+    @Nonnull @NotEmpty public static final String MDUI_LOGO_HEIGHT = "idp.metadata.idpsso.mdui.logo.height";
 
     /** Property for logo x. */
-    public static final String MDUI_LOGO_WIDTH = "idp.metadata.idpsso.mdui.logo.width";
+    @Nonnull @NotEmpty public static final String MDUI_LOGO_WIDTH = "idp.metadata.idpsso.mdui.logo.width";
 
     /** Property for logo path. */
-    public static final String MDUI_LOGO_PATH = "idp.metadata.idpsso.mdui.logo.path";
+    @Nonnull @NotEmpty public static final String MDUI_LOGO_PATH = "idp.metadata.idpsso.mdui.logo.path";
 
     /** Logger. */
-    private Logger log;
+    @Nullable private Logger log;
 
     /** Do we output SAML2. */
     @Parameter(names = { "+saml2", "+2", "+SAML2"} )
-    @Nullable private boolean saml2;
+    private boolean saml2;
 
     /** Do we NOT output SAML2. */
     @Parameter(names = { "-saml2", "-2", "-SAML2"} )
-    @Nullable private boolean noSaml2;
+    private boolean noSaml2;
 
     /** Do we output SAM1.?*/
     @Parameter(names = { "+saml1", "+1", "+SAML1"})
-    @Nullable private boolean saml1;
+    private boolean saml1;
 
     /** Do we output for an SP.*/
     @Parameter(names = { "+samlSP", "+sp", "+SP", "+SAMLSP"})
-    @Nullable private boolean samlSP;
+    private boolean samlSP;
 
     /** Do we output logout.*/
     @Parameter(names = { "+logout", "+lo"})
-    @Nullable private boolean logout;
+    private boolean logout;
 
     /** Do we output Artifact.*/
     @Parameter(names = { "+artifact", "+artefact"})
-    @Nullable private boolean artifact;
+    private boolean artifact;
 
     /** Do we output for an Attribute Fetch.*/
     @Parameter(names = { "+attributeFetch"})
-    @Nullable private boolean attributeFetch;
+    private boolean attributeFetch;
 
     /** Certificate for (IdP) BackChannel (attribute, artifact, logout).*/
     @Parameter(names = { "--backChannel", "-bc"})
@@ -155,11 +159,13 @@ public class MetadataGenCommandLineArguments extends AbstractIdPHomeAwareCommand
         return output;
     }
 
-    /** {@inheritDoc}
+    /**
+     * {@inheritDoc}
+     * 
      * We override this to add a property file of our own making for
      * the backchannel (if needed) and dnsname.
-     * */
-    public List<String> getPropertyFiles() {
+     */
+    @Nonnull @Unmodifiable @NotLive public List<String> getPropertyFiles() {
         final List<String> fromCmdline = super.getPropertyFiles();
         if (dnsName == null && backChannelPath == null) {
             return fromCmdline;
@@ -172,34 +178,38 @@ public class MetadataGenCommandLineArguments extends AbstractIdPHomeAwareCommand
         if (backChannelPath != null) {
             props.setProperty(BACKCHANNEL_PROPERTY, backChannelPath);
         }
-        
-        File file = null;
+
+        final List<String> result = new ArrayList<>(fromCmdline.size() + 1);
+
         try {
-            file = File.createTempFile("MetadataGen", ".properties");
+            final File file = File.createTempFile("MetadataGen", ".properties");
             file.deleteOnExit();
             try (final FileOutputStream out = new FileOutputStream(file)) {
                 props.store(out, "created");
             }
+            if (fromCmdline.isEmpty()) {
+                return CollectionSupport.singletonList(file.getAbsolutePath());
+            }
+            result.addAll(fromCmdline);
+            result.add(file.getAbsolutePath());
         } catch (final IOException e) {
             getLog().error("Could not generate property file", e);
         }
-        if (fromCmdline.isEmpty()) {
-            return Collections.singletonList(file.getAbsolutePath());
-        }
-        final List<String> result = new ArrayList<>(fromCmdline.size() + 1);
-        result.addAll(fromCmdline);
-        result.add(file.getAbsolutePath());
+
         return result;
     }
 
+    /** {@inheritDoc} */
     @Override
-    public synchronized Logger getLog() {
+    @Nonnull public synchronized Logger getLog() {
         if (log == null) {
             log = LoggerFactory.getLogger(MetadataGenCommandLineArguments.class);
         }
+        assert log != null;
         return log;
     }
 
+    /** {@inheritDoc} */
     @Override
     public void validate() throws IllegalArgumentException {
         if (!saml2 && noSaml2) {
@@ -208,10 +218,10 @@ public class MetadataGenCommandLineArguments extends AbstractIdPHomeAwareCommand
             saml2 = true;
         }
     }
-    // Checkstyle: CyclomaticComplcity ON
 
+    /** {@inheritDoc} */
     @Override
-    public void printHelp(final PrintStream out) {
+    public void printHelp(@Nonnull final PrintStream out) {
         super.printHelp(out);
         out.println(String.format("  %-20s %s", "+SAML1, +1",
                                   "Output SAML1 Metadata."));
@@ -233,4 +243,5 @@ public class MetadataGenCommandLineArguments extends AbstractIdPHomeAwareCommand
                                   "Output location."));
         out.println();
     }
-}
+    
+}
\ No newline at end of file
diff --git a/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenModule.java b/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenModule.java
index 93ca584..25b5d26 100644
--- a/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenModule.java
+++ b/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenModule.java
@@ -19,8 +19,8 @@ package net.shibboleth.idp.plugin.metadatagen.impl;
 
 import java.io.IOException;
 
-import net.shibboleth.idp.module.ModuleException;
 import net.shibboleth.idp.module.impl.PluginIdPModule;
+import net.shibboleth.profile.module.ModuleException;
 
 
 /**
@@ -38,5 +38,4 @@ public class MetadataGenModule extends PluginIdPModule{
         super(MetadataGenModule.class);
     }
     
-
 }
\ No newline at end of file
diff --git a/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenParameters.java b/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenParameters.java
index eb1e24f..f79649c 100644
--- a/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenParameters.java
+++ b/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenParameters.java
@@ -30,8 +30,8 @@ import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.core.io.Resource;
 
-import net.shibboleth.utilities.java.support.component.AbstractInitializableComponent;
-import net.shibboleth.utilities.java.support.component.ComponentInitializationException;
+import net.shibboleth.shared.component.AbstractInitializableComponent;
+import net.shibboleth.shared.component.ComponentInitializationException;
 
 /**
  * A simple bean for processing certificates & presenting them in an easy-to- output manner.
@@ -197,4 +197,5 @@ public class MetadataGenParameters extends AbstractInitializableComponent {
             return output;
         }
     }
-}
+
+}
\ No newline at end of file
diff --git a/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenPlugin.java b/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenPlugin.java
index 1b429f4..86a04c0 100644
--- a/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenPlugin.java
+++ b/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenPlugin.java
@@ -18,12 +18,12 @@
 package net.shibboleth.idp.plugin.metadatagen.impl;
 
 import java.io.IOException;
-import java.util.Collections;
 
 import net.shibboleth.idp.module.IdPModule;
-import net.shibboleth.idp.module.ModuleException;
-import net.shibboleth.idp.plugin.PluginException;
 import net.shibboleth.idp.plugin.impl.FirstPartyIdPPlugin;
+import net.shibboleth.profile.module.ModuleException;
+import net.shibboleth.profile.plugin.PluginException;
+import net.shibboleth.shared.collection.CollectionSupport;
 
 /**
  * {@link net.shibboleth.idp.plugin.IdPPlugin} for metadata generator.
@@ -40,12 +40,13 @@ public class MetadataGenPlugin extends FirstPartyIdPPlugin {
         super(MetadataGenPlugin.class);
         try {
             final IdPModule module = new MetadataGenModule();
-            setEnableOnInstall(Collections.singleton(module));
-            setDisableOnRemoval(Collections.singleton(module));
+            setEnableOnInstall(CollectionSupport.singleton(module));
+            setDisableOnRemoval(CollectionSupport.singleton(module));
         } catch (final IOException e) {
             throw e;
         } catch (final ModuleException e) {
             throw new PluginException(e);
         }
     }
+
 }
\ No newline at end of file
diff --git a/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/package-info.java b/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/package-info.java
index 8d39207..b2ac249 100644
--- a/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/package-info.java
+++ b/metadatagen-impl/src/main/java/net/shibboleth/idp/plugin/metadatagen/impl/package-info.java
@@ -14,8 +14,11 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
+
 /**
  * Package to contain classes to do with the metadata generation command line.
  */
-
+ at NonnullElements
 package net.shibboleth.idp.plugin.metadatagen.impl;
+
+import net.shibboleth.shared.annotation.constraint.NonnullElements;
diff --git a/metadatagen-impl/src/test/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenTest.java b/metadatagen-impl/src/test/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenTest.java
index 845cf08..1f73ed9 100644
--- a/metadatagen-impl/src/test/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenTest.java
+++ b/metadatagen-impl/src/test/java/net/shibboleth/idp/plugin/metadatagen/impl/MetadataGenTest.java
@@ -30,11 +30,9 @@ import java.nio.file.Files;
 import org.springframework.core.io.ClassPathResource;
 import org.testng.annotations.Test;
 
-import net.shibboleth.ext.spring.cli.AbstractCommandLine;
+import net.shibboleth.shared.cli.AbstractCommandLine;
+
 
-/**
- *
- */
 @SuppressWarnings("javadoc")
 public class MetadataGenTest {
 	
@@ -103,4 +101,4 @@ public class MetadataGenTest {
                 AbstractCommandLine.RC_OK);
     }
 
-}
+}
\ No newline at end of file
diff --git a/pom.xml b/pom.xml
index 8651aba..0a0ea43 100644
--- a/pom.xml
+++ b/pom.xml
@@ -1,68 +1,69 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
     <modelVersion>4.0.0</modelVersion>
+    
     <parent>
         <groupId>net.shibboleth</groupId>
         <artifactId>parent</artifactId>
-        <version>11.3.3</version>
+        <version>17.0.0-SNAPSHOT</version>
     </parent>
+    
     <groupId>net.shibboleth.idp.plugin.metadatagen</groupId>
     <artifactId>idp-plugin-metadatagen-parent</artifactId>
-    <version>1.0.2-SNAPSHOT</version>
+    <version>2.0.0-SNAPSHOT</version>
     <name>Shibboleth IdP :: Plugins :: metadatagen</name>
     <packaging>pom</packaging>
-    <description>metadatagen plugin for the Shibboleth IdP.</description>
+    <description>SAML metadata generation plugin for the Shibboleth IdP.</description>
+    
     <properties>
         <idp.groupId>net.shibboleth.idp</idp.groupId>
-        <idp.version>4.1.0</idp.version>
+        <idp.version>5.0.0-SNAPSHOT</idp.version>
         <opensaml.groupId>org.opensaml</opensaml.groupId>
-        <opensaml.version>4.1.0</opensaml.version>
+        <opensaml.version>5.0.0-SNAPSHOT</opensaml.version>
+        <shib-shared.groupId>net.shibboleth</shib-shared.groupId>
+        <shib-shared.version>9.0.0-SNAPSHOT</shib-shared.version>
+        <shib-profile.version>5.0.0-SNAPSHOT</shib-profile.version>
         <checkstyle.configLocation>${project.basedir}/checkstyle.xml</checkstyle.configLocation>
     </properties>
+    
     <distributionManagement>
         <site>
             <id>site</id>
             <url>dav:${shibboleth.site.url}java-idp-plugin-metadatagen/${project.version}/</url>
         </site>
     </distributionManagement>
-    <repositories>
-        <repository>
-            <id>shib-release</id>
-            <url>https://build.shibboleth.net/nexus/content/groups/public</url>
-            <snapshots>
-                <enabled>false</enabled>
-            </snapshots>
-        </repository>
-        <repository>
-            <id>shib-snapshot</id>
-            <url>https://build.shibboleth.net/nexus/content/repositories/snapshots</url>
-            <releases>
-                <enabled>false</enabled>
-            </releases>
-        </repository>
-    </repositories>
+
     <scm>
-        <connection>scm:git:https://git.shibboleth.net/git/java-${project.artifactId}</connection>
-        <developerConnection>scm:git:git at git.shibboleth.net:java-${project.artifactId}</developerConnection>
-        <url>https://git.shibboleth.net/view/?p=java-${project.artifactId}.git</url>  
+        <connection>scm:git:https://git.shibboleth.net/git/java-idp-plugin-metadatagen</connection>
+        <developerConnection>scm:git:git at git.shibboleth.net:java-idp-plugin-metadatagen</developerConnection>
+        <url>https://git.shibboleth.net/view/?p=idp-plugin-metadatagen.git</url>  
     </scm>
+    
     <dependencies>
-        <!-- Project wide test Dependencies -->
+        <!-- Project wide dependencies -->
+        <dependency>
+            <groupId>${slf4j.groupId}</groupId>
+            <artifactId>slf4j-api</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>com.google.code.findbugs</groupId>
+            <artifactId>jsr305</artifactId>
+            <scope>provided</scope>
+        </dependency>
+
         <dependency>
             <groupId>org.testng</groupId>
             <artifactId>testng</artifactId>
             <scope>test</scope>
         </dependency>
-        <dependency>
-            <groupId>${slf4j.groupId}</groupId>
-            <artifactId>slf4j-api</artifactId>
-        </dependency>
         <dependency>
             <groupId>org.mockito</groupId>
             <artifactId>mockito-core</artifactId>
             <scope>test</scope>
         </dependency>
     </dependencies>
+    
     <dependencyManagement>
         <!-- metadatagen project dependencies -->
         <dependencies>
@@ -76,7 +77,8 @@
                 <artifactId>idp-plugin-metadatagen-impl</artifactId>
                 <version>${project.version}</version>
             </dependency>
-            <!-- Shibboleth IdP BOM for importing IdP dependencies -->
+            
+            <!-- Import Dependencies: IdP -->
             <dependency>
                 <groupId>net.shibboleth.idp</groupId>
                 <artifactId>idp-bom</artifactId>
@@ -84,27 +86,41 @@
                 <type>pom</type>
                 <scope>import</scope>
             </dependency>
-            <!-- Provided shibboleth support dependencies -->
+            
+            <!-- Import Dependencies: Profile -->
             <dependency>
-                <groupId>net.shibboleth.utilities</groupId>
-                <artifactId>java-support</artifactId>
-                <version>${java-support.version}</version>
-                <scope>provided</scope>
+                <groupId>${shib-shared.groupId}</groupId>
+                <artifactId>shib-profile-bom</artifactId>
+                <version>${shib-profile.version}</version>
+                <type>pom</type>
+                <scope>import</scope>
             </dependency>
-            <!-- Test bom dependencies -->
+            
+            <!-- Import Dependencies: OpenSAML -->
             <dependency>
-                <groupId>${idp.groupId}</groupId>
-                <artifactId>idp-tests-bom</artifactId>
-                <version>${idp.version}</version>
+                <groupId>${opensaml.groupId}</groupId>
+                <artifactId>opensaml-bom</artifactId>
+                <version>${opensaml.version}</version>
+                <type>pom</type>
+                <scope>import</scope>
+            </dependency>
+            
+            <!-- Import Dependencies: Shared -->
+            <dependency>
+                <groupId>${shib-shared.groupId}</groupId>
+                <artifactId>shib-shared-bom</artifactId>
+                <version>${shib-shared.version}</version>
                 <type>pom</type>
                 <scope>import</scope>
             </dependency>
         </dependencies>
     </dependencyManagement>
+    
     <modules>
         <module>metadatagen-impl</module>
         <module>metadatagen-api</module>
         <!-- All DIST modules must come after the -api and -impl modules -->
         <module>metadatagen-dist</module>
     </modules>
+
 </project>

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the commits mailing list