You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tomee.apache.org by jg...@apache.org on 2017/06/22 20:07:02 UTC
tomee git commit: Use fixed keystores instead of an Ant task to speed
up build and make it more determinisic
Repository: tomee
Updated Branches:
refs/heads/tomee-1.7.x 679692347 -> bc00763ca
Use fixed keystores instead of an Ant task to speed up build and make it more determinisic
Project: http://git-wip-us.apache.org/repos/asf/tomee/repo
Commit: http://git-wip-us.apache.org/repos/asf/tomee/commit/bc00763c
Tree: http://git-wip-us.apache.org/repos/asf/tomee/tree/bc00763c
Diff: http://git-wip-us.apache.org/repos/asf/tomee/diff/bc00763c
Branch: refs/heads/tomee-1.7.x
Commit: bc00763ca916a6e8d81b29edd35736635399b7c2
Parents: 6796923
Author: Jonathan S. Fisher <jf...@tomitribe.com>
Authored: Thu Jun 22 14:37:34 2017 -0500
Committer: Jonathan S. Fisher <jf...@tomitribe.com>
Committed: Thu Jun 22 14:37:34 2017 -0500
----------------------------------------------------------------------
.../webservice-ws-security/create-keystores.xml | 198 -------------------
examples/webservice-ws-security/pom.xml | 19 --
.../src/main/resources/META-INF/clientStore.jks | Bin 0 -> 2830 bytes
.../src/main/resources/META-INF/serverStore.jks | Bin 0 -> 2830 bytes
4 files changed, 217 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/tomee/blob/bc00763c/examples/webservice-ws-security/create-keystores.xml
----------------------------------------------------------------------
diff --git a/examples/webservice-ws-security/create-keystores.xml b/examples/webservice-ws-security/create-keystores.xml
deleted file mode 100644
index cfd0cbf..0000000
--- a/examples/webservice-ws-security/create-keystores.xml
+++ /dev/null
@@ -1,198 +0,0 @@
-<?xml version="1.0"?>
-<!--
-
- Licensed to the Apache Software Foundation (ASF) under one or more
- contributor license agreements. See the NOTICE file distributed with
- this work for additional information regarding copyright ownership.
- The ASF licenses this file to You under the Apache License, Version 2.0
- (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-
--->
-
-<project default="run" name="create keystores et al">
-
- <!-- first create our properties -->
- <condition property="is.ibm.jdk">
- <available classname="com.ibm.crypto.tools.KeyTool"/>
- </condition>
- <condition property="is.sun.jdk">
- <available classname="sun.security.tools.KeyTool"/>
- </condition>
- <property name="server.alias" value="serveralias"/>
- <property name="server.keypass" value="serverPassword"/>
- <property name="server.keystore" value="${basedir}/target/classes/META-INF/serverStore.jks"/>
- <property name="server.storepass" value="keystorePass"/>
- <property name="server.dname" value="'cn=serveralias'"/>
- <property name="server.file" value="${basedir}/target/classes/META-INF/serverKey.rsa"/>
-
- <property name="client.alias" value="clientalias"/>
- <property name="client.keypass" value="clientPassword"/>
- <property name="client.keystore" value="${basedir}/target/test-classes/META-INF/clientStore.jks"/>
- <property name="client.storepass" value="keystorePass"/>
- <property name="client.dname" value="'cn=clientalias'"/>
- <property name="client.file" value="${basedir}/target/test-classes/META-INF/clientKey.rsa"/>
-
- <property name="keyalg" value="RSA"/>
-
- <!-- now create our JDK specific targets -->
- <target name="do.ibm.jdk" if="is.ibm.jdk">
- <echo message="*** Running on an IBM JDK ***"/>
- <echo message="generate server keys"/>
- <java classname="com.ibm.crypto.tools.KeyTool" fork="true">
- <arg line="-genkey"/>
- <arg line="-alias ${server.alias}"/>
- <arg line="-keypass ${server.keypass}"/>
- <arg line="-keystore ${server.keystore}"/>
- <arg line="-storepass ${server.storepass}"/>
- <arg line="-dname ${server.dname}"/>
- <arg line="-keyalg ${keyalg}"/>
- </java>
- <java classname="com.ibm.crypto.tools.KeyTool" fork="true">
- <arg line="-selfcert"/>
- <arg line="-alias ${server.alias}"/>
- <arg line="-keystore ${server.keystore}"/>
- <arg line="-storepass ${server.storepass}"/>
- <arg line="-keypass ${server.keypass}"/>
- </java>
- <java classname="com.ibm.crypto.tools.KeyTool" fork="true">
- <arg line="-export"/>
- <arg line="-alias ${server.alias}"/>
- <arg line="-file ${server.file}"/>
- <arg line="-keystore ${server.keystore}"/>
- <arg line="-storepass ${server.storepass}"/>
- </java>
-
- <echo message="generate client keys"/>
-
- <java classname="com.ibm.crypto.tools.KeyTool" fork="true">
- <arg line="-genkey"/>
- <arg line="-alias ${client.alias}"/>
- <arg line="-keypass ${client.keypass}"/>
- <arg line="-keystore ${client.keystore}"/>
- <arg line="-storepass ${client.storepass}"/>
- <arg line="-dname ${client.dname}"/>
- <arg line="-keyalg ${keyalg}"/>
- </java>
- <java classname="com.ibm.crypto.tools.KeyTool" fork="true">
- <arg line="-selfcert"/>
- <arg line="-alias ${client.alias}"/>
- <arg line="-keystore ${client.keystore}"/>
- <arg line="-storepass ${client.storepass}"/>
- <arg line="-keypass ${client.keypass}"/>
- </java>
- <java classname="com.ibm.crypto.tools.KeyTool" fork="true">
- <arg line="-export"/>
- <arg line="-alias ${client.alias}"/>
- <arg line="-file ${client.file}"/>
- <arg line="-keystore ${client.keystore}"/>
- <arg line="-storepass ${client.storepass}"/>
- </java>
-
- <echo message="import client/server public keys in client/server keystores"/>
- <java classname="com.ibm.crypto.tools.KeyTool" fork="true">
- <arg line="-import"/>
- <arg line="-alias ${server.alias}"/>
- <arg line="-file ${server.file}"/>
- <arg line="-keystore ${client.keystore}"/>
- <arg line="-storepass ${client.storepass}"/>
- <arg line="-noprompt"/>
- </java>
- <java classname="com.ibm.crypto.tools.KeyTool" fork="true">
- <arg line="-import"/>
- <arg line="-alias ${client.alias}"/>
- <arg line="-file ${client.file}"/>
- <arg line="-keystore ${server.keystore}"/>
- <arg line="-storepass ${server.storepass}"/>
- <arg line="-noprompt"/>
- </java>
- </target>
-
- <target name="do.sun.jdk" if="is.sun.jdk">
- <echo message="*** Running on a Sun JDK ***"/>
- <echo message="generate server keys"/>
- <java classname="sun.security.tools.KeyTool" fork="true">
- <arg line="-genkey"/>
- <arg line="-alias ${server.alias}"/>
- <arg line="-keypass ${server.keypass}"/>
- <arg line="-keystore ${server.keystore}"/>
- <arg line="-storepass ${server.storepass}"/>
- <arg line="-dname ${server.dname}"/>
- <arg line="-keyalg ${keyalg}"/>
- </java>
- <java classname="sun.security.tools.KeyTool" fork="true">
- <arg line="-selfcert"/>
- <arg line="-alias ${server.alias}"/>
- <arg line="-keystore ${server.keystore}"/>
- <arg line="-storepass ${server.storepass}"/>
- <arg line="-keypass ${server.keypass}"/>
- </java>
- <java classname="sun.security.tools.KeyTool" fork="true">
- <arg line="-export"/>
- <arg line="-alias ${server.alias}"/>
- <arg line="-file ${server.file}"/>
- <arg line="-keystore ${server.keystore}"/>
- <arg line="-storepass ${server.storepass}"/>
- </java>
-
- <echo message="generate client keys"/>
-
- <java classname="sun.security.tools.KeyTool" fork="true">
- <arg line="-genkey"/>
- <arg line="-alias ${client.alias}"/>
- <arg line="-keypass ${client.keypass}"/>
- <arg line="-keystore ${client.keystore}"/>
- <arg line="-storepass ${client.storepass}"/>
- <arg line="-dname ${client.dname}"/>
- <arg line="-keyalg ${keyalg}"/>
- </java>
- <java classname="sun.security.tools.KeyTool" fork="true">
- <arg line="-selfcert"/>
- <arg line="-alias ${client.alias}"/>
- <arg line="-keystore ${client.keystore}"/>
- <arg line="-storepass ${client.storepass}"/>
- <arg line="-keypass ${client.keypass}"/>
- </java>
- <java classname="sun.security.tools.KeyTool" fork="true">
- <arg line="-export"/>
- <arg line="-alias ${client.alias}"/>
- <arg line="-file ${client.file}"/>
- <arg line="-keystore ${client.keystore}"/>
- <arg line="-storepass ${client.storepass}"/>
- </java>
-
- <echo message="import client/server public keys in client/server keystores"/>
- <java classname="sun.security.tools.KeyTool" fork="true">
- <arg line="-import"/>
- <arg line="-alias ${server.alias}"/>
- <arg line="-file ${server.file}"/>
- <arg line="-keystore ${client.keystore}"/>
- <arg line="-storepass ${client.storepass}"/>
- <arg line="-noprompt"/>
- </java>
- <java classname="sun.security.tools.KeyTool" fork="true">
- <arg line="-import"/>
- <arg line="-alias ${client.alias}"/>
- <arg line="-file ${client.file}"/>
- <arg line="-keystore ${server.keystore}"/>
- <arg line="-storepass ${server.storepass}"/>
- <arg line="-noprompt"/>
- </java>
- </target>
-
- <!-- run everything from our main target -->
- <!-- the other targets will only be run when their properties are true -->
- <target name="run" depends="do.sun.jdk, do.ibm.jdk">
- <echo message="Running JDK specific keystore creation target"/>
- </target>
-
-</project>
-
http://git-wip-us.apache.org/repos/asf/tomee/blob/bc00763c/examples/webservice-ws-security/pom.xml
----------------------------------------------------------------------
diff --git a/examples/webservice-ws-security/pom.xml b/examples/webservice-ws-security/pom.xml
index 85956d7..5c0e9b0 100644
--- a/examples/webservice-ws-security/pom.xml
+++ b/examples/webservice-ws-security/pom.xml
@@ -112,25 +112,6 @@
</execution>
</executions>
</plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-antrun-plugin</artifactId>
- <version>1.7</version>
- <executions>
- <execution>
- <id>generate-keys</id>
- <phase>process-test-resources</phase>
- <goals>
- <goal>run</goal>
- </goals>
- <configuration>
- <target name="generate keys">
- <ant antfile="create-keystores.xml" target="run" />
- </target>
- </configuration>
- </execution>
- </executions>
- </plugin>
</plugins>
</build>
<!--
http://git-wip-us.apache.org/repos/asf/tomee/blob/bc00763c/examples/webservice-ws-security/src/main/resources/META-INF/clientStore.jks
----------------------------------------------------------------------
diff --git a/examples/webservice-ws-security/src/main/resources/META-INF/clientStore.jks b/examples/webservice-ws-security/src/main/resources/META-INF/clientStore.jks
new file mode 100644
index 0000000..7e3c1ce
Binary files /dev/null and b/examples/webservice-ws-security/src/main/resources/META-INF/clientStore.jks differ
http://git-wip-us.apache.org/repos/asf/tomee/blob/bc00763c/examples/webservice-ws-security/src/main/resources/META-INF/serverStore.jks
----------------------------------------------------------------------
diff --git a/examples/webservice-ws-security/src/main/resources/META-INF/serverStore.jks b/examples/webservice-ws-security/src/main/resources/META-INF/serverStore.jks
new file mode 100644
index 0000000..fe6b68f
Binary files /dev/null and b/examples/webservice-ws-security/src/main/resources/META-INF/serverStore.jks differ