<?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 https://maven.apache.org/xsd/maven-4.0.0.xsd">

    <modelVersion>4.0.0</modelVersion>

    <groupId>ch.mobileid.mid-java-client</groupId>
    <artifactId>mid-java-client-parent</artifactId>
    <version>1.5.7</version>
    <name>Mobile ID Java client</name>
    <description>Mobile ID client reference implementation in Java</description>
    <url>https://github.com/MobileID-Strong-Authentication/mobileid-client-java</url>
    <packaging>pom</packaging>

    <licenses>
        <license>
            <name>The Apache License, Version 2.0</name>
            <url>https://www.apache.org/licenses/LICENSE-2.0.txt</url>
        </license>
    </licenses>

    <developers>
        <developer>
            <id>phaupt</id>
            <name>Philipp Haupt</name>
        </developer>
        <developer>
            <id>bmocanu</id>
            <name>Bogdan Mocanu</name>
        </developer>
        <developer>
            <id>thomas4v</id>
            <name>Tomasz Gruszewski</name>
        </developer>
        <developer>
            <id>pso-rsystems</id>
            <name>Piotr Sokolowski</name>
        </developer>
    </developers>

    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
        <java.version>8</java.version>
        <maven.compiler.source>${java.version}</maven.compiler.source>
        <maven.compiler.target>${java.version}</maven.compiler.target>
    </properties>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>org.slf4j</groupId>
                <artifactId>slf4j-api</artifactId>
                <version>2.0.3</version>
            </dependency>
            <dependency>
                <groupId>ch.qos.logback</groupId>
                <artifactId>logback-classic</artifactId>
                <version>1.5.18</version>
            </dependency>
            <dependency>
                <groupId>com.fasterxml.jackson.core</groupId>
                <artifactId>jackson-databind</artifactId>
                <version>2.14.0</version>
            </dependency>
            <dependency>
                <groupId>com.fasterxml.jackson.core</groupId>
                <artifactId>jackson-core</artifactId>
                <version>2.15.0</version>
            </dependency>
            <dependency>
                <groupId>com.fasterxml.jackson.core</groupId>
                <artifactId>jackson-annotations</artifactId>
                <version>2.14.0</version>
            </dependency>
            <dependency>
                <groupId>org.apache.httpcomponents.client5</groupId>
                <artifactId>httpclient5</artifactId>
                <version>5.2.1</version>
            </dependency>
            <dependency>
                <groupId>org.apache.commons</groupId>
                <artifactId>commons-pool2</artifactId>
                <version>2.11.1</version>
            </dependency>
            <dependency>
                <groupId>commons-io</groupId>
                <artifactId>commons-io</artifactId>
                <version>2.11.0</version>
            </dependency>
            <dependency>
                <groupId>commons-codec</groupId>
                <artifactId>commons-codec</artifactId>
                <version>1.15</version>
            </dependency>
            <dependency>
                <groupId>com.sun.xml.ws</groupId>
                <artifactId>jaxws-rt</artifactId>
                <version>2.3.3</version>
                <exclusions>
                    <exclusion>
                        <groupId>com.fasterxml.woodstox</groupId>
                        <artifactId>woodstox-core</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>
            <!-- because of the exclusion above, a new version of com.fasterxml.woodstox:woodstox-core needs to be included -->
            <dependency>
                <groupId>com.fasterxml.woodstox</groupId>
                <artifactId>woodstox-core</artifactId>
                <version>5.4.0</version>
            </dependency>
            <dependency>
                <groupId>org.bouncycastle</groupId>
                <artifactId>bcprov-jdk18on</artifactId>
                <version>1.78</version>
            </dependency>
            <dependency>
                <groupId>org.bouncycastle</groupId>
                <artifactId>bcpkix-jdk18on</artifactId>
                <version>1.75</version>
            </dependency>
            <dependency>
                <groupId>org.bouncycastle</groupId>
                <artifactId>bcutil-jdk18on</artifactId>
                <version>1.78.1</version>
            </dependency>
            <dependency>
                <groupId>org.junit.jupiter</groupId>
                <artifactId>junit-jupiter-api</artifactId>
                <version>5.9.1</version>
                <scope>test</scope>
            </dependency>
            <dependency>
                <groupId>org.junit.jupiter</groupId>
                <artifactId>junit-jupiter-engine</artifactId>
                <version>5.9.1</version>
                <scope>test</scope>
            </dependency>
            <dependency>
                <groupId>org.mockito</groupId>
                <artifactId>mockito-core</artifactId>
                <version>4.8.1</version>
                <scope>test</scope>
            </dependency>
            <dependency>
                <groupId>org.mockito</groupId>
                <artifactId>mockito-junit-jupiter</artifactId>
                <version>4.8.1</version>
                <scope>test</scope>
            </dependency>
            <dependency>
                <groupId>com.github.tomakehurst</groupId>
                <artifactId>wiremock</artifactId>
                <version>2.27.2</version>
                <scope>test</scope>
            </dependency>
            <dependency>
                <groupId>org.hamcrest</groupId>
                <artifactId>hamcrest-library</artifactId>
                <version>2.2</version>
                <scope>test</scope>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <artifactId>maven-source-plugin</artifactId>
                    <version>3.2.1</version>
                </plugin>
                <plugin>
                    <artifactId>maven-dependency-plugin</artifactId>
                    <version>3.3.0</version>
                </plugin>
                <plugin>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>3.10.1</version>
                </plugin>
                <plugin>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>2.22.2</version>
                </plugin>
                <plugin>
                    <artifactId>maven-failsafe-plugin</artifactId>
                    <version>2.22.2</version>
                </plugin>
                <plugin>
                    <groupId>org.sonarsource.scanner.maven</groupId>
                    <artifactId>sonar-maven-plugin</artifactId>
                    <version>3.7.0.1746</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-javadoc-plugin</artifactId>
                    <version>3.4.1</version>
                </plugin>
                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>jaxws-maven-plugin</artifactId>
                    <version>2.6</version>
                    <!-- if you want to use a specific version of JAX-WS, you can do so like this -->
                    <dependencies>
                        <dependency>
                            <groupId>com.sun.xml.ws</groupId>
                            <artifactId>jaxws-tools</artifactId>
                            <version>2.3.3</version>
                        </dependency>
                    </dependencies>
                </plugin>
                <!--                <plugin>-->
                <!--                    <groupId>org.sonatype.plugins</groupId>-->
                <!--                    <artifactId>nexus-staging-maven-plugin</artifactId>-->
                <!--                    <version>1.6.13</version>-->
                <!--                </plugin>-->
                <plugin>
                    <groupId>org.sonatype.central</groupId>
                    <artifactId>central-publishing-maven-plugin</artifactId>
                    <version>0.8.0</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-gpg-plugin</artifactId>
                    <version>3.0.1</version>
                </plugin>

            </plugins>
        </pluginManagement>
    </build>

    <modules>
        <module>mid-java-client-core</module>
        <module>mid-java-client-rest</module>
        <module>mid-java-client-soap</module>
        <module>mid-java-client-usage</module>
    </modules>

    <scm>
        <connection>scm:git:git://github.com/MobileID-Strong-Authentication/mobileid-client-java.git</connection>
        <developerConnection>${project.scm.connection}</developerConnection>
        <url>https://github.com/MobileID-Strong-Authentication/mobileid-client-java/tree/main</url>
    </scm>

    <distributionManagement>
        <!--        <snapshotRepository>-->
        <!--            <id>ossrh</id>-->
        <!--            <url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>-->
        <!--        </snapshotRepository>-->
        <!--        <repository>-->
        <!--            <id>ossrh</id>-->
        <!--            <url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>-->
        <!--        </repository>-->
    </distributionManagement>

    <profiles>
        <profile>
            <id>releaseToMavenCentral</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-javadoc-plugin</artifactId>
                        <configuration>
                            <reportOutputDirectory>${project.basedir}</reportOutputDirectory>
                            <destDir>api-docs</destDir>
                            <excludePackageNames>
                                ch.swisscom.mid.ts102204.*:ch.swisscom.ts102204.*:fi.*:oasis.*:org.*
                            </excludePackageNames>
                        </configuration>
                        <executions>
                            <execution>
                                <id>attach-javadocs</id>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-source-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>attach-sources</id>
                                <goals>
                                    <goal>jar-no-fork</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.sonatype.central</groupId>
                        <artifactId>central-publishing-maven-plugin</artifactId>
                        <version>0.8.0</version>
                        <extensions>true</extensions>
                        <configuration>
                            <publishingServerId>central</publishingServerId>
                            <autoPublish>true</autoPublish>
                        </configuration>
                    </plugin>
                    <!--                    <plugin>-->
                    <!--                        <groupId>org.sonatype.plugins</groupId>-->
                    <!--                        <artifactId>nexus-staging-maven-plugin</artifactId>-->
                    <!--                        <extensions>true</extensions>-->
                    <!--                        <configuration>-->
                    <!--                            <serverId>ossrh</serverId>-->
                    <!--                            <nexusUrl>https://s01.oss.sonatype.org/</nexusUrl>-->
                    <!--                            <autoReleaseAfterClose>false</autoReleaseAfterClose>-->
                    <!--                        </configuration>-->
                    <!--                    </plugin>-->
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

</project>
