[java-identity-provider COMMIT] in /trunk: idp-distribution/src/main/resources/bin/build.xml idp-installer/src/main/j...
noreply at shibboleth.net
noreply at shibboleth.net
Fri Aug 29 11:32:31 EDT 2014
Author: rdw
Date: Fri Aug 29 11:32:31 2014
New Revision: 6484
URL: http://svn.shibboleth.net/view/java-identity-provider?rev=6484&view=rev
Log:
IDP 469 Key Generation on install
Added:
trunk/idp-installer/src/main/java/net/shibboleth/idp/installer/ant/
trunk/idp-installer/src/main/java/net/shibboleth/idp/installer/ant/SelfSignedCertificateGeneratorTask.java (with props)
trunk/idp-installer/src/main/java/net/shibboleth/idp/installer/ant/package-info.java (with props)
trunk/idp-installer/src/main/resources/net/
trunk/idp-installer/src/main/resources/net/shibboleth/
trunk/idp-installer/src/main/resources/net/shibboleth/idp/
trunk/idp-installer/src/main/resources/net/shibboleth/idp/installer/
trunk/idp-installer/src/main/resources/net/shibboleth/idp/installer/ant.xml (with props)
Modified:
trunk/idp-distribution/src/main/resources/bin/build.xml
Modified: trunk/idp-distribution/src/main/resources/bin/build.xml
URL: http://svn.shibboleth.net/view/java-identity-provider/trunk/idp-distribution/src/main/resources/bin/build.xml?rev=6484&r1=6483&r2=6484&view=diff
==============================================================================
--- trunk/idp-distribution/src/main/resources/bin/build.xml (original)
+++ trunk/idp-distribution/src/main/resources/bin/build.xml Fri Aug 29 11:32:31 2014
@@ -1,6 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="Shibboleth Identity Provider V3" basedir=".." default="install">
+ <taskdef resource="net/shibboleth/idp/installer/ant.xml"/>
+
<!-- We assume some properties set on the command line
idp.src.dir = where the install has been unpacked to
idp.target.dir = where we are installing to. In windows these are the same
@@ -20,6 +22,19 @@
<target name="install" depends="init, genkeys, upgrade, build-war"/>
<target name="v2upgrade" depends="init, v2v3prepopulate, install"/>
+ <!-- USER INPUT -->
+ <target name="gethostname" unless="idp.host.name">
+ <input message="Hostname" addproperty="idp.host.name"/>
+ </target>
+
+ <target name="geturisubjectaltname" unless="uri.subject.alt.name">
+ <property name="idp.uri.subject.alt.name" value="https://${idp.host.name}/org/shibboleth/idp"/>
+ </target>
+
+ <target name="getkeystorepassword" unless="uri.keystore.password">
+ <input message="Key Store Password" addproperty="uri.keystore.password"/>
+ </target>
+
<!--
KEY MANAGEMENT
@@ -37,16 +52,28 @@
<available property="idp.sealer.present" file="${idp.target.dir}/creds/sealer.kver"/>
</target>
- <target name="signing-key" unless="idp.signing.present">
- <echo>Gotta create that signing key</echo>
+ <target name="signing-key" unless="idp.signing.present" depends="gethostname, geturisubjectaltname">
+ <echo>Creating Signing Key, hostname ${idp.host.name} URI = ${idp.uri.subject.alt.name}</echo>
+ <selfsignedcert hostname="${idp.host.name}"
+ privateKeyFile="${idp.target.dir}/creds/idp-signing.key"
+ certificateFile="${idp.target.dir}/creds/idp-signing.crt"
+ uriSubjectAltNames="${idp.uri.subject.alt.name}"/>
</target>
- <target name="encryption-key" unless="idp.encryption.present">
- <echo>Gotta create that encryption key</echo>
+ <target name="encryption-key" unless="idp.encryption.present" depends="gethostname, geturisubjectaltname">
+ <echo>Creating Encryption Key, hostname ${idp.host.name} URI = ${idp.uri.subject.alt.name}</echo>
+ <selfsignedcert hostname="${idp.host.name}"
+ privateKeyFile="${idp.target.dir}/creds/idp-encryption.key"
+ certificateFile="${idp.target.dir}/creds/idp-encryption.crt"
+ uriSubjectAltNames="${idp.uri.subject.alt.name}"/>
</target>
- <target name="keystore" unless="idp.keystore.present">
- <echo>Gotta create that kestore key</echo>
+ <target name="keystore" unless="idp.keystore.present" depends="getkeystorepassword, gethostname, geturisubjectaltname">
+ <echo>Creating TLS keystore, hostname ${idp.host.name} URI = ${idp.uri.subject.alt.name} password supressed</echo>
+ <selfsignedcert hostname="${idp.host.name}"
+ keystoreFile="${idp.target.dir}/creds/idp-tls.p12"
+ keystorePassword="$(uri.keystore.password}"
+ uriSubjectAltNames="${idp.uri.subject.alt.name}"/>
</target>
<target name="sealer" unless="idp.sealer.present">
More information about the commits
mailing list