<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/maven-v4_0_0.xsd">
	<modelVersion>4.0.0</modelVersion>
	<parent>
		<groupId>de.invesdwin</groupId>
		<artifactId>invesdwin-context-parent</artifactId>
		<version>1.0.3-SNAPSHOT</version>
	</parent>
	<artifactId>invesdwin-context-webserver</artifactId>
	<packaging>jar</packaging>

	<dependencies>
		<dependency>
			<groupId>de.invesdwin</groupId>
			<artifactId>invesdwin-context-integration</artifactId>
		</dependency>
		<dependency>
			<groupId>de.invesdwin</groupId>
			<artifactId>invesdwin-maven-plugin-util</artifactId>
		</dependency>

		<dependency>
			<groupId>org.eclipse.jetty</groupId>
			<artifactId>jetty-webapp</artifactId>
		</dependency>
		<dependency>
			<groupId>org.eclipse.jetty.http2</groupId>
			<artifactId>http2-server</artifactId>
		</dependency>
		<dependency>
			<groupId>org.eclipse.jetty</groupId>
			<artifactId>jetty-alpn-server</artifactId>
		</dependency>
		<dependency>
			<groupId>org.eclipse.jetty</groupId>
			<artifactId>jetty-alpn-conscrypt-server</artifactId>
		</dependency>
		<dependency>
			<groupId>org.eclipse.jetty.websocket</groupId>
			<artifactId>javax-websocket-server-impl</artifactId>
		</dependency>
		<dependency>
			<groupId>org.ow2.asm</groupId>
			<artifactId>asm</artifactId>
		</dependency>
		<dependency>
			<groupId>org.ow2.asm</groupId>
			<artifactId>asm-commons</artifactId>
		</dependency>
		<dependency>
			<groupId>org.ow2.asm</groupId>
			<artifactId>asm-tree</artifactId>
		</dependency>
	</dependencies>

	<profiles>
		<profile>
			<!-- call with: mvn -Pgenerate-key-pair generate-resources -->
			<id>generate-key-pair</id>
			<build>
				<plugins>
					<plugin>
						<groupId>org.codehaus.mojo</groupId>
						<artifactId>keytool-maven-plugin</artifactId>
						<executions>
							<execution>
								<goals>
									<goal>generateKeyPair</goal>
								</goals>
								<phase>generate-resources</phase>
							</execution>
						</executions>
						<configuration>
							<keystore>${basedir}/src/main/java/META-INF/SslConnectorKeystore.jks</keystore>
							<storepass>invesdwin</storepass>
							<keypass>invesdwin</keypass>
							<![CDATA[
							    CN - Common Name of the certificate owner
							    OU - Organizational Unit of the certificate owner
							    O - Organization to which the certificate owner belongs
							    L - Locality name of the certificate owner
							    S - State or province of the certificate owner
							    C - Country of the certificate owner
							]]>
							<dname>CN=invesdwin.de, OU=None, O=invesdwin,
								L=None, S=None, C=DE</dname>
							<alias>invesdwin</alias>
							<!-- 100 years = 365 * 100 days -->
							<validity>365000</validity>
							<!-- rsa is better compatible with browsers -->
							<keyalg>RSA</keyalg>
						</configuration>
					</plugin>
				</plugins>
			</build>
		</profile>
	</profiles>

</project>
