source: raptor-distribution/MSIs/raptor-mua/trunk/source/mua/conf/attribute-association.xml @ 1722

Revision 1722, 7.1 KB checked in by rhyssmith, 5 years ago (diff)

Adding raptor-mua v1.0.0 MSI sources

  • Property svn:executable set to *
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<!-- Copyright (C) 2010 Cardiff University, Wales <smartp@cf.ac.uk> Licensed under the Apache License, Version 2.0 (the "License");
3    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
4    Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS
5    IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language
6    governing permissions and limitations under the License. -->
7
8<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
9    xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
10
11
12        <!--  the attribute association engine -->
13    <bean id="attributeAssociationEngine" class="uk.ac.cardiff.raptor.event.expansion.AttributeAssociationEngine">
14        <property name="attributeAssociationDefinitions">
15            <list>
16                <!--<ref bean="shibPrincipalAttributeAssociationDefinition"/>-->
17                <!--<ref bean="ezproxyPrincipalAttributeAssociationDefinition"/>-->
18                <ref bean="shibResourceCategoryAttributeAssociationDefinition"/> <!--Do NOT disable this-->
19             </list>
20        </property>
21    </bean>
22
23    <!-- Association policies to mark resources as internal or external. Do NOT disable this-->
24    <bean id="shibResourceCategoryAttributeAssociationDefinition" class="uk.ac.cardiff.raptor.event.expansion.ResourceCategoryAttributeAssociationDefinition">
25        <property name="definiationName"><value>Shib Resource Category Definition</value></property>
26        <property name="dataConnection"><ref bean="dataConnectionImpl"/></property>
27        <property name="enabled"><value>true</value></property>
28        <property name="classToAdd"><value type="java.lang.Class">uk.ac.cardiff.model.event.Event</value></property>
29        <property name="associateWithClass"><value>uk.ac.cardiff.model.event.ShibbolethIdpAuthenticationEvent</value></property>
30    </bean>
31
32
33    <!-- Properties to set. PrincipalInformation only has the attributes [school, affiliation] -->
34   
35    <bean id="shibPrincipalAttributeAssociationDefinition" class="uk.ac.cardiff.raptor.event.expansion.PrincipalAttributeAssociationDefinition">
36        <property name="definiationName"><value>ShibAssociationDefinition</value></property>
37        <property name="subjectPrincipalField"><value>principalName</value></property>
38        <property name="dataConnector"><ref bean="ldapDataConnector"/></property>
39        <!-- add the filter here, where [principal] is replaced by the actual principal value extracted per event -->
40        <property name="searchTemplate"><value>cn=[principal]</value></property>
41        <property name="enabled"><value>true</value></property>
42        <property name="classToAdd"><value type="java.lang.Class">uk.ac.cardiff.model.event.auxiliary.PrincipalInformation</value></property>
43        <property name="associateWithClass"><value>uk.ac.cardiff.model.event.ShibbolethIdpAuthenticationEvent</value></property>
44        <property name="lookupAttributes">
45            <list>
46                <bean class="uk.ac.cardiff.raptor.event.expansion.AttributeLookup">
47                    <property name="sourceAttributeName"><value>LDAP_ATTRIBUTE_NAME</value></property>
48                    <property name="internalAttributeName"><value>affiliation</value></property>
49                </bean>
50                 <bean class="uk.ac.cardiff.raptor.event.expansion.AttributeLookup">
51                    <property name="sourceAttributeName"><value>LDAP_ATTRIBUTE_NAME</value></property>
52                    <property name="internalAttributeName"><value>school</value></property>
53                </bean>
54            </list>
55        </property>
56    </bean>
57
58    <bean id="ezproxyPrincipalAttributeAssociationDefinition" class="uk.ac.cardiff.raptor.event.expansion.PrincipalAttributeAssociationDefinition">
59        <property name="definiationName"><value>EzproxyAssociationDefinition</value></property>
60        <property name="subjectPrincipalField"><value>principalName</value></property>
61        <property name="dataConnector"><ref bean="ldapDataConnector"/></property>
62        <!-- add the filter here, where [principal] is replaced by the actual principal value extracted per event -->
63        <property name="searchTemplate"><value>cn=[principal]</value></property>
64        <property name="enabled"><value>true</value></property>
65        <property name="classToAdd"><value type="java.lang.Class">uk.ac.cardiff.model.event.auxiliary.PrincipalInformation</value></property>
66        <property name="associateWithClass"><value>uk.ac.cardiff.model.event.EzproxyAuthenticationEvent</value></property>
67        <property name="lookupAttributes">
68            <list>
69                <bean class="uk.ac.cardiff.raptor.event.expansion.AttributeLookup">
70                    <property name="sourceAttributeName"><value>LDAP_ATTRIBUTE_NAME</value></property>
71                    <property name="internalAttributeName"><value>affiliation</value></property>
72                </bean>
73                 <bean class="uk.ac.cardiff.raptor.event.expansion.AttributeLookup">
74                    <property name="sourceAttributeName"><value>LDAP_ATTRIBUTE_NAME</value></property>
75                    <property name="internalAttributeName"><value>school</value></property>
76                </bean>
77            </list>
78        </property>
79    </bean>
80
81
82
83
84        <!-- data connectors.  -->
85    <bean id="ldapDataConnector" class="uk.ac.cardiff.raptor.event.expansion.connector.LdapDataConnector">
86         <property name="poolMaxIdle"><value>10</value></property>
87         <property name="poolInitIdleCapacity"><value>10</value></property>
88         <property name="ldapUrl"><value>LDAP_URL</value></property>
89         <property name="ldapBaseDn"><value>BASE</value></property>
90         <property name="startTls"><value>false</value></property>
91         <property name="principal"><value>PRINCIPAL</value></property>
92         <property name="principalCredential"><value>PASSWORD</value></property>
93         <property name="cacheResults"><value>true</value></property>
94         <property name="cacheTimeoutMs"><value>86400000</value></property>
95    </bean>
96   
97    <!--  Example RDBMS Data connectors for postgres. But mysql is also possible.
98        <bean id="databaseConnector" class="uk.ac.cardiff.raptor.event.expansion.connector.RDBMSDataConnector">         
99         <property name="cacheResults"><value>true</value></property>
100         <property name="cacheTimeoutMs"><value>86400000</value></property>
101         <property name="dataSource">
102            <bean id="dataSourceConnectionProperties" class="org.apache.commons.dbcp.BasicDataSource">
103                <property name="driverClassName" value="org.postgresql.Driver"/>
104                <property name="url"  value="jdbc:postgresql://localhost/identities"/>
105                <property name="username"  value="postgres"/>
106                <property name="password"  value=""/>
107            </bean>
108         </property>
109    </bean>-->
110
111
112</beans>
Note: See TracBrowser for help on using the repository browser.