-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Excludes the inc-mda-cloudhsm assembly. See incommon/inc-meta#92.
- Loading branch information
Showing
2 changed files
with
132 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,98 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!-- | ||
Generate and sign per-entity metadata using AWS CloudHSM. | ||
--> | ||
<beans xmlns="http://www.springframework.org/schema/beans" | ||
default-lazy-init="true" | ||
xmlns:c="http://www.springframework.org/schema/c" | ||
xmlns:p="http://www.springframework.org/schema/p" | ||
xmlns:util="http://www.springframework.org/schema/util" | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation=" | ||
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd | ||
http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util.xsd"> | ||
|
||
<!-- | ||
Import commonly used beans. | ||
--> | ||
<import resource="classpath:common-beans.xml"/> | ||
|
||
<!-- | ||
Import channel-specific beans. | ||
--> | ||
<import resource="classpath:incommon/beans.xml"/> | ||
|
||
<!-- This bean MUST be called "conversionService" to work properly. --> | ||
<bean id="conversionService" class="org.springframework.context.support.ConversionServiceFactoryBean"> | ||
<property name="converters"> | ||
<set> | ||
<bean class="net.shibboleth.ext.spring.config.DurationToLongConverter" /> | ||
<bean class="net.shibboleth.ext.spring.config.StringToIPRangeConverter" /> | ||
<bean class="net.shibboleth.ext.spring.config.BooleanToPredicateConverter" /> | ||
<bean class="net.shibboleth.ext.spring.config.StringBooleanToPredicateConverter" /> | ||
<bean class="net.shibboleth.ext.spring.config.StringToResourceConverter" /> | ||
</set> | ||
</property> | ||
</bean> | ||
|
||
<!-- | ||
Generate per-entity metadata. | ||
--> | ||
<bean id="mdq-multisign-cloudhsm" parent="mda.SimplePipeline"> | ||
<property name="stages"> | ||
<list> | ||
<!-- | ||
Start with the unsigned production aggregate. | ||
--> | ||
<bean id="production_aggregate" parent="mda.DOMResourceSourceStage"> | ||
<property name="parserPool" ref="parserPool"/> | ||
<property name="DOMResource"> | ||
<bean parent="FileSystemResource" c:_0="${mdq.input}"/> | ||
</property> | ||
</bean> | ||
|
||
<!-- Break down into individual entities. --> | ||
<ref bean="disassemble"/> | ||
|
||
<!-- Populate ItemId with the entityID. --> | ||
<ref bean="populateItemIds"/> | ||
|
||
<!-- Set ID, cacheDuration and validUntil attributes. --> | ||
<bean parent="mda.GenerateIdStage"/> | ||
<bean parent="mda.SetValidUntilStage" p:validityDuration="P14D"/> | ||
|
||
<!-- Identity transform fixes signing issues. --> | ||
<bean parent="mda.XSLTransformationStage" | ||
p:XSLResource="classpath:identity.xsl"/> | ||
|
||
<!-- Sign each item. --> | ||
<bean id="perform.signature" parent="mda.XMLSignatureSigningStage"> | ||
<property name="privateKey"> | ||
<bean class="uk.org.iay.incommon.mda.cloudhsm.CaviumPrivateKeyFactoryBean" | ||
p:username="${sign.keyUser}" | ||
p:password="${sign.keyPassword}" | ||
p:keyHandle="${sign.keyHandle}" | ||
/> | ||
</property> | ||
</bean> | ||
|
||
<!-- Write individual entity documents to files. --> | ||
<bean id="write.perentity" parent="mda.MultiOutputSerializationStage"> | ||
<property name="serializer" ref="serializer"/> | ||
<property name="outputStrategy"> | ||
<bean parent="mda.FilesInDirectoryMultiOutputStrategy" p:nameSuffix=".xml"> | ||
<property name="directory"> | ||
<bean parent="File" c:_="${mdq.output}"/> | ||
</property> | ||
<property name="nameTransformer"> | ||
<bean parent="mda.PathSegmentStringTransformer"/> | ||
</property> | ||
</bean> | ||
</property> | ||
</bean> | ||
|
||
</list> | ||
</property> | ||
</bean> | ||
|
||
</beans> |