<?xml version='1.0' encoding='UTF-8'?>
<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>
  <groupId>org.passay</groupId>
  <artifactId>passay-parent</artifactId>
  <packaging>pom</packaging>
  <version>2.0.0</version>
  <name>Passay Parent</name>
  <description>Library for checking that a password complies with a custom set of rules</description>
  <url>https://www.passay.org</url>
  <issueManagement>
    <system>GitHub</system>
    <url>https://github.com/vt-middleware/passay/issues</url>
  </issueManagement>
  <licenses>
    <license>
      <name>Apache 2</name>
      <url>https://www.apache.org/licenses/LICENSE-2.0.txt</url>
    </license>
    <license>
      <name>GNU Lesser General Public License</name>
      <url>https://www.gnu.org/licenses/lgpl-3.0.txt</url>
    </license>
  </licenses>
  <scm>
    <connection>scm:git:git@github.com:vt-middleware/passay.git</connection>
    <url>scm:git:git@github.com:vt-middleware/passay.git</url>
  </scm>
  <developers>
    <developer>
      <id>dfisher</id>
      <name>Daniel Fisher</name>
      <email>dfisher@vt.edu</email>
      <organization>Virginia Tech</organization>
      <organizationUrl>https://www.vt.edu</organizationUrl>
      <roles>
        <role>developer</role>
      </roles>
    </developer>
    <developer>
      <id>serac</id>
      <name>Marvin S. Addison</name>
      <email>serac@vt.edu</email>
      <organization>Virginia Tech</organization>
      <organizationUrl>https://www.vt.edu</organizationUrl>
      <roles>
        <role>developer</role>
      </roles>
    </developer>
  </developers>

  <properties>
    <maven.compiler.release>8</maven.compiler.release>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
    <checkstyle.dir>src/main/checkstyle</checkstyle.dir>
    <spotbugs.dir>src/main/spotbugs</spotbugs.dir>
    <japicmp.enabled>false</japicmp.enabled>
    <japicmp.oldVersion>1.6.0</japicmp.oldVersion>
  </properties>

  <modules>
    <module>core</module>
    <module>crypt</module>
    <module>bloom</module>
    <module>spring</module>
  </modules>

  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>org.passay</groupId>
        <artifactId>passay</artifactId>
        <version>${project.version}</version>
      </dependency>
      <dependency>
        <groupId>org.passay</groupId>
        <artifactId>passay-crypt</artifactId>
        <version>${project.version}</version>
      </dependency>
      <dependency>
        <groupId>org.passay</groupId>
        <artifactId>passay-bloom</artifactId>
        <version>${project.version}</version>
      </dependency>
      <dependency>
        <groupId>org.passay</groupId>
        <artifactId>passay-spring</artifactId>
        <version>${project.version}</version>
      </dependency>
      <dependency>
        <groupId>org.cryptacular</groupId>
        <artifactId>cryptacular</artifactId>
        <version>1.3.0</version>
      </dependency>
      <dependency>
        <groupId>com.google.guava</groupId>
        <artifactId>guava</artifactId>
        <version>33.5.0-jre</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-context</artifactId>
        <version>7.0.3</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.testng</groupId>
        <artifactId>testng</artifactId>
        <version>7.12.0</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.assertj</groupId>
        <artifactId>assertj-core</artifactId>
        <version>3.27.7</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.hsqldb</groupId>
        <artifactId>hsqldb</artifactId>
        <version>2.7.4</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>com.sun.codemodel</groupId>
        <artifactId>codemodel</artifactId>
        <version>2.6</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.wiremock</groupId>
        <artifactId>wiremock</artifactId>
        <version>3.13.2</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
  </dependencyManagement>

  <build>
    <pluginManagement>
      <plugins>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-clean-plugin</artifactId>
          <version>3.5.0</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-deploy-plugin</artifactId>
          <version>3.1.4</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-install-plugin</artifactId>
          <version>3.1.4</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-site-plugin</artifactId>
          <version>3.21.0</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-enforcer-plugin</artifactId>
          <version>3.6.2</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-dependency-plugin</artifactId>
          <version>3.9.0</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-resources-plugin</artifactId>
          <version>3.4.0</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>3.15.0</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-checkstyle-plugin</artifactId>
          <version>3.6.0</version>
          <dependencies>
            <dependency>
              <groupId>com.puppycrawl.tools</groupId>
              <artifactId>checkstyle</artifactId>
              <version>12.3.1</version>
            </dependency>
          </dependencies>
        </plugin>
        <plugin>
          <groupId>com.github.spotbugs</groupId>
          <artifactId>spotbugs-maven-plugin</artifactId>
          <version>4.9.8.2</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-surefire-plugin</artifactId>
          <version>3.5.4</version>
          <configuration>
            <redirectTestOutputToFile>true</redirectTestOutputToFile>
          </configuration>
        </plugin>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>build-helper-maven-plugin</artifactId>
          <version>3.6.1</version>
        </plugin>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>exec-maven-plugin</artifactId>
          <version>3.6.3</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-javadoc-plugin</artifactId>
          <version>3.12.0</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-source-plugin</artifactId>
          <version>3.4.0</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-jar-plugin</artifactId>
          <version>3.5.0</version>
        </plugin>
        <plugin>
          <groupId>org.apache.felix</groupId>
          <artifactId>maven-bundle-plugin</artifactId>
          <version>6.0.0</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-assembly-plugin</artifactId>
          <version>3.8.0</version>
        </plugin>
        <plugin>
          <groupId>com.github.siom79.japicmp</groupId>
          <artifactId>japicmp-maven-plugin</artifactId>
          <version>0.25.4</version>
        </plugin>
      </plugins>
    </pluginManagement>

    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-enforcer-plugin</artifactId>
        <executions>
          <execution>
            <id>enforce-maven</id>
            <goals>
              <goal>enforce</goal>
            </goals>
            <configuration>
              <rules>
                <requireMavenVersion>
                  <version>[3.9.0,)</version>
                </requireMavenVersion>
              </rules>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <configuration>
          <fork>true</fork>
          <debug>true</debug>
          <showDeprecation>true</showDeprecation>
          <showWarnings>true</showWarnings>
          <compilerArgs>
            <arg>-Xlint:unchecked</arg>
          </compilerArgs>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-checkstyle-plugin</artifactId>
        <configuration>
          <configLocation>${checkstyle.dir}/checks.xml</configLocation>
          <headerLocation>${checkstyle.dir}/header.txt</headerLocation>
          <suppressionsLocation>${checkstyle.dir}/suppressions.xml</suppressionsLocation>
          <includeTestSourceDirectory>true</includeTestSourceDirectory>
          <failsOnError>true</failsOnError>
          <outputFileFormat>plain</outputFileFormat>
          <outputFile>${project.build.directory}/checkstyle-result.txt</outputFile>
        </configuration>
        <executions>
          <execution>
            <id>checkstyle</id>
            <phase>compile</phase>
            <goals>
              <goal>checkstyle</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>com.github.spotbugs</groupId>
        <artifactId>spotbugs-maven-plugin</artifactId>
        <configuration>
          <effort>Max</effort>
          <threshold>Medium</threshold>
          <xmlOutput>true</xmlOutput>
          <xmlOutputDirectory>${project.build.directory}/spotbugs</xmlOutputDirectory>
          <excludeFilterFile>${spotbugs.dir}/exclude.xml</excludeFilterFile>
        </configuration>
        <executions>
          <execution>
            <goals>
              <goal>check</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
        <configuration>
          <source>8</source>
          <links>
            <link>https://docs.oracle.com/javase/8/docs/api</link>
          </links>
          <quiet>true</quiet>
          <author>false</author>
          <show>private</show>
          <version>true</version>
          <doctitle>Passay ${project.version} API</doctitle>
          <windowtitle>Passay ${project.version} API</windowtitle>
          <bottom><![CDATA[<i>Copyright &#169; 2003-2026 Virginia Tech. All Rights Reserved.</i>]]></bottom>
          <archive>
            <manifestEntries>
              <Automatic-Module-Name>${module.name}</Automatic-Module-Name>
            </manifestEntries>
          </archive>
        </configuration>
        <executions>
          <execution>
            <id>javadoc</id>
            <phase>package</phase>
            <goals>
              <goal>jar</goal>
            </goals>
            <configuration>
              <sourcepath>${project.build.sourceDirectory}:${project.build.directory}/dist-sources</sourcepath>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-source-plugin</artifactId>
        <configuration>
          <archive>
            <manifestEntries>
              <Automatic-Module-Name>${module.name}</Automatic-Module-Name>
            </manifestEntries>
          </archive>
        </configuration>
        <executions>
          <execution>
            <id>source</id>
            <phase>package</phase>
            <goals>
              <goal>jar</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-jar-plugin</artifactId>
        <configuration>
          <archive>
            <manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
            <manifestEntries>
              <Automatic-Module-Name>${module.name}</Automatic-Module-Name>
            </manifestEntries>
          </archive>
          <skipIfEmpty>true</skipIfEmpty>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.felix</groupId>
        <artifactId>maven-bundle-plugin</artifactId>
        <executions>
          <execution>
            <id>bundle-manifest</id>
            <phase>process-classes</phase>
            <goals>
              <goal>manifest</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>com.github.siom79.japicmp</groupId>
        <artifactId>japicmp-maven-plugin</artifactId>
        <configuration>
          <oldVersion>
            <dependency>
              <groupId>${project.groupId}</groupId>
              <artifactId>${project.artifactId}</artifactId>
              <version>${japicmp.oldVersion}</version>
              <type>jar</type>
            </dependency>
          </oldVersion>
          <newVersion>
            <file>
              <path>${project.build.directory}/${project.artifactId}-${project.version}.${project.packaging}</path>
            </file>
          </newVersion>
          <parameter>
            <ignoreNonResolvableArtifacts>false</ignoreNonResolvableArtifacts>
            <ignoreMissingClasses>true</ignoreMissingClasses>
            <onlyBinaryIncompatible>true</onlyBinaryIncompatible>
            <breakBuildOnBinaryIncompatibleModifications>${japicmp.enabled}</breakBuildOnBinaryIncompatibleModifications>
            <packagingSupporteds>
              <packagingSupported>jar</packagingSupported>
            </packagingSupporteds>
          </parameter>
        </configuration>
        <executions>
          <execution>
            <phase>verify</phase>
            <goals>
              <goal>cmp</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>
  <profiles>
    <profile>
      <id>integration</id>
      <modules>
        <module>integration</module>
      </modules>
    </profile>
    <profile>
      <id>fuzz</id>
      <modules>
        <module>fuzz</module>
      </modules>
    </profile>
    <profile>
      <id>heap</id>
      <modules>
        <module>heap</module>
      </modules>
    </profile>
    <profile>
      <id>distribution</id>
      <modules>
        <module>distribution</module>
      </modules>
    </profile>
    <profile>
      <id>sign-artifacts</id>
      <activation>
        <property>
          <name>sign</name>
          <value>true</value>
        </property>
      </activation>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-gpg-plugin</artifactId>
            <version>3.2.8</version>
            <executions>
              <execution>
                <id>sign-artifacts</id>
                <phase>package</phase>
                <goals>
                  <goal>sign</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>
</project>
