aboutsummaryrefslogtreecommitdiff
path: root/id
diff options
context:
space:
mode:
Diffstat (limited to 'id')
-rw-r--r--id/server/SamlEngine-VIDP/target/SamlEngine-1.4.0-sources.jarbin152332 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/SAMLEngine.classbin11791 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/SAMLEngineUtils.classbin19412 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/STORKSAMLEngine.classbin71959 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/X509PrincipalUtil.classbin1990 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/AuthenticationAttributes.classbin1108 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/CitizenCountryCode.classbin955 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/CustomAttributeQuery.classbin1100 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/CustomRequestAbstractType.classbin2341 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/EIDCrossBorderShare.classbin961 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/EIDCrossSectorShare.classbin962 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/EIDSectorShare.classbin907 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/QAAAttribute.classbin1033 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/RequestedAttribute.classbin1728 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/RequestedAttributes.classbin1010 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SAMLCore.classbin2649 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SAMLEngineSignI.classbin564 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPApplication.classbin923 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPCountry.classbin899 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPID.classbin871 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPInformation.classbin968 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPInstitution.classbin923 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPSector.classbin893 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/STORKSAMLCore.classbin7839 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/VIDPAuthenticationAttributes.classbin1241 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesBuilder.classbin1624 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesImpl.classbin2512 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesMarshaller.classbin436 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesUnmarshaller.classbin1116 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeBuilder.classbin1576 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeImpl.classbin1659 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeMarshaller.classbin1057 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeUnmarshaller.classbin879 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryBuilder.classbin1484 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryImpl.classbin1938 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryMarshaller.classbin1992 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryUnmarshaller.classbin4815 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareBuilder.classbin1584 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareImpl.classbin1667 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareMarshaller.classbin1061 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareUnmarshaller.classbin883 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareBuilder.classbin1593 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareImpl.classbin1667 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareMarshaller.classbin1061 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareUnmarshaller.classbin879 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDSectorShareBuilder.classbin1544 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDSectorShareImpl.classbin1627 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDSectorShareMarshaller.classbin1026 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDSectorShareUnmarshaller.classbin844 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/QAAAttributeBuilder.classbin1528 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/QAAAttributeImpl.classbin1595 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/QAAAttributeMarshaller.classbin1011 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/QAAAttributeUnmarshaller.classbin829 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributeBuilder.classbin1576 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributeImpl.classbin3478 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributeMarshaller.classbin2750 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributeUnmarshaller.classbin2599 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributesBuilder.classbin1584 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributesImpl.classbin2217 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributesMarshaller.classbin425 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributesUnmarshaller.classbin1083 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPApplicationBuilder.classbin1536 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPApplicationImpl.classbin1619 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPApplicationMarshaller.classbin1022 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPApplicationUnmarshaller.classbin844 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPCountryBuilder.classbin1504 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPCountryImpl.classbin1587 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPCountryMarshaller.classbin994 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPCountryUnmarshaller.classbin816 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPIDBuilder.classbin1464 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPIDImpl.classbin1547 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPIDMarshaller.classbin959 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPIDUnmarshaller.classbin781 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInformationBuilder.classbin1569 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInformationImpl.classbin2304 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInformationMarshaller.classbin407 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInformationUnmarshaller.classbin989 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInstitutionBuilder.classbin1536 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInstitutionImpl.classbin1619 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInstitutionMarshaller.classbin1022 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInstitutionUnmarshaller.classbin844 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPSectorBuilder.classbin1496 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPSectorImpl.classbin1272 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPSectorMarshaller.classbin987 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPSectorUnmarshaller.classbin809 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SignHW.classbin13842 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SignModuleFactory.classbin1319 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SignP12.classbin16097 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SignSW.classbin16107 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesBuilder.classbin1689 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesImpl.classbin2930 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesMarshaller.classbin452 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesUnmarshaller.classbin1274 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/validator/CustomAttributeQueryValidator.classbin2158 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/validator/ExtensionsSchemaValidator.classbin1949 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/validator/MultipleAssertionResponseValidator.classbin2268 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/validator/QAAAttributeSchemaValidator.classbin1612 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/ConfigurationCreator.classbin4541 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/ConfigurationEngine.classbin1125 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/ConfigurationReader.classbin5824 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/ConfigurationSingleton.classbin1934 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/InstanceEngine.classbin1212 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/exceptions/SAMLEngineException.classbin833 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/exceptions/STORKSAMLEngineException.classbin1864 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/exceptions/STORKSAMLEngineRuntimeException.classbin884 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/maven-archiver/pom.properties5
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/SamlEngine.xml67
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/SignModule_Conf0.xml21
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/SignModule_Conf1.xml12
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/SignModule_Conf2.xml12
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/SignModule_Conf3.xml12
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/SignModule_P11.xml11
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/StorkSamlEngine_Conf0.xml87
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/StorkSamlEngine_Conf1.xml85
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/StorkSamlEngine_Conf2.xml60
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/StorkSamlEngine_Conf3.xml57
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AttrQueryRequest.xml82
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AttrQueryRequestSdoc.xml15
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AttrQueryRequestTagDelete.xml66
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AttrQueryResponse.xml124
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AuthnRequest.xml72
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDelete.xml47
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDeleteEncoded.xml47
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/SSETestUtils.classbin4683 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/SimpleBaseTest.classbin1100 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkAttrQueryRequestTest.classbin15002 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkAttrQueryResponseTest.classbin29423 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkAuthRequestTest.classbin15798 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkLogoutRequestTest.classbin3110 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkLogoutResponseTest.classbin3961 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkNewResponseTest.classbin12588 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkResponseTest.classbin25902 -> 0 bytes
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/logback-test.xml21
-rw-r--r--id/server/SamlEngine-VIDP/target/test-classes/p11Conf.cfg24
-rw-r--r--id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/stork/STORKResponseProcessor.java32
-rw-r--r--id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/stork/VelocityProvider.java2
-rw-r--r--id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/protocols/stork2/AttributeCollector.java10
-rw-r--r--id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/protocols/stork2/ConsentEvaluator.java4
-rw-r--r--id/server/stork2-commons/.svn/all-wcprops17
-rw-r--r--id/server/stork2-commons/.svn/dir-prop-base10
-rw-r--r--id/server/stork2-commons/.svn/entries99
-rw-r--r--id/server/stork2-commons/.svn/text-base/Releases.svn-base73
-rw-r--r--id/server/stork2-commons/.svn/text-base/pom.xml.svn-base213
-rw-r--r--id/server/stork2-commons/Releases73
-rw-r--r--id/server/stork2-commons/pom.xml213
-rw-r--r--id/server/stork2-commons/src/.svn/all-wcprops5
-rw-r--r--id/server/stork2-commons/src/.svn/entries34
-rw-r--r--id/server/stork2-commons/src/main/.svn/all-wcprops5
-rw-r--r--id/server/stork2-commons/src/main/.svn/entries37
-rw-r--r--id/server/stork2-commons/src/main/config/.svn/all-wcprops5
-rw-r--r--id/server/stork2-commons/src/main/config/.svn/entries31
-rw-r--r--id/server/stork2-commons/src/main/config/embedded/.svn/all-wcprops11
-rw-r--r--id/server/stork2-commons/src/main/config/embedded/.svn/entries62
-rw-r--r--id/server/stork2-commons/src/main/config/embedded/.svn/text-base/pepsUtil.properties.svn-base269
-rw-r--r--id/server/stork2-commons/src/main/config/embedded/pepsUtil.properties269
-rw-r--r--id/server/stork2-commons/src/main/java/.svn/all-wcprops5
-rw-r--r--id/server/stork2-commons/src/main/java/.svn/entries31
-rw-r--r--id/server/stork2-commons/src/main/java/eu/.svn/all-wcprops5
-rw-r--r--id/server/stork2-commons/src/main/java/eu/.svn/entries31
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/.svn/all-wcprops5
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/.svn/entries31
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/.svn/all-wcprops5
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/.svn/entries34
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/.svn/all-wcprops5
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/.svn/entries34
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/all-wcprops191
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/entries1085
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeConstants.java.svn-base72
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeName.java.svn-base74
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeProvider.java.svn-base123
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeProvidersMap.java.svn-base96
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeSource.java.svn-base188
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeUtil.java.svn-base231
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/CitizenConsent.java.svn-base123
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/Country.java.svn-base95
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/CountryCodes.java.svn-base79
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/DateUtil.java.svn-base169
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IAttributeListProcessor.java.svn-base148
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IAttributeProvidersMap.java.svn-base82
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IPersonalAttributeList.java.svn-base194
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IStorkLogger.java.svn-base239
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IStorkSession.java.svn-base85
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/Linker.java.svn-base316
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PEPSErrors.java.svn-base392
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PEPSParameters.java.svn-base625
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PEPSUtil.java.svn-base391
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PEPSValues.java.svn-base342
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PersonalAttribute.java.svn-base348
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PersonalAttributeList.java.svn-base396
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKAttrQueryRequest.java.svn-base447
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKAttrQueryResponse.java.svn-base388
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKAuthnRequest.java.svn-base495
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKAuthnResponse.java.svn-base383
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKLogoutRequest.java.svn-base197
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKLogoutResponse.java.svn-base250
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKStatusCode.java.svn-base68
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKSubStatusCode.java.svn-base71
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/package-info.java.svn-base9
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeConstants.java72
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeName.java74
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeProvider.java123
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeProvidersMap.java96
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeSource.java188
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeUtil.java231
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/CitizenConsent.java123
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/Country.java95
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/CountryCodes.java79
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/DateUtil.java169
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IAttributeListProcessor.java148
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IAttributeProvidersMap.java82
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IPersonalAttributeList.java194
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IStorkLogger.java239
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IStorkSession.java85
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/Linker.java316
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PEPSErrors.java392
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PEPSParameters.java625
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PEPSUtil.java391
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PEPSValues.java342
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PersonalAttribute.java348
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PersonalAttributeList.java397
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKAttrQueryRequest.java447
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKAttrQueryResponse.java392
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKAuthnRequest.java495
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKAuthnResponse.java387
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKLogoutRequest.java197
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKLogoutResponse.java250
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKStatusCode.java68
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKSubStatusCode.java71
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/all-wcprops53
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/entries300
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/AbstractPEPSException.java.svn-base173
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/CPEPSException.java.svn-base143
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/InternalErrorPEPSException.java.svn-base74
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/InvalidParameterPEPSException.java.svn-base54
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/InvalidSessionPEPSException.java.svn-base46
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/SecurityPEPSException.java.svn-base67
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/StorkPEPSException.java.svn-base53
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/package-info.java.svn-base7
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/AbstractPEPSException.java173
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/CPEPSException.java143
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/InternalErrorPEPSException.java74
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/InvalidParameterPEPSException.java54
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/InvalidSessionPEPSException.java46
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/SecurityPEPSException.java67
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/StorkPEPSException.java53
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/package-info.java7
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/package-info.java9
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/all-wcprops41
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/entries232
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/IAUService.java.svn-base215
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/ICheckAttributeValue.java.svn-base37
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/IDeriveAttribute.java.svn-base40
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/INormaliseValue.java.svn-base35
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/ITranslatorService.java.svn-base100
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/package-info.java.svn-base8
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/IAUService.java215
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/ICheckAttributeValue.java37
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/IDeriveAttribute.java40
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/INormaliseValue.java35
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/ITranslatorService.java100
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/package-info.java8
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/.svn/all-wcprops5
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/.svn/entries31
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/all-wcprops125
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/entries708
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/AcTitleType.java.svn-base89
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/AttributeStatusType.java.svn-base61
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/CanonicalAddressType.java.svn-base264
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/Habilitation.java.svn-base89
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/HabilitationType.java.svn-base89
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/HasAccountInBankType.java.svn-base89
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/HasDegreeType.java.svn-base174
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsAcademicStaffType.java.svn-base145
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsAdminStaffType.java.svn-base89
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsCourseCoordinatorType.java.svn-base89
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsHCPType.java.svn-base145
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsHealthCareProfessionalType.java.svn-base145
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsStudentType.java.svn-base146
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsTeacherOfType.java.svn-base145
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/MandateContentType.java.svn-base233
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/MandateType.java.svn-base125
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/ObjectFactory.java.svn-base433
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/RepresentationPersonType.java.svn-base289
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/RequestedAttributeType.java.svn-base212
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/package-info.java.svn-base9
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/AcTitleType.java89
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/AttributeStatusType.java61
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/CanonicalAddressType.java264
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/Habilitation.java89
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/HabilitationType.java89
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/HasAccountInBankType.java89
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/HasDegreeType.java174
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsAcademicStaffType.java145
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsAdminStaffType.java89
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsCourseCoordinatorType.java89
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsHCPType.java145
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsHealthCareProfessionalType.java145
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsStudentType.java146
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsTeacherOfType.java145
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/MandateContentType.java233
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/MandateType.java125
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/ObjectFactory.java433
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/RepresentationPersonType.java289
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/RequestedAttributeType.java212
-rw-r--r--id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/package-info.java9
-rw-r--r--id/server/stork2-commons/src/main/resources/.svn/all-wcprops17
-rw-r--r--id/server/stork2-commons/src/main/resources/.svn/entries96
-rw-r--r--id/server/stork2-commons/src/main/resources/.svn/text-base/StorkcomplexAttributes.xsd.svn-base305
-rw-r--r--id/server/stork2-commons/src/main/resources/.svn/text-base/log4j.xml.svn-base19
-rw-r--r--id/server/stork2-commons/src/main/resources/StorkcomplexAttributes.xsd305
-rw-r--r--id/server/stork2-commons/src/main/resources/log4j.xml19
-rw-r--r--id/server/stork2-commons/src/test/.svn/all-wcprops5
-rw-r--r--id/server/stork2-commons/src/test/.svn/entries34
-rw-r--r--id/server/stork2-commons/src/test/java/.svn/all-wcprops5
-rw-r--r--id/server/stork2-commons/src/test/java/.svn/entries31
-rw-r--r--id/server/stork2-commons/src/test/java/eu/.svn/all-wcprops5
-rw-r--r--id/server/stork2-commons/src/test/java/eu/.svn/entries31
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/.svn/all-wcprops5
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/.svn/entries31
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/.svn/all-wcprops5
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/.svn/entries31
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/all-wcprops59
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/entries334
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/AttributeProvidersMapTestCase.java.svn-base134
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/AttributeSourceTestCase.java.svn-base88
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/AttributeUtilTestCase.java.svn-base537
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/ComplexAttributesMarshalling.java.svn-base187
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/DateUtilTestCase.java.svn-base294
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/PEPSUtilTestCase.java.svn-base553
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/PersonalAttributeListTestCase.java.svn-base747
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/PersonalAttributeTestCase.java.svn-base182
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/package-info.java.svn-base5
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/AttributeProvidersMapTestCase.java134
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/AttributeSourceTestCase.java88
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/AttributeUtilTestCase.java537
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/ComplexAttributesMarshalling.java187
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/DateUtilTestCase.java294
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/PEPSUtilTestCase.java553
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/PersonalAttributeListTestCase.java747
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/PersonalAttributeTestCase.java182
-rw-r--r--id/server/stork2-commons/src/test/java/eu/stork/peps/tests/package-info.java5
-rw-r--r--id/server/stork2-commons/src/test/resources/.svn/all-wcprops11
-rw-r--r--id/server/stork2-commons/src/test/resources/.svn/entries62
-rw-r--r--id/server/stork2-commons/src/test/resources/.svn/text-base/log4j.xml.svn-base19
-rw-r--r--id/server/stork2-commons/src/test/resources/log4j.xml19
-rw-r--r--id/server/stork2-saml-engine/pom.xml (renamed from id/server/SamlEngine-VIDP/pom.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/META-INF/MANIFEST.MF (renamed from id/server/SamlEngine-VIDP/src/main/java/META-INF/MANIFEST.MF)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/SAMLEngine.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/SAMLEngine.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/SAMLEngineUtils.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/SAMLEngineUtils.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/STORKSAMLEngine.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/STORKSAMLEngine.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/X509PrincipalUtil.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/X509PrincipalUtil.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/AuthenticationAttributes.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/AuthenticationAttributes.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/CitizenCountryCode.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/CitizenCountryCode.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/CustomAttributeQuery.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/CustomAttributeQuery.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/CustomRequestAbstractType.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/CustomRequestAbstractType.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/EIDCrossBorderShare.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/EIDCrossBorderShare.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/EIDCrossSectorShare.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/EIDCrossSectorShare.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/EIDSectorShare.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/EIDSectorShare.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/QAAAttribute.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/QAAAttribute.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/RequestedAttribute.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/RequestedAttribute.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/RequestedAttributes.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/RequestedAttributes.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SAMLCore.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SAMLCore.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SAMLEngineSignI.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SAMLEngineSignI.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPApplication.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPApplication.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPCountry.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPCountry.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPID.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPID.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPInformation.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPInformation.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPInstitution.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPInstitution.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPSector.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPSector.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/STORKSAMLCore.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/STORKSAMLCore.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/VIDPAuthenticationAttributes.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/VIDPAuthenticationAttributes.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesBuilder.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesBuilder.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesImpl.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesImpl.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesMarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesMarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesUnmarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesUnmarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeBuilder.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeBuilder.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeImpl.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeImpl.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeMarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeMarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeUnmarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeUnmarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryBuilder.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryBuilder.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryImpl.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryImpl.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryMarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryMarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryUnmarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryUnmarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareBuilder.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareBuilder.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareImpl.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareImpl.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareMarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareMarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareUnmarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareUnmarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareBuilder.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareBuilder.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareImpl.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareImpl.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareMarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareMarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareUnmarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareUnmarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareBuilder.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareBuilder.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareImpl.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareImpl.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareMarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareMarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareUnmarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareUnmarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeBuilder.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeBuilder.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeImpl.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeImpl.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeMarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeMarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeUnmarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeUnmarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeBuilder.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeBuilder.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeImpl.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeImpl.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeMarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeMarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeUnmarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeUnmarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesBuilder.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesBuilder.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesImpl.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesImpl.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesMarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesMarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesUnmarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesUnmarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationBuilder.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationBuilder.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationImpl.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationImpl.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationMarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationMarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationUnmarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationUnmarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryBuilder.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryBuilder.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryImpl.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryImpl.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryMarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryMarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryUnmarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryUnmarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDBuilder.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDBuilder.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDImpl.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDImpl.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDMarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDMarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDUnmarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDUnmarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationBuilder.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationBuilder.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationImpl.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationImpl.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationMarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationMarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationUnmarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationUnmarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionBuilder.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionBuilder.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionImpl.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionImpl.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionMarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionMarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionUnmarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionUnmarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorBuilder.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorBuilder.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorImpl.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorImpl.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorMarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorMarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorUnmarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorUnmarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignHW.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SignHW.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignModuleFactory.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SignModuleFactory.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignP12.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SignP12.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignSW.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SignSW.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesBuilder.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesBuilder.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesImpl.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesImpl.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesMarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesMarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesUnmarshaller.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesUnmarshaller.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/package-info.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/package-info.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/package-info.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/package-info.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/validator/CustomAttributeQueryValidator.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/validator/CustomAttributeQueryValidator.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/validator/ExtensionsSchemaValidator.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/validator/ExtensionsSchemaValidator.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/validator/MultipleAssertionResponseValidator.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/validator/MultipleAssertionResponseValidator.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/validator/QAAAttributeSchemaValidator.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/validator/QAAAttributeSchemaValidator.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/validator/package-info.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/validator/package-info.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/package-info.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/package-info.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/ConfigurationCreator.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/ConfigurationCreator.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/ConfigurationEngine.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/ConfigurationEngine.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/ConfigurationReader.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/ConfigurationReader.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/ConfigurationSingleton.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/ConfigurationSingleton.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/InstanceEngine.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/InstanceEngine.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/package-info.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/package-info.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/exceptions/SAMLEngineException.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/exceptions/SAMLEngineException.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/exceptions/STORKSAMLEngineException.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/exceptions/STORKSAMLEngineException.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/exceptions/STORKSAMLEngineRuntimeException.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/exceptions/STORKSAMLEngineRuntimeException.java)0
-rw-r--r--id/server/stork2-saml-engine/src/main/java/eu/stork/peps/exceptions/package-info.java (renamed from id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/exceptions/package-info.java)0
-rw-r--r--id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/SSETestUtils.java (renamed from id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/SSETestUtils.java)0
-rw-r--r--id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/SimpleBaseTest.java (renamed from id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/SimpleBaseTest.java)0
-rw-r--r--id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkAttrQueryRequestTest.java (renamed from id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkAttrQueryRequestTest.java)0
-rw-r--r--id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkAttrQueryResponseTest.java (renamed from id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkAttrQueryResponseTest.java)0
-rw-r--r--id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkAuthRequestTest.java (renamed from id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkAuthRequestTest.java)0
-rw-r--r--id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkLogoutRequestTest.java (renamed from id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkLogoutRequestTest.java)0
-rw-r--r--id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkLogoutResponseTest.java (renamed from id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkLogoutResponseTest.java)0
-rw-r--r--id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkNewResponseTest.java (renamed from id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkNewResponseTest.java)0
-rw-r--r--id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkResponseTest.java (renamed from id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkResponseTest.java)0
-rw-r--r--id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/package-info.java (renamed from id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/package-info.java)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/SamlEngine.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/SamlEngine.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/SignModule_Conf0.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/SignModule_Conf0.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/SignModule_Conf1.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/SignModule_Conf1.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/SignModule_Conf2.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/SignModule_Conf2.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/SignModule_Conf3.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/SignModule_Conf3.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/SignModule_P11.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/SignModule_P11.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/StorkSamlEngine_Conf0.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/StorkSamlEngine_Conf0.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/StorkSamlEngine_Conf1.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/StorkSamlEngine_Conf1.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/StorkSamlEngine_Conf2.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/StorkSamlEngine_Conf2.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/StorkSamlEngine_Conf3.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/StorkSamlEngine_Conf3.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequest.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequest.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequestSdoc.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequestSdoc.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequestTagDelete.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequestTagDelete.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryResponse.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryResponse.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequest.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequest.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDelete.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDelete.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDeleteEncoded.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDeleteEncoded.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/logback-test.xml (renamed from id/server/SamlEngine-VIDP/src/test/resources/logback-test.xml)0
-rw-r--r--id/server/stork2-saml-engine/src/test/resources/p11Conf.cfg (renamed from id/server/SamlEngine-VIDP/src/test/resources/p11Conf.cfg)0
486 files changed, 33792 insertions, 933 deletions
diff --git a/id/server/SamlEngine-VIDP/target/SamlEngine-1.4.0-sources.jar b/id/server/SamlEngine-VIDP/target/SamlEngine-1.4.0-sources.jar
deleted file mode 100644
index 447c8d8f8..000000000
--- a/id/server/SamlEngine-VIDP/target/SamlEngine-1.4.0-sources.jar
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/SAMLEngine.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/SAMLEngine.class
deleted file mode 100644
index d64cbf35a..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/SAMLEngine.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/SAMLEngineUtils.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/SAMLEngineUtils.class
deleted file mode 100644
index cad1781ba..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/SAMLEngineUtils.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/STORKSAMLEngine.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/STORKSAMLEngine.class
deleted file mode 100644
index de028b751..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/STORKSAMLEngine.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/X509PrincipalUtil.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/X509PrincipalUtil.class
deleted file mode 100644
index 6209f6eb5..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/X509PrincipalUtil.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/AuthenticationAttributes.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/AuthenticationAttributes.class
deleted file mode 100644
index f9c79ca30..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/AuthenticationAttributes.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/CitizenCountryCode.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/CitizenCountryCode.class
deleted file mode 100644
index 7da2c0e42..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/CitizenCountryCode.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/CustomAttributeQuery.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/CustomAttributeQuery.class
deleted file mode 100644
index b12c0987d..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/CustomAttributeQuery.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/CustomRequestAbstractType.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/CustomRequestAbstractType.class
deleted file mode 100644
index f6d4055fe..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/CustomRequestAbstractType.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/EIDCrossBorderShare.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/EIDCrossBorderShare.class
deleted file mode 100644
index 082d6024f..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/EIDCrossBorderShare.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/EIDCrossSectorShare.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/EIDCrossSectorShare.class
deleted file mode 100644
index 72f9d84a6..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/EIDCrossSectorShare.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/EIDSectorShare.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/EIDSectorShare.class
deleted file mode 100644
index 57778783e..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/EIDSectorShare.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/QAAAttribute.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/QAAAttribute.class
deleted file mode 100644
index ebe9ed6dd..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/QAAAttribute.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/RequestedAttribute.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/RequestedAttribute.class
deleted file mode 100644
index 2a485d3b5..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/RequestedAttribute.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/RequestedAttributes.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/RequestedAttributes.class
deleted file mode 100644
index 0c2fc75ef..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/RequestedAttributes.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SAMLCore.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SAMLCore.class
deleted file mode 100644
index 25ac4c69e..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SAMLCore.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SAMLEngineSignI.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SAMLEngineSignI.class
deleted file mode 100644
index a6c30d388..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SAMLEngineSignI.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPApplication.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPApplication.class
deleted file mode 100644
index 8f8939d20..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPApplication.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPCountry.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPCountry.class
deleted file mode 100644
index 00982e2a9..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPCountry.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPID.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPID.class
deleted file mode 100644
index 3d686cfc2..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPID.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPInformation.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPInformation.class
deleted file mode 100644
index 493bdb2de..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPInformation.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPInstitution.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPInstitution.class
deleted file mode 100644
index caf16dc7d..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPInstitution.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPSector.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPSector.class
deleted file mode 100644
index bcaef2a96..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/SPSector.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/STORKSAMLCore.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/STORKSAMLCore.class
deleted file mode 100644
index 3de661743..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/STORKSAMLCore.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/VIDPAuthenticationAttributes.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/VIDPAuthenticationAttributes.class
deleted file mode 100644
index 8f898214e..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/VIDPAuthenticationAttributes.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesBuilder.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesBuilder.class
deleted file mode 100644
index 38f3bc5b6..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesBuilder.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesImpl.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesImpl.class
deleted file mode 100644
index c52b2e7db..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesImpl.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesMarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesMarshaller.class
deleted file mode 100644
index 8efebb5e6..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesMarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesUnmarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesUnmarshaller.class
deleted file mode 100644
index 92c532e6e..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesUnmarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeBuilder.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeBuilder.class
deleted file mode 100644
index 79b677b07..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeBuilder.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeImpl.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeImpl.class
deleted file mode 100644
index 345fa960b..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeImpl.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeMarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeMarshaller.class
deleted file mode 100644
index 8e36a67ac..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeMarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeUnmarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeUnmarshaller.class
deleted file mode 100644
index 04cb2a479..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeUnmarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryBuilder.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryBuilder.class
deleted file mode 100644
index fa1c1d3da..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryBuilder.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryImpl.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryImpl.class
deleted file mode 100644
index cb5fbd326..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryImpl.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryMarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryMarshaller.class
deleted file mode 100644
index acffd5114..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryMarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryUnmarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryUnmarshaller.class
deleted file mode 100644
index 069e677c8..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryUnmarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareBuilder.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareBuilder.class
deleted file mode 100644
index 2e95d47c9..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareBuilder.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareImpl.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareImpl.class
deleted file mode 100644
index 2861c96fa..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareImpl.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareMarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareMarshaller.class
deleted file mode 100644
index 4a3efcf63..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareMarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareUnmarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareUnmarshaller.class
deleted file mode 100644
index 030b16a43..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareUnmarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareBuilder.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareBuilder.class
deleted file mode 100644
index 255c5fdb6..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareBuilder.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareImpl.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareImpl.class
deleted file mode 100644
index 01b48443b..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareImpl.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareMarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareMarshaller.class
deleted file mode 100644
index 94d8fc317..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareMarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareUnmarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareUnmarshaller.class
deleted file mode 100644
index f8faa5b80..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareUnmarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDSectorShareBuilder.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDSectorShareBuilder.class
deleted file mode 100644
index 3cef6c8c0..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDSectorShareBuilder.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDSectorShareImpl.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDSectorShareImpl.class
deleted file mode 100644
index 1a270f4e2..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDSectorShareImpl.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDSectorShareMarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDSectorShareMarshaller.class
deleted file mode 100644
index d13aee589..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDSectorShareMarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDSectorShareUnmarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDSectorShareUnmarshaller.class
deleted file mode 100644
index 2e3019255..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/EIDSectorShareUnmarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/QAAAttributeBuilder.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/QAAAttributeBuilder.class
deleted file mode 100644
index cac3037cf..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/QAAAttributeBuilder.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/QAAAttributeImpl.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/QAAAttributeImpl.class
deleted file mode 100644
index dd88db632..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/QAAAttributeImpl.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/QAAAttributeMarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/QAAAttributeMarshaller.class
deleted file mode 100644
index 7aef0f4fd..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/QAAAttributeMarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/QAAAttributeUnmarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/QAAAttributeUnmarshaller.class
deleted file mode 100644
index 013cb7e68..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/QAAAttributeUnmarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributeBuilder.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributeBuilder.class
deleted file mode 100644
index 9340a804b..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributeBuilder.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributeImpl.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributeImpl.class
deleted file mode 100644
index 6e47992f2..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributeImpl.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributeMarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributeMarshaller.class
deleted file mode 100644
index 783031d78..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributeMarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributeUnmarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributeUnmarshaller.class
deleted file mode 100644
index 06a34b622..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributeUnmarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributesBuilder.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributesBuilder.class
deleted file mode 100644
index ecb7104f6..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributesBuilder.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributesImpl.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributesImpl.class
deleted file mode 100644
index 7ae6d8f45..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributesImpl.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributesMarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributesMarshaller.class
deleted file mode 100644
index 2c878b0e7..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributesMarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributesUnmarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributesUnmarshaller.class
deleted file mode 100644
index cf03e83df..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/RequestedAttributesUnmarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPApplicationBuilder.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPApplicationBuilder.class
deleted file mode 100644
index a60f07621..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPApplicationBuilder.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPApplicationImpl.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPApplicationImpl.class
deleted file mode 100644
index cdf24dffc..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPApplicationImpl.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPApplicationMarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPApplicationMarshaller.class
deleted file mode 100644
index ce812be90..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPApplicationMarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPApplicationUnmarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPApplicationUnmarshaller.class
deleted file mode 100644
index ca335f0bf..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPApplicationUnmarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPCountryBuilder.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPCountryBuilder.class
deleted file mode 100644
index 2137135e4..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPCountryBuilder.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPCountryImpl.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPCountryImpl.class
deleted file mode 100644
index d8b4e1c3f..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPCountryImpl.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPCountryMarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPCountryMarshaller.class
deleted file mode 100644
index d1179ef11..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPCountryMarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPCountryUnmarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPCountryUnmarshaller.class
deleted file mode 100644
index 79b4fed37..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPCountryUnmarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPIDBuilder.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPIDBuilder.class
deleted file mode 100644
index 762681c9d..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPIDBuilder.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPIDImpl.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPIDImpl.class
deleted file mode 100644
index 98285837e..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPIDImpl.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPIDMarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPIDMarshaller.class
deleted file mode 100644
index 827f8de30..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPIDMarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPIDUnmarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPIDUnmarshaller.class
deleted file mode 100644
index 8f5f14fe2..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPIDUnmarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInformationBuilder.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInformationBuilder.class
deleted file mode 100644
index c3bd1f9b4..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInformationBuilder.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInformationImpl.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInformationImpl.class
deleted file mode 100644
index 9acde181f..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInformationImpl.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInformationMarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInformationMarshaller.class
deleted file mode 100644
index 09863dfee..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInformationMarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInformationUnmarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInformationUnmarshaller.class
deleted file mode 100644
index 0b6c4d39f..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInformationUnmarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInstitutionBuilder.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInstitutionBuilder.class
deleted file mode 100644
index 05515dd54..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInstitutionBuilder.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInstitutionImpl.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInstitutionImpl.class
deleted file mode 100644
index 0a9807fd0..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInstitutionImpl.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInstitutionMarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInstitutionMarshaller.class
deleted file mode 100644
index 230330a60..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInstitutionMarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInstitutionUnmarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInstitutionUnmarshaller.class
deleted file mode 100644
index d1897e4fd..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPInstitutionUnmarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPSectorBuilder.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPSectorBuilder.class
deleted file mode 100644
index e498256ae..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPSectorBuilder.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPSectorImpl.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPSectorImpl.class
deleted file mode 100644
index 58d18fe48..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPSectorImpl.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPSectorMarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPSectorMarshaller.class
deleted file mode 100644
index 097e76b80..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPSectorMarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPSectorUnmarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPSectorUnmarshaller.class
deleted file mode 100644
index 99a0c19ee..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SPSectorUnmarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SignHW.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SignHW.class
deleted file mode 100644
index dc7acbc35..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SignHW.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SignModuleFactory.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SignModuleFactory.class
deleted file mode 100644
index 96b8cf7c7..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SignModuleFactory.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SignP12.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SignP12.class
deleted file mode 100644
index ef11ce208..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SignP12.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SignSW.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SignSW.class
deleted file mode 100644
index 87726f6ac..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/SignSW.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesBuilder.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesBuilder.class
deleted file mode 100644
index 5c62d013b..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesBuilder.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesImpl.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesImpl.class
deleted file mode 100644
index 3749dbffe..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesImpl.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesMarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesMarshaller.class
deleted file mode 100644
index be892f684..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesMarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesUnmarshaller.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesUnmarshaller.class
deleted file mode 100644
index 850171df3..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesUnmarshaller.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/validator/CustomAttributeQueryValidator.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/validator/CustomAttributeQueryValidator.class
deleted file mode 100644
index 61f4e0b2f..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/validator/CustomAttributeQueryValidator.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/validator/ExtensionsSchemaValidator.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/validator/ExtensionsSchemaValidator.class
deleted file mode 100644
index b6db104c7..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/validator/ExtensionsSchemaValidator.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/validator/MultipleAssertionResponseValidator.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/validator/MultipleAssertionResponseValidator.class
deleted file mode 100644
index b31a1d586..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/validator/MultipleAssertionResponseValidator.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/validator/QAAAttributeSchemaValidator.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/validator/QAAAttributeSchemaValidator.class
deleted file mode 100644
index 2eda7b183..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/auth/engine/core/validator/QAAAttributeSchemaValidator.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/ConfigurationCreator.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/ConfigurationCreator.class
deleted file mode 100644
index 97944fb9c..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/ConfigurationCreator.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/ConfigurationEngine.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/ConfigurationEngine.class
deleted file mode 100644
index df1854e68..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/ConfigurationEngine.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/ConfigurationReader.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/ConfigurationReader.class
deleted file mode 100644
index c1edf063d..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/ConfigurationReader.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/ConfigurationSingleton.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/ConfigurationSingleton.class
deleted file mode 100644
index 15f565fc9..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/ConfigurationSingleton.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/InstanceEngine.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/InstanceEngine.class
deleted file mode 100644
index 10ebf1a10..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/configuration/InstanceEngine.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/exceptions/SAMLEngineException.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/exceptions/SAMLEngineException.class
deleted file mode 100644
index 1fc62d91c..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/exceptions/SAMLEngineException.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/exceptions/STORKSAMLEngineException.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/exceptions/STORKSAMLEngineException.class
deleted file mode 100644
index 7ff0077b6..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/exceptions/STORKSAMLEngineException.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/exceptions/STORKSAMLEngineRuntimeException.class b/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/exceptions/STORKSAMLEngineRuntimeException.class
deleted file mode 100644
index b19b665df..000000000
--- a/id/server/SamlEngine-VIDP/target/classes/eu/stork/peps/exceptions/STORKSAMLEngineRuntimeException.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/maven-archiver/pom.properties b/id/server/SamlEngine-VIDP/target/maven-archiver/pom.properties
deleted file mode 100644
index c3e05d54d..000000000
--- a/id/server/SamlEngine-VIDP/target/maven-archiver/pom.properties
+++ /dev/null
@@ -1,5 +0,0 @@
-#Generated by Maven
-#Mon Mar 17 17:10:39 CET 2014
-version=1.4.0
-groupId=eu.stork
-artifactId=SamlEngine
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/SamlEngine.xml b/id/server/SamlEngine-VIDP/target/test-classes/SamlEngine.xml
deleted file mode 100644
index 171e05f12..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/SamlEngine.xml
+++ /dev/null
@@ -1,67 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<instances>
-
- <!-- Configuration name -->
- <instance name="CONF0">
- <!-- Configurations parameters StorkSamlEngine -->
- <configuration name="SamlEngineConf">
- <parameter name="fileConfiguration" value="StorkSamlEngine_Conf0.xml" />
- </configuration>
-
- <!-- Settings module signature -->
- <configuration name="SignatureConf">
- <!-- Specific signature module -->
- <parameter name="class"
- value="eu.stork.peps.auth.engine.core.impl.SignSW" />
- <!-- Settings specific module -->
- <parameter name="fileConfiguration" value="SignModule_Conf0.xml" />
- </configuration>
- </instance>
-
- <!-- ******************** CONF1 ******************** -->
- <!-- Configuration name -->
- <instance name="CONF1">
- <!-- Configurations parameters StorkSamlEngine -->
- <configuration name="SamlEngineConf">
- <parameter name="fileConfiguration" value="StorkSamlEngine_Conf1.xml" />
- </configuration>
-
- <!-- Settings module signature -->
- <configuration name="SignatureConf">
- <!-- Specific signature module -->
- <parameter name="class"
- value="eu.stork.peps.auth.engine.core.impl.SignSW" />
- <!-- Settings specific module -->
- <parameter name="fileConfiguration" value="SignModule_Conf1.xml" />
- </configuration>
- </instance>
-
- <!-- ******************** CONF2 ******************** -->
-
- <instance name="CONF2">
- <configuration name="SamlEngineConf">
- <parameter name="fileConfiguration" value="StorkSamlEngine_Conf2.xml" />
- </configuration>
-
- <configuration name="SignatureConf">
- <parameter name="class"
- value="eu.stork.peps.auth.engine.core.impl.SignSW" />
- <parameter name="fileConfiguration" value="SignModule_Conf2.xml" />
- </configuration>
- </instance>
-
- <!-- ******************** CONF3 ******************** -->
-
- <instance name="CONF3">
- <configuration name="SamlEngineConf">
- <parameter name="fileConfiguration" value="StorkSamlEngine_Conf3.xml" />
- </configuration>
-
- <configuration name="SignatureConf">
- <parameter name="class"
- value="eu.stork.peps.auth.engine.core.impl.SignSW" />
- <parameter name="fileConfiguration" value="SignModule_Conf3.xml" />
- </configuration>
- </instance>
-
-</instances> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/SignModule_Conf0.xml b/id/server/SamlEngine-VIDP/target/test-classes/SignModule_Conf0.xml
deleted file mode 100644
index a9f2038b8..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/SignModule_Conf0.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
-
-<!-- properties>
- <comment>SWModule sign with JKS.</comment>
- <entry key="keystorePath">C:\opt\keystores\keyStoreCountry0.jks</entry>
- <entry key="keyStorePassword">local-demo</entry>
- <entry key="keyPassword">local-demo</entry>
- <entry key="issuer">CN=saml-demo-cert,OU=STORK2,O=Advania,L=Reykjavik,ST=Reykjavik,C=IS</entry>
- <entry key="serialNumber">524D4C6C</entry>
- <entry key="keystoreType">JKS</entry>
-</properties-->
-<properties>
- <comment>SWModule sign with JKS.</comment>
- <entry key="keystorePath">C:\opt\keystores\storkDemoKeysTest.jks</entry>
- <entry key="keyStorePassword">local-demo</entry>
- <entry key="keyPassword">local-demo</entry>
- <entry key="issuer">CN=local-demo, O=Indra, L=Madrid, ST=Spain, C=ES</entry>
- <entry key="serialNumber">4BA89DB2</entry>
- <entry key="keystoreType">JKS</entry>
-</properties> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/SignModule_Conf1.xml b/id/server/SamlEngine-VIDP/target/test-classes/SignModule_Conf1.xml
deleted file mode 100644
index e556a7331..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/SignModule_Conf1.xml
+++ /dev/null
@@ -1,12 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
-
-<properties>
- <comment>SWModule sign with JKS.</comment>
- <entry key="keystorePath">C:\opt\keystores\storkDemoKeysTest.jks</entry>
- <entry key="keyStorePassword">local-demo</entry>
- <entry key="keyPassword">local-demo</entry>
- <entry key="issuer">CN=local-demo, O=Indra, L=Madrid, ST=Spain, C=ES</entry>
- <entry key="serialNumber">4BA89DB2</entry>
- <entry key="keystoreType">JKS</entry>
-</properties> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/SignModule_Conf2.xml b/id/server/SamlEngine-VIDP/target/test-classes/SignModule_Conf2.xml
deleted file mode 100644
index 3da1e33df..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/SignModule_Conf2.xml
+++ /dev/null
@@ -1,12 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
-
-<properties>
- <comment>SWModule sign with JKS.</comment>
- <entry key="keystorePath">C:\opt\keystores\keyStoreCountry2.jks</entry>
- <entry key="keyStorePassword">local-demo</entry>
- <entry key="keyPassword">local-demo</entry>
- <entry key="issuer">CN=local-demo, O=Indra, L=Madrid, ST=Spain, C=ES</entry>
- <entry key="serialNumber">4BA89DB2</entry>
- <entry key="keystoreType">JKS</entry>
-</properties> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/SignModule_Conf3.xml b/id/server/SamlEngine-VIDP/target/test-classes/SignModule_Conf3.xml
deleted file mode 100644
index 4c14a1711..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/SignModule_Conf3.xml
+++ /dev/null
@@ -1,12 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
-
-<properties>
- <comment>SWModule sign with JKS.</comment>
- <entry key="keystorePath">C:\opt\keystores\keyStoreCountry3.jks</entry>
- <entry key="keyStorePassword">local-demo</entry>
- <entry key="keyPassword">local-demo</entry>
- <entry key="issuer">CN=local-demo, O=Indra, L=Madrid, ST=Spain, C=ES</entry>
- <entry key="serialNumber">4BA89DB2</entry>
- <entry key="keystoreType">JKS</entry>
-</properties> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/SignModule_P11.xml b/id/server/SamlEngine-VIDP/target/test-classes/SignModule_P11.xml
deleted file mode 100644
index c683d97c3..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/SignModule_P11.xml
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
-
-<properties>
- <comment>HWModule sign with interface PKCS11.</comment>
- <entry key="configurationFile">p11Config.cfg</entry>
- <entry key="keyPassword">*******</entry>
- <entry key="issuer">CN=XXXXXXXXX</entry>
- <entry key="serialNumber">xxxxxxxxxxxxxx</entry>
- <entry key="keystoreType">PKCS11</entry>
-</properties> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/StorkSamlEngine_Conf0.xml b/id/server/SamlEngine-VIDP/target/test-classes/StorkSamlEngine_Conf0.xml
deleted file mode 100644
index 8c3a94601..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/StorkSamlEngine_Conf0.xml
+++ /dev/null
@@ -1,87 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
-
-<properties>
- <comment>SAML constants for AuthnRequests and Responses.</comment>
-
- <!-- Types of consent obtained from the user for this authentication and
- data transfer. Allow values: 'unspecified'. -->
- <entry key="consentAuthnRequest">unspecified</entry>
-
- <!-- Allow values: 'obtained', 'prior', 'current-implicit', 'current-explicit',
- 'unspecified'. -->
- <entry key="consentAuthnResponse">obtained</entry>
-
- <!--URI representing the classification of the identifier Allow values:
- 'entity'. -->
- <entry key="formatEntity">entity</entry>
-
- <!--Only HTTP-POST binding is only supported for inter PEPS -->
- <!--The SOAP binding is only supported for direct communication between
- SP-MW and VIdP -->
- <entry key="protocolBinding">HTTP-POST</entry>
-
-
-
-
- <!--URI representing the classification of the identifier Allow values:
- 'entity'. <entry key="eIDSectorShare">true</entry> <entry key="eIDCrossSectorShare">true</entry>
- <entry key="eIDCrossBorderShare">true</entry> -->
-
-
-
- <!-- A friendly name for the attribute that can be displayed to a user -->
- <entry key="friendlyName">false</entry>
-
- <!-- A friendly name for the attribute that can be displayed to a user -->
- <entry key="isRequired">true</entry>
-
- <!--PEPS in the Service Provider's country -->
- <entry key="requester">http://S-PEPS.gov.xx</entry>
-
- <!--PEPS in the citizen's origin country -->
- <entry key="responder">http://C-PEPS.gov.xx</entry>
-
- <!--Subject cannot be confirmed on or after this seconds time (positive
- number) -->
- <entry key="timeNotOnOrAfter">300</entry>
-
- <!--Validation IP of the response -->
- <entry key="ipAddrValidation">false</entry>
-
-
- <!--Subject Attribute Definitions -->
- <entry key="eIdentifier">http://www.stork.gov.eu/1.0/eIdentifier</entry>
- <entry key="givenName">http://www.stork.gov.eu/1.0/givenName</entry>
- <entry key="surname">http://www.stork.gov.eu/1.0/surname</entry>
- <entry key="inheritedFamilyName">http://www.stork.gov.eu/1.0/inheritedFamilyName</entry>
- <entry key="adoptedFamilyName">http://www.stork.gov.eu/1.0/adoptedFamilyName</entry>
- <entry key="gender">http://www.stork.gov.eu/1.0/gender</entry>
- <entry key="dateOfBirth">http://www.stork.gov.eu/1.0/dateOfBirth</entry>
- <entry key="countryCodeOfBirth">http://www.stork.gov.eu/1.0/countryCodeOfBirth</entry>
- <entry key="nationalityCode">http://www.stork.gov.eu/1.0/nationalityCode</entry>
- <entry key="maritalStatus">http://www.stork.gov.eu/1.0/maritalStatus</entry>
- <entry key="residenceAddress">http://www.stork.gov.eu/1.0/residenceAddress</entry>
- <entry key="eMail">http://www.stork.gov.eu/1.0/eMail</entry>
- <entry key="academicTitle">http://www.stork.gov.eu/1.0/academicTitle</entry>
- <entry key="pseudonym">http://www.stork.gov.eu/1.0/pseudonym</entry>
- <entry key="age">http://www.stork.gov.eu/1.0/age</entry>
- <entry key="isAgeOver">http://www.stork.gov.eu/1.0/isAgeOver</entry>
-
- <entry key="textResidenceAddress">http://www.stork.gov.eu/1.0/textResidenceAddress</entry>
- <entry key="canonicalResidenceAddress">http://www.stork.gov.eu/1.0/canonicalResidenceAddress</entry>
-
- <entry key="title">http://www.stork.gov.eu/1.0/title</entry>
- <entry key="residencePermit">http://www.stork.gov.eu/1.0/residencePermit</entry>
-
- <entry key="signedDoc">http://www.stork.gov.eu/1.0/signedDoc</entry>
- <entry key="citizen509Certificate">http://www.stork.gov.eu/1.0/citizen509Certificate</entry>
-
- <entry key="newAttribute1">http://www.stork.gov.eu/1.0/newAttribute1</entry>
- <entry key="newAttribute2">http://www.stork.gov.eu/1.0/newAttribute2</entry>
- <entry key="hasDegree">http://www.stork.gov.eu/1.0/hasDegree</entry>
- <entry key="mandateContent">http://www.stork.gov.eu/1.0/mandateContent</entry>
-
- <entry key="docRequest">http://www.stork.gov.eu/1.0/docRequest</entry>
-
-</properties> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/StorkSamlEngine_Conf1.xml b/id/server/SamlEngine-VIDP/target/test-classes/StorkSamlEngine_Conf1.xml
deleted file mode 100644
index ad04cc3df..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/StorkSamlEngine_Conf1.xml
+++ /dev/null
@@ -1,85 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
-
-<properties>
- <comment>SAML constants for AuthnRequests and Responses.</comment>
-
- <!-- Types of consent obtained from the user for this authentication and
- data transfer. Allow values: 'unspecified'. -->
- <entry key="consentAuthnRequest">unspecified</entry>
-
- <!-- Allow values: 'obtained', 'prior', 'current-implicit', 'current-explicit',
- 'unspecified'. -->
- <entry key="consentAuthnResponse">obtained</entry>
-
- <!--URI representing the classification of the identifier Allow values:
- 'entity'. -->
- <entry key="formatEntity">entity</entry>
-
- <!--Only HTTP-POST binding is only supported for inter PEPS -->
- <!--The SOAP binding is only supported for direct communication between
- SP-MW and VIdP -->
- <entry key="protocolBinding">HTTP-POST</entry>
-
-
-
-
- <!--URI representing the classification of the identifier Allow values:
- 'entity'. <entry key="eIDSectorShare">true</entry> <entry key="eIDCrossSectorShare">true</entry>
- <entry key="eIDCrossBorderShare">true</entry> -->
-
-
-
- <!-- A friendly name for the attribute that can be displayed to a user -->
- <entry key="friendlyName">false</entry>
-
- <!-- A friendly name for the attribute that can be displayed to a user -->
- <entry key="isRequired">true</entry>
-
- <!--PEPS in the Service Provider's country -->
- <entry key="requester">http://S-PEPS.gov.xx</entry>
-
- <!--PEPS in the citizen's origin country -->
- <entry key="responder">http://C-PEPS.gov.xx</entry>
-
- <!--Subject cannot be confirmed on or after this seconds time (positive
- number) -->
- <entry key="timeNotOnOrAfter">300</entry>
-
- <!--Validation IP of the response -->
- <entry key="ipAddrValidation">false</entry>
-
-
- <!--Subject Attribute Definitions -->
- <entry key="eIdentifier">http://www.stork.gov.eu/1.0/eIdentifier</entry>
- <entry key="givenName">http://www.stork.gov.eu/1.0/givenName</entry>
- <entry key="surname">http://www.stork.gov.eu/1.0/surname</entry>
- <entry key="inheritedFamilyName">http://www.stork.gov.eu/1.0/inheritedFamilyName</entry>
- <entry key="adoptedFamilyName">http://www.stork.gov.eu/1.0/adoptedFamilyName</entry>
- <entry key="gender">http://www.stork.gov.eu/1.0/gender</entry>
- <entry key="dateOfBirth">http://www.stork.gov.eu/1.0/dateOfBirth</entry>
- <entry key="countryCodeOfBirth">http://www.stork.gov.eu/1.0/countryCodeOfBirth</entry>
- <entry key="nationalityCode">http://www.stork.gov.eu/1.0/nationalityCode</entry>
- <entry key="maritalStatus">http://www.stork.gov.eu/1.0/maritalStatus</entry>
- <entry key="residenceAddress">http://www.stork.gov.eu/1.0/residenceAddress</entry>
- <entry key="eMail">http://www.stork.gov.eu/1.0/eMail</entry>
- <entry key="academicTitle">http://www.stork.gov.eu/1.0/academicTitle</entry>
- <entry key="pseudonym">http://www.stork.gov.eu/1.0/pseudonym</entry>
- <entry key="age">http://www.stork.gov.eu/1.0/age</entry>
- <entry key="isAgeOver">http://www.stork.gov.eu/1.0/isAgeOver</entry>
-
- <entry key="textResidenceAddress">http://www.stork.gov.eu/1.0/textResidenceAddress</entry>
- <entry key="canonicalResidenceAddress">http://www.stork.gov.eu/1.0/canonicalResidenceAddress</entry>
-
- <entry key="title">http://www.stork.gov.eu/1.0/title</entry>
- <entry key="residencePermit">http://www.stork.gov.eu/1.0/residencePermit</entry>
-
- <entry key="signedDoc">http://www.stork.gov.eu/1.0/signedDoc</entry>
- <entry key="citizen509Certificate">http://www.stork.gov.eu/1.0/citizen509Certificate</entry>
-
- <entry key="newAttribute1">http://www.stork.gov.eu/1.0/newAttribute1</entry>
- <entry key="newAttribute2">http://www.stork.gov.eu/1.0/newAttribute2</entry>
- <entry key="hasDegree">http://www.stork.gov.eu/1.0/hasDegree</entry>
- <entry key="mandateContent">http://www.stork.gov.eu/1.0/mandateContent</entry>
-
-</properties> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/StorkSamlEngine_Conf2.xml b/id/server/SamlEngine-VIDP/target/test-classes/StorkSamlEngine_Conf2.xml
deleted file mode 100644
index fd1db92ac..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/StorkSamlEngine_Conf2.xml
+++ /dev/null
@@ -1,60 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
-
-<properties>
- <comment>SAML constants for AuthnRequests and Responses.</comment>
-
- <!-- Types of consent obtained from the user for this authentication and
- data transfer. Allow values: 'unspecified'. -->
- <entry key="consentAuthnRequest">unspecified</entry>
- <!-- Allow values: 'obtained', 'prior', 'curent-implicit', 'curent-explicit',
- 'unspecified'. -->
- <entry key="consentAuthnResponse">obtained</entry>
-
- <!--URI representing the classification of the identifier Allow values:
- 'entity'. -->
- <entry key="formatEntity">entity</entry>
-
- <!--Only HTTP-POST binding is only supported for inter PEPS -->
- <!--The SOAP binding is only supported for direct communication between
- SP-MW and VIdP -->
- <entry key="protocolBinding">HTTP-POST</entry>
-
- <entry key="eIDSectorShare">false</entry>
- <entry key="eIDCrossSectorShare">false</entry>
- <entry key="eIDCrossBorderShare">false</entry>
-
- <!--PEPS in the Service Provider's country -->
- <entry key="requester">http://S-PEPS.gov.xx</entry>
-
- <!--PEPS in the citizen's origin country -->
- <entry key="responder">http://C-PEPS.gov.xx</entry>
-
- <!--Subject cannot be confirmed on or after this seconds time -->
- <entry key="timeNotOnOrAfter">300</entry>
-
- <!--Validation IP of the response -->
- <entry key="ipAddrValidation">false</entry>
-
- <!-- A friendly name for the attribute that can be displayed to a user -->
- <entry key="isRequired">false</entry>
-
-
- <!--Subject Attribute Definitions -->
- <entry key="eIdentifier">http://www.stork.gov.eu/1.0/eIdentifier</entry>
- <entry key="givenName">http://www.stork.gov.eu/1.0/givenName</entry>
- <entry key="surname">http://www.stork.gov.eu/1.0/surname</entry>
- <entry key="inheritedFamilyName">http://www.stork.gov.eu/1.0/inheritedFamilyName</entry>
- <entry key="adoptedFamilyName">http://www.stork.gov.eu/1.0/adoptedFamilyName</entry>
- <entry key="gender">http://www.stork.gov.eu/1.0/gender</entry>
- <entry key="dateOfBirth">http://www.stork.gov.eu/1.0/dateOfBirth</entry>
- <entry key="countryCodeOfBirth">http://www.stork.gov.eu/1.0/countryCodeOfBirth</entry>
- <entry key="nationalityCode">http://www.stork.gov.eu/1.0/nationalityCode</entry>
- <entry key="maritalStatus">http://www.stork.gov.eu/1.0/maritalStatus</entry>
- <entry key="residenceAddress">http://www.stork.gov.eu/1.0/residenceAddress</entry>
- <entry key="eMail">http://www.stork.gov.eu/1.0/eMail</entry>
- <entry key="academicTitle">http://www.stork.gov.eu/1.0/academicTitle</entry>
- <entry key="pseudonym">http://www.stork.gov.eu/1.0/pseudonym</entry>
- <entry key="age">http://www.stork.gov.eu/1.0/age</entry>
- <entry key="isAgeOver">http://www.stork.gov.eu/1.0/isAgeOver</entry>
-</properties> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/StorkSamlEngine_Conf3.xml b/id/server/SamlEngine-VIDP/target/test-classes/StorkSamlEngine_Conf3.xml
deleted file mode 100644
index bea40d274..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/StorkSamlEngine_Conf3.xml
+++ /dev/null
@@ -1,57 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
-
-<properties>
- <comment>SAML constants for AuthnRequests and Responses.</comment>
-
- <!-- Types of consent obtained from the user for this authentication and
- data transfer. Allow values: 'unspecified'. -->
- <entry key="consentAuthnRequest">unspecified</entry>
- <!-- Allow values: 'obtained', 'prior', 'curent-implicit', 'curent-explicit',
- 'unspecified'. -->
- <entry key="consentAuthnResponse">obtained</entry>
-
- <!--URI representing the classification of the identifier Allow values:
- 'entity'. -->
- <entry key="formatEntity">entity</entry>
-
- <!--Only HTTP-POST binding is only supported for inter PEPS -->
- <!--The SOAP binding is only supported for direct communication between
- SP-MW and VIdP -->
- <entry key="protocolBinding">HTTP-POST</entry>
-
- <entry key="eIDSectorShare">false</entry>
- <entry key="eIDCrossSectorShare">false</entry>
- <entry key="eIDCrossBorderShare">false</entry>
-
- <!--PEPS in the Service Provider's country -->
- <entry key="requester">http://S-PEPS.gov.xx</entry>
-
- <!--PEPS in the citizen's origin country -->
- <entry key="responder">http://C-PEPS.gov.xx</entry>
-
- <!--Subject cannot be confirmed on or after this seconds time -->
- <entry key="timeNotOnOrAfter">300</entry>
-
- <!--Validation IP of the response -->
- <entry key="ipAddrValidation">false</entry>
-
- <!--Subject Attribute Definitions -->
- <entry key="eIdentifier">http://www.stork.gov.eu/1.0/eIdentifier</entry>
- <entry key="givenName">http://www.stork.gov.eu/1.0/givenName</entry>
- <entry key="surname">http://www.stork.gov.eu/1.0/surname</entry>
- <entry key="inheritedFamilyName">http://www.stork.gov.eu/1.0/inheritedFamilyName</entry>
- <entry key="adoptedFamilyName">http://www.stork.gov.eu/1.0/adoptedFamilyName</entry>
- <entry key="gender">http://www.stork.gov.eu/1.0/gender</entry>
- <entry key="dateOfBirth">http://www.stork.gov.eu/1.0/dateOfBirth</entry>
- <entry key="countryCodeOfBirth">http://www.stork.gov.eu/1.0/countryCodeOfBirth</entry>
- <entry key="nationalityCode">http://www.stork.gov.eu/1.0/nationalityCode</entry>
- <entry key="maritalStatus">http://www.stork.gov.eu/1.0/maritalStatus</entry>
- <entry key="residenceAddress">http://www.stork.gov.eu/1.0/residenceAddress</entry>
- <entry key="eMail">http://www.stork.gov.eu/1.0/eMail</entry>
- <entry key="academicTitle">http://www.stork.gov.eu/1.0/academicTitle</entry>
- <entry key="pseudonym">http://www.stork.gov.eu/1.0/pseudonym</entry>
- <entry key="age">http://www.stork.gov.eu/1.0/age</entry>
- <entry key="isAgeOver">http://www.stork.gov.eu/1.0/isAgeOver</entry>
- <entry key="unknown">http://www.stork.gov.eu/1.0/unknown</entry>
-</properties> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AttrQueryRequest.xml b/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AttrQueryRequest.xml
deleted file mode 100644
index 3764389e4..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AttrQueryRequest.xml
+++ /dev/null
@@ -1,82 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<saml2p:AttributeQuery xmlns:saml2p="urn:oasis:names:tc:SAML:2.0:protocol"
- xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:saml2="urn:oasis:names:tc:SAML:2.0:assertion"
- xmlns:stork="urn:eu:stork:names:tc:STORK:1.0:assertion" xmlns:storkp="urn:eu:stork:names:tc:STORK:1.0:protocol"
- xmlns:xs="http://www.w3.org/2001/XMLSchema" Consent="urn:oasis:names:tc:SAML:2.0:consent:unspecified"
- Destination="http://A-PEPS.gov.xx/PEPS/AttributeColleagueRequest" ID="_939726f0a02072f40b548de378612a50"
- IssueInstant="2013-10-04T16:57:55.547Z" Version="2.0">
- <saml2:Issuer Format="urn:oasis:names:tc:SAML:2.0:nameid-format:entity">http://S-PEPS.gov.xx</saml2:Issuer>
- <ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#">
- <ds:SignedInfo>
- <ds:CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#" />
- <ds:SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1" />
- <ds:Reference URI="#_939726f0a02072f40b548de378612a50">
- <ds:Transforms>
- <ds:Transform
- Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature" />
- <ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#">
- <ec:InclusiveNamespaces xmlns:ec="http://www.w3.org/2001/10/xml-exc-c14n#"
- PrefixList="xs" />
- </ds:Transform>
- </ds:Transforms>
- <ds:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1" />
- <ds:DigestValue>BgPDTVCv7BhiWIs6HsC06jaHaag=</ds:DigestValue>
- </ds:Reference>
- </ds:SignedInfo>
- <ds:SignatureValue>dIC61bGi6Jqp1zSVojpjaVq9WaZcDtNImXgo1Dyze5/hJA07Sy4TaHu+/IuLEC99aLjM6rxh2UUNqpPaQCFlF5eVkVv/c4gHEZVyevhjJKTidqmnuhlI78PGMx2thfxFsHsPcqHqOzy1Z6w18K1ds6APQP+aXI9TNKis+pykn4nJititYuiSseD0VY0F4QnXx+U6k3raoi1CAFE5fe7EuI/KfxuhhQLAbLq90Vm8R94ITBjfSS25mXstXNe9zppTSjDB42ld1TjDovDwXAn5OxiZasIEb5m68sRlxgoQ/2/+ZdYNNINFLAwkCbb8MiCbGASd626Bme0Kx+ropeWdxw==</ds:SignatureValue>
- <ds:KeyInfo>
- <ds:X509Data>
- <ds:X509Certificate>MIIDXjCCAkagAwIBAgIEUk1MbDANBgkqhkiG9w0BAQUFADBxMQswCQYDVQQGEwJJUzESMBAGA1UE
- CAwJUmV5a2phdmlrMRIwEAYDVQQHDAlSZXlramF2aWsxEDAOBgNVBAoMB0FkdmFuaWExDzANBgNV
- BAsMBlNUT1JLMjEXMBUGA1UEAwwOc2FtbC1kZW1vLWNlcnQwHhcNMTMxMDAzMTA1MzEyWhcNMjMx
- MDAzMTA1MzEyWjBxMQswCQYDVQQGEwJJUzESMBAGA1UECAwJUmV5a2phdmlrMRIwEAYDVQQHDAlS
- ZXlramF2aWsxEDAOBgNVBAoMB0FkdmFuaWExDzANBgNVBAsMBlNUT1JLMjEXMBUGA1UEAwwOc2Ft
- bC1kZW1vLWNlcnQwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCkSgTxZkNRXZTKLB0c
- 4oz7/8Dh56FX+0cYg7hjw4e8vn+ITXkxzrmUH57FtsvKln4mq1H0FHXL80u3IiWX8qY+QLgNeKeB
- m85lXuyOb3wWpKAaQvpLAkejGLCx22AN2L0WZkKZV2puwRQVsRHCq6U6vToJXDZ6Ui6ltKsAl/ZS
- 8qUFpiIvqD5ea4ohz4JsFE/uApRc7pbJ4VbOmAAeH/tQTayptq2kPb2vvUVk+2cH5J7UD+GCI88E
- e+mS+C33tV9NmWUHL69mYEe8FXjumbKA5e9i1ejn9i0/BLUtHFonHnL9YFMim0foI7NNc5mNg9aw
- vm0PuByVU3kuibQkqGBLAgMBAAEwDQYJKoZIhvcNAQEFBQADggEBAA9X5B4NBmVuhjECi+KOnRRX
- 5oUV+jbYKhGZODDPi+F4Uo7ZtPFQ6sS3tE54+8AoDl5zQ5q5fDDVXhB42IIIjDxHKo8cBXie5FZ6
- mJtErvWZWYWdO0uV2OQAUALq2LieidqSFDJ+Pjl8w1New8oi3migwyE0jZo4Q97lJGDfJTruV0A2
- JE/Gt6QAAcWhhN2hZl92pYkIi5OeqHXyzBUp5vg8LLfNmeyziCAiXDC1Sy/aQU/cllZ3zFJMrqZM
- s2xBpmB4sF1YRbIrr2OqEVE6M6DUx+pAQOd2uogV3AMT9D5MYpckI1jx/o/Tto7ju74nIVOskDiN
- K0FR8izxcT0HixM=</ds:X509Certificate>
- </ds:X509Data>
- </ds:KeyInfo>
- </ds:Signature>
- <saml2p:Extensions>
- <stork:QualityAuthenticationAssuranceLevel>3</stork:QualityAuthenticationAssuranceLevel>
- <storkp:eIDSectorShare>false</storkp:eIDSectorShare>
- <storkp:eIDCrossSectorShare>false</storkp:eIDCrossSectorShare>
- <storkp:eIDCrossBorderShare>false</storkp:eIDCrossBorderShare>
- <storkp:RequestedAttributes>
- <stork:RequestedAttribute Name="http://www.stork.gov.eu/1.0/dateOfBirth"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="false" />
- <stork:RequestedAttribute Name="http://www.stork.gov.eu/1.0/isAgeOver"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="true">
- <stork:AttributeValue xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:type="xs:anyType">16</stork:AttributeValue>
- <stork:AttributeValue xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:type="xs:anyType">18</stork:AttributeValue>
- </stork:RequestedAttribute>
- <stork:RequestedAttribute Name="http://www.stork.gov.eu/1.0/givenName"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="true">
- <stork:AttributeValue xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:type="xs:anyType">Sveinbjorn</stork:AttributeValue>
- </stork:RequestedAttribute>
- <stork:RequestedAttribute Name="http://www.stork.gov.eu/1.0/eIdentifier"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="true">
- <stork:AttributeValue xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:type="xs:anyType">ES/IS/1234567890</stork:AttributeValue>
- </stork:RequestedAttribute>
- </storkp:RequestedAttributes>
- </saml2p:Extensions>
- <saml2:Subject>
- <saml2:SubjectConfirmation Method="urn:oasis:names:tc:SAML:2.0:cm:bearer" />
- </saml2:Subject>
-</saml2p:AttributeQuery> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AttrQueryRequestSdoc.xml b/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AttrQueryRequestSdoc.xml
deleted file mode 100644
index d64572829..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AttrQueryRequestSdoc.xml
+++ /dev/null
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?><saml2p:AttributeQuery xmlns:saml2p="urn:oasis:names:tc:SAML:2.0:protocol" xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:saml2="urn:oasis:names:tc:SAML:2.0:assertion" xmlns:stork="urn:eu:stork:names:tc:STORK:1.0:assertion" xmlns:storkp="urn:eu:stork:names:tc:STORK:1.0:protocol" xmlns:xs="http://www.w3.org/2001/XMLSchema" AssertionConsumerServiceURL="http://S-PEPS.gov.xx/PEPS/ColleagueResponse" Consent="urn:oasis:names:tc:SAML:2.0:consent:unspecified" Destination="http://A-PEPS.gov.xx/PEPS/AttributeColleagueRequest" ID="_334488599e0c2781ff34857c4964debb" IssueInstant="2014-02-06T22:09:18.113Z" Version="2.0"><saml2:Issuer Format="urn:oasis:names:tc:SAML:2.0:nameid-format:entity">http://S-PEPS.gov.xx</saml2:Issuer><ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#"><ds:SignedInfo><ds:CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"/><ds:SignatureMethod Algorithm="http://www.w3.org/2001/04/xmldsig-more#rsa-sha256"/><ds:Reference URI="#_334488599e0c2781ff34857c4964debb"><ds:Transforms><ds:Transform Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature"/><ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"><ec:InclusiveNamespaces xmlns:ec="http://www.w3.org/2001/10/xml-exc-c14n#" PrefixList="xs"/></ds:Transform></ds:Transforms><ds:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1"/><ds:DigestValue>X1nUVB6qXdoKbJzNekiSo9ExLdw=</ds:DigestValue></ds:Reference></ds:SignedInfo><ds:SignatureValue>ExCPHHC/9OhdhOl1Ou+43Qw1nvskpbMYMu9vqa7m16doxM2PIUmK7LUw7hZiKtjIdBxuhpca3OrjO8O6MuTDN1FksWoj+7B1KTLFtmspucT5O7Cu2OqhK5WIVuCaLuA7CD0N2UfFouRwR5NlLHyzn9Trd7IM5OjA41dGb5jqYl7Ir+62+MgjhZRlLooDzb5fDAczbxv9LHGiKRBpgnk40w3gDAvoSPNdEuKhZi8LPQWWNBvVi3N5ZmJmAIacZWBqePywXTjygmChWAc8p7ptAX6tw0hpBxyxoW3aaZZzWQNcwobTRYbn89fcM11gqIz/YK7VXtiQ7WEQt1enQD/GAA==</ds:SignatureValue><ds:KeyInfo><ds:X509Data><ds:X509Certificate>MIIDIjCCAgqgAwIBAgIES6idsjANBgkqhkiG9w0BAQUFADBTMQswCQYDVQQGEwJFUzEOMAwGA1UE
-CAwFU3BhaW4xDzANBgNVBAcMBk1hZHJpZDEOMAwGA1UECgwFSW5kcmExEzARBgNVBAMMCmxvY2Fs
-LWRlbW8wHhcNMTMwODI4MTY0NzM1WhcNMTUwODI4MTY0NzM1WjBTMQswCQYDVQQGEwJFUzEOMAwG
-A1UECAwFU3BhaW4xDzANBgNVBAcMBk1hZHJpZDEOMAwGA1UECgwFSW5kcmExEzARBgNVBAMMCmxv
-Y2FsLWRlbW8wggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCx+7zEQUbt8Ot9dByR5TuY
-NPmTwaKhECtnkxYAx9tl+Ga3kFiv+dOSeDoQOhxkICG1ZMaG0Gtk0EQWjscC1cLwDXpAOdhOm5xh
-ndFHxa3V3Y3zomFZA7A3nwP8wt17wDrc1xi2Ye8VrwO7Vjb/F8Rgutlcrvq+LF4g9nQLoRiKUq8w
-NFvDlvhBbLr8hMVBMY/jY7tSQ85qLqKUkWRcoDttJjgWZoO1vpBS4m+FywtYdOoHnN6fv4Dvf1r2
-rNLgebgBvSfwznxiulwW6FBLasYX0rYKP7RfwG8TJ+FumOgAjADj2LdwK25RZNg44XU2V1z1Fp37
-fNXhfo08LpdD1ueFAgMBAAEwDQYJKoZIhvcNAQEFBQADggEBADMRGTWOmadZyCoJNluV+M7LopjC
-9WpFUj76X0cAoNXmt12zYqYe8hjRmBr6l2V/FXT3/TyWET1nILG46zwwAxslw3b2LvkhU+9QcuB8
-yC8TCJJ0kgsTZ/EUZPSbwUG7Nn2jkMiyjlyKcjSCQOzEKQyR1xYwyZG40+BPeGbYjmRgm6kcmCxY
-USWoPwNyfke9gNT80f0pUj7wJ9YwWbTIz1rhf/h7rxoMYypXo+JXwaXW/Ra8v1uDcwfKpE5ZgwAU
-nubLXF4A+H7/N7ZvB5XDwJ4W+99nuPsKfwacD8m1sflTXcEPzzhOq6iQ9anJT94/pMctnp827zXA
-y66jvDrin5I=</ds:X509Certificate></ds:X509Data></ds:KeyInfo></ds:Signature><saml2p:Extensions><stork:QualityAuthenticationAssuranceLevel>3</stork:QualityAuthenticationAssuranceLevel><stork:spCountry>IS</stork:spCountry><storkp:eIDSectorShare>false</storkp:eIDSectorShare><storkp:eIDCrossSectorShare>false</storkp:eIDCrossSectorShare><storkp:eIDCrossBorderShare>false</storkp:eIDCrossBorderShare><storkp:RequestedAttributes><stork:RequestedAttribute Name="http://www.stork.gov.eu/1.0/docRequest" NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri" isRequired="true"><stork:AttributeValue xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="xs:anyType">IS/IS/fbea6e68-0393-401b-b616-f767fff9418c</stork:AttributeValue></stork:RequestedAttribute></storkp:RequestedAttributes></saml2p:Extensions><saml2:Subject><saml2:SubjectConfirmation Method="urn:oasis:names:tc:SAML:2.0:cm:bearer"/></saml2:Subject></saml2p:AttributeQuery> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AttrQueryRequestTagDelete.xml b/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AttrQueryRequestTagDelete.xml
deleted file mode 100644
index becc689fe..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AttrQueryRequestTagDelete.xml
+++ /dev/null
@@ -1,66 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<saml2p:AttributeQuery xmlns:saml2p="urn:oasis:names:tc:SAML:2.0:protocol"
- xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:saml2="urn:oasis:names:tc:SAML:2.0:assertion"
- xmlns:stork="urn:eu:stork:names:tc:STORK:1.0:assertion" xmlns:storkp="urn:eu:stork:names:tc:STORK:1.0:protocol"
- xmlns:xs="http://www.w3.org/2001/XMLSchema" Consent="urn:oasis:names:tc:SAML:2.0:consent:unspecified"
- Destination="http://C-PEPS.gov.xx/PEPS/ColleagueRequest" ID="_f6c8fc355b9f125cb5283f038e1b3cdf"
- IssueInstant="2013-10-03T10:28:15.449Z" Version="2.0">
- <saml2:Issuer Format="urn:oasis:names:tc:SAML:2.0:nameid-format:entity">http://S-PEPS.gov.xx</saml2:Issuer>
- <ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#">
- <ds:SignatureValue>hhQXDKNrJJ3Yy/pkZNZF4GlWrA/Xsx4CH9chgVa5HK4qZQvFXvZwegdw6U7rm7qv0zmI4xaLTv/bpmqJzEPfY3sIvrDRu9EouEKwtjbMbcvVQsx7I+j0yy7/cBcQJe3lRwQwyvazfYVbnSeGFxBN6WOHPqv6uInaQO/hXkicT3tBtm8o3UgUDY6c8wIMuD5A0hWTkL6z6f893AbdN85OQYAdHItNsQWeLOIeiGC918X7qqTfhFtBAB2oGVjlsSEqWox1jNqrPl1jjA0dP76m5SIVSqF8XcDR306ZB9GLJywOHKba0lxGLsXOAzJ+8u9jeixJ6VZKFqZg2Fhl/saKbg==</ds:SignatureValue>
- <ds:KeyInfo>
- <ds:X509Data>
- <ds:X509Certificate>MIIDJzCCAg8CBEuonbIwDQYJKoZIhvcNAQEFBQAwWDELMAkGA1UEBhMCRVMxDjAMBgNVBAgMBVNw
- YWluMQ8wDQYDVQQHDAZNYWRyaWQxDjAMBgNVBAoMBUluZHJhMRgwFgYDVQQDDA9sb2NhbC1kZW1v
- LWNlcnQwHhcNMTAwMzIzMTA1MzM4WhcNMTAwNjAxMTA1MzM4WjBYMQswCQYDVQQGEwJFUzEOMAwG
- A1UECAwFU3BhaW4xDzANBgNVBAcMBk1hZHJpZDEOMAwGA1UECgwFSW5kcmExGDAWBgNVBAMMD2xv
- Y2FsLWRlbW8tY2VydDCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAJfdQ1/mkM9sqqab
- ri8qqqX4s0J6UEEXyF+0AjLU8RC4WMeYFSZ5tfwnyLsoXY0/9bZLXnBxSibQYaf4SnpZJhlVA4sU
- 0d8qyEWA2OvXGDCm7uspGHG3CRQa7fpHsmHmfIAqho9XDlwpwJdx5gK4Edc6aArcMQfjqMhy1s1n
- 6Of1i1lMGGsGrERIRY7biIQu/8nITbHH18sUAZMG1u/Q0Avi9O3LWyswHXUouZ818fWwG6xru2N5
- y6vtVO/SL3doRSdqYkEms93TgxTtaKg8XNe24zhNTte6nvWLaKesi2KzZGC57HU47HBFEs8NWk7z
- 9BDf8uLyPz9VDahwVKzMto8CAwEAATANBgkqhkiG9w0BAQUFAAOCAQEAgpuReXQ7Dsfdoe5zzy2F
- 6kn1qqtMkRGsBPKnDFCI/GkIZpBiqlfwdh6sipnFKWfKEDlPKN1kEhbkDR2GA1Cp4F4ZSL/HumZM
- pWabRhDxhTPvHIFbbShPDJY93+jw/yQeaWgMuhw3WzdH9TrVoRZH0Q7sG1pIJo5/6IogIZwFvJHT
- /NDutKmurU6Lw8Vnde8PfnQd+FTEhz0SEGyKkWjAuhGbJfseBy/z3L+MJq1rdSQ9PF7wXDvWNzJq
- yaNBUWWBV1TskvkNZXcaguroVPy2XhA1aixlAajWEXLk6Uuj5UYqalrV/reNYvDvY0BV2CIn51r7
- Ppm8IFVTk8mYfX8/jw==</ds:X509Certificate>
- </ds:X509Data>
- </ds:KeyInfo>
- </ds:Signature>
- <saml2p:Extensions>
- <stork:QualityAuthenticationAssuranceLevel>3</stork:QualityAuthenticationAssuranceLevel>
- <storkp:eIDSectorShare>false</storkp:eIDSectorShare>
- <storkp:eIDCrossSectorShare>false</storkp:eIDCrossSectorShare>
- <storkp:eIDCrossBorderShare>false</storkp:eIDCrossBorderShare>
- <storkp:RequestedAttributes>
- <stork:RequestedAttribute Name="http://www.stork.gov.eu/1.0/dateOfBirth"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="false" />
- <stork:RequestedAttribute Name="http://www.stork.gov.eu/1.0/isAgeOver"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="true">
- <stork:AttributeValue xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:type="xs:anyType">16</stork:AttributeValue>
- <stork:AttributeValue xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:type="xs:anyType">18</stork:AttributeValue>
- </stork:RequestedAttribute>
- <stork:RequestedAttribute Name="http://www.stork.gov.eu/1.0/givenName"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="true">
- <stork:AttributeValue xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:type="xs:anyType">Sveinbjörn</stork:AttributeValue>
- </stork:RequestedAttribute>
- <stork:RequestedAttribute Name="http://www.stork.gov.eu/1.0/eIdentifier"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="true">
- <stork:AttributeValue xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:type="xs:anyType">ES/IS/1234567890</stork:AttributeValue>
- </stork:RequestedAttribute>
- </storkp:RequestedAttributes>
- </saml2p:Extensions>
- <saml2:Subject>
- <saml2:SubjectConfirmation
- Method="urn:oasis:names:tc:SAML:1.0:cm:sender-vouches" />
- </saml2:Subject>
-</saml2p:AttributeQuery> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AttrQueryResponse.xml b/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AttrQueryResponse.xml
deleted file mode 100644
index 7ea486812..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AttrQueryResponse.xml
+++ /dev/null
@@ -1,124 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<saml2p:Response xmlns:saml2p="urn:oasis:names:tc:SAML:2.0:protocol"
- xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:saml2="urn:oasis:names:tc:SAML:2.0:assertion"
- xmlns:stork="urn:eu:stork:names:tc:STORK:1.0:assertion" xmlns:storkp="urn:eu:stork:names:tc:STORK:1.0:protocol"
- xmlns:xs="http://www.w3.org/2001/XMLSchema" Consent="urn:oasis:names:tc:SAML:2.0:consent:obtained"
- Destination="http://C-PEPS.gov.xx/PEPS/ColleagueRequest" ID="_483140d440fc4eef8e949ace49669f2e"
- InResponseTo="_0a22c1120bf2de912714c24e99dd38ed" IssueInstant="2013-10-08T09:11:17.255Z"
- Version="2.0">
- <saml2:Issuer Format="urn:oasis:names:tc:SAML:2.0:nameid-format:entity">http://C-PEPS.gov.xx</saml2:Issuer>
- <ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#">
- <ds:SignedInfo>
- <ds:CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#" />
- <ds:SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1" />
- <ds:Reference URI="#_483140d440fc4eef8e949ace49669f2e">
- <ds:Transforms>
- <ds:Transform
- Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature" />
- <ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#">
- <ec:InclusiveNamespaces xmlns:ec="http://www.w3.org/2001/10/xml-exc-c14n#"
- PrefixList="xs" />
- </ds:Transform>
- </ds:Transforms>
- <ds:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1" />
- <ds:DigestValue>yMOVS1T/yRiVh3L6IBM9rR9Ie3w=</ds:DigestValue>
- </ds:Reference>
- </ds:SignedInfo>
- <ds:SignatureValue>d8e/RyNNPmnHRIzTIuRSnW6B60oWGBGxjRua/HvNxTuod0qSarYJxEedhY9Wl1Z9WYXlry28FuKjp3DA3HhzNaVd7A7QpFqNC4dnizSVWFjxlhmoE/Uv3Y/ha9P/fk6nbtHCSKW4kHSX7QfFLeggcLmUG0IULRF8UmRdQ0WerCl0aSZZeSp8J3LsFBPeWCRSwXgfiLn+RehggzZmQU6g0ssxrpnsYEAtjAiOli+YVQGuumsZGaJ8zHA/DgJ2FTGovNUyfuSUFLhd9nLlSqFs2Avnx0Ck7Q1dxDO5truOm6e285YLHqLaGdetFyPQAj/Z4w4RJ5u5X6d7rhBjTfRAAw==</ds:SignatureValue>
- <ds:KeyInfo>
- <ds:X509Data>
- <ds:X509Certificate>MIIDJzCCAg8CBEuonbIwDQYJKoZIhvcNAQEFBQAwWDELMAkGA1UEBhMCRVMxDjAMBgNVBAgMBVNw
- YWluMQ8wDQYDVQQHDAZNYWRyaWQxDjAMBgNVBAoMBUluZHJhMRgwFgYDVQQDDA9sb2NhbC1kZW1v
- LWNlcnQwHhcNMTAwMzIzMTA1MzM4WhcNMTAwNjAxMTA1MzM4WjBYMQswCQYDVQQGEwJFUzEOMAwG
- A1UECAwFU3BhaW4xDzANBgNVBAcMBk1hZHJpZDEOMAwGA1UECgwFSW5kcmExGDAWBgNVBAMMD2xv
- Y2FsLWRlbW8tY2VydDCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAJfdQ1/mkM9sqqab
- ri8qqqX4s0J6UEEXyF+0AjLU8RC4WMeYFSZ5tfwnyLsoXY0/9bZLXnBxSibQYaf4SnpZJhlVA4sU
- 0d8qyEWA2OvXGDCm7uspGHG3CRQa7fpHsmHmfIAqho9XDlwpwJdx5gK4Edc6aArcMQfjqMhy1s1n
- 6Of1i1lMGGsGrERIRY7biIQu/8nITbHH18sUAZMG1u/Q0Avi9O3LWyswHXUouZ818fWwG6xru2N5
- y6vtVO/SL3doRSdqYkEms93TgxTtaKg8XNe24zhNTte6nvWLaKesi2KzZGC57HU47HBFEs8NWk7z
- 9BDf8uLyPz9VDahwVKzMto8CAwEAATANBgkqhkiG9w0BAQUFAAOCAQEAgpuReXQ7Dsfdoe5zzy2F
- 6kn1qqtMkRGsBPKnDFCI/GkIZpBiqlfwdh6sipnFKWfKEDlPKN1kEhbkDR2GA1Cp4F4ZSL/HumZM
- pWabRhDxhTPvHIFbbShPDJY93+jw/yQeaWgMuhw3WzdH9TrVoRZH0Q7sG1pIJo5/6IogIZwFvJHT
- /NDutKmurU6Lw8Vnde8PfnQd+FTEhz0SEGyKkWjAuhGbJfseBy/z3L+MJq1rdSQ9PF7wXDvWNzJq
- yaNBUWWBV1TskvkNZXcaguroVPy2XhA1aixlAajWEXLk6Uuj5UYqalrV/reNYvDvY0BV2CIn51r7
- Ppm8IFVTk8mYfX8/jw==</ds:X509Certificate>
- </ds:X509Data>
- </ds:KeyInfo>
- </ds:Signature>
- <saml2p:Status>
- <saml2p:StatusCode Value="urn:oasis:names:tc:SAML:2.0:status:Success" />
- <saml2p:StatusMessage>urn:oasis:names:tc:SAML:2.0:status:Success</saml2p:StatusMessage>
- </saml2p:Status>
- <saml2:Assertion ID="_9ed05849dee5c154e62fa9e3ba53e9f3"
- IssueInstant="2013-10-08T09:11:17.255Z" Version="2.0">
- <saml2:Issuer Format="urn:oasis:names:tc:SAML:2.0:nameid-format:entity">http://C-PEPS.gov.xx</saml2:Issuer>
- <saml2:Subject>
- <saml2:NameID Format="urn:oasis:names:tc:SAML:1.1:nameid-format:unspecified"
- NameQualifier="http://C-PEPS.gov.xx">urn:oasis:names:tc:SAML:1.1:nameid-format:unspecified</saml2:NameID>
- <saml2:SubjectConfirmation Method="urn:oasis:names:tc:SAML:2.0:cm:bearer">
- <saml2:SubjectConfirmationData
- Address="111.222.333.444" InResponseTo="_0a22c1120bf2de912714c24e99dd38ed"
- NotOnOrAfter="2013-10-08T09:16:17.255Z" />
- </saml2:SubjectConfirmation>
- </saml2:Subject>
- <saml2:Conditions NotBefore="2013-10-08T09:11:17.255Z"
- NotOnOrAfter="2013-10-08T09:16:17.255Z">
- <saml2:AudienceRestriction>
- <saml2:Audience>http://S-PEPS.gov.xx</saml2:Audience>
- </saml2:AudienceRestriction>
- <saml2:OneTimeUse />
- </saml2:Conditions>
- <saml2:AuthnStatement AuthnInstant="2013-10-08T09:11:17.255Z">
- <saml2:SubjectLocality Address="111.222.333.444" />
- <saml2:AuthnContext>
- <saml2:AuthnContextDecl />
- </saml2:AuthnContext>
- </saml2:AuthnStatement>
- <saml2:AttributeStatement>
- <saml2:Attribute Name="http://www.stork.gov.eu/1.0/dateOfBirth"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- stork:AttributeStatus="Available">
- <saml2:AttributeValue xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:type="xs:anyType">16/12/2008</saml2:AttributeValue>
- </saml2:Attribute>
- <saml2:Attribute
- Name="http://www.stork.gov.eu/1.0/canonicalResidenceAddress"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- stork:AttributeStatus="Available">
- <saml2:AttributeValue xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:type="xs:anyType">
- <stork:postalCode xsi:type="xs:anyType">105</stork:postalCode>
- <stork:state xsi:type="xs:anyType">IS</stork:state>
- <stork:streetNumber xsi:type="xs:anyType">10</stork:streetNumber>
- <stork:streetName xsi:type="xs:anyType">Gudrunartun</stork:streetName>
- <stork:town xsi:type="xs:anyType">Reykjavik</stork:town>
- </saml2:AttributeValue>
- </saml2:Attribute>
- <saml2:Attribute Name="http://www.stork.gov.eu/1.0/newAttribute2"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- stork:AttributeStatus="Available">
- <saml2:AttributeValue xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:type="xs:anyType">
- <stork:value3 xsi:type="xs:anyType">value3</stork:value3>
- <stork:value4 xsi:type="xs:anyType">value4</stork:value4>
- <stork:value1 xsi:type="xs:anyType">value1</stork:value1>
- <stork:value2 xsi:type="xs:anyType">value2</stork:value2>
- </saml2:AttributeValue>
- </saml2:Attribute>
- <saml2:Attribute Name="http://www.stork.gov.eu/1.0/isAgeOver"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- stork:AttributeStatus="Available">
- <saml2:AttributeValue xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:type="xs:anyType">16</saml2:AttributeValue>
- <saml2:AttributeValue xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:type="xs:anyType">18</saml2:AttributeValue>
- </saml2:Attribute>
- <saml2:Attribute Name="http://www.stork.gov.eu/1.0/eIdentifier"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- stork:AttributeStatus="Available">
- <saml2:AttributeValue xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:type="xs:anyType">123456789IS</saml2:AttributeValue>
- </saml2:Attribute>
- </saml2:AttributeStatement>
- </saml2:Assertion>
-</saml2p:Response> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AuthnRequest.xml b/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AuthnRequest.xml
deleted file mode 100644
index c48bfde95..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AuthnRequest.xml
+++ /dev/null
@@ -1,72 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<saml2p:AuthnRequest xmlns:saml2p="urn:oasis:names:tc:SAML:2.0:protocol"
- xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:saml2="urn:oasis:names:tc:SAML:2.0:assertion"
- xmlns:stork="urn:eu:stork:names:tc:STORK:1.0:assertion" xmlns:storkp="urn:eu:stork:names:tc:STORK:1.0:protocol"
- AssertionConsumerServiceURL="http://S-PEPS.gov.xx/PEPS/ColleagueResponse"
- Consent="urn:oasis:names:tc:SAML:2.0:consent:unspecified" Destination="http://C-PEPS.gov.xx/PEPS/ColleagueRequest"
- ForceAuthn="true" ID="_e54eee285e7b8e2772875c406ec39674" IsPassive="false"
- IssueInstant="2010-06-08T07:37:54.533Z" ProtocolBinding="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST"
- ProviderName="University of Oxford" Version="2.0">
- <saml2:Issuer Format="urn:oasis:names:tc:SAML:2.0:nameid-format:entity">http://S-PEPS.gov.xx</saml2:Issuer>
- <ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#">
- <ds:SignedInfo>
- <ds:CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#" />
- <ds:SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1" />
- <ds:Reference URI="#_e54eee285e7b8e2772875c406ec39674">
- <ds:Transforms>
- <ds:Transform
- Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature" />
- <ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#">
- <ec:InclusiveNamespaces xmlns:ec="http://www.w3.org/2001/10/xml-exc-c14n#"
- PrefixList="ds saml2 saml2p stork storkp xs" />
- </ds:Transform>
- </ds:Transforms>
- <ds:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1" />
- <ds:DigestValue>yzsqaxBNicOrixBUno5cL0CBOpE=</ds:DigestValue>
- </ds:Reference>
- </ds:SignedInfo>
- <ds:SignatureValue>
- Xycll1PF7hh3Xdykpr6nIr8Q6PQ6OxLIBBBugoGpAm/V4Hu7tKakHJp8TgtRWZ30jG5eolOXnJkC
- wiaTVUFaQz7cNn27syRJkdA+eYlz9doiwUJ5eD1cAyddZYsNPpSeAj5UK45oN0qCH+/pI9mRw8Oi
- YIN/BUEtXkoYTjPtkmA=
- </ds:SignatureValue>
- <ds:KeyInfo>
- <ds:X509Data>
- <ds:X509Certificate>MIIBmDCCAQECBEuWisIwDQYJKoZIhvcNAQEFBQAwEzERMA8GA1UEAxMIY291bnRyeTEwHhcNMTAw
- MzA5MTc1MjAyWhcNMTAwNjA3MTc1MjAyWjATMREwDwYDVQQDEwhjb3VudHJ5MTCBnzANBgkqhkiG
- 9w0BAQEFAAOBjQAwgYkCgYEAnb2gcchwxvJBclcsfCBWJnYefLJYQnDGCQ3RUtYZc26JznnLXclu
- h1XfLJlWgYk/pFKz7B9KfJztal47c6mBfisnxjhdcLqcbXOuRIm7E8TZPzdbHEd60WHPDv20jr+r
- /WkOQs12tKQMbgDX2wtBBcJODLYCDiYa1oQsnyhdOGkCAwEAATANBgkqhkiG9w0BAQUFAAOBgQBk
- 3luVRc0EqEE1zZeYvRPi5a2yOZfI9H+/rXI1qNLwmICnuJX++ukUbqJHm/FV1iSPM9O9oqzifJ/K
- eKL5EcUugJ76Tu5XO8za2FoJvYr+jIZDsEkCg+OSzcp/eljiWAIh2enZcQ/ON6QxWXeSNJPH0xOq
- KAoZgbUK0Zld3Dsheg==</ds:X509Certificate>
- </ds:X509Data>
- </ds:KeyInfo>
- </ds:Signature>
- <saml2p:Extensions>
- <stork:QualityAuthenticationAssuranceLevel>3</stork:QualityAuthenticationAssuranceLevel>
- <stork:spSector>EDU001</stork:spSector>
- <stork:spInstitution>OXF001</stork:spInstitution>
- <stork:spApplication>APP001</stork:spApplication>
- <stork:spCountry>EN</stork:spCountry>
- <storkp:eIDSectorShare>true</storkp:eIDSectorShare>
- <storkp:eIDCrossSectorShare>true</storkp:eIDCrossSectorShare>
- <storkp:eIDCrossBorderShare>true</storkp:eIDCrossBorderShare>
- <storkp:RequestedAttributes>
- <stork:RequestedAttribute Name="http://www.stork.gov.eu/1.0/isAgeOver"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="true">
- <stork:AttributeValue xmlns:xs="http://www.w3.org/2001/XMLSchema"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="xs:string">16</stork:AttributeValue>
- <stork:AttributeValue xmlns:xs="http://www.w3.org/2001/XMLSchema"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="xs:string">18</stork:AttributeValue>
- </stork:RequestedAttribute>
- <stork:RequestedAttribute Name="http://www.stork.gov.eu/1.0/dateOfBirth"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="false" />
- <stork:RequestedAttribute Name="http://www.stork.gov.eu/1.0/eIdentifier"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="true" />
- </storkp:RequestedAttributes>
- </saml2p:Extensions>
-</saml2p:AuthnRequest> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDelete.xml b/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDelete.xml
deleted file mode 100644
index 8766f9a8b..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDelete.xml
+++ /dev/null
@@ -1,47 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<saml2p:AuthnRequest xmlns:saml2p="urn:oasis:names:tc:SAML:2.0:protocol"
- xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:saml2="urn:oasis:names:tc:SAML:2.0:assertion"
- xmlns:stork="urn:eu:stork:names:tc:STORK:1.0:stork" xmlns:storkp="urn:eu:stork:names:tc:STORK:1.0:protocol"
- AssertionConsumerServiceURL="http://localhost:8080/SP/ReturnPage"
- Consent="urn:oasis:names:tc:SAML:2.0:consent:unspecified" Destination="http://locahost:8080/PEPS/ServiceProvider"
- ForceAuthn="true" ID="_0c64ff85-1323-4618-847b-12d1983b86e4" IsPassive="false"
- IssueInstant="2010-04-07T16:45:03.593Z" ProtocolBinding="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST"
- ProviderName="PT-SP" Version="2.0">
- <saml2:Issuer Format="urn:oasis:names:tc:SAML:2.0:nameid-format:entity">http://S-PEPS.gov.xx</saml2:Issuer>
- <ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#">
- <ds:SignatureValue>
- S6nY97RSCUJXq3HZ5obSLCI341LvtAA3vHjR1FWxrIMDPACQMqlNWBYNnRP1RiZiJV6x0RieH+SR
- Vkiy03jYyhr0XkwAE5Wd6Huf+zIbeTXjZkdQj7JpAXoB+ky4G/+L0deamvsP3eO7ZJ4grady4gmC
- Xt8p8tK3EoMocZse2hw=
- </ds:SignatureValue>
- <ds:KeyInfo>
- <ds:X509Data>
- <ds:X509Certificate>MIIBkTCB+wIESpT8bTANBgkqhkiG9w0BAQUFADAQMQ4wDAYDVQQDEwVzdG9yazAeFw0wOTA4MjYw
- OTEyMTNaFw0wOTExMjQwOTEyMTNaMBAxDjAMBgNVBAMTBXN0b3JrMIGfMA0GCSqGSIb3DQEBAQUA
- A4GNADCBiQKBgQDK/QL8NuMd41I1lObObeRA6DaM8bjeYqIz5mg5WnnZv4jlcK7Gq89Lk6htXRFl
- lAXpDYhI3zolMIMHEMZ3zQQPc7lgTV6Bbz9uD2YTJ9Kx55e8Y6Y49DO+TiiejGJxTzTFUcuBJHaK
- ipuvLVd1a8N3RAnaGSUOozhrTqxba82mEwIDAQABMA0GCSqGSIb3DQEBBQUAA4GBAFJgeS18nhUl
- r7WnvSn9FlkI94U//Hk3iZLc3/cScTu7D7Y/J0eUq4TF8PsSzWX5khGuqrTkswNgfEtl2IpACQ2w
- kB8+RxeRNdddQlGHlO4ZqnpvxXBwSouiy2yUeAo0y++vMFm6DO4sxfk8eTtimPDo5SzBtjtGtbqS
- 3cyl/wz8</ds:X509Certificate>
- </ds:X509Data>
- </ds:KeyInfo>
- </ds:Signature>
- <saml2p:Extensions>
- <stork:QualityAuthenticationAssuranceLevel>3</stork:QualityAuthenticationAssuranceLevel>
- <storkp:eIDSectorShare>false</storkp:eIDSectorShare>
- <storkp:eIDCrossSectorShare>false</storkp:eIDCrossSectorShare>
- <storkp:eIDCrossBorderShare>false</storkp:eIDCrossBorderShare>
- <storkp:RequestedAttributes>
- <stork:RequestedAttribute
- Name="http://www.stork.gov.eu/1.0/nationalityCode" NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="true" />
- <stork:RequestedAttribute Name="http://www.stork.gov.eu/1.0/dateOfBirth"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="true" />
- <stork:RequestedAttribute Name="http://www.stork.gov.eu/1.0/givenName"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="true" />
- </storkp:RequestedAttributes>
- </saml2p:Extensions>
-</saml2p:AuthnRequest> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDeleteEncoded.xml b/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDeleteEncoded.xml
deleted file mode 100644
index 1b1e1646c..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDeleteEncoded.xml
+++ /dev/null
@@ -1,47 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<saml2p:AuthnRequest xmlns:saml2p="urn:oasis:names:tc:SAML:2.0:protocol"
- xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:saml2="urn:oasis:names:tc:SAML:2.0:assertion"
- xmlns:stork="urn:eu:stork:names:tc:STORK:1.0:stork" xmlns:storkp="urn:eu:stork:names:tc:STORK:1.0:protocol"
- AssertionConsumerServiceURL="http://localhost:8080/SP/ReturnPage"
- Consent="urn:oasis:names:tc:SAML:2.0:consent:unspecified" Destination="http://localhost:8080/PEPS/ServiceProvider"
- ForceAuthn="true" ID="_0c64ff85-1323-4618-847b-12d1983b86e4" IsPassive="false"
- IssueInstant="2010-04-07T16:45:03.593Z" ProtocolBinding="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST"
- ProviderName="PT-SP" Version="2.0">
- <saml2:Issuer Format="urn:oasis:names:tc:SAML:2.0:nameid-format:entity">http://S-PEPS.gov.xx</saml2:Issuer>
- <ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#">
- <ds:SignatureValue>
- S6nY97RSCUJXq3HZ5obSLCI341LvtAA3vHjR1FWxrIMDPACQMqlNWBYNnRP1RiZiJV6x0RieH+SR
- Vkiy03jYyhr0XkwAE5Wd6Huf+zIbeTXjZkdQj7JpAXoB+ky4G/+L0deamvsP3eO7ZJ4grady4gmC
- Xt8p8tK3EoMocZse2hw=
- </ds:SignatureValue>
- <ds:KeyInfo>
- <ds:X509Data>
- <ds:X509Certificate>MIIBkTCB+wIESpT8bTANBgkqhkiG9w0BAQUFADAQMQ4wDAYDVQQDEwVzdG9yazAeFw0wOTA4MjYw
- OTEyMTNaFw0wOTExMjQwOTEyMTNaMBAxDjAMBgNVBAMTBXN0b3JrMIGfMA0GCSqGSIb3DQEBAQUA
- A4GNADCBiQKBgQDK/QL8NuMd41I1lObObeRA6DaM8bjeYqIz5mg5WnnZv4jlcK7Gq89Lk6htXRFl
- lAXpDYhI3zolMIMHEMZ3zQQPc7lgTV6Bbz9uD2YTJ9Kx55e8Y6Y49DO+TiiejGJxTzTFUcuBJHaK
- ipuvLVd1a8N3RAnaGSUOozhrTqxba82mEwIDAQABMA0GCSqGSIb3DQEBBQUAA4GBAFJgeS18nhUl
- r7WnvSn9FlkI94U//Hk3iZLc3/cScTu7D7Y/J0eUq4TF8PsSzWX5khGuqrTkswNgfEtl2IpACQ2w
- kB8+RxeRNdddQlGHlO4ZqnpvxXBwSouiy2yUeAo0y++vMFm6DO4sxfk8eTtimPDo5SzBtjtGtbqS
- 3cyl/wz8</ds:X509Certificate>
- </ds:X509Data>
- </ds:KeyInfo>
- </ds:Signature>
- <saml2p:Extensions>
- <stork:QualityAuthenticationAssuranceLevel>3</stork:QualityAuthenticationAssuranceLevel>
- <storkp:eIDSectorShare>false</storkp:eIDSectorShare>
- <storkp:eIDCrossSectorShare>false</storkp:eIDCrossSectorShare>
- <storkp:eIDCrossBorderShare>false</storkp:eIDCrossBorderShare>
- <storkp:RequestedAttributes>
- <stork:RequestedAttribute
- Name="http://www.stork.gov.eu/1.0/nationalityCode" NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="true" />
- <stork:RequestedAttribute Name="http://www.stork.gov.eu/1.0/dateOfBirth"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="true" />
- <stork:RequestedAttribute Name="http://www.stork.gov.eu/1.0/givenName"
- NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:uri"
- isRequired="true" />
- </storkp:RequestedAttributes>
- </saml2p:Extensions>
-</saml2p:AuthnRequest> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/SSETestUtils.class b/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/SSETestUtils.class
deleted file mode 100644
index 04ee36e06..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/SSETestUtils.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/SimpleBaseTest.class b/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/SimpleBaseTest.class
deleted file mode 100644
index d2e26053d..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/SimpleBaseTest.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkAttrQueryRequestTest.class b/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkAttrQueryRequestTest.class
deleted file mode 100644
index ef33ccfac..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkAttrQueryRequestTest.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkAttrQueryResponseTest.class b/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkAttrQueryResponseTest.class
deleted file mode 100644
index d6a90501c..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkAttrQueryResponseTest.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkAuthRequestTest.class b/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkAuthRequestTest.class
deleted file mode 100644
index 9aae365f2..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkAuthRequestTest.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkLogoutRequestTest.class b/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkLogoutRequestTest.class
deleted file mode 100644
index 8edfc3c0a..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkLogoutRequestTest.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkLogoutResponseTest.class b/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkLogoutResponseTest.class
deleted file mode 100644
index 6381cbbd4..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkLogoutResponseTest.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkNewResponseTest.class b/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkNewResponseTest.class
deleted file mode 100644
index c7c95781f..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkNewResponseTest.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkResponseTest.class b/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkResponseTest.class
deleted file mode 100644
index 36c9d64eb..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/eu/stork/peps/test/simple/StorkResponseTest.class
+++ /dev/null
Binary files differ
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/logback-test.xml b/id/server/SamlEngine-VIDP/target/test-classes/logback-test.xml
deleted file mode 100644
index 99d7d353a..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/logback-test.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Basic configuration used until the IdP can load the real configuration -->
-<configuration>
-
- <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
- <layout class="ch.qos.logback.classic.PatternLayout">
- <Pattern>%d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n
- </Pattern>
- </layout>
- </appender>
-
- <logger name="eu.stork">
- <level value="DEBUG" />
- </logger>
-
- <root>
- <appender-ref ref="STDOUT" />
- <level value="INFO" />
- </root>
-
-</configuration> \ No newline at end of file
diff --git a/id/server/SamlEngine-VIDP/target/test-classes/p11Conf.cfg b/id/server/SamlEngine-VIDP/target/test-classes/p11Conf.cfg
deleted file mode 100644
index bd9f357ce..000000000
--- a/id/server/SamlEngine-VIDP/target/test-classes/p11Conf.cfg
+++ /dev/null
@@ -1,24 +0,0 @@
-//ATTRIBUTE VALUE
-//name name suffix of this provider instance
-//library pathname of PKCS#11 implementation
-//slotListIndex slot index
-
-//PREFIX DESCRIPTION
-//CKO_ Object class
-//CKA_ Attribute
-//CKK_ Key type
-
-//attributes(operation, keytype, keyalgorithm) = {
-// name1 = value1
-// [...]
-//}
-
-name=nameProvider
-library=library.dll
-slotListIndex=0
-attributes(*,CKO_PUBLIC_KEY,CKK_RSA)={
- CKA_VERIFY=true
-}
-attributes(*,CKO_PRIVATE_KEY,CKK_RSA)={
- CKA_SIGN=true
-} \ No newline at end of file
diff --git a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/stork/STORKResponseProcessor.java b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/stork/STORKResponseProcessor.java
index 57843d0f3..ab9decde0 100644
--- a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/stork/STORKResponseProcessor.java
+++ b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/stork/STORKResponseProcessor.java
@@ -138,7 +138,37 @@ public class STORKResponseProcessor {
String citizenSignature = getAttributeValue("signedDoc", attributeList);
// if we have a signedDoc we test for a representation case
- if(hasAttribute("mandateContent", attributeList) || hasAttribute("representative", attributeList) || hasAttribute("represented", attributeList)) {
+ // - according to stork samlengine and commons
+ if(hasAttribute("mandate", attributeList)) {
+ // we have a representation case
+ String mandate = getAttributeValue("mandate", attributeList);
+
+ if(!hasAttribute("dateOfBirth", attributeList)) {
+ // if we get here, we have a natural person representing a legal person
+ String organizationAddress = getAttributeValue("canonicalRegisteredAddress", attributeList);
+ String organizationType = getAttributeValue("translateableType", attributeList);
+
+ identityLinkResponse = AuthenticationServer.getInstance().getIdentityLink(citizenSignature, null, null, mandate, organizationAddress, organizationType, targetType, targetValue, oaFriendlyName, filters);
+ } else {
+ // if we get here, we have a natural person representing another natural person
+ String eIdentifier = getAttributeValue("eIdentifier", attributeList);
+ String givenName = getAttributeValue("givenName", attributeList);
+ String lastName = getAttributeValue("surname", attributeList);
+ String dateOfBirth = getAttributeValue("dateOfBirth", attributeList);
+
+ // gender attribute is mandatory here because of some legal stuff
+ String gender = getAttributeValue("gender", attributeList);
+
+ if (!StringUtils.isEmpty(dateOfBirth))
+ dateOfBirth = DateTimeUtils.formatPEPSDateToMOADate(dateOfBirth);
+
+ identityLinkResponse = AuthenticationServer.getInstance().getIdentityLink(eIdentifier,
+ givenName, lastName, dateOfBirth, gender, citizenSignature, null,
+ null, mandate, targetType, targetValue, oaFriendlyName, filters);
+ }
+ }
+ // - according to stork spec
+ else if(hasAttribute("mandateContent", attributeList) || hasAttribute("representative", attributeList) || hasAttribute("represented", attributeList)) {
// we have a representation case
String representative = getAttributeValue("representative", attributeList);
String represented = getAttributeValue("represented", attributeList);
diff --git a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/stork/VelocityProvider.java b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/stork/VelocityProvider.java
index b923727f9..534121443 100644
--- a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/stork/VelocityProvider.java
+++ b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/stork/VelocityProvider.java
@@ -103,6 +103,8 @@ public class VelocityProvider {
VelocityEngine velocityEngine = new VelocityEngine();
velocityEngine.setProperty(RuntimeConstants.ENCODING_DEFAULT, "UTF-8");
velocityEngine.setProperty(RuntimeConstants.OUTPUT_ENCODING, "UTF-8");
+ velocityEngine.setProperty(RuntimeConstants.RUNTIME_LOG_LOGSYSTEM_CLASS,
+ "org.apache.velocity.runtime.log.SimpleLog4JLogSystem");
return velocityEngine;
}
diff --git a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/protocols/stork2/AttributeCollector.java b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/protocols/stork2/AttributeCollector.java
index e0f14c41d..4bf193e9e 100644
--- a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/protocols/stork2/AttributeCollector.java
+++ b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/protocols/stork2/AttributeCollector.java
@@ -109,6 +109,7 @@ public class AttributeCollector implements IAction {
if (!responseAttributeList.containsKey(current.getName()))
missingAttributes.add(current);
+ Logger.info("collecting attributes...");
Logger.debug("found " + missingAttributes.size() + " missing attributes");
// Try to get all missing attributes
@@ -135,8 +136,10 @@ public class AttributeCollector implements IAction {
break;
} catch (UnsupportedAttributeException e) {
// ok, try the next attributeprovider
+ Logger.info(currentProvider.getClass().getSimpleName() + " could not handle attribute '" + currentAttribute.getName() + "'");
} catch (MOAIDException e) {
// the current plugin had an error. Try the next one.
+ Logger.info(currentProvider.getClass().getSimpleName() + " could not handle attribute '" + currentAttribute.getName() + "' due to an error");
}
}
@@ -148,6 +151,7 @@ public class AttributeCollector implements IAction {
// else, update any existing attributes
addOrUpdateAll(container.getResponse().getPersonalAttributeList(), aquiredAttributes);
}
+ Logger.info("collecting attributes done");
// ask for consent if necessary
if(oaParam.isRequireConsentForStorkAttributes())
@@ -194,9 +198,9 @@ public class AttributeCollector implements IAction {
* @throws MOAIDException
*/
private void addOrUpdateAll(IPersonalAttributeList target, IPersonalAttributeList source) throws MOAIDException {
- Logger.info("Updating " + source.size() + " attribute(s)...");
+ Logger.debug("Updating " + source.size() + " attributes...");
for (PersonalAttribute current : source) {
- Logger.debug("treating " + current.getName());
+ Logger.trace("treating " + current.getName());
// check if we need to update the current pa
if (target.containsKey(current.getName())) {
@@ -213,7 +217,7 @@ public class AttributeCollector implements IAction {
} else
target.add(current);
- Logger.debug("...successfully treated " + current.getName());
+ Logger.trace("...successfully treated " + current.getName());
}
}
diff --git a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/protocols/stork2/ConsentEvaluator.java b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/protocols/stork2/ConsentEvaluator.java
index 19ec754ee..bcf086b56 100644
--- a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/protocols/stork2/ConsentEvaluator.java
+++ b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/protocols/stork2/ConsentEvaluator.java
@@ -137,6 +137,8 @@ public class ConsentEvaluator implements IAction {
public void generateSTORKResponse(HttpServletResponse httpResp, DataContainer container) throws MOAIDException {
MOASTORKRequest request = container.getRequest();
MOASTORKResponse response = container.getResponse();
+
+ Logger.info("generating stork response...");
try {
//Get SAMLEngine instance
@@ -155,8 +157,6 @@ public class ConsentEvaluator implements IAction {
throw new MOAIDException("stork.05", null);
}
- Logger.info("STORK SAML Response message succesfully generated ");
-
// preparing redirection for the client
try {
VelocityEngine velocityEngine = VelocityProvider.getClassPathVelocityEngine();
diff --git a/id/server/stork2-commons/.svn/all-wcprops b/id/server/stork2-commons/.svn/all-wcprops
new file mode 100644
index 000000000..013d868be
--- /dev/null
+++ b/id/server/stork2-commons/.svn/all-wcprops
@@ -0,0 +1,17 @@
+K 25
+svn:wc:ra_dav:version-url
+V 45
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons
+END
+pom.xml
+K 25
+svn:wc:ra_dav:version-url
+V 53
+/CITnet/svn/STORK2/!svn/ver/712/trunk/Commons/pom.xml
+END
+Releases
+K 25
+svn:wc:ra_dav:version-url
+V 54
+/CITnet/svn/STORK2/!svn/ver/712/trunk/Commons/Releases
+END
diff --git a/id/server/stork2-commons/.svn/dir-prop-base b/id/server/stork2-commons/.svn/dir-prop-base
new file mode 100644
index 000000000..9dc541cfd
--- /dev/null
+++ b/id/server/stork2-commons/.svn/dir-prop-base
@@ -0,0 +1,10 @@
+K 10
+svn:ignore
+V 44
+.classpath
+.project
+.settings
+report
+target
+
+END
diff --git a/id/server/stork2-commons/.svn/entries b/id/server/stork2-commons/.svn/entries
new file mode 100644
index 000000000..6956e0c9c
--- /dev/null
+++ b/id/server/stork2-commons/.svn/entries
@@ -0,0 +1,99 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+has-props
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+Releases
+file
+
+
+
+
+2014-03-05T09:36:08.094515Z
+5013e8d011c7d67a3faac86ae0ec7aae
+2014-03-03T15:10:40.224759Z
+712
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2653
+
+src
+dir
+
+pom.xml
+file
+
+
+
+
+2014-03-05T09:36:08.086515Z
+c245a61144c036e0dc82e0adfed566aa
+2014-03-03T15:10:40.224759Z
+712
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+5777
+
diff --git a/id/server/stork2-commons/.svn/text-base/Releases.svn-base b/id/server/stork2-commons/.svn/text-base/Releases.svn-base
new file mode 100644
index 000000000..6550affd0
--- /dev/null
+++ b/id/server/stork2-commons/.svn/text-base/Releases.svn-base
@@ -0,0 +1,73 @@
+Created 06-04-2011
+
+Branch : STORKCommons_0_5_UPDATE_06042011
+Date : 06-04-2011
+Changes: No changes.
+
+Branch : STORKCommons_0_5_UPDATE_07072011
+Date : 07-07-2011
+Changes: Inserted constants to HttpOnly HTTP Header.
+
+Branch : STORKCommons_0_6
+Date : 07-11-2011
+Changes: Improved error exception handling (few changes on the exception classes).
+ Improved Constansts (unused removed, others added).
+ Unit Tests include (almost all the code is cover).
+ Fix some minor bugs found on unit tests.
+ New Copyright License added.
+ PEPUtils refactored.
+ Improved error code message (three kind of messages: to citizen, admin and saml token).
+
+Branch : STORKCommons_0_6_1
+Date : 28-11-2011
+Changes: Removed unnecessary javadoc package file.
+ Updated pepsUtils.properties file (check attribute value had old error message)
+
+Branch : STORKCommons_0_9
+Date : 02-12-2011
+Changes: Updated Version to 0.9
+
+Branch : STORKCommons_1_0
+Date : 02-12-2011
+Changes: Updated Version to 1.0
+
+Branch : STORKCommons_1_1_0
+Date : 01-11-2013
+Changes: Updated Version to 1.1.0
+ Dependencies updated
+ Business Logic Part I changes
+ SAML Engine Changes merged (from SamlEngine/1.1.0/Commons branch to be easier to merge this branch with trunk)
+ Fixed some errors on Test Case
+
+Branch : STORKCommons_1_1_1
+Date : 02-12-2013
+Changes: Updated Version to 1.1.1
+ Added mandate error code
+ PMD quality code changes (some final identifier missing)
+ Added new methods to personal attribute list to get Mandatory/Optional and/or Simple/Complex attributes
+ Added new unit tests
+
+Branch : Commons_1_1_2
+Date : 13-12-2013
+Changes: Updated Version to 1.1.2
+ Added request flow of PV (incomplete)
+ Added AP mandatory attribute to get data for business attributes
+ *) based on configuration file it adds the missing attributes (eIdentifier, givenName, surname and dateOfBirth) or change isRequired to true.
+ changes original isRequired state in response
+ Added new Interface (IAttributeListProcessor) to make some operations on attribute lists
+
+Branch : Commons_1_1_3
+Date : 21-12-2013
+Changes: Updated Version to 1.1.3
+ Power Validation is complete now
+ Business Logic I and II integration (Request Complete!)
+
+Branch : Commons_1_1_4
+Date : 08-01-2014
+Changes: Updated Version to 1.1.4
+ Added new method to Personal attribute List to check if there is at least one attribute with no value.
+
+Branch : Commons_1_4_0
+Date : 28-02-2014
+Changes: Updated Version to 1.4.0
+ Removed AUB \ No newline at end of file
diff --git a/id/server/stork2-commons/.svn/text-base/pom.xml.svn-base b/id/server/stork2-commons/.svn/text-base/pom.xml.svn-base
new file mode 100644
index 000000000..04b35f5f5
--- /dev/null
+++ b/id/server/stork2-commons/.svn/text-base/pom.xml.svn-base
@@ -0,0 +1,213 @@
+<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>
+ <groupId>eu.stork</groupId>
+ <artifactId>Commons</artifactId>
+ <packaging>jar</packaging>
+ <name>Stork Commons</name>
+ <properties>
+ <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+ <stork.version>1.4.0</stork.version>
+ <opensaml.version>2.6.0</opensaml.version>
+ </properties>
+ <version>${stork.version}</version>
+ <description>
+ The STORKCommons library provides beans, Java Interfaces and utility classes to integrate PEPS and SAML Engine.
+ </description>
+
+ <dependencies>
+
+ <!-- Joda -->
+ <dependency>
+ <groupId>joda-time</groupId>
+ <artifactId>joda-time</artifactId>
+ <version>2.3</version>
+ </dependency>
+
+ <!-- Log4J -->
+ <dependency>
+ <groupId>log4j</groupId>
+ <artifactId>log4j</artifactId>
+ <version>1.2.17</version>
+ <exclusions>
+ <exclusion>
+ <groupId>javax.jms</groupId>
+ <artifactId>jms</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>com.sun.jdmk</groupId>
+ <artifactId>jmxtools</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>com.sun.jmx</groupId>
+ <artifactId>jmxri</artifactId>
+ </exclusion>
+ <exclusion>
+ <artifactId>mail</artifactId>
+ <groupId>javax.mail</groupId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+
+ <dependency>
+ <groupId>org.opensaml</groupId>
+ <artifactId>opensaml</artifactId>
+ <version>${opensaml.version}</version>
+ <exclusions>
+ <exclusion>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-api</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-simple</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.slf4j</groupId>
+ <artifactId>jcl-over-slf4j</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.slf4j</groupId>
+ <artifactId>log4j-over-slf4j</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.slf4j</groupId>
+ <artifactId>jul-to-slf4j</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+
+ <!-- Bouncy Castle -->
+ <dependency>
+ <groupId>org.bouncycastle</groupId>
+ <artifactId>bcprov-jdk16</artifactId>
+ <version>1.46</version>
+ </dependency>
+
+ <!-- Servlet API -->
+ <!-- provided by Application Server -->
+ <dependency>
+ <groupId>javax.servlet</groupId>
+ <artifactId>servlet-api</artifactId>
+ <version>2.5</version>
+ <scope>provided</scope>
+ </dependency>
+
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ <version>2.6</version>
+ <type>jar</type>
+ <scope>compile</scope>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <version>4.11</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <finalName>commons</finalName>
+ <pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <version>3.1</version>
+ <configuration>
+ <source>1.7</source>
+ <target>1.7</target>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <runOrder>reversealphabetical</runOrder>
+ <skip>false</skip>
+ <includes>
+ <runOrder>reversealphabetical</runOrder>
+ <include>**/PEPSUtilTest.java</include>
+ <include>**/PersonalAttributeTestCase.java</include>
+ <include>**/PersonalAttributeListTestCase.java</include>
+ <include>**/DateUtilTestCase.java</include>
+ <include>**/AttributeUtilTest.java</include>
+ </includes>
+ </configuration>
+ </plugin>
+ </plugins>
+ </pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-javadoc-plugin</artifactId>
+ <version>2.9.1</version>
+ <configuration>
+ <links>
+ <link>http://commons.apache.org/lang/api/</link>
+ <link>http://java.sun.com/j2se/1.6.0/docs/api/</link>
+ <link>http://www.bouncycastle.org/docs/docs1.6/</link>
+ <link>http://docs.oracle.com/javase/6/docs/api/</link>
+ </links>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-source-plugin</artifactId>
+ <version>2.2.1</version>
+ <executions>
+ <execution>
+ <id>attach-sources</id>
+ <phase>verify</phase>
+ <goals>
+ <goal>jar-no-fork</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ <testResources>
+ <testResource>
+ <directory>src/test/resources</directory>
+ <includes>
+ <include>log4j.xml</include>
+ </includes>
+ </testResource>
+ </testResources>
+ </build>
+ <profiles>
+ <profile>
+ <id>embedded</id>
+ <build>
+ <resources>
+ <resource>
+ <directory> ${project.basedir}/src/main/resources</directory>
+ </resource>
+ <resource>
+ <directory> ${project.basedir}/src/main/config/embedded</directory>
+ </resource>
+ </resources>
+ </build>
+ </profile>
+ <profile>
+ <id>metrics</id>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>cobertura-maven-plugin</artifactId>
+ <version>2.5.1</version>
+ <configuration>
+ <formats>
+ <format>html</format>
+ <format>xml</format>
+ </formats>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ </profiles>
+</project>
diff --git a/id/server/stork2-commons/Releases b/id/server/stork2-commons/Releases
new file mode 100644
index 000000000..6550affd0
--- /dev/null
+++ b/id/server/stork2-commons/Releases
@@ -0,0 +1,73 @@
+Created 06-04-2011
+
+Branch : STORKCommons_0_5_UPDATE_06042011
+Date : 06-04-2011
+Changes: No changes.
+
+Branch : STORKCommons_0_5_UPDATE_07072011
+Date : 07-07-2011
+Changes: Inserted constants to HttpOnly HTTP Header.
+
+Branch : STORKCommons_0_6
+Date : 07-11-2011
+Changes: Improved error exception handling (few changes on the exception classes).
+ Improved Constansts (unused removed, others added).
+ Unit Tests include (almost all the code is cover).
+ Fix some minor bugs found on unit tests.
+ New Copyright License added.
+ PEPUtils refactored.
+ Improved error code message (three kind of messages: to citizen, admin and saml token).
+
+Branch : STORKCommons_0_6_1
+Date : 28-11-2011
+Changes: Removed unnecessary javadoc package file.
+ Updated pepsUtils.properties file (check attribute value had old error message)
+
+Branch : STORKCommons_0_9
+Date : 02-12-2011
+Changes: Updated Version to 0.9
+
+Branch : STORKCommons_1_0
+Date : 02-12-2011
+Changes: Updated Version to 1.0
+
+Branch : STORKCommons_1_1_0
+Date : 01-11-2013
+Changes: Updated Version to 1.1.0
+ Dependencies updated
+ Business Logic Part I changes
+ SAML Engine Changes merged (from SamlEngine/1.1.0/Commons branch to be easier to merge this branch with trunk)
+ Fixed some errors on Test Case
+
+Branch : STORKCommons_1_1_1
+Date : 02-12-2013
+Changes: Updated Version to 1.1.1
+ Added mandate error code
+ PMD quality code changes (some final identifier missing)
+ Added new methods to personal attribute list to get Mandatory/Optional and/or Simple/Complex attributes
+ Added new unit tests
+
+Branch : Commons_1_1_2
+Date : 13-12-2013
+Changes: Updated Version to 1.1.2
+ Added request flow of PV (incomplete)
+ Added AP mandatory attribute to get data for business attributes
+ *) based on configuration file it adds the missing attributes (eIdentifier, givenName, surname and dateOfBirth) or change isRequired to true.
+ changes original isRequired state in response
+ Added new Interface (IAttributeListProcessor) to make some operations on attribute lists
+
+Branch : Commons_1_1_3
+Date : 21-12-2013
+Changes: Updated Version to 1.1.3
+ Power Validation is complete now
+ Business Logic I and II integration (Request Complete!)
+
+Branch : Commons_1_1_4
+Date : 08-01-2014
+Changes: Updated Version to 1.1.4
+ Added new method to Personal attribute List to check if there is at least one attribute with no value.
+
+Branch : Commons_1_4_0
+Date : 28-02-2014
+Changes: Updated Version to 1.4.0
+ Removed AUB \ No newline at end of file
diff --git a/id/server/stork2-commons/pom.xml b/id/server/stork2-commons/pom.xml
new file mode 100644
index 000000000..04b35f5f5
--- /dev/null
+++ b/id/server/stork2-commons/pom.xml
@@ -0,0 +1,213 @@
+<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>
+ <groupId>eu.stork</groupId>
+ <artifactId>Commons</artifactId>
+ <packaging>jar</packaging>
+ <name>Stork Commons</name>
+ <properties>
+ <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+ <stork.version>1.4.0</stork.version>
+ <opensaml.version>2.6.0</opensaml.version>
+ </properties>
+ <version>${stork.version}</version>
+ <description>
+ The STORKCommons library provides beans, Java Interfaces and utility classes to integrate PEPS and SAML Engine.
+ </description>
+
+ <dependencies>
+
+ <!-- Joda -->
+ <dependency>
+ <groupId>joda-time</groupId>
+ <artifactId>joda-time</artifactId>
+ <version>2.3</version>
+ </dependency>
+
+ <!-- Log4J -->
+ <dependency>
+ <groupId>log4j</groupId>
+ <artifactId>log4j</artifactId>
+ <version>1.2.17</version>
+ <exclusions>
+ <exclusion>
+ <groupId>javax.jms</groupId>
+ <artifactId>jms</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>com.sun.jdmk</groupId>
+ <artifactId>jmxtools</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>com.sun.jmx</groupId>
+ <artifactId>jmxri</artifactId>
+ </exclusion>
+ <exclusion>
+ <artifactId>mail</artifactId>
+ <groupId>javax.mail</groupId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+
+ <dependency>
+ <groupId>org.opensaml</groupId>
+ <artifactId>opensaml</artifactId>
+ <version>${opensaml.version}</version>
+ <exclusions>
+ <exclusion>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-api</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-simple</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.slf4j</groupId>
+ <artifactId>jcl-over-slf4j</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.slf4j</groupId>
+ <artifactId>log4j-over-slf4j</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.slf4j</groupId>
+ <artifactId>jul-to-slf4j</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+
+ <!-- Bouncy Castle -->
+ <dependency>
+ <groupId>org.bouncycastle</groupId>
+ <artifactId>bcprov-jdk16</artifactId>
+ <version>1.46</version>
+ </dependency>
+
+ <!-- Servlet API -->
+ <!-- provided by Application Server -->
+ <dependency>
+ <groupId>javax.servlet</groupId>
+ <artifactId>servlet-api</artifactId>
+ <version>2.5</version>
+ <scope>provided</scope>
+ </dependency>
+
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ <version>2.6</version>
+ <type>jar</type>
+ <scope>compile</scope>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <version>4.11</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <finalName>commons</finalName>
+ <pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <version>3.1</version>
+ <configuration>
+ <source>1.7</source>
+ <target>1.7</target>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <runOrder>reversealphabetical</runOrder>
+ <skip>false</skip>
+ <includes>
+ <runOrder>reversealphabetical</runOrder>
+ <include>**/PEPSUtilTest.java</include>
+ <include>**/PersonalAttributeTestCase.java</include>
+ <include>**/PersonalAttributeListTestCase.java</include>
+ <include>**/DateUtilTestCase.java</include>
+ <include>**/AttributeUtilTest.java</include>
+ </includes>
+ </configuration>
+ </plugin>
+ </plugins>
+ </pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-javadoc-plugin</artifactId>
+ <version>2.9.1</version>
+ <configuration>
+ <links>
+ <link>http://commons.apache.org/lang/api/</link>
+ <link>http://java.sun.com/j2se/1.6.0/docs/api/</link>
+ <link>http://www.bouncycastle.org/docs/docs1.6/</link>
+ <link>http://docs.oracle.com/javase/6/docs/api/</link>
+ </links>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-source-plugin</artifactId>
+ <version>2.2.1</version>
+ <executions>
+ <execution>
+ <id>attach-sources</id>
+ <phase>verify</phase>
+ <goals>
+ <goal>jar-no-fork</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ <testResources>
+ <testResource>
+ <directory>src/test/resources</directory>
+ <includes>
+ <include>log4j.xml</include>
+ </includes>
+ </testResource>
+ </testResources>
+ </build>
+ <profiles>
+ <profile>
+ <id>embedded</id>
+ <build>
+ <resources>
+ <resource>
+ <directory> ${project.basedir}/src/main/resources</directory>
+ </resource>
+ <resource>
+ <directory> ${project.basedir}/src/main/config/embedded</directory>
+ </resource>
+ </resources>
+ </build>
+ </profile>
+ <profile>
+ <id>metrics</id>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>cobertura-maven-plugin</artifactId>
+ <version>2.5.1</version>
+ <configuration>
+ <formats>
+ <format>html</format>
+ <format>xml</format>
+ </formats>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ </profiles>
+</project>
diff --git a/id/server/stork2-commons/src/.svn/all-wcprops b/id/server/stork2-commons/src/.svn/all-wcprops
new file mode 100644
index 000000000..b2a57db4c
--- /dev/null
+++ b/id/server/stork2-commons/src/.svn/all-wcprops
@@ -0,0 +1,5 @@
+K 25
+svn:wc:ra_dav:version-url
+V 49
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src
+END
diff --git a/id/server/stork2-commons/src/.svn/entries b/id/server/stork2-commons/src/.svn/entries
new file mode 100644
index 000000000..35f74102a
--- /dev/null
+++ b/id/server/stork2-commons/src/.svn/entries
@@ -0,0 +1,34 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+test
+dir
+
+main
+dir
+
diff --git a/id/server/stork2-commons/src/main/.svn/all-wcprops b/id/server/stork2-commons/src/main/.svn/all-wcprops
new file mode 100644
index 000000000..ca1ee03bd
--- /dev/null
+++ b/id/server/stork2-commons/src/main/.svn/all-wcprops
@@ -0,0 +1,5 @@
+K 25
+svn:wc:ra_dav:version-url
+V 54
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main
+END
diff --git a/id/server/stork2-commons/src/main/.svn/entries b/id/server/stork2-commons/src/main/.svn/entries
new file mode 100644
index 000000000..76ff91c7b
--- /dev/null
+++ b/id/server/stork2-commons/src/main/.svn/entries
@@ -0,0 +1,37 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/main
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+resources
+dir
+
+java
+dir
+
+config
+dir
+
diff --git a/id/server/stork2-commons/src/main/config/.svn/all-wcprops b/id/server/stork2-commons/src/main/config/.svn/all-wcprops
new file mode 100644
index 000000000..e39a1da21
--- /dev/null
+++ b/id/server/stork2-commons/src/main/config/.svn/all-wcprops
@@ -0,0 +1,5 @@
+K 25
+svn:wc:ra_dav:version-url
+V 61
+/CITnet/svn/STORK2/!svn/ver/712/trunk/Commons/src/main/config
+END
diff --git a/id/server/stork2-commons/src/main/config/.svn/entries b/id/server/stork2-commons/src/main/config/.svn/entries
new file mode 100644
index 000000000..9a3950062
--- /dev/null
+++ b/id/server/stork2-commons/src/main/config/.svn/entries
@@ -0,0 +1,31 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/main/config
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-03T15:10:40.224759Z
+712
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+embedded
+dir
+
diff --git a/id/server/stork2-commons/src/main/config/embedded/.svn/all-wcprops b/id/server/stork2-commons/src/main/config/embedded/.svn/all-wcprops
new file mode 100644
index 000000000..61c832a4b
--- /dev/null
+++ b/id/server/stork2-commons/src/main/config/embedded/.svn/all-wcprops
@@ -0,0 +1,11 @@
+K 25
+svn:wc:ra_dav:version-url
+V 70
+/CITnet/svn/STORK2/!svn/ver/712/trunk/Commons/src/main/config/embedded
+END
+pepsUtil.properties
+K 25
+svn:wc:ra_dav:version-url
+V 90
+/CITnet/svn/STORK2/!svn/ver/712/trunk/Commons/src/main/config/embedded/pepsUtil.properties
+END
diff --git a/id/server/stork2-commons/src/main/config/embedded/.svn/entries b/id/server/stork2-commons/src/main/config/embedded/.svn/entries
new file mode 100644
index 000000000..3dcc1bccf
--- /dev/null
+++ b/id/server/stork2-commons/src/main/config/embedded/.svn/entries
@@ -0,0 +1,62 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/main/config/embedded
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-03T15:10:40.224759Z
+712
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+pepsUtil.properties
+file
+
+
+
+
+2014-03-05T09:36:08.010515Z
+2d984e7eb1a7f6c6ba7048f46b85920b
+2014-03-03T15:10:40.224759Z
+712
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+7885
+
diff --git a/id/server/stork2-commons/src/main/config/embedded/.svn/text-base/pepsUtil.properties.svn-base b/id/server/stork2-commons/src/main/config/embedded/.svn/text-base/pepsUtil.properties.svn-base
new file mode 100644
index 000000000..ae811dda7
--- /dev/null
+++ b/id/server/stork2-commons/src/main/config/embedded/.svn/text-base/pepsUtil.properties.svn-base
@@ -0,0 +1,269 @@
+#Max allowed params size
+validation.active=true
+max.spUrl.size=150
+max.attrList.size=20000
+max.invalidAttributeList.size=20000
+max.attrName.size=100
+max.callback.size=300
+max.idp.url.size=300
+max.atp.url.size=300
+max.cpepsURL.size=300
+max.attrValue.size=20000
+max.attrType.size=25
+max.spId.size=40
+max.providerName.size=128
+max.spName.size=25
+max.country.size=150
+max.qaaLevel.size=1
+max.spQaaLevel.size=1
+max.errorCode.size=5
+max.errorMessage.size=300
+max.username.size=30
+max.spepsRedirectUrl.size=300
+max.speps.redirectUrl.size=300
+max.cpeps.redirectUrl.size=300
+max.cpepsRedirectUrl.size=300
+max.spepsAssertionUrl.size=300
+max.SAMLRequest.size=131072
+max.SAMLResponse.size=131072
+max.RelayState.size=80
+max.remoteAddr.size=300
+max.remoteHost.size=300
+max.localAddr.size=300
+max.localName.size=300
+max.apepsUrl.size=300
+max.apeps.callbackUrl.size=300
+
+dtl.url=http://localhost:8080/DocumentService/DocumentService
+
+#ERROR codes/messages (accordingly to specification)
+
+#CountrySelector Interface errors
+spCountrySelector.invalidSPQAA.code=0000001
+spCountrySelector.invalidSPQAA.message=invalid.spQAA.parameter
+
+spCountrySelector.invalidQaaSPid.code=0000001
+spCountrySelector.invalidQaaSPid.message=invalid.spQAAId.parameter
+
+spCountrySelector.invalidSpId.code=000002
+spCountrySelector.invalidSpId.message=invalid.spId.parameter
+
+spCountrySelector.invalidSpURL.code=000003
+spCountrySelector.invalidSpURL.message=invalid.spUrl.parameter
+
+domain.CountrySelectorAction.code=000003
+domain.CountrySelectorAction.message=invalid.cs.domain
+
+requests.CountrySelectorAction.code=000004
+requests.CountrySelectorAction.message=reached.max.requests.cs
+
+spCountrySelector.spNotAllowed.code=000006
+spCountrySelector.spNotAllowed.message=attr.access.deny
+
+spCountrySelector.invalidAttr.code=000007
+spCountrySelector.invalidAttr.message=invalid.spAttr.parameter
+
+spCountrySelector.invalidProviderName.code=000008
+spCountrySelector.invalidProviderName.message=invalid.spProvidername.parameter
+
+spCountrySelector.errorCreatingSAML.code=203001
+spCountrySelector.errorCreatingSAML.message=error.create.sp.saml
+
+spepsSAMLRequest.code=203001
+spepsSAMLRequest.message=error.create.saml.speps
+
+#ServiceProvider Interface errors
+sProviderAction.invalidSPQAA.code=200001
+sProviderAction.invalidSPQAA.message=invalid.sp.qaa
+
+sProviderAction.invalidSPQAAId.code=200001
+sProviderAction.invalidSPQAAId.message=invalid.sp.qaaid
+
+sProviderAction.invalidSPId.code=200002
+sProviderAction.invalidSPId.message=invalid.sp.id
+
+domain.ServiceProviderAction.code=200003
+domain.ServiceProviderAction.message=invalid.sp.domain
+
+sProviderAction.invalidSPDomain.code=200003
+sProviderAction.invalidSPDomain.message=invalid.sp.domain
+
+sProviderAction.invalidCountry.code=200004
+sProviderAction.invalidCountry.message=invalid.sp.country
+
+sProviderAction.spNotAllowed.code=200005
+sProviderAction.spNotAllowed.message=sp.not.allowed
+
+sProviderAction.invalidSaml.code=200006
+sProviderAction.invalidSaml.message=invalid.sp.samlrequest
+
+sProviderAction.invalidSPProviderName.code=200007
+sProviderAction.invalidSPProviderName.message=sp.not.identified
+
+sProviderAction.invalidSPRedirect.code=200008
+sProviderAction.invalidSPRedirect.message=invalid.sp.redirectUrl
+
+sProviderAction.invalidRelayState.code=200009
+sProviderAction.invalidRelayState.message=invalid.sp.relaystate
+
+sProviderAction.invalidAttr.code=200011
+sProviderAction.invalidAttr.message=invalid.sp.attr
+
+requests.ServiceProviderAction.code=200012
+requests.ServiceProviderAction.message=reached.max.requests.sp
+
+sPPowerValidationAction.invalidSPPVAttrList.code=200013
+sPPowerValidationAction.invalidSPPVAttrList.message=invalid.sp.pv.attrlist
+
+invalid.sp.pv.attrlist.code=200013
+invalid.sp.pv.attrlist.message=invalid.sp.pv.attrlist
+
+sProviderAction.invalidSPAlias.code=203003
+sProviderAction.invalidSPAlias.message=invalid.sp.alias
+
+sProviderAction.errorCreatingSAML.code=203001
+sProviderAction.errorCreatingSAML.message=error.create.saml.speps
+
+#Internal Error
+internalError.code=203001
+internalError.message=internalError
+
+attrList.code=202005
+attrList.message=invalid.attrList.parameter
+
+missing.sessionId.code=203010
+missing.sessionId.message=missing.session.id
+
+sessionError.code=203011
+sessionError.message=invalid.session.id
+
+invalid.sessionId.code=203011
+invalid.sessionId.message=invalid.session.id
+
+missing.mandate.code=203013
+missing.mandate.message=missing.mandate
+
+invalid.session.code=203012
+invalid.session.message=invalid.session
+
+callback.code=203006
+callback.message=invalid.callback.url
+
+idp.url.code=203006
+idp.url.message=invalid.idp.url
+
+IdPSAMLResponse.code=002001
+IdPSAMLResponse.message=invalid.idp.response
+
+authenticationFailed.code=003002
+authenticationFailed.message=authentication.failed
+
+username.code=003002
+username.message=authentication.failed
+
+invalidAttributeList.code=203001
+invalidAttributeList.message=invalid.attrlist
+
+invalidAttributeValue.code=203001
+invalidAttributeValue.message=invalid.attr.value
+
+attVerification.mandatory.code=202010
+attVerification.mandatory.message=missing.mandatory.attr
+
+attrValue.verification.code=203008
+attrValue.verification.message=invalid.stork.attrValue
+
+cpepsSAMLResponse.code=202012
+cpepsSAMLResponse.message=error.gen.cpeps.saml
+
+AtPSAMLResponse.code=202009
+AtPSAMLResponse.message=error.gen.atp.saml
+
+atp.url.code=203006
+atp.url.message=invalid.atp.url
+
+hash.error.code=203001
+hash.error.message=error.hash
+
+qaaLevel.code=203006
+qaaLevel.message=invalid.cpeps.qaalevel
+
+SAMLRequest.code=203001
+SAMLRequest.message=invalid.SAMLRequest
+
+atp.response.error.code=202011
+atp.response.error.message=atp.response.error
+
+#Colleague Request Interface errors
+
+colleagueRequest.invalidSAML.code=201002
+colleagueRequest.invalidSAML.message=invalid.speps.samlrequest
+
+colleagueRequest.invalidCountryCode.code=002001
+colleagueRequest.invalidCountryCode.message=country.cpeps.nomatch
+
+colleagueRequest.errorCreatingSAML.code=203001
+colleagueRequest.errorCreatingSAML.message=error.create.saml.cpeps
+
+colleagueRequest.invalidQaa.code=202004
+colleagueRequest.invalidQaa.message=invalid.requested.cpeps.qaalevel
+
+colleagueRequest.attrNull.code=202005
+colleagueRequest.attrNull.message=invalid.requested.attrlist.cpeps
+
+colleaguePVRequest.invalidPVAttrList.code=202013
+colleaguePVRequest.invalidPVAttrList.message=invalid.speps.pv.attrlist
+
+colleagueRequest.invalidRedirect.code=202001
+colleagueRequest.invalidRedirect.message=invalid.redirecturl.cpeps
+
+colleagueRequest.invalidDestUrl.code=203006
+colleagueRequest.invalidDestUrl.message=invalid.cpeps.destUrl
+
+cpepsRedirectUrl.code=203006
+cpepsRedirectUrl.message=invalid.cpeps.redirectUrl
+
+#Citizen Consent Interfaces errors
+
+citizenResponse.mandatory.code=202007
+citizenResponse.mandatory.message=no.consent.mand.attr
+
+cPeps.attrNull.code=202005
+cPeps.attrNull.message=invalid.attrList.cpeps
+
+citizenNoConsent.mandatory.code=202012
+citizenNoConsent.mandatory.message=no.consent.val.mand.attr
+
+#Colleague Response Interface errors
+
+colleagueResponse.invalidSAML.code=202002
+colleagueResponse.invalidSAML.message=invalid.cpeps.samlresp
+
+auRequestIdError.code=201005
+auRequestIdError.message=invalid.speps.saml.id
+
+audienceRestrictionError.code=201004
+audienceRestrictionError.message=speps.saml.condition.notmet
+
+spepsSAMLResponse.code=200010
+spepsSAMLResponse.message=error.gen.speps.saml
+
+
+invalid.apepsRedirectUrl.code=001001
+invalid.apepsRedirectUrl.message=invalid.apeps.redirectUrl
+
+apepsSAMLRequest.code=001002
+apepsSAMLRequest.message=invalid.apeps.saml.request
+
+apepsSAMLResponse.code=001003
+apepsSAMLResponse.message=invalid.apeps.saml.response
+
+invalid.apepsCallbackUrl.code=001004
+invalid.apepsCallbackUrl.message=invalid.apeps.callback.url
+
+colleagueAttributeRequest.invalidSAML.code=001005
+colleagueAttributeRequest.invalidSAML.message=invalid.attr.request.saml
+
+
+#Hash Digests
+hashDigest.className=org.bouncycastle.crypto.digests.SHA512Digest
diff --git a/id/server/stork2-commons/src/main/config/embedded/pepsUtil.properties b/id/server/stork2-commons/src/main/config/embedded/pepsUtil.properties
new file mode 100644
index 000000000..ae811dda7
--- /dev/null
+++ b/id/server/stork2-commons/src/main/config/embedded/pepsUtil.properties
@@ -0,0 +1,269 @@
+#Max allowed params size
+validation.active=true
+max.spUrl.size=150
+max.attrList.size=20000
+max.invalidAttributeList.size=20000
+max.attrName.size=100
+max.callback.size=300
+max.idp.url.size=300
+max.atp.url.size=300
+max.cpepsURL.size=300
+max.attrValue.size=20000
+max.attrType.size=25
+max.spId.size=40
+max.providerName.size=128
+max.spName.size=25
+max.country.size=150
+max.qaaLevel.size=1
+max.spQaaLevel.size=1
+max.errorCode.size=5
+max.errorMessage.size=300
+max.username.size=30
+max.spepsRedirectUrl.size=300
+max.speps.redirectUrl.size=300
+max.cpeps.redirectUrl.size=300
+max.cpepsRedirectUrl.size=300
+max.spepsAssertionUrl.size=300
+max.SAMLRequest.size=131072
+max.SAMLResponse.size=131072
+max.RelayState.size=80
+max.remoteAddr.size=300
+max.remoteHost.size=300
+max.localAddr.size=300
+max.localName.size=300
+max.apepsUrl.size=300
+max.apeps.callbackUrl.size=300
+
+dtl.url=http://localhost:8080/DocumentService/DocumentService
+
+#ERROR codes/messages (accordingly to specification)
+
+#CountrySelector Interface errors
+spCountrySelector.invalidSPQAA.code=0000001
+spCountrySelector.invalidSPQAA.message=invalid.spQAA.parameter
+
+spCountrySelector.invalidQaaSPid.code=0000001
+spCountrySelector.invalidQaaSPid.message=invalid.spQAAId.parameter
+
+spCountrySelector.invalidSpId.code=000002
+spCountrySelector.invalidSpId.message=invalid.spId.parameter
+
+spCountrySelector.invalidSpURL.code=000003
+spCountrySelector.invalidSpURL.message=invalid.spUrl.parameter
+
+domain.CountrySelectorAction.code=000003
+domain.CountrySelectorAction.message=invalid.cs.domain
+
+requests.CountrySelectorAction.code=000004
+requests.CountrySelectorAction.message=reached.max.requests.cs
+
+spCountrySelector.spNotAllowed.code=000006
+spCountrySelector.spNotAllowed.message=attr.access.deny
+
+spCountrySelector.invalidAttr.code=000007
+spCountrySelector.invalidAttr.message=invalid.spAttr.parameter
+
+spCountrySelector.invalidProviderName.code=000008
+spCountrySelector.invalidProviderName.message=invalid.spProvidername.parameter
+
+spCountrySelector.errorCreatingSAML.code=203001
+spCountrySelector.errorCreatingSAML.message=error.create.sp.saml
+
+spepsSAMLRequest.code=203001
+spepsSAMLRequest.message=error.create.saml.speps
+
+#ServiceProvider Interface errors
+sProviderAction.invalidSPQAA.code=200001
+sProviderAction.invalidSPQAA.message=invalid.sp.qaa
+
+sProviderAction.invalidSPQAAId.code=200001
+sProviderAction.invalidSPQAAId.message=invalid.sp.qaaid
+
+sProviderAction.invalidSPId.code=200002
+sProviderAction.invalidSPId.message=invalid.sp.id
+
+domain.ServiceProviderAction.code=200003
+domain.ServiceProviderAction.message=invalid.sp.domain
+
+sProviderAction.invalidSPDomain.code=200003
+sProviderAction.invalidSPDomain.message=invalid.sp.domain
+
+sProviderAction.invalidCountry.code=200004
+sProviderAction.invalidCountry.message=invalid.sp.country
+
+sProviderAction.spNotAllowed.code=200005
+sProviderAction.spNotAllowed.message=sp.not.allowed
+
+sProviderAction.invalidSaml.code=200006
+sProviderAction.invalidSaml.message=invalid.sp.samlrequest
+
+sProviderAction.invalidSPProviderName.code=200007
+sProviderAction.invalidSPProviderName.message=sp.not.identified
+
+sProviderAction.invalidSPRedirect.code=200008
+sProviderAction.invalidSPRedirect.message=invalid.sp.redirectUrl
+
+sProviderAction.invalidRelayState.code=200009
+sProviderAction.invalidRelayState.message=invalid.sp.relaystate
+
+sProviderAction.invalidAttr.code=200011
+sProviderAction.invalidAttr.message=invalid.sp.attr
+
+requests.ServiceProviderAction.code=200012
+requests.ServiceProviderAction.message=reached.max.requests.sp
+
+sPPowerValidationAction.invalidSPPVAttrList.code=200013
+sPPowerValidationAction.invalidSPPVAttrList.message=invalid.sp.pv.attrlist
+
+invalid.sp.pv.attrlist.code=200013
+invalid.sp.pv.attrlist.message=invalid.sp.pv.attrlist
+
+sProviderAction.invalidSPAlias.code=203003
+sProviderAction.invalidSPAlias.message=invalid.sp.alias
+
+sProviderAction.errorCreatingSAML.code=203001
+sProviderAction.errorCreatingSAML.message=error.create.saml.speps
+
+#Internal Error
+internalError.code=203001
+internalError.message=internalError
+
+attrList.code=202005
+attrList.message=invalid.attrList.parameter
+
+missing.sessionId.code=203010
+missing.sessionId.message=missing.session.id
+
+sessionError.code=203011
+sessionError.message=invalid.session.id
+
+invalid.sessionId.code=203011
+invalid.sessionId.message=invalid.session.id
+
+missing.mandate.code=203013
+missing.mandate.message=missing.mandate
+
+invalid.session.code=203012
+invalid.session.message=invalid.session
+
+callback.code=203006
+callback.message=invalid.callback.url
+
+idp.url.code=203006
+idp.url.message=invalid.idp.url
+
+IdPSAMLResponse.code=002001
+IdPSAMLResponse.message=invalid.idp.response
+
+authenticationFailed.code=003002
+authenticationFailed.message=authentication.failed
+
+username.code=003002
+username.message=authentication.failed
+
+invalidAttributeList.code=203001
+invalidAttributeList.message=invalid.attrlist
+
+invalidAttributeValue.code=203001
+invalidAttributeValue.message=invalid.attr.value
+
+attVerification.mandatory.code=202010
+attVerification.mandatory.message=missing.mandatory.attr
+
+attrValue.verification.code=203008
+attrValue.verification.message=invalid.stork.attrValue
+
+cpepsSAMLResponse.code=202012
+cpepsSAMLResponse.message=error.gen.cpeps.saml
+
+AtPSAMLResponse.code=202009
+AtPSAMLResponse.message=error.gen.atp.saml
+
+atp.url.code=203006
+atp.url.message=invalid.atp.url
+
+hash.error.code=203001
+hash.error.message=error.hash
+
+qaaLevel.code=203006
+qaaLevel.message=invalid.cpeps.qaalevel
+
+SAMLRequest.code=203001
+SAMLRequest.message=invalid.SAMLRequest
+
+atp.response.error.code=202011
+atp.response.error.message=atp.response.error
+
+#Colleague Request Interface errors
+
+colleagueRequest.invalidSAML.code=201002
+colleagueRequest.invalidSAML.message=invalid.speps.samlrequest
+
+colleagueRequest.invalidCountryCode.code=002001
+colleagueRequest.invalidCountryCode.message=country.cpeps.nomatch
+
+colleagueRequest.errorCreatingSAML.code=203001
+colleagueRequest.errorCreatingSAML.message=error.create.saml.cpeps
+
+colleagueRequest.invalidQaa.code=202004
+colleagueRequest.invalidQaa.message=invalid.requested.cpeps.qaalevel
+
+colleagueRequest.attrNull.code=202005
+colleagueRequest.attrNull.message=invalid.requested.attrlist.cpeps
+
+colleaguePVRequest.invalidPVAttrList.code=202013
+colleaguePVRequest.invalidPVAttrList.message=invalid.speps.pv.attrlist
+
+colleagueRequest.invalidRedirect.code=202001
+colleagueRequest.invalidRedirect.message=invalid.redirecturl.cpeps
+
+colleagueRequest.invalidDestUrl.code=203006
+colleagueRequest.invalidDestUrl.message=invalid.cpeps.destUrl
+
+cpepsRedirectUrl.code=203006
+cpepsRedirectUrl.message=invalid.cpeps.redirectUrl
+
+#Citizen Consent Interfaces errors
+
+citizenResponse.mandatory.code=202007
+citizenResponse.mandatory.message=no.consent.mand.attr
+
+cPeps.attrNull.code=202005
+cPeps.attrNull.message=invalid.attrList.cpeps
+
+citizenNoConsent.mandatory.code=202012
+citizenNoConsent.mandatory.message=no.consent.val.mand.attr
+
+#Colleague Response Interface errors
+
+colleagueResponse.invalidSAML.code=202002
+colleagueResponse.invalidSAML.message=invalid.cpeps.samlresp
+
+auRequestIdError.code=201005
+auRequestIdError.message=invalid.speps.saml.id
+
+audienceRestrictionError.code=201004
+audienceRestrictionError.message=speps.saml.condition.notmet
+
+spepsSAMLResponse.code=200010
+spepsSAMLResponse.message=error.gen.speps.saml
+
+
+invalid.apepsRedirectUrl.code=001001
+invalid.apepsRedirectUrl.message=invalid.apeps.redirectUrl
+
+apepsSAMLRequest.code=001002
+apepsSAMLRequest.message=invalid.apeps.saml.request
+
+apepsSAMLResponse.code=001003
+apepsSAMLResponse.message=invalid.apeps.saml.response
+
+invalid.apepsCallbackUrl.code=001004
+invalid.apepsCallbackUrl.message=invalid.apeps.callback.url
+
+colleagueAttributeRequest.invalidSAML.code=001005
+colleagueAttributeRequest.invalidSAML.message=invalid.attr.request.saml
+
+
+#Hash Digests
+hashDigest.className=org.bouncycastle.crypto.digests.SHA512Digest
diff --git a/id/server/stork2-commons/src/main/java/.svn/all-wcprops b/id/server/stork2-commons/src/main/java/.svn/all-wcprops
new file mode 100644
index 000000000..ca59ad1e3
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/.svn/all-wcprops
@@ -0,0 +1,5 @@
+K 25
+svn:wc:ra_dav:version-url
+V 59
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java
+END
diff --git a/id/server/stork2-commons/src/main/java/.svn/entries b/id/server/stork2-commons/src/main/java/.svn/entries
new file mode 100644
index 000000000..ff9dfce64
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/.svn/entries
@@ -0,0 +1,31 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/main/java
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+eu
+dir
+
diff --git a/id/server/stork2-commons/src/main/java/eu/.svn/all-wcprops b/id/server/stork2-commons/src/main/java/eu/.svn/all-wcprops
new file mode 100644
index 000000000..30e4698c0
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/.svn/all-wcprops
@@ -0,0 +1,5 @@
+K 25
+svn:wc:ra_dav:version-url
+V 62
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu
+END
diff --git a/id/server/stork2-commons/src/main/java/eu/.svn/entries b/id/server/stork2-commons/src/main/java/eu/.svn/entries
new file mode 100644
index 000000000..4c0ceff03
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/.svn/entries
@@ -0,0 +1,31 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/main/java/eu
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+stork
+dir
+
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/.svn/all-wcprops b/id/server/stork2-commons/src/main/java/eu/stork/.svn/all-wcprops
new file mode 100644
index 000000000..8e248afa5
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/.svn/all-wcprops
@@ -0,0 +1,5 @@
+K 25
+svn:wc:ra_dav:version-url
+V 68
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork
+END
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/.svn/entries b/id/server/stork2-commons/src/main/java/eu/stork/.svn/entries
new file mode 100644
index 000000000..ff2fa64d7
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/.svn/entries
@@ -0,0 +1,31 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/main/java/eu/stork
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+peps
+dir
+
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/.svn/all-wcprops b/id/server/stork2-commons/src/main/java/eu/stork/peps/.svn/all-wcprops
new file mode 100644
index 000000000..da872cf08
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/.svn/all-wcprops
@@ -0,0 +1,5 @@
+K 25
+svn:wc:ra_dav:version-url
+V 73
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps
+END
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/.svn/entries b/id/server/stork2-commons/src/main/java/eu/stork/peps/.svn/entries
new file mode 100644
index 000000000..f0c47a6d2
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/.svn/entries
@@ -0,0 +1,34 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/main/java/eu/stork/peps
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+auth
+dir
+
+complex
+dir
+
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/.svn/all-wcprops b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/.svn/all-wcprops
new file mode 100644
index 000000000..78e9d344c
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/.svn/all-wcprops
@@ -0,0 +1,5 @@
+K 25
+svn:wc:ra_dav:version-url
+V 78
+/CITnet/svn/STORK2/!svn/ver/712/trunk/Commons/src/main/java/eu/stork/peps/auth
+END
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/.svn/entries b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/.svn/entries
new file mode 100644
index 000000000..253bfd218
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/.svn/entries
@@ -0,0 +1,34 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/main/java/eu/stork/peps/auth
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-03T15:10:40.224759Z
+712
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+specific
+dir
+
+commons
+dir
+
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/all-wcprops b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/all-wcprops
new file mode 100644
index 000000000..edb1120b5
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/all-wcprops
@@ -0,0 +1,191 @@
+K 25
+svn:wc:ra_dav:version-url
+V 86
+/CITnet/svn/STORK2/!svn/ver/712/trunk/Commons/src/main/java/eu/stork/peps/auth/commons
+END
+AttributeSource.java
+K 25
+svn:wc:ra_dav:version-url
+V 107
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/AttributeSource.java
+END
+package-info.java
+K 25
+svn:wc:ra_dav:version-url
+V 103
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/package-info.java
+END
+PEPSValues.java
+K 25
+svn:wc:ra_dav:version-url
+V 102
+/CITnet/svn/STORK2/!svn/ver/712/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/PEPSValues.java
+END
+STORKAttrQueryRequest.java
+K 25
+svn:wc:ra_dav:version-url
+V 113
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/STORKAttrQueryRequest.java
+END
+CitizenConsent.java
+K 25
+svn:wc:ra_dav:version-url
+V 106
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/CitizenConsent.java
+END
+AttributeProvidersMap.java
+K 25
+svn:wc:ra_dav:version-url
+V 113
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/AttributeProvidersMap.java
+END
+STORKAttrQueryResponse.java
+K 25
+svn:wc:ra_dav:version-url
+V 114
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/STORKAttrQueryResponse.java
+END
+PersonalAttributeList.java
+K 25
+svn:wc:ra_dav:version-url
+V 113
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/PersonalAttributeList.java
+END
+AttributeName.java
+K 25
+svn:wc:ra_dav:version-url
+V 105
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/AttributeName.java
+END
+PEPSUtil.java
+K 25
+svn:wc:ra_dav:version-url
+V 100
+/CITnet/svn/STORK2/!svn/ver/712/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/PEPSUtil.java
+END
+PersonalAttribute.java
+K 25
+svn:wc:ra_dav:version-url
+V 109
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/PersonalAttribute.java
+END
+IAttributeListProcessor.java
+K 25
+svn:wc:ra_dav:version-url
+V 115
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/IAttributeListProcessor.java
+END
+STORKAuthnRequest.java
+K 25
+svn:wc:ra_dav:version-url
+V 108
+/CITnet/svn/STORK2/!svn/ver/56/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/STORKAuthnRequest.java
+END
+STORKLogoutResponse.java
+K 25
+svn:wc:ra_dav:version-url
+V 111
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/STORKLogoutResponse.java
+END
+IStorkLogger.java
+K 25
+svn:wc:ra_dav:version-url
+V 103
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/IStorkLogger.java
+END
+DateUtil.java
+K 25
+svn:wc:ra_dav:version-url
+V 99
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/DateUtil.java
+END
+AttributeProvider.java
+K 25
+svn:wc:ra_dav:version-url
+V 109
+/CITnet/svn/STORK2/!svn/ver/712/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/AttributeProvider.java
+END
+IStorkSession.java
+K 25
+svn:wc:ra_dav:version-url
+V 104
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/IStorkSession.java
+END
+Linker.java
+K 25
+svn:wc:ra_dav:version-url
+V 98
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/Linker.java
+END
+PEPSParameters.java
+K 25
+svn:wc:ra_dav:version-url
+V 106
+/CITnet/svn/STORK2/!svn/ver/712/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/PEPSParameters.java
+END
+AttributeConstants.java
+K 25
+svn:wc:ra_dav:version-url
+V 109
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/AttributeConstants.java
+END
+STORKStatusCode.java
+K 25
+svn:wc:ra_dav:version-url
+V 106
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/STORKStatusCode.java
+END
+AttributeUtil.java
+K 25
+svn:wc:ra_dav:version-url
+V 105
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/AttributeUtil.java
+END
+Country.java
+K 25
+svn:wc:ra_dav:version-url
+V 98
+/CITnet/svn/STORK2/!svn/ver/96/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/Country.java
+END
+PEPSErrors.java
+K 25
+svn:wc:ra_dav:version-url
+V 102
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/PEPSErrors.java
+END
+STORKLogoutRequest.java
+K 25
+svn:wc:ra_dav:version-url
+V 110
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/STORKLogoutRequest.java
+END
+IAttributeProvidersMap.java
+K 25
+svn:wc:ra_dav:version-url
+V 113
+/CITnet/svn/STORK2/!svn/ver/31/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/IAttributeProvidersMap.java
+END
+STORKSubStatusCode.java
+K 25
+svn:wc:ra_dav:version-url
+V 109
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/STORKSubStatusCode.java
+END
+IPersonalAttributeList.java
+K 25
+svn:wc:ra_dav:version-url
+V 114
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/IPersonalAttributeList.java
+END
+CountryCodes.java
+K 25
+svn:wc:ra_dav:version-url
+V 103
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/CountryCodes.java
+END
+STORKAuthnResponse.java
+K 25
+svn:wc:ra_dav:version-url
+V 110
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/STORKAuthnResponse.java
+END
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/entries b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/entries
new file mode 100644
index 000000000..0b8070876
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/entries
@@ -0,0 +1,1085 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/main/java/eu/stork/peps/auth/commons
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-03T15:10:40.224759Z
+712
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+AttributeConstants.java
+file
+
+
+
+
+2013-12-20T12:27:56.638475Z
+940dcb9e93ede62e221f4b25abd6576b
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+1831
+
+STORKStatusCode.java
+file
+
+
+
+
+2013-12-20T12:27:56.638475Z
+771689c75a8263c7e3966e820d59025e
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+1906
+
+AttributeUtil.java
+file
+
+
+
+
+2014-01-21T08:38:55.336702Z
+2859d3335dfe719ca04258fae54e69a3
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+7927
+
+exceptions
+dir
+
+Country.java
+file
+
+
+
+
+2013-12-20T12:27:56.638475Z
+9cbde5f25b646d02dae7ccf424906b4a
+2013-11-01T20:35:30.927048Z
+96
+emferreri
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2208
+
+PEPSErrors.java
+file
+
+
+
+
+2014-01-21T08:38:55.336702Z
+bfe69afce772675187fdd637453ed12f
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+12165
+
+STORKLogoutRequest.java
+file
+
+
+
+
+2014-01-21T08:38:55.336702Z
+af445a2013f21ffecd3db7773ae3236e
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+4343
+
+IAttributeProvidersMap.java
+file
+
+
+
+
+2013-12-20T12:27:56.634475Z
+225257e8d6d7b9e6bcc4bea2463c33be
+2013-10-10T17:38:31.956327Z
+31
+emlelisst
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2534
+
+STORKSubStatusCode.java
+file
+
+
+
+
+2013-12-20T12:27:56.634475Z
+65e615e0119d4125d5f4f58af8bcd18b
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2181
+
+IPersonalAttributeList.java
+file
+
+
+
+
+2014-01-21T08:38:55.336702Z
+b441a2c6c3eddcf1043c55e55f48faa6
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+6598
+
+STORKAuthnResponse.java
+file
+
+
+
+
+2014-01-21T08:38:55.336702Z
+f2247f9a89e8ad01f9a24ad716f993ca
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+8724
+
+CountryCodes.java
+file
+
+
+
+
+2013-12-20T12:27:56.638475Z
+f91b0f8df0b2a68fe1b900d425257c23
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+3527
+
+package-info.java
+file
+
+
+
+
+2013-12-20T12:27:56.638475Z
+8d8068e217f10425f76a8d37192ccd80
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+277
+
+AttributeSource.java
+file
+
+
+
+
+2014-01-21T08:38:55.336702Z
+a0555599193656bc17e02c3ce23043be
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+4501
+
+PEPSValues.java
+file
+
+
+
+
+2014-03-05T09:36:07.946515Z
+4a94fe7623d8d6b679efddecd8d49009
+2014-03-03T15:10:40.224759Z
+712
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+7899
+
+STORKAttrQueryRequest.java
+file
+
+
+
+
+2014-01-21T08:38:55.336702Z
+2d4ac505f71020c482ebbefa10484552
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+10617
+
+CitizenConsent.java
+file
+
+
+
+
+2014-01-21T08:38:55.336702Z
+39e236d6888f266d9b4967f19726126c
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+3445
+
+AttributeProvidersMap.java
+file
+
+
+
+
+2014-01-21T08:38:55.336702Z
+b487da35df5353c8b2aba47ab3cdb68d
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2608
+
+STORKAttrQueryResponse.java
+file
+
+
+
+
+2014-01-21T08:38:55.336702Z
+93fc508be2bc0fd29ae453b0868e1d2b
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+9080
+
+PersonalAttributeList.java
+file
+
+
+
+
+2014-01-21T08:38:55.336702Z
+0036d26679cc31fe7d1bdea1b8b3555a
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+12041
+
+AttributeName.java
+file
+
+
+
+
+2014-01-21T08:38:55.336702Z
+164e63d1f4e5aeb47d371caff534eaab
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+1504
+
+PEPSUtil.java
+file
+
+
+
+
+2014-03-05T09:36:07.946515Z
+9aa5d40e80a49d19293f42db68feca97
+2014-03-03T15:10:40.224759Z
+712
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+12702
+
+PersonalAttribute.java
+file
+
+
+
+
+2014-01-21T08:38:55.336702Z
+ce98ef39a754869644b5516cdcfcb40d
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+8914
+
+IAttributeListProcessor.java
+file
+
+
+
+
+2014-01-21T08:38:55.336702Z
+07efc5b742cc9e4b80a2f8b17fe4b946
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+4713
+
+DateUtil.java
+file
+
+
+
+
+2013-12-20T12:27:56.634475Z
+59f9cd2a3d1169a0f1a797b28719921a
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+5702
+
+IStorkLogger.java
+file
+
+
+
+
+2013-12-20T12:27:56.634475Z
+f15979b29f52d1674103528aed914ae7
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+4766
+
+STORKLogoutResponse.java
+file
+
+
+
+
+2014-01-21T08:38:55.336702Z
+880a05076cf8412311766aa40cf6a63f
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+5474
+
+STORKAuthnRequest.java
+file
+
+
+
+
+2013-12-20T12:27:56.634475Z
+3f36e65f0c4f1c7df753784b2e64f00b
+2013-10-24T15:44:04.704923Z
+56
+emgrtargr
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+11269
+
+AttributeProvider.java
+file
+
+
+
+
+2014-03-05T09:36:07.946515Z
+54177f09aad369707021fb3c0f5b2b1e
+2014-03-03T15:10:40.224759Z
+712
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2914
+
+IStorkSession.java
+file
+
+
+
+
+2013-12-20T12:27:56.634475Z
+5a8701b1fd27998d5cf3280a5c99bcb0
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2745
+
+Linker.java
+file
+
+
+
+
+2014-01-21T08:38:55.336702Z
+98f46baee16310e3dc59ef224ba5b5ab
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+8950
+
+PEPSParameters.java
+file
+
+
+
+
+2014-03-05T09:36:07.946515Z
+ba1718cf8c1a52eae81aa6b182315b95
+2014-03-03T15:10:40.224759Z
+712
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+15394
+
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeConstants.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeConstants.java.svn-base
new file mode 100644
index 000000000..09769641c
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeConstants.java.svn-base
@@ -0,0 +1,72 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+/**
+ * This enum class contains all the STORK PEPS, Commons and Specific errors
+ * constant identifiers.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.2 $, $Date: 2010-11-17 05:15:28 $
+ */
+public enum AttributeConstants {
+
+ /**
+ * Represents the attribute's name index.
+ */
+ ATTR_NAME_INDEX(0),
+ /**
+ * Represents the attribute's type index.
+ */
+ ATTR_TYPE_INDEX(1),
+ /**
+ * Represents the attribute's value index.
+ */
+ ATTR_VALUE_INDEX(2),
+ /**
+ * Represents the attribute's status index.
+ */
+ ATTR_STATUS_INDEX(3),
+ /**
+ * Represents the number of allowed tuples.
+ */
+ NUMBER_TUPLES(4);
+
+ /**
+ * Represents the constant's value.
+ */
+ private int attribute;
+
+ /**
+ * Solo Constructor.
+ *
+ * @param attr The Attribute Constant value.
+ */
+ AttributeConstants(final int attr) {
+
+ this.attribute = attr;
+ }
+
+ /**
+ * Return the Constant Value.
+ *
+ * @return The constant value.
+ */
+ public int intValue() {
+
+ return attribute;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeName.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeName.java.svn-base
new file mode 100644
index 000000000..a44768c7e
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeName.java.svn-base
@@ -0,0 +1,74 @@
+package eu.stork.peps.auth.commons;
+
+/**
+ * This class is a bean used to store information relative to Attribute Names.
+ *
+ * @author Stelios Lelis (stelios.lelis@aegean.gr), Elias Pastos (ilias@aegean.gr)
+ *
+ * @version $Revision: 1.00 $, $Date: 2013-11-26 $
+ */
+public final class AttributeName {
+
+ /**
+ * Attribute Id.
+ */
+ private String attributeId;
+
+ /**
+ * Attribute Name.
+ */
+ private String attributeName;
+
+ /**
+ * Attribute Name Constructor.
+ *
+ * @param aId Id of the Attribute Name.
+ * @param aName Name of the Attribute Name.
+ */
+ public AttributeName(final String aId, final String aName) {
+
+ this.attributeId = aId;
+ this.attributeName = aName;
+ }
+
+ /**
+ * Getter for the attributeId value.
+ *
+ * @return The attributeId value.
+ */
+ public String getAttributeId() {
+
+ return attributeId;
+ }
+
+ /**
+ * Setter for the attributeId value.
+ *
+ * @param aId Id of the Attribute Name.
+ */
+ public void setAttributeId(final String aId) {
+
+ this.attributeId = aId;
+ }
+
+ /**
+ * Getter for the attributeName value.
+ *
+ * @return The attributeName value.
+ */
+ public String getAttributeName() {
+
+ return attributeName;
+ }
+
+ /**
+ * Setter for the attributeName value.
+ *
+ * @param name Name of the Attribute Name.
+ */
+ public void setAttributeName(final String name) {
+
+ this.attributeName = name;
+ }
+
+} \ No newline at end of file
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeProvider.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeProvider.java.svn-base
new file mode 100644
index 000000000..575732e27
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeProvider.java.svn-base
@@ -0,0 +1,123 @@
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+import java.util.List;
+
+/**
+ * This class is a bean used to store the information relative to the Attribute Provider.
+ *
+ * @author Stelios Lelis (stelios.lelis@aegean.gr), Elias Pastos (ilias@aegean.gr)
+ *
+ * @version $Revision: 1.01 $, $Date: 2014-01-13 $
+ */
+public final class AttributeProvider implements Serializable {
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 7210186241917444559L;
+
+ /**
+ * Provider Id.
+ */
+ private String providerId;
+
+ /**
+ * Provider Name.
+ */
+ private String providerName;
+
+ /**
+ * Allowed groups of attribute names.
+ */
+ private List<String> allowedGroups;
+
+ /**
+ * Attribute Provider Constructor.
+ *
+ * @param pId Id of the Attribute Provider.
+ * @param pName Name of the Attribute Provider.
+ */
+ public AttributeProvider(final String pId, final String pName, final List<String> pAllowedGroups) {
+
+ this.providerId = pId;
+ this.providerName = pName;
+ this.allowedGroups = pAllowedGroups;
+ }
+
+ /**
+ * Getter for the providerId value.
+ *
+ * @return The providerId value.
+ */
+ public String getProviderId() {
+
+ return providerId;
+ }
+
+ /**
+ * Setter for the providerId value.
+ *
+ * @param pId Id of the Attribute Provider.
+ */
+ public void setProviderId(final String pId) {
+
+ this.providerId = pId;
+ }
+
+ /**
+ * Getter for the providerName value.
+ *
+ * @return The providerName value.
+ */
+ public String getProviderName() {
+
+ return providerName;
+ }
+
+ /**
+ * Setter for the providerName value.
+ *
+ * @param name Name of the Attribute Provider.
+ */
+ public void setProviderName(final String name) {
+
+ this.providerName = name;
+ }
+
+ /**
+ * Getter for the allowedGroups value.
+ *
+ * @return The allowedGroups value.
+ */
+ public List<String> getAllowedGroups() {
+
+ return allowedGroups;
+ }
+
+ /**
+ * Setter for the allowedGroups value.
+ *
+ * @param name AllowedGroups of the Attribute Provider.
+ */
+ public void setAllowedGroups(final List<String> pAllowedGroups) {
+
+ this.allowedGroups = pAllowedGroups;
+ }
+
+ /**
+ * Check if an attribute name is allowed for this Attribute Provider
+ *
+ * @param pAttrName the Attribute Name to check
+ * @return true if the name is allowed, false otherwise
+ */
+ public boolean isAttributeNameAllowed(final String pAttrName) {
+ if ( allowedGroups==null || pAttrName==null )
+ return false;
+ else if ( allowedGroups.contains(PEPSParameters.ATTRIBUTE_GROUPS_ALL.toString()) )
+ return true;
+ else if ( allowedGroups.contains(PEPSParameters.ATTRIBUTE_GROUPS_NONE.toString()) )
+ return false;
+ else
+ return allowedGroups.contains(pAttrName);
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeProvidersMap.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeProvidersMap.java.svn-base
new file mode 100644
index 000000000..85aec2625
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeProvidersMap.java.svn-base
@@ -0,0 +1,96 @@
+package eu.stork.peps.auth.commons;
+
+import java.util.Iterator;
+import java.util.LinkedHashMap;
+
+import org.apache.log4j.Logger;
+
+/**
+ * Implementation of the AttributeProviderMap using a LinkedHashMap.
+ *
+ * @author Stelios Lelis (stelios.lelis@aegean.gr), Elias Pastos (ilias@aegean.gr)
+ *
+ * @version $Revision: 1.01 $, $Date: 2013-09-20 $
+ *
+ * @see LinkedHashMap
+ */
+public class AttributeProvidersMap extends LinkedHashMap<AttributeSource, IPersonalAttributeList>
+ implements IAttributeProvidersMap {
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(AttributeProvidersMap.class.getName());
+
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 8949081185106296122L;
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public IPersonalAttributeList get(final AttributeSource key) {
+ return this.get((Object) key);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public IPersonalAttributeList remove(final AttributeSource key) {
+ return this.remove((Object) key);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public boolean containsKey(final AttributeSource key) {
+ return this.containsKey((Object) key);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public Iterator<AttributeSource> keyIterator() {
+ return this.keySet().iterator();
+ }
+
+ public void trace() {
+ Iterator<AttributeSource> iterator;
+ Iterator<PersonalAttribute> iterator2;
+ AttributeSource source;
+ IPersonalAttributeList pal;
+ PersonalAttribute pa;
+
+ iterator = this.keyIterator();
+ LOG.trace("Start dumping of AttributeProvidersMap\n=======================");
+ while (iterator.hasNext()) {
+ source = iterator.next();
+
+ LOG.trace("Source details: type [" + source.getSourceType() + "], URL [" + source.getProviderURL() + "]");
+
+ if(source.getSourceType() == AttributeSource.SOURCE_LOCAL_APROVIDER) {
+ LOG.trace("-> Attribute Provider: ID [" + source.getProvider().getProviderId() + "], name [" + source.getProvider().getProviderName() + "]");
+ }
+ else {
+ LOG.trace("-> Country: ID [" + source.getCountry().getCountryId() + "], name [" + source.getCountry().getCountryName() + "]");
+ }
+
+ pal = this.get(source);
+ LOG.trace("++++++++=>");
+ iterator2 = pal.iterator();
+ while (iterator2.hasNext()) {
+ pa = iterator2.next();
+
+ LOG.trace("-> Citizen Attribute: name [" + pa.getName() + "], required [" + pa.isRequired() + "]");
+ }
+ LOG.trace("<=++++++++");
+
+ LOG.trace("-----------------------");
+ }
+ LOG.trace("END\n=======================");
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeSource.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeSource.java.svn-base
new file mode 100644
index 000000000..846f54f67
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeSource.java.svn-base
@@ -0,0 +1,188 @@
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+
+import org.apache.log4j.Logger;
+
+/**
+ * This class is a bean used to store the information relative to the Attribute Source (either AttributeProvider or Country).
+ *
+ * @author Stelios Lelis (stelios.lelis@aegean.gr), Elias Pastos (ilias@aegean.gr)
+ *
+ * @version $Revision: 1.10 $, $Date: 2013-11-29 $
+ */
+public final class AttributeSource implements Serializable {
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 432243595968469014L;
+
+ public static final int SOURCE_LOCAL_APROVIDER = 1;
+ public static final int SOURCE_REMOTE_COUNTRY = 2;
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(AttributeSource.class.getName());
+
+ /**
+ * Provider source.
+ */
+ private int sourceType;
+
+ /**
+ * Provider URL.
+ */
+ private String providerURL;
+
+ /**
+ * The local Attribute Provider.
+ */
+ private AttributeProvider provider;
+
+ /**
+ * The remote Country.
+ */
+ private Country country;
+
+ /**
+ * Attribute Source Constructor.
+ *
+ * @param provider The local Attribute Provider.
+ * @param pURL URL of the Attribute Provider.
+ */
+ public AttributeSource(final AttributeProvider provider, final String pURL) {
+ this.setSourceType(SOURCE_LOCAL_APROVIDER);
+
+ this.setProvider(provider);
+ this.setProviderURL(pURL);
+ }
+
+ /**
+ * Attribute Source Constructor.
+ *
+ * @param country The remote Country.
+ * @param pURL URL of the Country.
+ */
+ public AttributeSource(final Country country, final String pURL) {
+ this.setSourceType(SOURCE_REMOTE_COUNTRY);
+
+ this.setCountry(country);
+ this.setProviderURL(pURL);
+ }
+
+ /**
+ * @param sourceType the sourceType to set
+ */
+ public void setSourceType(final int sourceType) {
+ this.sourceType = sourceType;
+ }
+
+ /**
+ * @return the sourceType
+ */
+ public int getSourceType() {
+ return sourceType;
+ }
+
+ /**
+ * @param providerURL the providerURL to set
+ */
+ public void setProviderURL(final String providerURL) {
+ this.providerURL = providerURL;
+ }
+
+ /**
+ * @return the providerURL
+ */
+ public String getProviderURL() {
+ return providerURL;
+ }
+
+ /**
+ * @param provider the provider to set
+ */
+ public void setProvider(final AttributeProvider provider) {
+ this.setSourceType(SOURCE_LOCAL_APROVIDER);
+
+ this.provider = provider;
+ }
+
+ /**
+ * @return the provider
+ */
+ public AttributeProvider getProvider() {
+ return provider;
+ }
+
+ /**
+ * @param country the country to set
+ */
+ public void setCountry(final Country country) {
+ this.setSourceType(SOURCE_REMOTE_COUNTRY);
+
+ this.country = country;
+ }
+
+ /**
+ * @return the country
+ */
+ public Country getCountry() {
+ return country;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public boolean equals(Object obj) {
+ boolean outcome = false;
+
+ LOG.debug("Calling equals with Object.");
+ if ( obj instanceof AttributeSource ) {
+ LOG.debug("Calling equals with AttributeSource.");
+ outcome = this.equals((AttributeSource)obj);
+ }
+
+ LOG.debug("Object equals outcome: " + outcome);
+ return outcome;
+ }
+
+ /**
+ * Compare the given AttributeSource with the current object in order to determinine
+ * if they are equal.
+ *
+ * @param obj The AttributeSource to compare to
+ *
+ * @return true if the two objects are equal
+ */
+ public boolean equals(AttributeSource obj) {
+ boolean outcome = false;
+
+ if ( this.sourceType==obj.getSourceType() ) {
+ if ( this.sourceType==AttributeSource.SOURCE_LOCAL_APROVIDER ) {
+ if ( this.provider.getProviderId().equals(obj.getProvider().getProviderId()) )
+ outcome = true;
+ }
+ else if ( this.sourceType==AttributeSource.SOURCE_REMOTE_COUNTRY ) {
+ if ( this.country.getCountryId().equals(obj.getCountry().getCountryId()) )
+ outcome = true;
+ }
+ }
+
+ LOG.debug("AttributeSource equals outcome: " + outcome);
+ return outcome;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public int hashCode() {
+ int hash = 1;
+ hash = hash * 17 + this.sourceType;
+ if ( this.sourceType==AttributeSource.SOURCE_LOCAL_APROVIDER )
+ hash = hash * 31 + this.provider.getProviderName().hashCode();
+ else
+ hash = hash * 31 + this.country.getCountryName().hashCode();
+ return hash;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeUtil.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeUtil.java.svn-base
new file mode 100644
index 000000000..af7ab6cf3
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/AttributeUtil.java.svn-base
@@ -0,0 +1,231 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.Map.Entry;
+
+import org.apache.commons.lang.StringUtils;
+
+/**
+ * This class holds static helper methods.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.5 $, $Date: 2010-12-15 23:19:59 $
+ */
+public final class AttributeUtil {
+
+ /**
+ * Private constructor. Prevents the class from being instantiated.
+ */
+ private AttributeUtil() {
+ // empty constructor
+ }
+
+ /**
+ * Safe escape any given string.
+ *
+ * @param value The HTTP Value to escaped.
+ *
+ * @return The value escaped value.
+ */
+ public static String escape(final String value) {
+
+ final String attrSep = PEPSValues.ATTRIBUTE_SEP.toString();
+ final String attrTupleSep = PEPSValues.ATTRIBUTE_TUPLE_SEP.toString();
+ final String attrValueSep = PEPSValues.ATTRIBUTE_VALUE_SEP.toString();
+
+ final String escAttrSep = "%" + (int) attrSep.charAt(0);
+ final String escAttrTupleSep = "%" + (int) attrTupleSep.charAt(0);
+ final String escAttrValueSep = "%" + (int) attrValueSep.charAt(0);
+
+ return value.replace(attrSep, escAttrSep)
+ .replace(attrTupleSep, escAttrTupleSep)
+ .replace(attrValueSep, escAttrValueSep);
+ }
+
+ /**
+ * Unescape any given string.
+ *
+ * @param value The HTTP Value to be unescaped.
+ *
+ * @return The value unescaped value.
+ */
+ public static String unescape(final String value) {
+ final String attrSep = PEPSValues.ATTRIBUTE_SEP.toString();
+ final String attrTupleSep = PEPSValues.ATTRIBUTE_TUPLE_SEP.toString();
+ final String attrValueSep = PEPSValues.ATTRIBUTE_VALUE_SEP.toString();
+
+ final String escAttrSep = "%" + (int) attrSep.charAt(0);
+ final String escAttrTupleSep = "%" + (int) attrTupleSep.charAt(0);
+ final String escAttrValueSep = "%" + (int) attrValueSep.charAt(0);
+
+ return value.replace(escAttrSep, attrSep)
+ .replace(escAttrTupleSep, attrTupleSep)
+ .replace(escAttrValueSep, attrValueSep);
+ }
+
+ /**
+ * Appends the string representation of an object to a StringBuilder.
+ *
+ * @param strBuilder The StringBuilder to append to.
+ * @param val The string representation of an object.
+ */
+ public static void appendIfNotNull(final StringBuilder strBuilder,
+ final Object val) {
+
+ if (val != null) {
+ strBuilder.append(val);
+ }
+ }
+
+ /**
+ * Given a separator and a list of strings, joins the list, as a string,
+ * separated by the separator string.
+ *
+ * @param list The list of strings to join.
+ * @param separator The separator string.
+ * @return the list, as a string, separated by the separator string.
+ */
+ public static String listToString(final List<String> list,
+ final String separator) {
+
+ final StringBuilder strBuilder = new StringBuilder();
+ for (final String s : list) {
+ if (!StringUtils.isEmpty(s)) {
+ strBuilder.append(AttributeUtil.escape(s) + separator);
+ }
+ }
+ return strBuilder.toString();
+ }
+
+ /**
+ * Given a separator and a map of strings to strings, joins the map, as a
+ * string, separated by the separator string with the pair key/value
+ * concatenated with a '='.
+ *
+ * @param map The map of strings to join.
+ * @param separator The separator string.
+ *
+ * @return the map of strings, as a string, separated by the separator string
+ * with the pair key/value concatenated with a '='.
+ */
+ public static String mapToString(final Map<String, String> map,
+ final String separator) {
+
+ final StringBuilder strBuilder = new StringBuilder();
+ final Iterator<Entry<String, String>> valuesIt = map.entrySet().iterator();
+ while (valuesIt.hasNext()) {
+ final Entry<String, String> entry = valuesIt.next();
+ strBuilder.append(entry.getKey());
+ strBuilder.append('=');
+ strBuilder.append(AttributeUtil.escape(entry.getValue()));
+ strBuilder.append(separator);
+ }
+ return strBuilder.toString();
+ }
+
+ /**
+ * Validates the attribute value format.
+ *
+ * @param value The attribute value to validate.
+ *
+ * @return true if value has a valid format.
+ */
+ public static boolean isValidValue(final String value) {
+ boolean retVal = false;
+ if (value != null && value.charAt(0) == '[' && value.endsWith("]")) {
+ final String tmpAttrValue = value.substring(1, value.length() - 1);
+ final String[] vals =
+ tmpAttrValue.split(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+
+ if (tmpAttrValue.length() >= 0
+ || (vals.length > 0 && vals[0].length() > 0)) {
+ retVal = true;
+ }
+ }
+ return retVal;
+ }
+
+ /**
+ * Validates the attribute type value. It's case insensitive. E.g. return true
+ * value to: a) "true", "TRUE", "True", ... b) "false", "FALSE", "False", ...
+ *
+ * @param type The attribute type value.
+ *
+ * @return true if type has a true or false (case insensitive) value.
+ */
+ public static boolean isValidType(final String type) {
+ return StringUtils.isNotEmpty(type) && (PEPSValues.TRUE.toString().equalsIgnoreCase(type) || PEPSValues.FALSE.toString().equalsIgnoreCase(type)) ;
+ }
+
+ /**
+ * Validates the Personal attribute tuple. E.g. name:type:[value]:status
+ *
+ * @param tuples The Personal attribute's tuple.
+ *
+ * @return true if the tuples' format is valid.
+ *
+ * @see PEPSUtil#validateParameter(String, String, String)
+ * @see String#equalsIgnoreCase(String)
+ */
+ public static boolean hasValidTuples(final String[] tuples) {
+ boolean retVal = false;
+
+ final int numberTuples = AttributeConstants.NUMBER_TUPLES.intValue();
+ if (tuples != null && tuples.length == numberTuples) {
+ // validate attrName
+ final int attrNameIndex = AttributeConstants.ATTR_NAME_INDEX.intValue();
+ final int attrTypeIndex = AttributeConstants.ATTR_TYPE_INDEX.intValue();
+ final int attrValueIndex = AttributeConstants.ATTR_VALUE_INDEX.intValue();
+
+ retVal =
+ StringUtils.isNotEmpty(tuples[attrNameIndex])
+ && StringUtils.isNotEmpty(tuples[attrTypeIndex])
+ && StringUtils.isNotEmpty(tuples[attrValueIndex])
+ && AttributeUtil.isValidType(tuples[attrTypeIndex])
+ && AttributeUtil.isValidValue(tuples[attrValueIndex]);
+ }
+ return retVal;
+ }
+
+ /**
+ * Check if all mandatory attributes have values.
+ *
+ * @param personalAttrList The Personal Attributes List.
+ *
+ * @return true if all mandatory attributes have values, false if at least one
+ * attribute doesn't have value.
+ */
+ public static boolean checkMandatoryAttributes(
+ final IPersonalAttributeList personalAttrList) {
+
+ final Iterator<PersonalAttribute> itAttributes =
+ personalAttrList.values().iterator();
+ boolean retVal = true;
+ while (itAttributes.hasNext() && retVal) {
+ final PersonalAttribute attr = itAttributes.next();
+ if (attr.isRequired()
+ && !STORKStatusCode.STATUS_AVAILABLE.toString()
+ .equals(attr.getStatus())) {
+ retVal = false;
+ }
+ }
+ return retVal;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/CitizenConsent.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/CitizenConsent.java.svn-base
new file mode 100644
index 000000000..9ebcfbd5a
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/CitizenConsent.java.svn-base
@@ -0,0 +1,123 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * This class is a bean used to store the information relative to the Citizen
+ * Consent.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.15 $, $Date: 2010-11-17 05:15:28 $
+ */
+public final class CitizenConsent {
+
+ /**
+ * Mandatory attributes list.
+ */
+ private List<String> mandatoryList;
+
+ /**
+ * Optional attributes list.
+ */
+ private List<String> optionalList;
+
+ /**
+ * Citizen Consent default Constructor.
+ */
+ public CitizenConsent() {
+ this.mandatoryList = new ArrayList<String>();
+ this.optionalList = new ArrayList<String>();
+ }
+
+ /**
+ * Getter for the mandatoryList value.
+ *
+ * @return The mandatoryList value.
+ */
+ public List<String> getMandatoryList() {
+ return this.mandatoryList;
+ }
+
+ /**
+ * Setter for the mandatoryList value.
+ *
+ * @param mandatoryAttrList Mandatory parameters list.
+ */
+ public void setMandatoryList(final List<String> mandatoryAttrList) {
+ this.mandatoryList = mandatoryAttrList;
+ }
+
+ /**
+ * Setter for some mandatoryAttribute. Adds the input parameter to the
+ * mandatoryList.
+ *
+ * @param mandatoryAttr Attribute to add to the mandatoryList.
+ */
+ public void setMandatoryAttribute(final String mandatoryAttr) {
+ this.mandatoryList.add(mandatoryAttr);
+ }
+
+ /**
+ * Getter for the optionalList value.
+ *
+ * @return The optionalList value.
+ */
+ public List<String> getOptionalList() {
+ return optionalList;
+ }
+
+ /**
+ * Setter for the optionalList value.
+ *
+ * @param optAttrList Optional parameters list.
+ */
+ public void setOptionalList(final List<String> optAttrList) {
+ this.optionalList = optAttrList;
+ }
+
+ /**
+ * Setter for some optionalAttr. Adds the input parameter to the optionalList.
+ *
+ * @param optionalAttr Attribute to add to the optionalList.
+ */
+ public void setOptionalAttribute(final String optionalAttr) {
+ this.optionalList.add(optionalAttr);
+ }
+
+ /**
+ * Returns a string in the following format. "Mandatory attributes:
+ * mandatoryAttr1;mandatoryAttr2;mandatoryAttrN Optional attributes:
+ * optionalAttr1;optionalAttr2;optionalAttrN"
+ *
+ * @return {@inheritDoc}
+ */
+ public String toString() {
+ final StringBuilder strbldr = new StringBuilder(46);
+ strbldr.append("Mandatory attributes: ");
+ for (final String str : mandatoryList) {
+ strbldr.append(str).append(';');
+ }
+ strbldr.append(" Optional attributes: ");
+ for (final String str : optionalList) {
+ strbldr.append(str).append(';');
+ }
+ return strbldr.toString();
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/Country.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/Country.java.svn-base
new file mode 100644
index 000000000..001f9317a
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/Country.java.svn-base
@@ -0,0 +1,95 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+
+/**
+ * This class is a bean used to store the information relative to the Country.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.10 $, $Date: 2010-11-17 05:15:28 $
+ */
+public final class Country implements Serializable {
+
+ /**
+ *
+ */
+ private static final long serialVersionUID = 1135994036496370993L;
+
+/**
+ * Country Id.
+ */
+ private String countryId;
+
+ /**
+ * Country Name.
+ */
+ private String countryName;
+
+ /**
+ * Country Constructor.
+ *
+ * @param cId Id of the Country.
+ * @param cName Name of the Country.
+ */
+ public Country(final String cId, final String cName) {
+
+ this.countryId = cId;
+ this.countryName = cName;
+ }
+
+ /**
+ * Getter for the countryId value.
+ *
+ * @return The countryId value.
+ */
+ public String getCountryId() {
+
+ return countryId;
+ }
+
+ /**
+ * Setter for the countryId value.
+ *
+ * @param cId Id of the Country.
+ */
+ public void setCountryId(final String cId) {
+
+ this.countryId = cId;
+ }
+
+ /**
+ * Getter for the countryName value.
+ *
+ * @return The countryName value.
+ */
+ public String getCountryName() {
+
+ return countryName;
+ }
+
+ /**
+ * Setter for the countryName value.
+ *
+ * @param name Name of the Country.
+ */
+ public void setCountryName(final String name) {
+
+ this.countryName = name;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/CountryCodes.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/CountryCodes.java.svn-base
new file mode 100644
index 000000000..54345f3ea
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/CountryCodes.java.svn-base
@@ -0,0 +1,79 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.util.Arrays;
+import java.util.List;
+
+/**
+ * This class contains all the ISO 3166-1 Alpha 3 Country Codes.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.2 $, $Date: 2011-04-14 00:24:56 $
+ */
+public final class CountryCodes {
+
+ /**
+ * Private Constructor.
+ */
+ private CountryCodes() {
+
+ }
+
+ /**
+ * ISO 3166-1 Alpha 3 Country Codes.
+ */
+ private static List<String> countrysAlpha3 = Arrays.asList("ABW", "AFG",
+ "AGO", "AIA", "ALA", "ALB", "AND", "ANT", "ARE", "ARG", "ARM", "ASM",
+ "ATA", "ATF", "ATG", "AUS", "AUT", "AZE", "BDI", "BEL", "BEN", "BES",
+ "BFA", "BGD", "BGR", "BHR", "BHS", "BIH", "BLM", "BLR", "BLZ", "BMU",
+ "BOL", "BRA", "BRB", "BRN", "BTN", "BUR", "BVT", "BWA", "BYS", "CAF",
+ "CAN", "CCK", "CHE", "CHL", "CHN", "CIV", "CMR", "COD", "COG", "COK",
+ "COL", "COM", "CPV", "CRI", "CSK", "CUB", "CUW", "CXR", "CYM", "CYP",
+ "CZE", "DEU", "DJI", "DMA", "DNK", "DOM", "DZA", "ECU", "EGY", "ERI",
+ "ESH", "ESP", "EST", "ETH", "FIN", "FJI", "FLK", "FRA", "FRO", "FSM",
+ "GAB", "GBR", "GEO", "GGY", "GHA", "GIB", "GIN", "GLP", "GMB", "GNB",
+ "GNQ", "GRC", "GRD", "GRL", "GTM", "GUF", "GUM", "GUY", "HKG", "HMD",
+ "HND", "HRV", "HTI", "HUN", "IDN", "IMN", "IND", "IOT", "IRL", "IRN",
+ "IRQ", "ISL", "ISR", "ITA", "JAM", "JEY", "JOR", "JPN", "KAZ", "KEN",
+ "KGZ", "KHM", "KIR", "KNA", "KOR", "KWT", "LAO", "LBN", "LBR", "LBY",
+ "LCA", "LIE", "LKA", "LSO", "LTU", "LUX", "LVA", "MAC", "MAF", "MAR",
+ "MCO", "MDA", "MDG", "MDV", "MEX", "MHL", "MKD", "MLI", "MLT", "MMR",
+ "MNE", "MNG", "MNP", "MOZ", "MRT", "MSR", "MTQ", "MUS", "MWI", "MYS",
+ "MYT", "NAM", "NCL", "NER", "NFK", "NGA", "NIC", "NIU", "NLD", "NOR",
+ "NPL", "NRU", "NZL", "OMN", "PAK", "PAN", "PCN", "PER", "PHL", "PLW",
+ "PNG", "POL", "PRI", "PRK", "PRT", "PRY", "PSE", "PYF", "QAT", "REU",
+ "ROM", "ROU", "RUS", "RWA", "SAU", "SCG", "SDN", "SEN", "SGP", "SGS",
+ "SHN", "SJM", "SLB", "SLE", "SLV", "SMR", "SOM", "SPM", "SRB", "STP",
+ "SUR", "SVK", "SVN", "SXW", "SWE", "SWZ", "SYC", "SYR", "TCA", "TCD",
+ "TGO", "THA", "TJK", "TKL", "TKM", "TLS", "TMP", "TON", "TTO", "TUN",
+ "TUR", "TUV", "TWN", "TZA", "UGA", "UKR", "UMI", "URY", "USA", "UZB",
+ "VAT", "VCT", "VEN", "VGB", "VIR", "VNM", "VUT", "WLF", "WSM", "YEM",
+ "YUG", "ZAF", "ZAR", "ZMB", "ZWE");
+
+ /**
+ * Searches the CountryCode (3166-1 alpha3 format) an return true if it
+ * exists.
+ *
+ * @param countryCode The Country code to search.
+ *
+ * @return true if the CountryCode exists, false otherwise.
+ */
+ public static boolean hasCountryCodeAlpha3(final String countryCode) {
+
+ return CountryCodes.countrysAlpha3.contains(countryCode);
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/DateUtil.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/DateUtil.java.svn-base
new file mode 100644
index 000000000..9c0bd6775
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/DateUtil.java.svn-base
@@ -0,0 +1,169 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.sql.Timestamp;
+import java.util.GregorianCalendar;
+
+import org.apache.log4j.Logger;
+import org.joda.time.DateTime;
+import org.joda.time.Years;
+import org.joda.time.format.DateTimeFormat;
+import org.joda.time.format.DateTimeFormatter;
+
+import eu.stork.peps.auth.commons.exceptions.SecurityPEPSException;
+
+/**
+ * This class holds static helper methods for Date Operations.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.4 $, $Date: 2010-11-17 05:15:28 $
+ */
+public final class DateUtil {
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(DateUtil.class.getName());
+
+ /**
+ * yyyy Date format size.
+ */
+ private static final int YEAR_DATE_SIZE = 4;
+
+ /**
+ * yyyyMM Date format size.
+ */
+ private static final int MONTH_DATE_SIZE = 6;
+
+ /**
+ * Private constructor. Prevents the class from being instantiated.
+ */
+ private DateUtil() {
+ // empty constructor
+ }
+
+ /**
+ * Fulfils dateValue with a valid date. The following roles are applied: a) If
+ * the dateValue only contains the year then fulfils with last year's day.
+ * e.g. this method returns 19951231 to the 1995 dateValue. b) If the
+ * dateValue contains the year and the month then fulfils with last month's
+ * day. e.g. this method returns 19950630 to the 199505 dateValue.
+ *
+ * @param dateValue The date to be fulfilled.
+ *
+ * @return The dateValue fulfilled.
+ */
+ private static String fulfilDate(final String dateValue) {
+
+ final StringBuffer strBuf = new StringBuffer();
+ strBuf.append(dateValue);
+ // if the IdP just provides the year then we must fullfil the date.
+ if (dateValue.length() == YEAR_DATE_SIZE) {
+ strBuf.append(PEPSValues.LAST_MONTH.toString());
+ }
+ // if the IdP provides the year and the month then we must fullfil the
+ // date.
+ if (dateValue.length() == MONTH_DATE_SIZE
+ || strBuf.length() == MONTH_DATE_SIZE) {
+ // IdP doesn't provide the day, so we will use DateTime to
+ // calculate it.
+ final String noDayCons = PEPSValues.NO_DAY_DATE_FORMAT.toString();
+ final DateTimeFormatter fmt = DateTimeFormat.forPattern(noDayCons);
+ final DateTime dateTime = fmt.parseDateTime(strBuf.toString());
+ // Append the last month's day.
+ strBuf.append(dateTime.dayOfMonth().withMaximumValue().getDayOfMonth());
+ }
+
+ return strBuf.toString();
+ }
+
+ /**
+ * Validates the dateValue format: a) if has a valid size; b) if has a numeric
+ * value; Note: dateValue must have the format yyyyMMdd.
+ *
+ * @param dateValueTmp The date to be validated.
+ * @param pattern The accepted date format.
+ *
+ * @return true if the date has a valid format.
+ */
+ public static boolean isValidFormatDate(final String dateValueTmp,
+ final String pattern) {
+
+ boolean retVal = true;
+ try {
+ final String dateValue = DateUtil.fulfilDate(dateValueTmp);
+
+ final DateTimeFormatter fmt = DateTimeFormat.forPattern(pattern);
+ fmt.parseDateTime(dateValue);
+ } catch (final Exception e) {
+ // We catch Exception because we only have to return false
+ // value!
+ retVal = false;
+ }
+ return retVal;
+ }
+
+ /**
+ * Calculates the age for a given date string.
+ *
+ * @param dateVal The date to be validated.
+ * @param now The current date.
+ * @param pattern The date pattern.
+ *
+ * @return The age value.
+ */
+ public static int calculateAge(final String dateVal, final DateTime now,
+ final String pattern) {
+
+ if (DateUtil.isValidFormatDate(dateVal, pattern)) {
+ try {
+ final String dateValueTemp = DateUtil.fulfilDate(dateVal);
+ final DateTimeFormatter fmt = DateTimeFormat.forPattern(pattern);
+ final DateTime dateTime = fmt.parseDateTime(dateValueTemp);
+ // Calculating age
+ final Years age = Years.yearsBetween(dateTime, now);
+
+ return age.getYears();
+ } catch (final IllegalArgumentException e) {
+ LOG.warn("Invalid date format (" + pattern
+ + ") or an invalid dateValue.");
+ throw new SecurityPEPSException(
+ PEPSUtil.getConfig(PEPSErrors.INVALID_ATTRIBUTE_VALUE.errorCode()),
+ PEPSUtil.getConfig(PEPSErrors.INVALID_ATTRIBUTE_VALUE.errorMessage()),
+ e);
+ }
+ } else {
+ LOG.warn("Couldn't calculate Age, invalid date!");
+ throw new SecurityPEPSException(
+ PEPSUtil.getConfig(PEPSErrors.INVALID_ATTRIBUTE_VALUE.errorCode()),
+ PEPSUtil.getConfig(PEPSErrors.INVALID_ATTRIBUTE_VALUE.errorMessage()));
+ }
+
+ }
+
+ /**
+ * Generates the current timestamp.
+ *
+ * @return timestamp The current timestamp
+ */
+ public static Timestamp currentTimeStamp() {
+ final GregorianCalendar cal = new GregorianCalendar();
+ final long millis = cal.getTimeInMillis();
+ return new Timestamp(millis);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IAttributeListProcessor.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IAttributeListProcessor.java.svn-base
new file mode 100644
index 000000000..b13c70f04
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IAttributeListProcessor.java.svn-base
@@ -0,0 +1,148 @@
+package eu.stork.peps.auth.commons;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * Interface for {@link AttributeListProcessor}.
+ *
+ * @author ricardo.ferreira@multicert.com
+ *
+ * @version $Revision: $, $Date: $
+ *
+ * @see IPersonalAttributeList
+ */
+public interface IAttributeListProcessor {
+
+ /**
+ * Checks if attribute list only contains allowed attributes.
+ *
+ * @param attrList the requested attribute list
+ * @param attributes the allowed attributes
+ *
+ * @return true is all the attributes are allowed.
+ *
+ * @see IPersonalAttributeList
+ */
+ boolean hasAllowedAttributes(final IPersonalAttributeList attrList, final List<String> attributes);
+
+ /**
+ * Lookup for business attribute.
+ *
+ * @param attrList the requested attribute list
+ * @param normalAttributes the normal attributes
+ *
+ * @return true is at least one business attribute was requested.
+ *
+ * @see IPersonalAttributeList
+ */
+ boolean hasBusinessAttributes(final IPersonalAttributeList attrList, final List<String> normalAttributes);
+
+ /**
+ * Lookup for business attribute in normal attribute list (loaded by
+ * implementation).
+ *
+ * @param attrList the requested attribute list
+ *
+ * @return true is at least one business attribute was requested.
+ *
+ * @see IPersonalAttributeList
+ */
+ boolean hasBusinessAttributes(final IPersonalAttributeList attrList);
+
+ /**
+ * Adds eIdentifier, name, surname, and DateOfBirth attributes to get business
+ * attributes from some AP.
+ *
+ * @param attrList the requested attribute list
+ * @param attributes the list of attributes to add (eIdentifier, name,
+ * surname, and DateOfBirth).
+ *
+ * @return the requested attribute list and the new attributes added
+ * (eIdentifier, name, surname, and DateOfBirth).
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList addAPMandatoryAttributes(final IPersonalAttributeList attrList, final List<String> attributes);
+
+ /**
+ * Adds eIdentifier, name, surname, and DateOfBirth attributes, loaded by
+ * implementation, to get business attributes from some AP.
+ *
+ * @param attrList the requested attribute list
+ *
+ * @return the requested attribute list and the new attributes added
+ * (eIdentifier, name, surname, and DateOfBirth).
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList addAPMandatoryAttributes(final IPersonalAttributeList attrList);
+
+ /**
+ * Removes from attribute list the given list of attributes.
+ *
+ * @param attrList the requested attribute list
+ * @param attributes the list of attributes to remove.
+ *
+ * @return the requested attribute list and the attributes removed.
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList removeAPMandatoryAttributes(final IPersonalAttributeList attrList, final List<String> attributes);
+
+ /**
+ * Removes from attribute list the given list of attributes and change
+ * attributes status if attribute was optional in the request.
+ *
+ * @param attrList the requested attribute list
+ * @param attributes the map of attributes (attribute name, mandatory/optional) to remove.
+ *
+ * @return the requested attribute list and the attributes removed
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList removeAPMandatoryAttributes(IPersonalAttributeList attrList, Map<String, Boolean> attributes);
+
+ /**
+ * Checks if mandate attribute exist in the requested Attribute List. Power
+ * attribute name to lookup is loaded by implementation.
+ *
+ * @param attrList the requested attribute list.
+ *
+ * @return true if mandate attribute exists or false otherwise.
+ *
+ * @see IPersonalAttributeList
+ */
+ boolean hasPowerAttribute(final IPersonalAttributeList attrList);
+
+ /**
+ * Checks if attribute name was requested and has value.
+ *
+ * @param attrList the requested attribute list.
+ * @param attrName the attribute name to lookup for .
+ *
+ * @return true if attribute was requested and has value or false otherwise.
+ *
+ * @see IPersonalAttributeList
+ */
+ boolean hasAttributeValue(final IPersonalAttributeList attrList, final String attrName);
+
+ /**
+ * Checks if attribute has value.
+ *
+ * @param attr the attribute to check.
+ *
+ * @return true if has value;
+ *
+ * @see PersonalAttribute
+ */
+ boolean hasAttributeValue(final PersonalAttribute attr);
+
+ /**
+ * Gets a map (attribute name, attribute isRequired) of attributes added to attribute list.
+ *
+ * @return the Map of attributes added and if is required to attribute list.
+ */
+ Map<String, Boolean> getNormalAttributesAdded();
+
+} \ No newline at end of file
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IAttributeProvidersMap.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IAttributeProvidersMap.java.svn-base
new file mode 100644
index 000000000..733399ca3
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IAttributeProvidersMap.java.svn-base
@@ -0,0 +1,82 @@
+package eu.stork.peps.auth.commons;
+
+import java.util.Iterator;
+
+/**
+ * Interface for Attributes Providers map.
+ *
+ * @author Stelios Lelis (stelios.lelis@aegean.gr), Elias Pastos (ilias@aegean.gr)
+ *
+ * @version $Revision: 1.00 $, $Date: 2013-09-20 $
+ */
+public interface IAttributeProvidersMap {
+
+ /**
+ * Returns the object associated the the given key.
+ *
+ * @param key with which the specified value is to be associated.
+ *
+ * @return The object associated the the given key.
+ */
+ IPersonalAttributeList get(AttributeSource key);
+
+ /**
+ * Associates a key to a value, and inserts them in the session object.
+ *
+ * @param key with which the specified value is to be associated.
+ * @param value to be associated with the specified key.
+ *
+ * @return previous value associated with specified key, or null if there was
+ * no mapping for key. A null return can also indicate that the map
+ * previously associated null with the specified key.
+ */
+ Object put(AttributeSource key, IPersonalAttributeList value);
+
+ /**
+ * Removes the mapping for this key.
+ *
+ * @param key with which the specified value is to be associated.
+ *
+ * @return previous value associated with specified key, or null if there was
+ * no mapping for key. A null return can also indicate that the map
+ * previously associated null with the specified key.
+ */
+ IPersonalAttributeList remove(AttributeSource key);
+
+ /**
+ * Returns the number of key-value mappings in this map.
+ *
+ * @return the number of key-value mappings in this map.
+ */
+ int size();
+
+ /**
+ * Returns true if this map contains a mapping for the specified key.
+ *
+ * @param key with which the specified value is to be associated.
+ *
+ * @return true if this map contains a mapping for the specified key.
+ */
+ boolean containsKey(AttributeSource key);
+
+ /**
+ * Removes all mappings from this map.
+ */
+ void clear();
+
+ /**
+ * Returns true if this map contains no key-value mappings.
+ *
+ * @return true if this map contains no key-value mappings.
+ */
+ boolean isEmpty();
+
+ /**
+ * Returns an Iterator of the keys contained in this map. The implementation must
+ * take care in order for the Iterator to have predictable order of the returned
+ * keys.
+ *
+ * @return an iterator of the keys contained in this map
+ */
+ Iterator<AttributeSource> keyIterator();
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IPersonalAttributeList.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IPersonalAttributeList.java.svn-base
new file mode 100644
index 000000000..b24c915c0
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IPersonalAttributeList.java.svn-base
@@ -0,0 +1,194 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.Set;
+
+/**
+ * Interface for {@link PersonalAttributeList}.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.16 $, $Date: 2010-11-17 05:15:28 $
+ *
+ * @see PersonalAttribute
+ */
+@SuppressWarnings("PMD.CloneMethodMustImplementCloneable")
+public interface IPersonalAttributeList extends Iterable<PersonalAttribute>,
+ Cloneable {
+
+ /**
+ * Associates the specified value with the specified key in this Personal
+ * Attribute List.
+ *
+ * @param key with which the specified value is to be associated.
+ * @param value to be associated with the specified key.
+ *
+ * @return the previous value associated with key, or null if there was no
+ * mapping for key.
+ *
+ * @see PersonalAttribute
+ */
+ PersonalAttribute put(String key, PersonalAttribute value);
+
+ /**
+ * Returns the value to which the specified key is mapped, or null if this map
+ * contains no mapping for the key.
+ *
+ * @param key whose associated value is to be returned.
+ *
+ * @return The value to which the specified key is mapped, or null if this map
+ * contains no mapping for the key.
+ *
+ * @see PersonalAttribute
+ */
+ PersonalAttribute get(Object key);
+
+ /**
+ * Adds to the PersonalAttributeList the given PersonalAttribute. It sets the
+ * attribute name as the key to the attribute value.
+ *
+ * @param value PersonalAttribute to add to the PersonalAttributeList
+ */
+ void add(PersonalAttribute value);
+
+ /**
+ * Get the size of the Personal Attribute List.
+ *
+ * @return size of the Personal Attribute List.
+ */
+ int size();
+
+ /**
+ * Checks if the Personal Attribute List contains the given key.
+ *
+ * @param key with which the specified value is to be associated.
+ *
+ * @return true if the Personal Attribute List contains the given key, false
+ * otherwise.
+ */
+ boolean containsKey(Object key);
+
+ /**
+ * Getter for the iterator of the Personal Attribute List values.
+ *
+ * @return The iterator for the Personal Attribute List values.
+ *
+ * @see PersonalAttribute
+ */
+ Iterator<PersonalAttribute> iterator();
+
+ /**
+ * Creates a Personal Attribute List from a String representing an Attribute
+ * List.
+ *
+ * @param attrList String Object representing the attribute list.
+ */
+ void populate(String attrList);
+
+ /**
+ * Removes the mapping for this key from this map if present.
+ *
+ * @param key key whose mapping is to be removed from the map.
+ * @return previous value associated with specified key, or <tt>null</tt> if
+ * there was no mapping for key. A <tt>null</tt> return can also
+ * indicate that the map previously associated <tt>null</tt> with the
+ * specified key.
+ */
+ PersonalAttribute remove(Object key);
+
+ /**
+ * Returns a collection view of the values contained in this map. The
+ * collection is backed by the map, so changes to the map are reflected in the
+ * collection, and vice-versa. The collection supports element removal, which
+ * removes the corresponding mapping from this map, via the
+ * <tt>Iterator.remove</tt>, <tt>Collection.remove</tt>, <tt>removeAll</tt>,
+ * <tt>retainAll</tt>, and <tt>clear</tt> operations. It does not support the
+ * <tt>add</tt> or <tt>addAll</tt> operations.
+ *
+ * @return a collection view of the values contained in this map.
+ */
+ Collection<PersonalAttribute> values();
+
+ /**
+ * Returns a {@link Set} view of the keys contained in this map.
+ * The set is backed by the map, so changes to the map are
+ * reflected in the set, and vice-versa. If the map is modified
+ * while an iteration over the set is in progress (except through
+ * the iterator's own <tt>remove</tt> operation), the results of
+ * the iteration are undefined. The set supports element removal,
+ * which removes the corresponding mapping from the map, via the
+ * <tt>Iterator.remove</tt>, <tt>Set.remove</tt>,
+ * <tt>removeAll</tt>, <tt>retainAll</tt>, and <tt>clear</tt>
+ * operations. It does not support the <tt>add</tt> or <tt>addAll</tt>
+ * operations.
+ *
+ * @return a set view of the keys contained in this map
+ */
+ Set<String> keySet();
+
+
+ /**
+ * Returns a IPersonalAttributeList of the complex attributes.
+ *
+ * @return an IPersonalAttributeList of the complex attributes.
+ */
+ IPersonalAttributeList getComplexAttributes();
+
+ /**
+ * Returns a IPersonalAttributeList of the simple value attributes.
+ *
+ * @return an IPersonalAttributeList of the simple value attributes.
+ */
+ IPersonalAttributeList getSimpleValueAttributes();
+
+ /**
+ * Returns a IPersonalAttributeList of the mandatory attributes in this map.
+ *
+ * @return an IPersonalAttributeList of the mandatory attributes contained in this map.
+ */
+ IPersonalAttributeList getMandatoryAttributes();
+
+ /**
+ * Returns a IPersonalAttributeList of the optional attributes in this map.
+ *
+ * @return an IPersonalAttributeList of the optional attributes contained in this map.
+ */
+ IPersonalAttributeList getOptionalAttributes();
+
+ /**
+ * Returns <tt>true</tt> if this map contains no key-value mappings.
+ *
+ * @return <tt>true</tt> if this map contains no key-value mappings.
+ */
+ boolean isEmpty();
+
+ /**
+ * Returns <tt>true</tt> if this map contains at least one element that doesn't have value.
+ *
+ * @return <tt>true</tt> if this map contains at least one element that doesn't have value.
+ */
+ boolean hasMissingValues();
+
+ /**
+ * Returns a copy of this <tt>IPersonalAttributeList</tt> instance.
+ *
+ * @return The copy of this IPersonalAttributeList.
+ */
+ Object clone() throws CloneNotSupportedException;
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IStorkLogger.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IStorkLogger.java.svn-base
new file mode 100644
index 000000000..33eb618f0
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IStorkLogger.java.svn-base
@@ -0,0 +1,239 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+/**
+ * Interface for stork logging.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.10 $, $Date: 2011-02-17 22:44:34 $
+ */
+public interface IStorkLogger {
+
+ /**
+ * Getter for SpApplication.
+ *
+ * @return The SpApplication value.
+ */
+ String getSpApplication();
+
+ /**
+ * Setter for SpApplication.
+ *
+ * @param spApplication The SP Application.
+ */
+ void setSpApplication(String spApplication);
+
+ /**
+ * Getter for ProviderName.
+ *
+ * @return The ProviderName value.
+ */
+ String getProviderName();
+
+ /**
+ * Setter for ProviderName.
+ *
+ * @param providerName The provider name.
+ */
+ void setProviderName(String providerName);
+
+ /**
+ *
+ * Getter for Origin.
+ *
+ * @return The Origin value.
+ *
+ */
+ String getOrigin();
+
+ /**
+ * Setter for Origin.
+ *
+ * @param origin The origin.
+ */
+ void setOrigin(String origin);
+
+ /**
+ *
+ * Getter for QAA Level.
+ *
+ * @return The QAA Level value.
+ *
+ */
+ int getQaaLevel();
+
+ /**
+ * Setter for QAA Level.
+ *
+ * @param qaaLevel The qaa level.
+ */
+ void setQaaLevel(int qaaLevel);
+
+ /**
+ *
+ * Getter for timestamp.
+ *
+ * @return The timestamp value.
+ *
+ */
+ String getTimestamp();
+
+ /**
+ * Setter for timestamp.
+ *
+ * @param timestamp The request's timestamp.
+ */
+ void setTimestamp(String timestamp);
+
+ /**
+ * Getter for InResponseTo.
+ *
+ * @return The InResponseTo value.
+ */
+ String getInResponseTo();
+
+ /**
+ * Setter for InResponseTo.
+ *
+ * @param inResponseTo The Saml's response id.
+ */
+ void setInResponseTo(String inResponseTo);
+
+ /**
+ * Getter for InResponseToSPReq.
+ *
+ * @return The InResponseToSPReq value.
+ */
+ String getInResponseToSPReq();
+
+ /**
+ * Setter for InResponseToSPRequ.
+ *
+ * @param inResponseToSPReq The Saml's response id.
+ */
+ void setInResponseToSPReq(String inResponseToSPReq);
+
+ /**
+ * Getter for opType.
+ *
+ * @return The opType value.
+ */
+ String getOpType();
+
+ /**
+ * Setter for opType.
+ *
+ * @param opType The operation type.
+ */
+ void setOpType(String opType);
+
+ /**
+ * Getter for destination.
+ *
+ * @return The destination value.
+ */
+ String getDestination();
+
+ /**
+ * Setter for destinationIp.
+ *
+ * @param destination The remote IP.
+ */
+ void setDestination(String destination);
+
+ /**
+ * Getter for message or assertion consumer.
+ *
+ * @return The message or assertion consumer.
+ */
+ String getMessage();
+
+ /**
+ * Setter for message or assertion consumer.
+ *
+ * @param message or assertion consumer.
+ */
+ void setMessage(String message);
+
+ /**
+ * Getter for country.
+ *
+ * @return The country value.
+ */
+ String getCountry();
+
+ /**
+ * Setter for country.
+ *
+ * @param country The country.
+ */
+ void setCountry(String country);
+
+ /**
+ * Getter for samlHash.
+ *
+ * @return The samlHash value.
+ */
+ byte[] getSamlHash();
+
+ /**
+ * Setter for samlHash.
+ *
+ * @param samlHash the encrypted SAML token
+ */
+ void setSamlHash(byte[] samlHash);
+
+ /**
+ * Getter for msgId.
+ *
+ * @return the msgId
+ */
+ String getMsgId();
+
+ /**
+ * Setter for msgId.
+ *
+ * @param msgId the ID of the originator of this message
+ */
+ void setMsgId(String msgId);
+
+ /**
+ * Getter for sPMsgId.
+ *
+ * @return the sPMsgId
+ */
+ String getSPMsgId();
+
+ /**
+ * Setter for sPMsgId.
+ *
+ * @param sPMsgId the ID of the originator of this message
+ */
+ void setSPMsgId(String sPMsgId);
+
+ /**
+ * The format of the returned String must be the following:
+ * "requestCounter#ddMMMyyyykk:mm:ss#opType#originIp#originName
+ * #destinationIp#destinationName#samlHash#[originatorName#msgId#]"
+ *
+ * The values enclosed in '[]' only apply when logging responses.
+ *
+ * @return {@inheritDoc}
+ */
+ @Override
+ String toString();
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IStorkSession.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IStorkSession.java.svn-base
new file mode 100644
index 000000000..f38b41838
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/IStorkSession.java.svn-base
@@ -0,0 +1,85 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+/**
+ * Interface for stork session.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.9 $, $Date: 2010-11-17 05:15:28 $
+ */
+public interface IStorkSession {
+
+ /**
+ * Returns the object associated the the given key.
+ *
+ * @param key with which the specified value is to be associated.
+ *
+ * @return The object associated the the given key.
+ */
+ Object get(Object key);
+
+ /**
+ * Associates a key to a value, and inserts them in the session object.
+ *
+ * @param key with which the specified value is to be associated.
+ * @param value to be associated with the specified key.
+ *
+ * @return previous value associated with specified key, or null if there was
+ * no mapping for key. A null return can also indicate that the map
+ * previously associated null with the specified key.
+ */
+ Object put(String key, Object value);
+
+ /**
+ * Removes the mapping for this key.
+ *
+ * @param key with which the specified value is to be associated.
+ *
+ * @return previous value associated with specified key, or null if there was
+ * no mapping for key. A null return can also indicate that the map
+ * previously associated null with the specified key.
+ */
+ Object remove(Object key);
+
+ /**
+ * Returns the number of key-value mappings in this map.
+ *
+ * @return the number of key-value mappings in this map.
+ */
+ int size();
+
+ /**
+ * Returns true if this map contains a mapping for the specified key.
+ *
+ * @param key with which the specified value is to be associated.
+ *
+ * @return true if this map contains a mapping for the specified key.
+ */
+ boolean containsKey(Object key);
+
+ /**
+ * Removes all mappings from this map.
+ */
+ void clear();
+
+ /**
+ * Returns true if this map contains no key-value mappings.
+ *
+ * @return true if this map contains no key-value mappings.
+ */
+ boolean isEmpty();
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/Linker.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/Linker.java.svn-base
new file mode 100644
index 000000000..6e7c891da
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/Linker.java.svn-base
@@ -0,0 +1,316 @@
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.LinkedHashMap;
+import java.util.List;
+
+import org.apache.log4j.Logger;
+
+/**
+ * This class is a bean used to store the information of Attribute Providers, the Attribute
+ * List to be requested, the Assertions returned by the Attribute Providers and the values
+ * that each Attribute has. This information along with the current status of the Linker (the
+ * attribute providers that were queried and the remaining providers) is used by the PEPS
+ * actions in order to complete the Attribute gathering.
+ *
+ * @author Stelios Lelis (stelios.lelis@aegean.gr), Elias Pastos (ilias@aegean.gr)
+ *
+ * @version $Revision: 1.50 $, $Date: 2013-11-28 $
+ */
+public final class Linker implements Serializable {
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = -3268006381745987237L;
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(Linker.class.getName());
+
+ /**
+ * Attributes Providers map.
+ */
+ private IAttributeProvidersMap attributeProvidersMap;
+
+ /**
+ * Assertion map.
+ */
+ private LinkedHashMap<AttributeSource, STORKAttrQueryResponse> assertions;
+
+ /**
+ * The current index of local (domestic) Attribute Providers.
+ */
+ private int localIndex;
+
+ /**
+ * The current index of remote (foreign) Attribute Providers - countries.
+ */
+ private int remoteIndex;
+
+ /**
+ * Constructs an empty Linker object.
+ */
+ public Linker() {
+ localIndex = 0;
+ remoteIndex = 0;
+
+ assertions = new LinkedHashMap<AttributeSource, STORKAttrQueryResponse>();
+ }
+
+ /**
+ * Based on the internal state of the Linker it returns the next local Attribute Source
+ *
+ * @return The next Attribute Source or null if not found
+ *
+ * @see AttributeSource
+ */
+ public AttributeSource getNextLocalProvider() {
+ Iterator<AttributeSource> iterator;
+ AttributeSource source, found;
+ int curIndex = 0;
+
+ found = null;
+
+ if ( attributeProvidersMap!=null && !attributeProvidersMap.isEmpty() ) {
+ iterator = attributeProvidersMap.keyIterator();
+ while (iterator.hasNext()) {
+ source = iterator.next();
+
+ if ( source.getSourceType()==AttributeSource.SOURCE_LOCAL_APROVIDER ) {
+ if ( curIndex>=localIndex ) {
+ found = source;
+
+ break;
+ }
+
+ curIndex++;
+ }
+ }
+ }
+
+ return found;
+ }
+
+ /**
+ * Based on the internal state of the Linker it returns the next remote Attribute Source
+ *
+ * @return The next Attribute Source or null if not found
+ *
+ * @see AttributeSource
+ */
+ public AttributeSource getNextRemoteProvider() {
+ Iterator<AttributeSource> iterator;
+ AttributeSource source, found;
+ int curIndex = 0;
+
+ found = null;
+
+ if ( attributeProvidersMap !=null && !attributeProvidersMap.isEmpty() ) {
+ iterator = attributeProvidersMap.keyIterator();
+ while (iterator.hasNext()) {
+ source = iterator.next();
+
+ if ( source.getSourceType()==AttributeSource.SOURCE_REMOTE_COUNTRY ) {
+ if ( curIndex>=remoteIndex ) {
+ found = source;
+
+ break;
+ }
+
+ curIndex++;
+ }
+ }
+ }
+
+ return found;
+ }
+
+ /**
+ * It updates the Linker with the values returned by the Attribute Source. It also advances
+ * to the next index in order to mark this attribute source as completed.
+ *
+ * @param source The Attribute Source that was queried for attribute values.
+ * @param attrResponse The attrResponse returned by the Attribute Source that contains the attribute values.
+ *
+ * @see AttributeSource, STORKAttrQueryResponse
+ */
+ public void setProviderReponse(AttributeSource source, STORKAttrQueryResponse attrResponse) {
+ if ( source.getSourceType()==AttributeSource.SOURCE_REMOTE_COUNTRY )
+ remoteIndex++;
+ else
+ localIndex++;
+
+ //Assertion storage
+ this.assertions.put(source, attrResponse);
+
+ this.attributeProvidersMap.put(source, attrResponse.getPersonalAttributeList());
+ //this.attributeProvidersMap.put(source, attrResponse.getTotalPersonalAttributeList());
+ }
+
+ /**
+ * Reset the internal state of the local Attribute Source in order to start over.
+ */
+ public void resetLocalIndex() {
+ localIndex = 0;
+ }
+
+ /**
+ * Reset the internal state of the remote Attribute Source in order to start over.
+ */
+ public void resetRemoteIndex() {
+ remoteIndex = 0;
+ }
+
+ /**
+ * Setter for attributeProvidersMap.
+ *
+ * @param attributeProvidersMap The attributeProvidersMap to set.
+ */
+ public void setAttributeProvidersMap(IAttributeProvidersMap attributeProvidersMap) {
+ this.attributeProvidersMap = attributeProvidersMap;
+ }
+
+ /**
+ * Getter for attributeProvidersMap.
+ *
+ * @return attributeProvidersMap
+ */
+ public IAttributeProvidersMap getAttributeProvidersMap() {
+ return attributeProvidersMap;
+ }
+
+ /**
+ * Returns the Personal Attribute list of the provided Attribute Source.
+ *
+ * @param source The attributeSource in reference
+ *
+ * @return The IPersonalAttributeList assosiated with this source or null if empty
+ *
+ * @see IPersonalAttributeList
+ */
+ public IPersonalAttributeList getProviderAttributes(AttributeSource source) {
+ if ( attributeProvidersMap.containsKey(source) )
+ return attributeProvidersMap.get(source);
+ else
+ return null;
+ }
+
+ /**
+ * Returns the merged Personal Attribute list from all the Attribute Sources.
+ *
+ * @return The IPersonalAttributeList merged Personal Attribute list or null if empty
+ *
+ * @see IPersonalAttributeList
+ */
+ public IPersonalAttributeList getAllAttributes() {
+ Iterator<AttributeSource> iterator;
+ AttributeSource source;
+ IPersonalAttributeList list, merged;
+
+ merged = null;
+
+ if ( attributeProvidersMap !=null && !attributeProvidersMap.isEmpty() ) {
+ iterator = attributeProvidersMap.keyIterator();
+
+ merged = new PersonalAttributeList();
+ while (iterator.hasNext()) {
+ source = iterator.next();
+ list = this.getProviderAttributes(source);
+
+ for (final PersonalAttribute pa : list) {
+ merged.add(pa);
+ }
+ }
+ }
+
+ return merged;
+ }
+
+ /**
+ * Returns a List with all the assertions gathered by the AAS-PEPS module
+ * returned both by local APs or remote A-PEPS.
+ *
+ * @return The assertions returned from the APs and A-PEPS
+ */
+ public List<STORKAttrQueryResponse> getAttrQueryResponseList() {
+ List<STORKAttrQueryResponse> originalAssertions;
+
+ originalAssertions = new ArrayList<STORKAttrQueryResponse>();
+
+ //Gather all assertions
+ for (STORKAttrQueryResponse element : this.assertions.values()) {
+ originalAssertions.add(element);
+ }
+
+ return originalAssertions;
+ }
+
+ /**
+ * Checks the internal state of the Linker and if all Attribute Sources where visited
+ * returns true, otherwise it returns false. So if you go directly from AtPLinkerAction
+ * to MoreAttributesAction the call will have, since the method setProviderReponse
+ * was not executed from every Attribute Source.
+ *
+ * @return true if everything is OK, false otherwise
+ */
+ public boolean isComplete() {
+ boolean outcome = false;
+
+ LOG.debug("Check if linkder is complete: R[" + remoteIndex + "], L[" + localIndex + "], S[" + attributeProvidersMap.size() + "]");
+ if ( attributeProvidersMap !=null && !attributeProvidersMap.isEmpty() ) {
+ if ( (remoteIndex + localIndex)==attributeProvidersMap.size() )
+ outcome = true;
+ }
+ else {
+ outcome = true;
+ }
+
+ return outcome;
+ }
+
+ /**
+ * Merge the two Linker objects.
+ *
+ * @param previous The other Linker object to merge with this one.
+ */
+ public void mergeWith(Linker previous) {
+ //BEFORE
+ if ( LOG.isDebugEnabled() ) {
+ LOG.debug("The attributeProvidersMap from the current object.");
+ ((AttributeProvidersMap)this.attributeProvidersMap).trace();
+ LOG.debug("The attributeProvidersMap from the provided object.");
+ ((AttributeProvidersMap)previous.getAttributeProvidersMap()).trace();
+ }
+
+ IAttributeProvidersMap map = previous.getAttributeProvidersMap();
+ Iterator<AttributeSource> items = map.keyIterator();
+ while( items.hasNext() ) {
+ AttributeSource item = items.next();
+ IPersonalAttributeList pal = map.get(item);
+
+ if ( this.attributeProvidersMap.containsKey(item) ) {
+ IPersonalAttributeList new_pal = this.attributeProvidersMap.get(item);
+
+ for(PersonalAttribute pa : pal)
+ new_pal.add(pa);
+ }
+ else {
+ if ( item.getSourceType()==AttributeSource.SOURCE_REMOTE_COUNTRY )
+ remoteIndex++;
+ else
+ localIndex++;
+
+ this.attributeProvidersMap.put(item, pal);
+ }
+ }
+
+ //AFTER
+ if ( LOG.isDebugEnabled() ) {
+ LOG.debug("The attributeProvidersMap after the merge.");
+ ((AttributeProvidersMap)this.attributeProvidersMap).trace();
+ }
+ }
+} \ No newline at end of file
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PEPSErrors.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PEPSErrors.java.svn-base
new file mode 100644
index 000000000..5da9ba494
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PEPSErrors.java.svn-base
@@ -0,0 +1,392 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+/**
+ * This enum class contains all the STORK PEPS, Commons and Specific errors
+ * constant identifiers.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.10 $, $Date: 2011-02-17 22:44:34 $
+ */
+public enum PEPSErrors {
+
+ /**
+ * Represents the 'authenticationFailed' constant error identifier.
+ */
+ AUTHENTICATION_FAILED_ERROR("authenticationFailed"),
+ /**
+ * Represents the 'spCountrySelector.errorCreatingSAML' constant error
+ * identifier.
+ */
+ SP_COUNTRY_SELECTOR_ERROR_CREATE_SAML("spCountrySelector.errorCreatingSAML"),
+ /**
+ * Represents the 'spCountrySelector.destNull' constant error identifier.
+ */
+ SP_COUNTRY_SELECTOR_DESTNULL("spCountrySelector.destNull"),
+ /**
+ * Represents the 'spCountrySelector.invalidAttr' constant error identifier.
+ */
+ SP_COUNTRY_SELECTOR_INVALID_ATTR("spCountrySelector.invalidAttr"),
+ /**
+ * Represents the 'spCountrySelector.invalidProviderName' constant error
+ * identifier.
+ */
+ SP_COUNTRY_SELECTOR_INVALID_PROVIDER_NAME(
+ "spCountrySelector.invalidProviderName"),
+ /**
+ * Represents the 'spCountrySelector.invalidQaaSPid' constant error
+ * identifier.
+ */
+ SP_COUNTRY_SELECTOR_INVALID_QAASPID("spCountrySelector.invalidQaaSPid"),
+ /**
+ * Represents the 'spCountrySelector.invalidSpId' constant error identifier.
+ */
+ SP_COUNTRY_SELECTOR_INVALID_SPID("spCountrySelector.invalidSpId"),
+ /**
+ * Represents the 'spCountrySelector.invalidSPQAA' constant error identifier.
+ */
+ SP_COUNTRY_SELECTOR_INVALID_SPQAA("spCountrySelector.invalidSPQAA"),
+ /**
+ * Represents the 'spCountrySelector.invalidSpURL' constant error identifier.
+ */
+ SP_COUNTRY_SELECTOR_INVALID_SPURL("spCountrySelector.invalidSpURL"),
+ /**
+ * Represents the 'spCountrySelector.spNotAllowed' constant error identifier.
+ */
+ SP_COUNTRY_SELECTOR_SPNOTALLOWED("spCountrySelector.spNotAllowed"),
+
+ /**
+ * Represents the 'sProviderAction.errorCreatingSAML' constant error
+ * identifier.
+ */
+ SPROVIDER_SELECTOR_ERROR_CREATE_SAML("sProviderAction.errorCreatingSAML"),
+ /**
+ * Represents the 'sProviderAction.attr' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_ATTR("sProviderAction.invalidAttr"),
+ /**
+ * Represents the 'sProviderAction.country' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_COUNTRY("sProviderAction.invalidCountry"),
+ /**
+ * Represents the 'sProviderAction.relayState' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_RELAY_STATE("sProviderAction.invalidRelayState"),
+ /**
+ * Represents the 'sProviderAction.saml' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_SAML("sProviderAction.invalidSaml"),
+ /**
+ * Represents the 'sProviderAction.spAlias' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_SPALIAS("sProviderAction.invalidSPAlias"),
+ /**
+ * Represents the 'sProviderAction.spDomain' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_SPDOMAIN("sProviderAction.invalidSPDomain"),
+ /**
+ * Represents the 'sProviderAction.spId' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_SPID("sProviderAction.invalidSPId"),
+ /**
+ * Represents the 'sProviderAction.spQAA' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_SPQAA("sProviderAction.invalidSPQAA"),
+ /**
+ * Represents the 'sProviderAction.spQAAId' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_SPQAAID("sProviderAction.invalidSPQAAId"),
+ /**
+ * Represents the 'sProviderAction.spRedirect' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_SPREDIRECT("sProviderAction.invalidSPRedirect"),
+ /**
+ * Represents the 'sPPowerValidationAction.invalidSPPVAttrList' constant error identifier.
+ */
+ SPPOWERVALIDATION_SELECTOR_INVALID_SP_PV_ATTR_LIST("sPPowerValidationAction.invalidSPPVAttrList"),
+
+ /**
+ * Represents the 'sProviderAction.invalidSPProviderName' constant error
+ * identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_SP_PROVIDERNAME(
+ "sProviderAction.invalidSPProviderName"),
+ /**
+ * Represents the 'sProviderAction.spNotAllowed' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_SPNOTALLOWED("sProviderAction.spNotAllowed"),
+
+
+ /**
+ * Represents the 'internalError' constant error identifier.
+ */
+ INTERNAL_ERROR("internalError"),
+
+ /**
+ * Represents the 'colleagueRequest.attrNull' constant error identifier.
+ */
+ COLLEAGUE_REQ_ATTR_NULL("colleagueRequest.attrNull"),
+ /**
+ * Represents the 'colleagueRequest.errorCreatingSAML' constant error
+ * identifier.
+ */
+ COLLEAGUE_REQ_ERROR_CREATE_SAML("colleagueRequest.errorCreatingSAML"),
+ /**
+ * Represents the 'colleagueRequest.invalidCountryCode' constant error
+ * identifier.
+ */
+ COLLEAGUE_REQ_INVALID_COUNTRYCODE("colleagueRequest.invalidCountryCode"),
+ /**
+ * Represents the 'colleagueRequest.invalidDestUrl' constant error identifier.
+ */
+ COLLEAGUE_REQ_INVALID_DEST_URL("colleagueRequest.invalidDestUrl"),
+ /**
+ * Represents the 'colleagueRequest.invalidQaa' constant error identifier.
+ */
+ COLLEAGUE_REQ_INVALID_QAA("colleagueRequest.invalidQaa"),
+ /**
+ * Represents the 'colleagueRequest.invalidRedirect' constant error
+ * identifier.
+ */
+ COLLEAGUE_REQ_INVALID_REDIRECT("colleagueRequest.invalidRedirect"),
+ /**
+ * Represents the 'colleagueRequest.invalidSAML' constant error identifier.
+ */
+ COLLEAGUE_REQ_INVALID_SAML("colleagueRequest.invalidSAML"),
+
+ /**
+ * Represents the 'colleaguePVRequest.invalidPVAttrList' constant error identifier.
+ */
+ COLLEAGUE_PV_REQ_INVALID_PV_ATTR_LIST("colleaguePVRequest.invalidPVAttrList"),
+
+
+ /**
+ * Represents the 'cpepsRedirectUrl' constant error identifier.
+ */
+ CPEPS_REDIRECT_URL("cpepsRedirectUrl"),
+ /**
+ * Represents the 'spepsRedirectUrl' constant error identifier.
+ */
+ SPEPS_REDIRECT_URL("spepsRedirectUrl"),
+ /**
+ * Represents the 'sProviderAction.invCountry' constant error identifier.
+ */
+ SP_ACTION_INV_COUNTRY("sProviderAction.invCountry"),
+
+ /**
+ * Represents the 'providernameAlias.invalid' constant error identifier.
+ */
+ PROVIDER_ALIAS_INVALID("providernameAlias.invalid"),
+
+
+ /**
+ * Represents the 'cPeps.attrNull' constant error identifier.
+ */
+ CPEPS_ATTR_NULL("cPeps.attrNull"),
+
+ /**
+ * Represents the 'colleagueResponse.invalidSAML' constant error identifier.
+ */
+ COLLEAGUE_RESP_INVALID_SAML("colleagueResponse.invalidSAML"),
+
+ /**
+ * Represents the 'citizenNoConsent.mandatory' constant error identifier.
+ */
+ CITIZEN_NO_CONSENT_MANDATORY("citizenNoConsent.mandatory"),
+ /**
+ * Represents the 'citizenResponse.mandatory' constant error identifier.
+ */
+ CITIZEN_RESPONSE_MANDATORY("citizenResponse.mandatory"),
+ /**
+ * Represents the 'attVerification.mandatory' constant error identifier.
+ */
+ ATT_VERIFICATION_MANDATORY("attVerification.mandatory"),
+ /**
+ * Represents the 'attrValue.verification' constant error identifier.
+ */
+ ATTR_VALUE_VERIFICATION("attrValue.verification"),
+
+ /**
+ * Represents the 'audienceRestrictionError' constant error identifier.
+ */
+ AUDIENCE_RESTRICTION("audienceRestrictionError"),
+ /**
+ * Represents the 'auRequestIdError' constant error identifier.
+ */
+ AU_REQUEST_ID("auRequestIdError"),
+ /**
+ * Represents the 'domain' constant error identifier.
+ */
+ DOMAIN("domain"),
+ /**
+ * Represents the 'hash.error' constant error identifier.
+ */
+ HASH_ERROR("hash.error"),
+ /**
+ * Represents the 'invalidAttributeList' constant error identifier.
+ */
+ INVALID_ATTRIBUTE_LIST("invalidAttributeList"),
+ /**
+ * Represents the 'invalidAttributeValue' constant error identifier.
+ */
+ INVALID_ATTRIBUTE_VALUE("invalidAttributeValue"),
+ /**
+ * Represents the 'qaaLevel' constant error identifier.
+ */
+ QAALEVEL("qaaLevel"),
+ /**
+ * Represents the 'requests' constant error identifier.
+ */
+ REQUESTS("requests"),
+ /**
+ * Represents the 'SPSAMLRequest' constant error identifier.
+ */
+ SP_SAML_REQUEST("SPSAMLRequest"),
+ /**
+ * Represents the 'spepsSAMLRequest' constant error identifier.
+ */
+ SPEPS_SAML_REQUEST("spepsSAMLRequest"),
+ /**
+ * Represents the 'IdPSAMLResponse' constant error identifier.
+ */
+ IDP_SAML_RESPONSE("IdPSAMLResponse"),
+ /**
+ * Represents the 'cpepsSAMLResponse' constant error identifier.
+ */
+ CPEPS_SAML_RESPONSE("cpepsSAMLResponse"),
+ /**
+ * Represents the 'cpepsSAMLResponse' constant error identifier.
+ */
+ SPEPS_SAML_RESPONSE("spepsSAMLResponse"),
+ /**
+ * Represents the 'session' constant error identifier.
+ */
+ SESSION("session"),
+ /**
+ * Represents the 'invalid.session' constant error identifier.
+ */
+ INVALID_SESSION("invalid.session"),
+ /**
+ * Represents the 'invalid.sessionId' constant error identifier.
+ */
+ INVALID_SESSION_ID("invalid.sessionId"),
+ /**
+ * Represents the 'missing.sessionId' constant error identifier.
+ */
+ MISSING_SESSION_ID("sessionError"),
+ /**
+ * Represents the 'missing.mandate' constant error identifier.
+ */
+ MISSING_MANDATE("missing.mandate"),
+ /**
+ * Represents the 'AtPSAMLResponse' constant error identifier.
+ */
+ ATP_SAML_RESPONSE("AtPSAMLResponse"),
+
+ /**
+ * Represents the 'AtPSAMLResponse' constant error identifier.
+ */
+ ATP_RESPONSE_ERROR("atp.response.error"),
+
+ /**
+ * Represents the 'apepsSAMLRequest' constant error identifier.
+ */
+ APEPS_SAML_REQUEST("apepsSAMLRequest"),
+
+ /**
+ * Represents the 'apepsSAMLResponse' constant error identifier.
+ */
+ APEPS_SAML_RESPONSE("apepsSAMLResponse"),
+
+ /**
+ * Represents the 'invalid.apepsRedirectUrl' constant error identifier.
+ */
+ INVALID_APEPS_REDIRECT_URL("invalid.apepsRedirectUrl"),
+
+ /**
+ * Represents the 'invalid.apepsCallbackUrl' constant error identifier.
+ */
+ INVALID_APEPS_CALLBACK_URL("invalid.apepsCallbackUrl"),
+
+ /**
+ * Represents the 'colleagueAttributeRequest.invalidSAML' constant error identifier.
+ */
+ COLLEAGUE_ATTR_REQ_INVALID_SAML("colleagueAttributeRequest.invalidSAML");
+
+ /**
+ * Represents the constant's value.
+ */
+ private String error;
+
+ /**
+ * Solo Constructor.
+ *
+ * @param nError The Constant error value.
+ */
+ PEPSErrors(final String nError) {
+ this.error = nError;
+ }
+
+ /**
+ * Construct the errorCode Constant value.
+ *
+ * @return The errorCode Constant.
+ */
+ public String errorCode() {
+ return error + ".code";
+ }
+
+ /**
+ * Construct the errorCode Constant value with the given code text.
+ *
+ * @param text the code text to append to the constant.
+ *
+ * @return The errorCode Constant for the given code text.
+ */
+ public String errorCode(final String text) {
+ return error + "." + text + ".code";
+ }
+
+ /**
+ * Construct the errorMessage constant value.
+ *
+ * @return The errorMessage constant.
+ */
+ public String errorMessage() {
+ return error + ".message";
+ }
+
+ /**
+ * Construct the errorMessage Constant value with the given message text.
+ *
+ * @param text the message text to append to the constant.
+ *
+ * @return The errorMessage Constant for the given text.
+ */
+ public String errorMessage(final String text) {
+ return error + "." + text + ".message";
+ }
+
+ /**
+ * Return the Constant Value.
+ *
+ * @return The constant value.
+ */
+ public String toString() {
+ return error;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PEPSParameters.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PEPSParameters.java.svn-base
new file mode 100644
index 000000000..15c2ae552
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PEPSParameters.java.svn-base
@@ -0,0 +1,625 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+/**
+ * This enum class contains all the STORK PEPS, Commons and Specific Parameters.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.13 $, $Date: 2011-07-07 20:48:45 $
+ */
+public enum PEPSParameters {
+
+ /**
+ * Represents the 'apId' parameter constant.
+ */
+ AP_ID("apId"),
+ /**
+ * Represents the 'apUrl' parameter constant.
+ */
+ AP_URL("apUrl"),
+ /**
+ * Represents the 'ap.number' parameter constant.
+ */
+ AP_NUMBER("ap.number"),
+
+ /**
+ * Represents the 'assertionConsumerServiceURL' parameter constant.
+ */
+ ASSERTION_CONSUMER_S_URL("assertionConsumerServiceURL"),
+
+ /**
+ * Represents the 'auth' parameter constant.
+ */
+ AUTHENTICATION("auth"),
+
+ /**
+ * Represents the 'attr' parameter constant.
+ */
+ ATTRIBUTE("attr"),
+ /**
+ * Represents the 'attrName' parameter constant.
+ */
+ ATTRIBUTE_NAME("attrName"),
+ /**
+ * Represents the 'attrStatus' parameter constant.
+ */
+ ATTRIBUTE_STATUS("attrStatus"),
+ /**
+ * Represents the 'attrType' parameter constant.
+ */
+ ATTRIBUTE_TYPE("attrType"),
+ /**
+ * Represents the 'attrValue' parameter constant.
+ */
+ ATTRIBUTE_VALUE("attrValue"),
+ /**
+ * Represents the 'attrList' parameter constant.
+ */
+ ATTRIBUTE_LIST("attrList"),
+ /**
+ * Represents the 'apMandAttrList' parameter constant.
+ */
+ AP_MANDATORY_ATTRIBUTE_LIST("apMandAttrList"),
+ /**
+ * Represents the 'attrTuple' parameter constant.
+ */
+ ATTRIBUTE_TUPLE("attrTuple"),
+ /**
+ * Represents the 'attribute-missing' parameter constant.
+ */
+ ATTRIBUTE_MISSING("attribute-missing"),
+ /**
+ * Represents the 'attributesNotAllowed' parameter constant.
+ */
+ ATTRIBUTES_NOT_ALLOWED("attributesNotAllowed"),
+ /**
+ * Represents the 'authnRequest' parameter constant.
+ */
+ AUTH_REQUEST("authnRequest"),
+
+ /**
+ * Represents the 'attrValue.number' parameter constant.
+ */
+ ATTR_VALUE_NUMBER("attrValue.number"),
+
+ /**
+ * Represents the 'derivation.date.format' parameter constant.
+ */
+ DERIVATION_DATE_FORMAT("derivation.date.format"),
+ /**
+ * Represents the 'deriveAttr.number' parameter constant.
+ */
+ DERIVE_ATTRIBUTE_NUMBER("deriveAttr.number"),
+
+ /**
+ * Represents the complex attributes parameter constant.
+ */
+ COMPLEX_ADDRESS_VALUE("canonicalResidenceAddress"),
+ COMPLEX_NEWATTRIBUTE_VALUE("newAttribute2"),
+ COMPLEX_HASDEGREE_VALUE("hasDegree"),
+ COMPLEX_MANDATECONTENT_VALUE("mandateContent"),
+ /**
+ * Represents the 'consent-type' parameter constant.
+ */
+ CONSENT_TYPE("consent-type"),
+ /**
+ * Represents the 'consent-value' parameter constant.
+ */
+ CONSENT_VALUE("consent-value"),
+ /**
+ * Represents the 'country' parameter constant.
+ */
+ COUNTRY("country"),
+ /**
+ * Represents the 'countryOrigin' parameter constant.
+ */
+ COUNTRY_ORIGIN("countryOrigin"),
+
+ /**
+ * Represents the 'cpepsURL' parameter constant.
+ */
+ CPEPS_URL("cpepsURL"),
+ /**
+ * Represents the 'callback' parameter constant.
+ */
+ CPEPS_CALLBACK("callback"),
+ /**
+ * Represents the 'peps.specificidpredirect.url' parameter constant.
+ */
+ CPEPS_IDP_CALLBACK_VALUE("peps.specificidpredirect.url"),
+ /**
+ * Represents the 'peps.specificapredirect.url' parameter constant.
+ */
+ CPEPS_AP_CALLBACK_VALUE("peps.specificapredirect.url"),
+
+ /**
+ * Represents the 'errorCode' parameter constant.
+ */
+ ERROR_CODE("errorCode"),
+ /**
+ * Represents the 'subCode' parameter constant.
+ */
+ ERROR_SUBCODE("subCode"),
+ /**
+ * Represents the 'errorMessage' parameter constant.
+ */
+ ERROR_MESSAGE("errorMessage"),
+ /**
+ * Represents the 'errorRedirectUrl' parameter constant.
+ */
+ ERROR_REDIRECT_URL("errorRedirectUrl"),
+
+ /**
+ * errorRedirectUrl Represents the 'external-authentication' parameter
+ * constant.
+ */
+ EXTERNAL_AUTH("external-authentication"),
+ /**
+ * Represents the 'external-ap' parameter constant.
+ */
+ EXTERNAL_AP("external-ap"),
+ /**
+ * Represents the 'external-pv' parameter constant.
+ */
+ EXTERNAL_PV("external-pv"),
+ /**
+ * Represents the 'external-sig-module' parameter constant.
+ */
+ EXT_SIG_CREATOR_MOD("external-sig-module"),
+
+ /**
+ * Represents the 'http-x-forwarded-for' parameter constant.
+ */
+ HTTP_X_FORWARDED_FOR("http-x-forwarded-for"),
+
+ /**
+ * Represents the 'idp.url' parameter constant.
+ */
+ IDP_URL("idp.url"),
+ /**
+ * Represents the 'internal-authentication' parameter constant.
+ */
+ INTERNAL_AUTH("internal-authentication"),
+ /**
+ * Represents the 'internal-ap' parameter constant.
+ */
+ INTERNAL_AP("internal-ap"),
+ /**
+ * Represents the 'internal-pv' parameter constant.
+ */
+ INTERNAL_PV("internal-pv"),
+
+ /**
+ * Represents the 'samlIssuer' parameter constant.
+ */
+ ISSUER("samlIssuer"),
+ /**
+ * Represents the 'samlIssuer.idp' parameter constant.
+ */
+ ISSUER_IDP("samlIssuer.idp"),
+ /**
+ * Represents the 'samlIssuer.atp' parameter constant.
+ */
+ ISSUER_ATP("samlIssuer.atp"),
+
+ /**
+ * Represents the 'mandatory' parameter constant.
+ */
+ MANDATORY("mandatory"),
+ /**
+ * Represents the 'mandatoryAttributeMissing' parameter constant.
+ */
+ MANDATORY_ATTR_MISSING("mandatoryAttributeMissing"),
+ /**
+ * Represents the 'mandatoryConsentAttrMissing' parameter constant.
+ */
+ MANDATORY_CONSENT_MISSING("mandatoryConsentAttrMissing"),
+ /**
+ * Represents the 'missing-attrs' parameter constant.
+ */
+ MISSING_ATTRS("missing-attrs"),
+ /**
+ * Represents the 'no-more-attrs' parameter constant.
+ */
+ NO_MORE_ATTRS("no-more-attrs"),
+
+ /**
+ * Represents the 'optional' parameter constant.
+ */
+ OPTIONAL("optional"),
+
+ /**
+ * Represents the 'no-consent-type' parameter constant.
+ */
+ NO_CONSENT_TYPE("no-consent-type"),
+ /**
+ * Represents the 'no-consent-value' parameter constant.
+ */
+ NO_CONSENT_VALUE("no-consent-value"),
+
+ /**
+ * Represents the 'provider.name' parameter constant.
+ */
+ PROVIDER_NAME_VALUE("providerName"),
+ /**
+ * Represents the 'cpeps.askconsent' parameter constant.
+ */
+ PEPS_ASK_CONSENT("cpeps.askconsent"),
+ /**
+ * Represents the 'cpeps.askconsentvalue' parameter constant.
+ */
+ PEPS_ASK_CONSENT_VALUE("cpeps.askconsentvalue"),
+ /**
+ * Represents the 'pepsAuth' parameter constant.
+ */
+ PEPS_AUTH_CONSENT("pepsAuth"),
+ /**
+ * Represents the 'validation.bypass' parameter constant.
+ */
+ PEPS_BYPASS("validation.bypass"),
+ /**
+ * Represents the 'cpeps.number' parameter constant.
+ */
+ PEPS_NUMBER("cpeps.number"),
+ /**
+ * Represents the 'cpeps.specificapredirect.url' parameter constant.
+ */
+ PEPS_SPECIFIC_URL("cpeps.specificapredirect.url"),
+ /**
+ * Represents the 'pv.url' parameter constant.
+ */
+ PV_URL("pv.url"),
+
+ /**
+ * Represents the 'qaaLevel' parameter constant.
+ */
+ QAALEVEL("qaaLevel"),
+
+ /**
+ * Represents the 'speps.redirectUrl' parameter constant.
+ */
+ SPEPS_REDIRECT_URL("speps.redirectUrl"),
+
+ /**
+ * Represents the 'sp.redirectUrl' parameter constant.
+ */
+ SP_REDIRECT_URL("sp.redirectUrl"),
+ /**
+ * Represents the 'cpeps.redirectUrl' parameter constant.
+ */
+ CPEPS_REDIRECT_URL("cpeps.redirectUrl"),
+ /**
+ * Represents the 'RelayState' parameter constant.
+ */
+ RELAY_STATE("RelayState"),
+ /**
+ * Represents the 'remoteAddr' parameter constant.
+ */
+ REMOTE_ADDR("remoteAddr"),
+ /**
+ * Represents the 'remoteUser' parameter constant.
+ */
+ REMOTE_USER("remoteUser"),
+
+ /**
+ * Represents the 'SAMLRequest' parameter constant.
+ */
+ SAML_REQUEST("SAMLRequest"),
+ /**
+ * Represents the 'SAMLResponse' parameter constant.
+ */
+ SAML_RESPONSE("SAMLResponse"),
+ /**
+ * Represents the 'SAMLFail' parameter constant.
+ */
+ SAML_TOKEN_FAIL("SAMLFail"),
+ /**
+ * Represents the 'TokenId' parameter constant.
+ */
+ SAML_TOKEN_ID("TokenId"),
+ /**
+ * Represents the 'inResponseTo' parameter constant.
+ */
+ SAML_IN_RESPONSE_TO("inResponseTo"),
+ /**
+ * Represents the 'inResponseTo.idp' parameter constant.
+ */
+ SAML_IN_RESPONSE_TO_IDP("inResponseTo.idp"),
+ /**
+ * Represents the 'inResponseTo.atp' parameter constant.
+ */
+ SAML_IN_RESPONSE_TO_ATP("inResponseTo.atp"),
+ /**
+ * Represents the 'SignatureResponse' parameter constant.
+ */
+ SIGNATURE_RESPONSE("SignatureResponse"),
+
+ /**
+ * Represents the 'cPepsSession' parameter constant.
+ */
+ SESSION_ID_URL("cPepsSession"),
+ /**
+ * Represents the 'spId' parameter constant.
+ */
+ SP_ID("spId"),
+ /**
+ * Represents the 'spQaaLevel' parameter constant.
+ */
+ SP_QAALEVEL("spQaaLevel"),
+ /**
+ * Represents the 'spUrl' parameter constant.
+ */
+ SP_URL("spUrl"),
+
+ /**
+ * Represents the 'allow.derivation.all' parameter constant.
+ */
+ SPECIFIC_ALLOW_DERIVATION_ALL("allow.derivation.all"),
+ /**
+ * Represents the ''allow.unknowns parameter constant.
+ */
+ SPECIFIC_ALLOW_UNKNOWNS("allow.unknowns"),
+ /**
+ * Represents the 'derivation.date.separator' parameter constant.
+ */
+ SPECIFIC_DERIVATION_DATE_SEP("derivation.date.separator"),
+ /**
+ * Represents the 'derivation.month.position' parameter constant.
+ */
+ SPECIFIC_DERIVATION_MONTH_POS("derivation.month.position"),
+ /**
+ * Represents the 'derivation.day.position' parameter constant.
+ */
+ SPECIFIC_DERIVATION_DAY_POS("derivation.day.position"),
+ /**
+ * Represents the 'derivation.year.position' parameter constant.
+ */
+ SPECIFIC_DERIVATION_YEAR_POS("derivation.year.position"),
+
+ /**
+ * sp.authorized.parameters Represents the '' parameter constant.
+ */
+ SPEPS_AUTHORIZED("sp.authorized.parameters"),
+
+ /**
+ * Represents the 'spSector' constant value.
+ */
+ SPSECTOR("spSector"),
+ /**
+ * Represents the 'spApplication' constant value.
+ */
+ SPAPPLICATION("spApplication"),
+ /**
+ * Represents the 'spCountry' constant value.
+ */
+ SPCOUNTRY("spCountry"),
+ /**
+ * Represents the 'spInstitution' constant value.
+ */
+ SPINSTITUTION("spInstitution"),
+ /**
+ * Represents the 'storkAttribute.number' parameter constant.
+ */
+ STORK_ATTRIBUTE_NUMBER("storkAttribute.number"),
+ /**
+ * Represents the 'storkAttributeValue.number' parameter constant.
+ */
+ STORK_ATTRIBUTE_VALUE_NUMBER("storkAttributeValue.number"),
+
+ /**
+ * Represents the 'username' parameter constant.
+ */
+ USERNAME("username"),
+
+ /**
+ * Represents the 'tooManyParameters' parameter constant.
+ */
+ TOO_MANY_PARAMETERS("tooManyParameters"),
+ /**
+ * Represents the 'validation.active' parameter constant.
+ */
+ VALIDATION_ACTIVE("validation.active"),
+
+ /**
+ * Represents the 'x-forwarded-for' parameter constant.
+ */
+ X_FORWARDED_FOR("x-forwarded-for"),
+ /**
+ * Represents the 'x-forwarded-host' parameter constant.
+ */
+ X_FORWARDED_HOST("x-forwarded-host"),
+ /**
+ * Represents the 'XMLResponse' parameter constant.
+ */
+ XML_RESPONSE("XMLResponse"),
+
+ /**
+ * Represents the 'ap-cpeps.number' parameter constant.
+ */
+ AP_PEPS_NUMBER("ap-cpeps.number"),
+
+ /**
+ * Represents the 'atp.number' parameter constant.
+ */
+ ATTRIBUTE_PROVIDER_NUMBER("atp.number"),
+
+ /**
+ * Represents the 'atn.number' parameter constant.
+ */
+ ATTRIBUTE_NAME_NUMBER("atn.number"),
+
+ /**
+ * Represents the 'apLinker' parameter constant.
+ */
+ AP_LINKER("apLinker"),
+
+ /**
+ * Represents the 'prevApLinker' parameter constant.
+ */
+ PREV_AP_LINKER("prevApLinker"),
+
+ /**
+ * Represents the 'NOSEL' parameter constant (no attribute provider selected).
+ */
+ AP_NO_SELECTION("NOSEL"),
+
+ /**
+ * Represents the 'OCSEL' parameter constant (attribute provider in another country).
+ */
+ AP_OTHER_COUNTRY("OCSEL"),
+
+ /**
+ * Represents the '_provider' suffix parameter constant.
+ */
+ AP_PROVIDER_SELECT_SUFFIX("_provider"),
+
+ /**
+ * Represents the '_country' suffix parameter constant.
+ */
+ AP_COUNTRY_SELECT_SUFFIX("_country"),
+
+ /**
+ * Represents the '_name' suffix parameter constant.
+ */
+ AP_NAME_SELECT_SUFFIX("_name"),
+
+ /**
+ * Represents the 'next-ap' parameter constant.
+ */
+ NEXT_AP("next-ap"),
+
+ /**
+ * Represents the 'next-apeps' parameter constant.
+ */
+ NEXT_APEPS("next-apeps"),
+
+ /**
+ * Represents the 'back-to-apeps' parameter constant.
+ */
+ BACK_TO_APEPS("back-to-apeps"),
+
+ /**
+ * Represents the 'is-remote-apeps' parameter constant.
+ */
+ IS_REMOTE_APEPS("is-remote-apeps"),
+
+ /**
+ * Represents the 'more-attributes' parameter constant.
+ */
+ MORE_ATTRIBUTES("more-attributes"),
+
+ /**
+ * Represents the 'attr-filter.number' parameter constant.
+ */
+ ATTRIBUTES_FILTER_NUMBER("attr-filter.number"),
+
+ /**
+ * Represents the 'attr-group' parameter constant.
+ */
+ ATTRIBUTE_GROUPS("attr-group"),
+
+ /**
+ * Represents the 'all' parameter constant for attribute groups.
+ */
+ ATTRIBUTE_GROUPS_ALL("all"),
+
+ /**
+ * Represents the 'none' parameter constant for attribute groups.
+ */
+ ATTRIBUTE_GROUPS_NONE("none"),
+
+ /**
+ * Represents the 'atp.url' parameter constant.
+ */
+ ATP_URL("atp.url"),
+ /**
+ * Represents the 'apepsURL' parameter constant.
+ */
+ APEPS_URL("apepsUrl"),
+
+ /**
+ * Represents the 'apepsCountry' parameter constant.
+ */
+ APEPS_COUNTRY("apepsCountry"),
+
+ /**
+ * Represents the 'apepsAuthRequest' parameter constant.
+ */
+ APEPS_ATTR_REQUEST("apepsAttrRequest"),
+
+ /**
+ * Represents the 'isApepsRequest' parameter constant.
+ */
+ APEPS_REQUEST_COMPLETE("apeps-request-complete"),
+
+ /**
+ * Represents the 'apeps.callbackUrl' parameter constant.
+ */
+ APEPS_CALLBACK_URL("apeps.callbackUrl"),
+ /**
+ * Represents the 'attrListMand' parameter constant.
+ */
+ ATTR_LIST_MAND("attrListMand"),
+
+ /**
+ * Represents the 'attrListOpt' parameter constant.
+ */
+ ATTR_LIST_OPT("attrListOpt"),
+
+ /**
+ * Represents the 'simpleAttrListMand' parameter constant.
+ */
+ SIMPLE_ATTR_LIST_MAND("simpleAttrListMand"),
+
+ /**
+ * Represents the 'simpleAttrListOpt' parameter constant.
+ */
+ SIMPLE_ATTR_LIST_OPT("simpleAttrListOpt"),
+
+ /**
+ * Represents the 'complexAttrListMand' parameter constant.
+ */
+ COMPLEX_ATTR_LIST_MAND("complexAttrListMand"),
+
+ /**
+ * Represents the 'complexAttrListOpt' parameter constant.
+ */
+ COMPLEX_ATTR_LIST_OPT("complexAttrListOpt");
+
+ /**
+ * Represents the constant's value.
+ */
+ private String value;
+
+ /**
+ * Solo Constructor.
+ *
+ * @param nValue The Constant value.
+ */
+ PEPSParameters(final String nValue) {
+ this.value = nValue;
+ }
+
+ /**
+ * Return the Constant Value.
+ *
+ * @return The constant value.
+ */
+ public String toString() {
+ return value;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PEPSUtil.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PEPSUtil.java.svn-base
new file mode 100644
index 000000000..69729c0bb
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PEPSUtil.java.svn-base
@@ -0,0 +1,391 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.io.ByteArrayInputStream;
+import java.io.InputStream;
+import java.io.UnsupportedEncodingException;
+import java.util.Properties;
+
+import org.apache.commons.lang.StringUtils;
+import org.apache.log4j.Logger;
+import org.bouncycastle.crypto.Digest;
+import org.bouncycastle.util.encoders.Base64;
+import org.bouncycastle.util.encoders.UrlBase64;
+
+import eu.stork.peps.auth.commons.exceptions.InternalErrorPEPSException;
+import eu.stork.peps.auth.commons.exceptions.InvalidParameterPEPSException;
+
+/**
+ * This class holds static helper methods.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.75 $, $Date: 2010-11-23 00:05:35 $
+ */
+public final class PEPSUtil {
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(PEPSUtil.class.getName());
+
+ /**
+ * Configurations object.
+ */
+ private static Properties configs;
+
+ /**
+ * Max prefix.
+ */
+ private static final String MAX_PARAM_PREFIX = "max.";
+
+ /**
+ * Code prefix to get error code.
+ */
+ private static final String CODE_PARAM_SUFFIX = ".code";
+
+ /**
+ * param's size prefix to get max param size.
+ */
+ private static final String MAX_PARAM_SUFFIX = ".size";
+
+ /**
+ * Message prefix to get error message.
+ */
+ private static final String MSG_PARAM_SUFFIX = ".message";
+
+ /**
+ * Private constructor. Prevents the class from being instantiated.
+ */
+ private PEPSUtil() {
+ // empty constructor
+ }
+
+ /**
+ * Creates a single instance of this class and sets the properties.
+ *
+ * @param nConfigs The set of available configurations.
+ *
+ * @return The created PEPSUtil's class.
+ */
+ public static PEPSUtil createInstance(final Properties nConfigs) {
+ if (nConfigs != null) {
+ PEPSUtil.configs = nConfigs;
+ }
+ return new PEPSUtil();
+ }
+
+ /**
+ * Getter for the Properties.
+ *
+ * @return configs The properties value.
+ */
+ public Properties getConfigs() {
+ return configs;
+ }
+
+ /**
+ * Setter for the Properties.
+ *
+ * @param nConfigs The new properties value.
+ */
+ public static void setConfigs(final Properties nConfigs) {
+ if (nConfigs != null) {
+ PEPSUtil.configs = nConfigs;
+ }
+ }
+
+ /**
+ * Returns the identifier of some configuration given a set of configurations
+ * and the corresponding configuration key.
+ *
+ * @param configKey The key that IDs some configuration.
+ *
+ * @return The configuration String value.
+ */
+ public static String getConfig(final String configKey) {
+ return configs.getProperty(configKey);
+ }
+
+ /**
+ * Validates the input paramValue identified by the paramName.
+ *
+ * @param paramName The name of the parameter to validate.
+ * @param paramValue The value of the parameter to validate.
+ *
+ * @return true if the parameter is valid.
+ */
+ public static boolean isValidParameter(final String paramName,
+ final String paramValue) {
+
+ final String validationParam =
+ PEPSUtil.getConfig(PEPSParameters.VALIDATION_ACTIVE.toString());
+ boolean retVal = true;
+
+ final String paramConf = MAX_PARAM_PREFIX + paramName + MAX_PARAM_SUFFIX;
+
+ if (PEPSValues.TRUE.toString().equals(validationParam)) {
+ final String paramSizeStr = PEPSUtil.getConfig(paramConf);
+ // Checking if the parameter size exists and if it's numeric
+ if (StringUtils.isNumeric(paramSizeStr)) {
+ final int maxParamSize = Integer.valueOf(paramSizeStr);
+ if (StringUtils.isEmpty(paramValue)
+ || paramValue.length() > maxParamSize) {
+ retVal = false;
+ LOG.warn("Invalid parameter [" + paramName + "] value " + paramValue);
+ }
+ } else {
+ retVal = false;
+ LOG.error("Missing " + paramConf
+ + " configuration in the pepsUtils.properties configuration file");
+ }
+ }
+ return retVal;
+ }
+
+ /**
+ * Validates the Parameter and throws an exception if an error occurs. Throws
+ * an InvalidParameterPEPSException runtime exception if the parameter is
+ * invalid.
+ *
+ * @param className The Class Name that invoked the method.
+ * @param paramName The name of the parameter to validate.
+ * @param paramValue The value of the parameter to validate.
+ */
+ public static void validateParameter(final String className,
+ final String paramName, final Object paramValue) {
+
+ if (paramValue == null) {
+ PEPSUtil.validateParameter(className, paramName, "");
+ } else {
+ PEPSUtil.validateParameter(className, paramName, paramValue.toString());
+ }
+ }
+
+ /**
+ * Validates the Parameters and throws an exception if an error occurs.
+ *
+ * @param className The Class Name that invoked the method.
+ * @param paramName The name of the parameter to validate.
+ * @param paramValue The value of the parameter to validate.
+ */
+ public static void validateParameter(final String className,
+ final String paramName, final String paramValue) {
+
+ PEPSUtil.validateParameter(className, paramName, paramValue,
+ PEPSUtil.getErrorCode(paramName), PEPSUtil.getErrorMessage(paramName));
+ }
+
+ /**
+ * Validates the Parameters and throws an exception if an error occurs.
+ *
+ * @param className The Class Name that invoked the method.
+ * @param paramName The name of the parameter to validate.
+ * @param paramValue The value of the parameter to validate.
+ * @param error The PEPSError to get error code and messages from configs.
+ */
+ public static void validateParameter(final String className,
+ final String paramName, final String paramValue, final PEPSErrors error) {
+
+ PEPSUtil.validateParameter(className, paramName, paramValue,
+ PEPSUtil.getConfig(error.errorCode()),
+ PEPSUtil.getConfig(error.errorMessage()));
+ }
+
+ /**
+ * Validates the HTTP Parameter and throws an exception if an error occurs.
+ * Throws an InvalidParameterPEPSException runtime exception if the parameter
+ * is invalid.
+ *
+ * @param className The Class Name that invoked the method.
+ * @param paramName The name of the parameter to validate.
+ * @param paramValue The value of the parameter to validate.
+ * @param errorCode The error code to include on the exception.
+ * @param errorMessage The error message to include on the exception.
+ */
+ public static void validateParameter(final String className,
+ final String paramName, final String paramValue, final String errorCode,
+ final String errorMessage) {
+
+ if (!isValidParameter(paramName, paramValue)) {
+ LOG.warn("Invalid parameter [" + paramName + "] value found at "
+ + className);
+ throw new InvalidParameterPEPSException(errorCode, errorMessage);
+ }
+ }
+
+ /**
+ * Getter for the error code of some given error related to the input param.
+ *
+ * @param paramName The name of the parameter associated with the error.
+ *
+ * @return The code of the error.
+ */
+ private static String getErrorCode(final String paramName) {
+ return getConfig(paramName + CODE_PARAM_SUFFIX);
+ }
+
+ /**
+ * Getter for the error message of some given error related to the input
+ * parameter.
+ *
+ * @param paramName The name of the parameter associated with the message.
+ *
+ * @return The message for the error.
+ */
+ private static String getErrorMessage(final String paramName) {
+ return getConfig(paramName + MSG_PARAM_SUFFIX);
+ }
+
+ /**
+ * {@link Base64} encodes the input samlToken parameter.
+ *
+ * @param samlToken the SAML Token to be encoded.
+ *
+ * @return The Base64 String representing the samlToken.
+ *
+ * @see Base64#encode
+ */
+ public static String encodeSAMLToken(final byte[] samlToken) {
+ try {
+ return new String(Base64.encode(samlToken), "UTF8");
+ } catch (final UnsupportedEncodingException e) {
+ LOG.error(PEPSErrors.INTERNAL_ERROR.errorMessage(), e);
+ return null;
+ }
+ }
+
+ /**
+ * Encode samltoken url safe
+ * @param samlToken the saml token to encode
+ * @return the bas64 encoded string
+ */
+ public static String encodeSAMLTokenUrlSafe(final byte[] samlToken) {
+ try {
+ return new String(UrlBase64.encode(samlToken), "UTF8");
+ } catch (final UnsupportedEncodingException e) {
+ LOG.error(PEPSErrors.INTERNAL_ERROR.errorMessage(), e);
+ return null;
+ }
+ }
+
+ /**
+ * Decodes the {@link Base64} String input parameter representing a samlToken.
+ *
+ * @param samlToken the SAML Token to be decoded.
+ *
+ * @return The samlToken decoded bytes.
+ *
+ * @see Base64#decode
+ */
+ public static byte[] decodeSAMLToken(final String samlToken) {
+ return Base64.decode(samlToken);
+ }
+
+ /**
+ * Decode URL save base64 saml token
+ * @param samlToken the SAML toke to decode
+ * @return The decoded bytes
+ */
+ public static byte[] decodeSAMLTokenUrlSafe(final String samlToken) {
+ return UrlBase64.decode(samlToken);
+ }
+
+ /**
+ * Hashes a SAML token. Throws an InternalErrorPEPSException runtime exception
+ * if the Cryptographic Engine fails.
+ *
+ * @param samlToken the SAML Token to be hashed.
+ *
+ * @return byte[] with the hashed SAML Token.
+ */
+ public static byte[] hashPersonalToken(final byte[] samlToken) {
+ try {
+ final String className =
+ PEPSUtil.getConfig(PEPSValues.HASH_DIGEST_CLASS.toString());
+
+ final Digest digest =
+ (Digest) Class.forName(className).getConstructor()
+ .newInstance((Object[]) null);
+ digest.update(samlToken, 0, samlToken.length);
+
+ final int retLength = digest.getDigestSize();
+ final byte[] ret = new byte[retLength];
+
+ digest.doFinal(ret, 0);
+ return ret;
+
+ } catch (final Exception e) {
+ // For all those exceptions that could be thrown, we always log it and
+ // thrown an InternalErrorPEPSException.
+ LOG.error(PEPSErrors.HASH_ERROR.errorMessage(), e);
+ throw new InternalErrorPEPSException(
+ PEPSUtil.getConfig(PEPSErrors.HASH_ERROR.errorCode()),
+ PEPSUtil.getConfig(PEPSErrors.HASH_ERROR.errorMessage()), e);
+ }
+ }
+
+ /**
+ * Gets the Stork error code in the error message if exists!
+ *
+ * @param errorMessage The message to get the error code if exists;
+ *
+ * @return the error code if exists. Returns null otherwise.
+ */
+ public static String getStorkErrorCode(final String errorMessage) {
+ if (StringUtils.isNotBlank(errorMessage)
+ && errorMessage.indexOf(PEPSValues.ERROR_MESSAGE_SEP.toString()) >= 0) {
+ final String[] msgSplitted =
+ errorMessage.split(PEPSValues.ERROR_MESSAGE_SEP.toString());
+ if (msgSplitted.length == 2 && StringUtils.isNumeric(msgSplitted[0])) {
+ return msgSplitted[0];
+ }
+ }
+ return null;
+ }
+
+ /**
+ * Gets the Stork error message in the saml message if exists!
+ *
+ * @param errorMessage The message to get in the saml message if exists;
+ *
+ * @return the error message if exists. Returns the original message
+ * otherwise.
+ */
+ public static String getStorkErrorMessage(final String errorMessage) {
+ if (StringUtils.isNotBlank(errorMessage)
+ && errorMessage.indexOf(PEPSValues.ERROR_MESSAGE_SEP.toString()) >= 0) {
+ final String[] msgSplitted =
+ errorMessage.split(PEPSValues.ERROR_MESSAGE_SEP.toString());
+ if (msgSplitted.length == 2 && StringUtils.isNumeric(msgSplitted[0])) {
+ return msgSplitted[1];
+ }
+ }
+ return errorMessage;
+ }
+
+ /**
+ * Get inputstream from string
+ * @param string the string to convert
+ * @param codePage the codepage of string
+ * @return an inputstream
+ * @throws UnsupportedEncodingException
+ */
+ public static InputStream getStream(final String string, final String codePage) throws UnsupportedEncodingException
+ {
+ return new ByteArrayInputStream(string.getBytes(codePage));
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PEPSValues.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PEPSValues.java.svn-base
new file mode 100644
index 000000000..89cf8fa9b
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PEPSValues.java.svn-base
@@ -0,0 +1,342 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+/**
+ * This enum class contains all the value constants.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.17 $, $Date: 2011-07-07 20:48:45 $
+ */
+public enum PEPSValues {
+
+ /**
+ * Represents the 'all' constant value.
+ */
+ ALL("all"),
+ /**
+ * Represents the 'none' constant value.
+ */
+ NONE("none"),
+ /**
+ * Represents the 'true' constant value.
+ */
+ TRUE("true"),
+ /**
+ * Represents the 'false' constant value.
+ */
+ FALSE("false"),
+ /**
+ * Represents the empty string constant value.
+ */
+ EMPTY_STRING(""),
+
+ /**
+ * Represents the ',' separator constant value.
+ */
+ ATTRIBUTE_VALUE_SEP(","),
+ /**
+ * Represents the ';' separator constant value.
+ */
+ ATTRIBUTE_SEP(";"),
+ /**
+ * Represents the ':' separator constant value.
+ */
+ ATTRIBUTE_TUPLE_SEP(":"),
+ /**
+ * Represents the '/' separator constant value.
+ */
+ EID_SEPARATOR("/"),
+ /**
+ * Represents the ' - ' separator constant value.
+ */
+ ERROR_MESSAGE_SEP(" - "),
+ /**
+ * Represents the '#' parameter constant value.
+ */
+ LOGGER_SEP("#"),
+ /**
+ * Represents the 'NOT_AVAILABLE' parameter constant value.
+ */
+ NOT_AVAILABLE("NotAvailable"),
+ /**
+ * Represents the ';' parameter constant value.
+ */
+ SPEPS_AUTHORIZED_SEP(";"),
+
+ /**
+ * Represents the 'ap' constant value.
+ */
+ AP("ap"),
+ /**
+ * Represents the 'C-PEPS' constant value.
+ */
+ CPEPS("C-PEPS"),
+ /**
+ * Represents the 'cpeps' constant value.
+ */
+ CPEPS_PREFIX("cpeps"),
+ /**
+ * Represents the 'peps' constant value.
+ */
+ PEPS("peps"),
+ /**
+ * Represents the '-PEPS' constant value.
+ */
+ PEPS_SUFFIX("-PEPS"),
+ /**
+ * Represents the 'SP' constant value.
+ */
+ SP("SP"),
+ /**
+ * Represents the 'S-PEPS' constant value.
+ */
+ SPEPS("S-PEPS"),
+ /**
+ * Represents the 'speps' constant value.
+ */
+ SPEPS_PREFIX("speps"),
+ /**
+ * Represents the 'sp.default.parameters' constant value.
+ */
+ DEFAULT("sp.default.parameters"),
+ /**
+ * Represents the default saml id constant value.
+ */
+ DEFAULT_SAML_ID("1"),
+ /**
+ * Represents the 'hashDigest.className' constant value.
+ */
+ HASH_DIGEST_CLASS("hashDigest.className"),
+
+ /**
+ * Represents the 'eu.stork.communication.requests' constant value.
+ */
+ STORK_PACKAGE_REQUEST_LOGGER_VALUE("eu.stork.communication.requests"),
+ /**
+ * Represents the 'eu.stork.communication.responses' constant value.
+ */
+ STORK_PACKAGE_RESPONSE_LOGGER_VALUE("eu.stork.communication.responses"),
+
+ /**
+ * Represents the 'S-PEPS receives request from SP' constant value.
+ */
+ SP_REQUEST("S-PEPS receives request from SP"),
+ /**
+ * Represents the 'Get Citizen Consent' constant value.
+ */
+ CITIZEN_CONSENT_LOG("Get Citizen Consent"),
+ /**
+ * Represents the 'C-PEPS receives request from S-PEPS' constant value.
+ */
+ CPEPS_REQUEST("C-PEPS receives request from S-PEPS"),
+ /**
+ * Represents the 'C-PEPS generates response to S-PEPS' constant value.
+ */
+ CPEPS_RESPONSE("C-PEPS generates response to S-PEPS"),
+ /**
+ * Represents the 'S-PEPS generates request to C-PEPS' constant value.
+ */
+ SPEPS_REQUEST("S-PEPS generates request to C-PEPS"),
+ /**
+ * Represents the 'S-PEPS receives response from C-PEPS' constant value.
+ */
+ SPEPS_RESPONSE("S-PEPS receives response from C-PEPS"),
+ /**
+ * Represents the 'S-PEPS generates response to SP' constant value.
+ */
+ SP_RESPONSE("S-PEPS generates response to SP"),
+ /**
+ * Represents the 'Success' constant value.
+ */
+ SUCCESS("Success"),
+ /**
+ * Represents the December's month number constant value.
+ */
+ LAST_MONTH("12"),
+ /**
+ * Represents the yyyyMM constant value.
+ */
+ NO_DAY_DATE_FORMAT("yyyyMM"),
+
+ /**
+ * Represents the 'attrValue' constant value.
+ */
+ ATTRIBUTE("attrValue"),
+ /**
+ * Represents the 'derivedAttr' constant value.
+ */
+ DERIVE_ATTRIBUTE("deriveAttr"),
+ /**
+ * Represents the 'storkAttribute' constant value.
+ */
+ STORK_ATTRIBUTE("storkAttribute"),
+
+ /**
+ * Represents the 'properties' constant value.
+ */
+ PROPERTIES("properties"),
+ /**
+ * Represents the 'referer' constant value.
+ */
+ REFERER("referer"),
+ /**
+ * Represents the 'host' constant value.
+ */
+ HOST("host"),
+ /**
+ * Represents the 'spid' constant value.
+ */
+ SPID("spid"),
+ /**
+ * Represents the 'domain' constant value.
+ */
+ DOMAIN("domain"),
+ /**
+ * Represents the '.validation' constant value.
+ */
+ VALIDATION_SUFFIX(".validation"),
+ /**
+ * Represents the 'jsessionid' constant value.
+ */
+ EQUAL("="),
+ /**
+ * Represents the 'HttpOnly' constant value.
+ */
+ HTTP_ONLY("HttpOnly"),
+ /**
+ * Represents the 'SET-COOKIE' constant value.
+ */
+ JSSESSION("JSESSIONID"),
+ /**
+ * Represents the '=' constant value.
+ */
+ SETCOOKIE("SET-COOKIE"),
+ /**
+ * Represents the ';' constant value.
+ */
+ SEMICOLON(";"),
+ /**
+ * Represents the ' ' constant value.
+ */
+ SPACE(" "),
+ /**
+ * Represents the 'atp' constant value.
+ */
+ APROVIDER_PREFIX("atp"),
+ /**
+ * Represents the 'atn' constant value.
+ */
+ ANAME_PREFIX("atn"),
+ /**
+ * Represents the 'ap-cpeps' constant value.
+ */
+ AP_CPEPS_PREFIX("ap-cpeps"),
+ /**
+ * Represents the 'attr-filter' constant value.
+ */
+ AP_ATTRFILTER_PREFIX("attr-filter");
+
+ /**
+ * Represents the constant's value.
+ */
+ private String value;
+
+ /**
+ * Solo Constructor.
+ *
+ * @param val The Constant value.
+ */
+ PEPSValues(final String val) {
+
+ this.value = val;
+ }
+
+ /**
+ * Return the Constant Value.
+ *
+ * @return The constant value.
+ */
+ public String toString() {
+
+ return value;
+ }
+
+ /**
+ * Construct the return value with the following structure
+ * CONSTANT_VALUE+index+".id".
+ *
+ * @param index the number.
+ *
+ * @return The concatenated String value.
+ */
+ public String index(final int index) {
+
+ return value + index + ".id";
+ }
+
+ /**
+ * Construct the return value with the following structure
+ * CONSTANT_VALUE+index+".value".
+ *
+ * @param index the number.
+ *
+ * @return The concatenated string value.
+ */
+ public String value(final int index) {
+
+ return value + index + ".value";
+ }
+
+ /**
+ * Construct the return value with the following structure
+ * CONSTANT_VALUE+index+".name".
+ *
+ * @param index the number.
+ *
+ * @return The concatenated String value.
+ */
+ public String name(final int index) {
+
+ return value + index + ".name";
+ }
+
+ /**
+ * Construct the return value with the following structure
+ * CONSTANT_VALUE+index+".url".
+ *
+ * @param index the number.
+ *
+ * @return The concatenated String value.
+ */
+ public String url(final int index) {
+
+ return value + index + ".url";
+ }
+
+ /**
+ * Construct the return value with the following structure
+ * CONSTANT_VALUE+index+".allowedGroups".
+ *
+ * @param index the number.
+ *
+ * @return The concatenated String value.
+ */
+ public String allowedGroups(final int index) {
+
+ return value + index + ".allowedGroups";
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PersonalAttribute.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PersonalAttribute.java.svn-base
new file mode 100644
index 000000000..5d8281445
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PersonalAttribute.java.svn-base
@@ -0,0 +1,348 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.concurrent.ConcurrentHashMap;
+
+import org.apache.log4j.Logger;
+
+import eu.stork.peps.auth.commons.exceptions.InternalErrorPEPSException;
+
+/**
+ * This class is a bean used to store the information relative to the
+ * PersonalAttribute.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.22 $, $Date: 2010-11-17 05:15:28 $
+ */
+public final class PersonalAttribute implements Serializable, Cloneable {
+
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 2612951678412632174L;
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(PersonalAttribute.class
+ .getName());
+
+ /**
+ * Name of the personal attribute.
+ */
+ private String name;
+
+ /**
+ * Values of the personal attribute.
+ */
+ private List<String> value = new ArrayList<String>();
+
+ /**
+ * Type of the personal attribute.
+ */
+ private String type;
+
+ /**
+ * Complex values of the personal attribute.
+ */
+ private Map<String, String> complexValue = new ConcurrentHashMap<String, String>();
+
+ /**
+ * Is the personal attribute mandatory?
+ */
+ private transient boolean required;
+
+ /**
+ * Returned status of the attribute from the IdP.
+ */
+ private String status;
+
+ /**
+ * Name of the personal attribute.
+ */
+ private String friendlyName;
+
+ /**
+ * Empty Constructor.
+ */
+ public PersonalAttribute() {
+ super();
+ }
+
+ /**
+ * PersonalAttribute Constructor for complex values.
+ *
+ * @param attrName The attribute name.
+ * @param attrIsRequired The attribute type value.
+ * @param attrComplexValue The attribute's value.
+ * @param attrStatus The attribute's status value.
+ */
+ public PersonalAttribute(final String attrName, final boolean attrIsRequired,
+ final List<String> attrComplexValue, final String attrStatus) {
+ this.setName(attrName);
+ this.setIsRequired(attrIsRequired);
+ this.setValue(attrComplexValue);
+ this.setStatus(attrStatus);
+ }
+
+ /**
+ * PersonalAttribute Constructor for complex values.
+ *
+ * @param attrName The attribute name.
+ * @param attrIsRequired The attribute type value.
+ * @param attrComplexValue The attribute's complex value.
+ * @param attrStatus The attribute's status value.
+ */
+ public PersonalAttribute(final String attrName, final boolean attrIsRequired,
+ final Map<String, String> attrComplexValue, final String attrStatus) {
+ this.setName(attrName);
+ this.setIsRequired(attrIsRequired);
+ this.setComplexValue(attrComplexValue);
+ this.setStatus(attrStatus);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @SuppressWarnings("unchecked")
+ public Object clone() {
+
+ try {
+ final PersonalAttribute personalAttr = (PersonalAttribute) super.clone();
+ personalAttr.setIsRequired(this.isRequired());
+ personalAttr.setName(this.getName());
+ personalAttr.setStatus(this.getStatus());
+ if (!isEmptyValue()) {
+ final List<String> val =
+ (List<String>) ((ArrayList<String>) this.getValue()).clone();
+ personalAttr.setValue(val);
+ }
+ if (!isEmptyComplexValue()) {
+ final Map<String, String> complexVal =
+ (Map<String, String>) ((HashMap<String, String>) this
+ .getComplexValue()).clone();
+ personalAttr.setComplexValue(complexVal);
+ }
+ return personalAttr;
+ } catch (final CloneNotSupportedException e) {
+ // assert false;
+ LOG.trace("Nothing to do.");
+ throw new InternalErrorPEPSException(
+ PEPSUtil.getConfig(PEPSErrors.INTERNAL_ERROR.errorCode()),
+ PEPSUtil.getConfig(PEPSErrors.INTERNAL_ERROR.errorMessage()), e);
+ }
+ }
+
+ /**
+ * Getter for the required value.
+ *
+ * @return The required value.
+ */
+ public boolean isRequired() {
+ return required;
+ }
+
+ /**
+ * Setter for the required value.
+ *
+ * @param attrIsRequired this attribute?
+ */
+ public void setIsRequired(final boolean attrIsRequired) {
+ this.required = attrIsRequired;
+ }
+
+ /**
+ * Getter for the name value.
+ *
+ * @return The name value.
+ */
+ public String getName() {
+ return name;
+ }
+
+ /**
+ * Setter for the name value.
+ *
+ * @param attrName The personal attribute name.
+ */
+ public void setName(final String attrName) {
+ this.name = attrName;
+ }
+
+ /**
+ * Getter for the value.
+ *
+ * @return The list of values.
+ */
+ public List<String> getValue() {
+ return value;
+ }
+
+ /**
+ * Setter for the list of values.
+ *
+ * @param attrValue The personal attribute value.
+ */
+ public void setValue(final List<String> attrValue) {
+ if (attrValue != null) {
+ this.value = attrValue;
+ }
+ }
+
+
+ /**
+ * Getter for the type value.
+ *
+ * @return The name value.
+ */
+ public String getType() {
+ return type;
+ }
+
+ /**
+ * Setter for the type value.
+ *
+ * @param attrName The personal attribute type.
+ */
+ public void setType(final String attrType) {
+ this.type = attrType;
+ }
+
+ /**
+ * Getter for the status.
+ *
+ * @return The status value.
+ */
+ public String getStatus() {
+ return status;
+ }
+
+ /**
+ * Setter for the status value.
+ *
+ * @param attrStatus The personal attribute status.
+ */
+ public void setStatus(final String attrStatus) {
+ this.status = attrStatus;
+ }
+
+ /**
+ * Getter for the complex value.
+ *
+ * @return The complex value.
+ */
+ public Map<String, String> getComplexValue() {
+ return complexValue;
+ }
+
+ /**
+ * Setter for the complex value.
+ *
+ * @param complexVal The personal attribute Complex value.
+ */
+ public void setComplexValue(final Map<String, String> complexVal) {
+ if (complexVal != null) {
+ this.complexValue = complexVal;
+ }
+ }
+
+ /**
+ * Getter for the personal's friendly name.
+ *
+ * @return The personal's friendly name value.
+ */
+ public String getFriendlyName() {
+ return friendlyName;
+ }
+
+ /**
+ * Setter for the personal's friendly name.
+ *
+ * @param fName The personal's friendly name.
+ */
+ public void setFriendlyName(final String fName) {
+ this.friendlyName = fName;
+ }
+
+ /**
+ * Return true the value is empty.
+ *
+ * @return True if the value is empty "[]";
+ */
+ public boolean isEmptyValue() {
+ return value.isEmpty() || (value.size() == 1 && value.get(0).length() == 0);
+ }
+
+ /**
+ * Returns true if the Complex Value is empty.
+ *
+ * @return True if the Complex Value is empty;
+ */
+ public boolean isEmptyComplexValue() {
+ return complexValue.isEmpty();
+ }
+
+ /**
+ * Returns true if the Status is empty.
+ *
+ * @return True if the Status is empty;
+ */
+ public boolean isEmptyStatus() {
+ return (status == null || status.length() == 0);
+ }
+
+ /**
+ * Prints the PersonalAttribute in the following format.
+ * name:required:[v,a,l,u,e,s]|[v=a,l=u,e=s]:status;
+ *
+ * @return The PersonalAttribute as a string.
+ */
+ public String toString() {
+ final StringBuilder strBuild = new StringBuilder();
+
+ AttributeUtil.appendIfNotNull(strBuild, getName());
+ strBuild.append(PEPSValues.ATTRIBUTE_TUPLE_SEP.toString());
+ AttributeUtil.appendIfNotNull(strBuild, String.valueOf(isRequired()));
+ strBuild.append(PEPSValues.ATTRIBUTE_TUPLE_SEP.toString());
+ strBuild.append('[');
+
+ if (isEmptyValue()) {
+ if (!isEmptyComplexValue()) {
+ AttributeUtil.appendIfNotNull(strBuild, AttributeUtil.mapToString(
+ getComplexValue(), PEPSValues.ATTRIBUTE_VALUE_SEP.toString()));
+ }
+ } else {
+ AttributeUtil.appendIfNotNull(
+ strBuild,
+ AttributeUtil.listToString(getValue(),
+ PEPSValues.ATTRIBUTE_VALUE_SEP.toString()));
+ }
+
+ strBuild.append(']');
+ strBuild.append(PEPSValues.ATTRIBUTE_TUPLE_SEP.toString());
+ AttributeUtil.appendIfNotNull(strBuild, getStatus());
+ strBuild.append(PEPSValues.ATTRIBUTE_SEP.toString());
+
+ return strBuild.toString();
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PersonalAttributeList.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PersonalAttributeList.java.svn-base
new file mode 100644
index 000000000..642b249d4
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/PersonalAttributeList.java.svn-base
@@ -0,0 +1,396 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.StringTokenizer;
+
+import org.apache.commons.lang.StringUtils;
+import org.apache.log4j.Logger;
+
+/**
+ * This class is a bean used to store the information relative to the
+ * PersonalAttributeList.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.27 $, $Date: 2010-11-18 22:54:56 $
+ *
+ * @see PersonalAttribute
+ */
+@SuppressWarnings("PMD")
+public final class PersonalAttributeList extends
+ ConcurrentHashMap<String, PersonalAttribute> implements IPersonalAttributeList{
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger
+ .getLogger(PersonalAttributeList.class.getName());
+
+ /**
+ * Serial id.
+ */
+ private static final long serialVersionUID = 7375127363889975062L;
+
+ /**
+ * Hash with the latest fetched attribute name alias.
+ */
+ private final transient Map<String, Integer> latestAttrAlias =
+ new HashMap<String, Integer>();
+
+ /**
+ * Hash with mapping number of alias or the attribute name.
+ */
+ private final transient Map<String, Integer> attrAliasNumber =
+ new HashMap<String, Integer>();
+
+ /**
+ * Default constructor.
+ */
+ public PersonalAttributeList() {
+ // The best practices recommend to call the super constructor.
+ super();
+ }
+
+ /**
+ * Constructor with initial capacity for the PersonalAttributeList size.
+ *
+ * @param capacity The initial capacity for the PersonalAttributeList.
+ */
+ public PersonalAttributeList(final int capacity) {
+ super(capacity);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public Iterator<PersonalAttribute> iterator() {
+ return this.values().iterator();
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public PersonalAttribute get(final Object key) {
+ String attrName = (String) key;
+
+ if (this.latestAttrAlias.containsKey(key)) {
+ attrName = attrName + this.latestAttrAlias.get(key);
+ } else {
+ if (this.attrAliasNumber.containsKey(key)) {
+ this.latestAttrAlias.put(attrName, this.attrAliasNumber.get(key));
+ }
+ }
+ return super.get(attrName);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public void add(final PersonalAttribute value) {
+ if (value != null) {
+ this.put(value.getName(), value);
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public PersonalAttribute put(final String key, final PersonalAttribute val) {
+ if (StringUtils.isNotEmpty(key) && val != null) {
+ // Validate if attribute name already exists!
+ String attrAlias = key;
+ if (this.containsKey(attrAlias)) {
+ //TODO isAgeOver should not be hardcoded, a better way of handling multipe isAgeOver requests should be implemented.
+ if (!val.isEmptyValue() && StringUtils.isNumeric(val.getValue().get(0)) && "isAgeOver".equals( val.getName() ) ) {
+ final String attrValue = val.getValue().get(0);
+ attrAlias = key + attrValue;
+ this.attrAliasNumber.put(key, Integer.valueOf(attrValue));
+ } else {
+ final PersonalAttribute attr = super.get(key);
+ if (!attr.isEmptyValue()
+ && StringUtils.isNumeric(attr.getValue().get(0))) {
+ attrAlias = key + attr.getValue().get(0);
+ super.put(key, (PersonalAttribute) attr);
+ this.attrAliasNumber.put(key, null);
+ }
+ }
+ }
+ return super.put(attrAlias, val);
+ } else {
+ return null;
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public void populate(final String attrList) {
+ final StringTokenizer strToken =
+ new StringTokenizer(attrList, PEPSValues.ATTRIBUTE_SEP.toString());
+
+ while (strToken.hasMoreTokens()) {
+ final PersonalAttribute persAttr = new PersonalAttribute();
+ String[] tuples =
+ strToken.nextToken().split(PEPSValues.ATTRIBUTE_TUPLE_SEP.toString(),
+ AttributeConstants.NUMBER_TUPLES.intValue());
+
+ // Convert to the new format if needed!
+ tuples = convertFormat(tuples);
+
+ if (AttributeUtil.hasValidTuples(tuples)) {
+ final int attrValueIndex =
+ AttributeConstants.ATTR_VALUE_INDEX.intValue();
+ final String tmpAttrValue =
+ tuples[attrValueIndex].substring(1,
+ tuples[attrValueIndex].length() - 1);
+ final String[] vals =
+ tmpAttrValue.split(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+
+ persAttr.setName(tuples[AttributeConstants.ATTR_NAME_INDEX.intValue()]);
+ persAttr.setIsRequired(Boolean
+ .valueOf(tuples[AttributeConstants.ATTR_TYPE_INDEX.intValue()]));
+
+ // check if it is a complex value
+ if (isComplexValue(vals)) {
+ persAttr.setComplexValue(createComplexValue(vals));
+ }
+ else
+ {
+ persAttr.setValue(createValues(vals));
+ }
+
+ if (tuples.length == AttributeConstants.NUMBER_TUPLES.intValue()) {
+ persAttr.setStatus(tuples[AttributeConstants.ATTR_STATUS_INDEX
+ .intValue()]);
+ }
+ this.put(tuples[AttributeConstants.ATTR_NAME_INDEX.intValue()],
+ persAttr);
+
+ } else {
+ LOG.warn("Invalid personal attribute list tuples");
+ }
+
+ }
+ }
+
+ /**
+ * Returns a copy of this <tt>IPersonalAttributeList</tt> instance.
+ *
+ * @return The copy of this IPersonalAttributeList.
+ */
+ public Object clone() {
+ try {
+ return (PersonalAttributeList) super.clone();
+ } catch (CloneNotSupportedException e) {
+ return null;
+ }
+ }
+
+ /**
+ * Creates a string in the following format.
+ *
+ * attrName:attrType:[attrValue1,attrValue2=attrComplexValue]:attrStatus;
+ *
+ * @return {@inheritDoc}
+ */
+ @Override
+ public String toString() {
+ final Iterator<Entry<String, PersonalAttribute>> itAttrs =
+ this.entrySet().iterator();
+ final StringBuilder strBuilder = new StringBuilder();
+
+ while (itAttrs.hasNext()) {
+ final Entry<String, PersonalAttribute> attrEntry = itAttrs.next();
+ final PersonalAttribute attr = attrEntry.getValue();
+ //strBuilder.append(attr.toString());
+ strBuilder.insert(0, attr.toString());
+ }
+
+ return strBuilder.toString();
+ }
+
+ /**
+ * Validates and creates the attribute's complex values.
+ *
+ * @param values The complex values.
+ *
+ * @return The {@link Map} with the complex values.
+ *
+ * @see Map
+ */
+ private Map<String, String> createComplexValue(final String[] values) {
+ final Map<String, String> complexValue = new HashMap<String, String>();
+ for (final String val : values) {
+ final String[] tVal = val.split("=");
+ if (StringUtils.isNotEmpty(val) && tVal.length == 2) {
+ complexValue.put(tVal[0], AttributeUtil.unescape(tVal[1]));
+ }
+ }
+ return complexValue;
+ }
+
+ /**
+ * Checks if value is complex or not
+ * @param values The values to check
+ * @return True if succesful
+ */
+ private boolean isComplexValue(final String[] values) {
+ boolean isComplex = false;
+ if (values.length > 0) {
+ final String[] tVal = values[0].split("=");
+ if (StringUtils.isNotEmpty(values[0]) && tVal.length == 2) {
+ isComplex = true;
+ }
+ }
+ return isComplex;
+ }
+
+ /**
+ * Validates and creates the attribute values.
+ *
+ * @param vals The attribute values.
+ *
+ * @return The {@link List} with the attribute values.
+ *
+ * @see List
+ */
+ private List<String> createValues(final String[] vals) {
+ final List<String> values = new ArrayList<String>();
+ for (final String val : vals) {
+ if (StringUtils.isNotEmpty(val)) {
+ values.add(AttributeUtil.unescape(val));
+ }
+ }
+ return values;
+ }
+
+ /**
+ * Converts the attribute tuple (attrName:attrType...) to the new format.
+ *
+ * @param tuples The attribute tuples to convert.
+ *
+ * @return The attribute tuples in the new format.
+ */
+ private String[] convertFormat(final String[] tuples) {
+ final String[] newFormatTuples =
+ new String[AttributeConstants.NUMBER_TUPLES.intValue()];
+ if (tuples != null) {
+ System.arraycopy(tuples, 0, newFormatTuples, 0, tuples.length);
+
+ for (int i = tuples.length; i < newFormatTuples.length; i++) {
+ if (i == AttributeConstants.ATTR_VALUE_INDEX.intValue()) {
+ newFormatTuples[i] = "[]";
+ } else {
+ newFormatTuples[i] = "";
+ }
+ }
+ }
+ return newFormatTuples;
+ }
+
+ /**
+ * Returns a IPersonalAttributeList of the complex attributes in this map.
+ *
+ * @return an IPersonalAttributeList of the complex attributes contained in this map.
+ */
+ public IPersonalAttributeList getComplexAttributes() {
+ LOG.info("get complex attributes");
+ IPersonalAttributeList attrList = new PersonalAttributeList();
+ for(PersonalAttribute attr: this) {
+ if(!attr.getComplexValue().isEmpty()) {
+ attrList.put(attr.getName(), attr);
+ LOG.info("adding complex attribute:"+attr.getName());
+ }
+ }
+ return attrList;
+ }
+
+ /**
+ * Returns a IPersonalAttributeList of the mandatory attributes in this map.
+ *
+ * @return an IPersonalAttributeList of the mandatory attributes contained in this map.
+ */
+ public IPersonalAttributeList getSimpleValueAttributes() {
+ LOG.info("get simple attributes");
+ IPersonalAttributeList attrList = new PersonalAttributeList();
+ for(PersonalAttribute attr: this) {
+ if(attr.getComplexValue().isEmpty()) {
+ attrList.put(attr.getName(), attr);
+ LOG.info("adding simple attribute:"+attr.getName());
+ }
+ }
+ return attrList;
+ }
+
+
+
+ /**
+ * Returns a IPersonalAttributeList of the mandatory attributes in this map.
+ *
+ * @return an IPersonalAttributeList of the mandatory attributes contained in this map.
+ */
+ public IPersonalAttributeList getMandatoryAttributes() {
+ return getAttributesByParam(true);
+ }
+
+
+ /**
+ * Returns a IPersonalAttributeList of the attributes in this map by parameter value.
+ *
+ * @param compareValue The boolean to get mandatory (true) or optional (false) attributes.
+ *
+ * @return an IPersonalAttributeList of the mandatory attributes contained in this map if compareValue is true or optional otherwise.
+ */
+ private IPersonalAttributeList getAttributesByParam(final boolean compareValue) {
+ LOG.info("get attributes by param :"+compareValue);
+ IPersonalAttributeList attrList = new PersonalAttributeList();
+ for(PersonalAttribute attr: this) {
+ if(attr.isRequired() == compareValue) {
+ attrList.put(attr.getName(), attr);
+ LOG.info("adding attribute:"+attr.getName());
+ }
+ }
+ return attrList;
+ }
+
+
+ /**
+ * Returns a IPersonalAttributeList of the optional attributes in this map.
+ *
+ * @return an IPersonalAttributeList of the optional attributes contained in this map.
+ */
+ public IPersonalAttributeList getOptionalAttributes() {
+ return getAttributesByParam(false);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public boolean hasMissingValues() {
+ for(PersonalAttribute attr: this) {
+ if(attr.isEmptyValue() && attr.isEmptyComplexValue()) {
+ return true;
+ }
+ }
+ return false;
+ }
+} \ No newline at end of file
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKAttrQueryRequest.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKAttrQueryRequest.java.svn-base
new file mode 100644
index 000000000..65936f1a8
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKAttrQueryRequest.java.svn-base
@@ -0,0 +1,447 @@
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+
+import org.apache.log4j.Logger;
+
+public class STORKAttrQueryRequest implements Serializable, Cloneable {
+
+ /** The Constant serialVersionUID. */
+ private static final long serialVersionUID = 4778480781609392750L;
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(STORKAttrQueryRequest.class
+ .getName());
+
+ /** The samlId. */
+ private String samlId;
+
+ /** The destination. */
+ private String destination;
+
+ /** The assertion consumer service url. */
+ private String serviceURL;
+
+ /** The distinguished name. */
+ private String distinguishedName;
+
+ /** The e id sector share. */
+ private boolean eIDSectorShare;
+
+ /** The e id cross sector share. */
+ private boolean eIDCrossSectorShare;
+
+ /** The e id cross border share. */
+ private boolean eIDCrossBorderShare;
+
+ /** The personal attribute list. */
+ private IPersonalAttributeList attributeList = new PersonalAttributeList();
+
+ /** The qaa. */
+ private int qaa;
+
+ /** The token saml. */
+ private byte[] tokenSaml = new byte[0];
+
+ /** The issuer. */
+ private String issuer;
+
+ /** The service provider sector. */
+ private String spSector;
+
+ /** The service provider institution. */
+ private String spInstitution;
+
+ /** The service provider application. */
+ private String spApplication;
+
+ /** The service provider country. */
+ private String spCountry;
+
+ /** The country. */
+ private String country;
+
+ /** The citizen country code. */
+ private String citizenCountry;
+
+ /** The Service Provider ID. */
+ private String sPID;
+
+ /** The Alias used at the keystore for saving this certificate. */
+ private String alias;
+
+ /**
+ * Gets the SP's Certificate Alias.
+ *
+ * @return alias The SP's Certificate Alias.
+ */
+ public String getAlias() {
+ return alias;
+ }
+
+ /**
+ * Sets the SP's Certificate Alias.
+ *
+ * @param nAlias The SP's Certificate Alias.
+ */
+ public void setAlias(final String nAlias) {
+ this.alias = nAlias;
+ }
+
+ /**
+ * Gets the SP ID.
+ *
+ * @return sPID The SP ID.
+ */
+ public String getSPID() {
+ return sPID;
+ }
+
+ /**
+ * Sets the SP ID.
+ *
+ * @param sPId The new sp samlId.
+ */
+ public void setSPID(final String sPId) {
+ this.sPID = sPId;
+ }
+
+ /**
+ * Gets the citizen country code.
+ *
+ * @return The citizen country code value.
+ */
+ public String getCitizenCountryCode() {
+ return citizenCountry;
+ }
+
+ /**
+ * Sets the citizen country code.
+ *
+ * @param countryCode the new citizen country code value.
+ */
+ public void setCitizenCountryCode(final String countryCode) {
+ this.citizenCountry = countryCode;
+ }
+
+ /**
+ * Gets the sp country.
+ *
+ * @return The sp country value.
+ */
+ public String getSpCountry() {
+ return spCountry;
+ }
+
+ /**
+ * Sets the sp country.
+ *
+ * @param sPCountry the new sp country value.
+ */
+ public void setSpCountry(final String sPCountry) {
+ this.spCountry = sPCountry;
+ }
+
+ /**
+ * Gets the issuer.
+ *
+ * @return The issuer value.
+ */
+ public String getIssuer() {
+ return issuer;
+ }
+
+ /**
+ * Sets the issuer.
+ *
+ * @param samlIssuer the new issuer value.
+ */
+ public void setIssuer(final String samlIssuer) {
+ this.issuer = samlIssuer;
+ }
+
+ /**
+ * Gets the SAML Token.
+ *
+ * @return The SAML Token value.
+ */
+ public byte[] getTokenSaml() {
+ return tokenSaml.clone();
+ }
+
+ /**
+ * Sets the SAML Token.
+ *
+ * @param samlToken The new SAML Token value.
+ */
+ public void setTokenSaml(final byte[] samlToken) {
+ if (samlToken != null) {
+ this.tokenSaml = samlToken.clone();
+ }
+ }
+
+ /**
+ * Gets the country.
+ *
+ * @return The country value.
+ */
+ public String getCountry() {
+ return country;
+ }
+
+ /**
+ * Sets the country.
+ *
+ * @param nCountry the new country value.
+ */
+ public void setCountry(final String nCountry) {
+ this.country = nCountry;
+ }
+
+ /**
+ * Getter for the qaa value.
+ *
+ * @return The qaa value value.
+ */
+ public int getQaa() {
+ return qaa;
+ }
+
+ /**
+ * Setter for the qaa value.
+ *
+ * @param qaaLevel The new qaa value.
+ */
+ public void setQaa(final int qaaLevel) {
+ this.qaa = qaaLevel;
+ }
+
+ /**
+ * Getter for the serviceURL value.
+ *
+ * @return The serviceURL value.
+ */
+ public String getAssertionConsumerServiceURL() {
+ return serviceURL;
+ }
+
+ /**
+ * Setter for the serviceURL value.
+ *
+ * @param newServiceURL the assertion consumer service URL.
+ */
+ public void setAssertionConsumerServiceURL(final String newServiceURL) {
+ this.serviceURL = newServiceURL;
+ }
+
+ /**
+ * Getter for the destination value.
+ *
+ * @return The destination value.
+ */
+ public String getDestination() {
+ return destination;
+ }
+
+ /**
+ * Setter for the destination value.
+ *
+ * @param detination the new destination value.
+ */
+ public void setDestination(final String detination) {
+ this.destination = detination;
+ }
+
+ /**
+ * Getter for the samlId value.
+ *
+ * @return The samlId value.
+ */
+ public String getSamlId() {
+ return samlId;
+ }
+
+ /**
+ * Setter for the samlId value.
+ *
+ * @param newSamlId the new samlId value.
+ */
+ public void setSamlId(final String newSamlId) {
+ this.samlId = newSamlId;
+ }
+
+
+ /**
+ * Getter for the attributeList value.
+ *
+ * @return The attributeList value.
+ *
+ * @see IPersonalAttributeList
+ */
+ public IPersonalAttributeList getPersonalAttributeList() {
+ IPersonalAttributeList personnalAttributeList = null;
+ try {
+ personnalAttributeList = (IPersonalAttributeList) attributeList.clone();
+ } catch (CloneNotSupportedException e1) {
+ LOG.trace("[PersonalAttribute] Nothing to do.");
+ }
+ return personnalAttributeList;
+ }
+
+ /**
+ * Setter for the attributeList value.
+ *
+ * @param attrList the personal attribute list value.
+ *
+ * @see IPersonalAttributeList
+ */
+ public void setPersonalAttributeList(final IPersonalAttributeList attrList) {
+ if (attrList != null) {
+ this.attributeList = attrList;
+ }
+ }
+
+ /**
+ * Getter for the distinguishedName value.
+ *
+ * @return The distinguishedName value.
+ */
+ public String getDistinguishedName() {
+ return distinguishedName;
+ }
+
+ /**
+ * Setter for the distinguishedName value.
+ *
+ * @param certDN the distinguished name value.
+ */
+ public void setDistinguishedName(final String certDN) {
+ this.distinguishedName = certDN;
+ }
+
+ /**
+ * Gets the service provider sector.
+ *
+ * @return The service provider sector value.
+ */
+ public String getSpSector() {
+ return spSector;
+ }
+
+ /**
+ * Sets the service provider sector.
+ *
+ * @param samlSPSector the new service provider sector value.
+ */
+ public void setSpSector(final String samlSPSector) {
+ this.spSector = samlSPSector;
+ }
+
+ /**
+ * Gets the service provider institution.
+ *
+ * @return The service provider institution value.
+ */
+ public String getSpInstitution() {
+ return spInstitution;
+ }
+
+ /**
+ * Sets the service provider institution.
+ *
+ * @param samlSPInst the new service provider institution value.
+ */
+ public void setSpInstitution(final String samlSPInst) {
+ this.spInstitution = samlSPInst;
+ }
+
+ /**
+ * Gets the service provider application.
+ *
+ * @return The service provider application value.
+ */
+ public String getSpApplication() {
+ return spApplication;
+ }
+
+ /**
+ * Sets the service provider application.
+ *
+ * @param samlSPApp the new service provider application value.
+ */
+ public void setSpApplication(final String samlSPApp) {
+ this.spApplication = samlSPApp;
+ }
+
+ /**
+ * Checks if is eId sector share.
+ *
+ * @return true, if is eId sector share.
+ */
+ public boolean isEIDSectorShare() {
+ return eIDSectorShare;
+ }
+
+ /**
+ * Sets the eId sector share.
+ *
+ * @param eIdSectorShare the new eId sector share value.
+ */
+ public void setEIDSectorShare(final boolean eIdSectorShare) {
+ this.eIDSectorShare = eIdSectorShare;
+ }
+
+ /**
+ * Checks if is eId cross sector share.
+ *
+ * @return true, if is eId cross sector share.
+ */
+ public boolean isEIDCrossSectorShare() {
+ return eIDCrossSectorShare;
+ }
+
+ /**
+ * Sets the eId cross sector share.
+ *
+ * @param eIdCrossSectorShare the new eId cross sector share value.
+ */
+ public void setEIDCrossSectorShare(final boolean eIdCrossSectorShare) {
+ this.eIDCrossSectorShare = eIdCrossSectorShare;
+ }
+
+ /**
+ * Checks if is eId cross border share.
+ *
+ * @return true, if is eId cross border share.
+ */
+ public boolean isEIDCrossBorderShare() {
+ return eIDCrossBorderShare;
+ }
+
+ /**
+ * Sets the eId cross border share.
+ *
+ * @param eIdCrossBorderShare the new eId cross border share value.
+ */
+ public void setEIDCrossBorderShare(final boolean eIdCrossBorderShare) {
+ this.eIDCrossBorderShare = eIdCrossBorderShare;
+ }
+
+ /**
+ * Returns a copy of this <tt>STORKAttrQueryRequest</tt> instance.
+ *
+ * @return The copy of this STORKAttrQueryRequest.
+ * @throws CloneNotSupportedException on clone exception
+ */
+ @Override
+ public Object clone() throws CloneNotSupportedException{
+ STORKAttrQueryRequest storkAttrQueryReq = null;
+ storkAttrQueryReq = (STORKAttrQueryRequest) super.clone();
+ storkAttrQueryReq.setPersonalAttributeList(getPersonalAttributeList());
+ storkAttrQueryReq.setTokenSaml(getTokenSaml());
+ return storkAttrQueryReq;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKAttrQueryResponse.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKAttrQueryResponse.java.svn-base
new file mode 100644
index 000000000..4e40d6d01
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKAttrQueryResponse.java.svn-base
@@ -0,0 +1,388 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.util.List;
+
+import org.apache.log4j.Logger;
+import org.joda.time.DateTime;
+import org.opensaml.saml2.core.Assertion;
+
+public class STORKAttrQueryResponse {
+
+ /** Response Id. */
+ private String samlId;
+
+ /** Request failed? */
+ private boolean fail;
+
+ /** Status code. */
+ private String statusCode;
+
+ /** Secondary status code. */
+ private String subStatusCode;
+
+ /** Audience restriction. */
+ private transient String audienceRest;
+
+ /** Error message. */
+ private String message;
+
+ /** Id of the request that originated this response. */
+ private String inResponseTo;
+
+ /** Expiration date. */
+ private DateTime notOnOrAfter;
+
+ /** Creation date. */
+ private DateTime notBefore;
+
+ /** The SAML token. */
+ private byte[] tokenSaml = new byte[0];
+
+ /** Country. */
+ private String country;
+
+ /** The complete assertion **/
+ private Assertion assertion;
+
+ /** List of all assertions in response **/
+ private List<Assertion> assertions;
+
+ /** The complete list from all assertions **/
+ private transient IPersonalAttributeList totalAttributeList = new PersonalAttributeList();
+
+ /** All personal attribute lists **/
+ private List<IPersonalAttributeList> attributeLists;
+
+ /** Citizen's personal attribute list. */
+ private transient IPersonalAttributeList attributeList = new PersonalAttributeList();
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(STORKAttrQueryResponse.class.getName());
+
+ /**
+ * Getter for the subStatusCode.
+ *
+ * @return The subStatusCode value.
+ */
+ public String getSubStatusCode() {
+ return subStatusCode;
+ }
+
+ /**
+ * Setter for the subStatusCode.
+ *
+ * @param samlSubStatusCode the new subStatusCode value.
+ */
+ public void setSubStatusCode(final String samlSubStatusCode) {
+ this.subStatusCode = samlSubStatusCode;
+ }
+
+ /**
+ * Getter for audienceRest.
+ *
+ * @return The audienceRest value.
+ */
+ public String getAudienceRestriction() {
+ return audienceRest;
+ }
+
+ /**
+ * Setter for audienceRest.
+ *
+ * @param audRest the new audienceRest value.
+ */
+ public void setAudienceRestriction(final String audRest) {
+ this.audienceRest = audRest;
+ }
+
+ /**
+ * Getter for the samlToken.
+ *
+ * @return The samlToken value.
+ */
+ public byte[] getTokenSaml() {
+ return tokenSaml.clone();
+ }
+
+ /**
+ * Setter for samlToken.
+ *
+ * @param samlToken the new tokenSaml value.
+ */
+ public void setTokenSaml(final byte[] samlToken) {
+ if (samlToken != null) {
+ this.tokenSaml = samlToken.clone();
+ }
+ }
+
+ /**
+ * Getter for the country name.
+ *
+ * @return The country name value.
+ */
+ public String getCountry() {
+ return country;
+ }
+
+ /**
+ * Setter for the country name.
+ *
+ * @param cCountry the new country name value.
+ */
+ public void setCountry(final String cCountry) {
+ this.country = cCountry;
+ }
+
+ /**
+ * Getter for pal value.
+ *
+ * @return The pal value.
+ *
+ * @see PersonalAttributeList
+ */
+ public IPersonalAttributeList getPersonalAttributeList() {
+ IPersonalAttributeList personnalAttributeList = null;
+ try {
+ personnalAttributeList = (IPersonalAttributeList) attributeList.clone();
+ } catch (CloneNotSupportedException e1) {
+ LOG.trace("[PersonalAttribute] Nothing to do.");
+ }
+ return personnalAttributeList;
+ }
+
+ /**
+ * Setter for the Personal Attribute List value.
+ *
+ * @param attrList the new value.
+ *
+ * @see PersonalAttributeList
+ */
+ public void setPersonalAttributeList(final IPersonalAttributeList attrList) {
+ if (attrList != null) {
+ this.attributeList = attrList;
+ }
+ }
+
+ /**
+ * Getter for the inResponseTo value.
+ *
+ * @return The inResponseTo value.
+ */
+ public String getInResponseTo() {
+ return inResponseTo;
+ }
+
+ /**
+ * Setter for the inResponseTo value.
+ *
+ * @param samlInResponseTo the new inResponseTo value.
+ */
+ public void setInResponseTo(final String samlInResponseTo) {
+ this.inResponseTo = samlInResponseTo;
+ }
+
+ /**
+ * Getter for the fail value.
+ *
+ * @return The fail value.
+ */
+ public boolean isFail() {
+ return fail;
+ }
+
+ /**
+ * Setter for the fail value.
+ *
+ * @param failVal the new fail value.
+ */
+ public void setFail(final boolean failVal) {
+ this.fail = failVal;
+ }
+
+ /**
+ * Getter for the message value.
+ *
+ * @return The message value.
+ */
+ public String getMessage() {
+ return message;
+ }
+
+ /**
+ * Setter for the message value.
+ *
+ * @param msg the new message value.
+ */
+ public void setMessage(final String msg) {
+ this.message = msg;
+ }
+
+ /**
+ * Getter for the statusCode value.
+ *
+ * @return The statusCode value.
+ */
+ public String getStatusCode() {
+ return statusCode;
+ }
+
+ /**
+ * Setter for the statusCode value.
+ *
+ * @param status the new statusCode value.
+ */
+ public void setStatusCode(final String status) {
+ this.statusCode = status;
+ }
+
+ /**
+ * Getter for the samlId value.
+ *
+ * @return The samlId value.
+ */
+ public String getSamlId() {
+ return samlId;
+ }
+
+ /**
+ * Setter for the samlId value.
+ *
+ * @param nSamlId the new samlId value.
+ */
+ public void setSamlId(final String nSamlId) {
+ this.samlId = nSamlId;
+ }
+
+ /**
+ * Getter for the notOnOrAfter value.
+ *
+ * @return The notOnOrAfter value.
+ *
+ * @see DateTime
+ */
+ public DateTime getNotOnOrAfter() {
+ return this.notOnOrAfter;
+ }
+
+ /**
+ * Setter for the notOnOrAfter value.
+ *
+ * @param nOnOrAfter the new notOnOrAfter value.
+ *
+ * @see DateTime
+ */
+ public void setNotOnOrAfter(final DateTime nOnOrAfter) {
+ this.notOnOrAfter = nOnOrAfter;
+ }
+
+ /**
+ * Getter for the notBefore value.
+ *
+ * @return The notBefore value.
+ *
+ * @see DateTime
+ */
+ public DateTime getNotBefore() {
+ return notBefore;
+ }
+
+ /**
+ * Setter for the notBefore value.
+ *
+ * @param nBefore the new notBefore value.
+ *
+ * @see DateTime
+ */
+ public void setNotBefore(final DateTime nBefore) {
+ this.notBefore = nBefore;
+ }
+
+ /** Get the assertion from the response **/
+ public Assertion getAssertion() {
+ return assertion;
+ }
+
+ /** Set the assertion in the response **/
+ public void setAssertion(final Assertion nAssertion) {
+ this.assertion = nAssertion;
+ }
+
+ public void setAssertions(List<Assertion> newAssert) {
+ this.assertions = newAssert;
+ }
+
+ public List<Assertion> getAssertions() {
+ return assertions;
+ }
+
+ /**
+ * Getter for the toal pal value.
+ *
+ * @return The total pal value.
+ *
+ * @see PersonalAttributeList
+ */
+ public IPersonalAttributeList getTotalPersonalAttributeList() {
+ IPersonalAttributeList personnalAttributeList = null;
+ try {
+ personnalAttributeList = (IPersonalAttributeList) totalAttributeList.clone();
+ } catch (CloneNotSupportedException e1) {
+ LOG.trace("[PersonalAttribute] Nothing to do.");
+ }
+ return personnalAttributeList;
+ }
+
+ /**
+ * Setter for the total Personal Attribute List value.
+ *
+ * @param attrList the new value.
+ *
+ * @see PersonalAttributeList
+ */
+ public void setTotalPersonalAttributeList(final IPersonalAttributeList attrList) {
+ if (attrList != null) {
+ this.totalAttributeList = attrList;
+ }
+ }
+
+ /**
+ * Getter for personal attribute lists
+ *
+ * @return The lists
+ *
+ * @see PersonalAttributeList
+ */
+ public List<IPersonalAttributeList> getPersonalAttributeLists() {
+ return attributeLists;
+ }
+
+ /**
+ * Setter for the Personal Attribute List value.
+ *
+ * @param attrList the new value.
+ *
+ * @see PersonalAttributeList
+ */
+ public void setPersonalAttributeLists(final List<IPersonalAttributeList> attrLists) {
+ if (attrLists != null) {
+ this.attributeLists = attrLists;
+ }
+ }
+
+}
+
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKAuthnRequest.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKAuthnRequest.java.svn-base
new file mode 100644
index 000000000..2354d0eb1
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKAuthnRequest.java.svn-base
@@ -0,0 +1,495 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+
+import org.apache.log4j.Logger;
+
+/**
+ * This class is a bean used to store the information relative to the
+ * STORKAuthnRequest (SAML Token Request).
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.21 $, $Date: 2011-02-17 22:44:34 $
+ */
+public final class STORKAuthnRequest implements Serializable, Cloneable {
+
+ /** The Constant serialVersionUID. */
+ private static final long serialVersionUID = 4778480781609392750L;
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(STORKAuthnRequest.class
+ .getName());
+
+ /** The samlId. */
+ private String samlId;
+
+ /** The assertion consumer service url. */
+ private String serviceURL;
+
+ /** The destination. */
+ private String destination;
+
+ /** The provider name. */
+ private String providerName;
+
+ /** The distinguished name. */
+ private String distinguishedName;
+
+ /** The e id sector share. */
+ private boolean eIDSectorShare;
+
+ /** The e id cross sector share. */
+ private boolean eIDCrossSectorShare;
+
+ /** The e id cross border share. */
+ private boolean eIDCrossBorderShare;
+
+ /** The personal attribute list. */
+ private IPersonalAttributeList attributeList = new PersonalAttributeList();
+
+ /** The qaa. */
+ private int qaa;
+
+ /** The token saml. */
+ private byte[] tokenSaml = new byte[0];
+
+ /** The issuer. */
+ private String issuer;
+
+ /** The service provider sector. */
+ private String spSector;
+
+ /** The service provider institution. */
+ private String spInstitution;
+
+ /** The service provider application. */
+ private String spApplication;
+
+ /** The service provider country. */
+ private String spCountry;
+
+ /** The country. */
+ private String country;
+
+ /** The citizen country code. */
+ private String citizenCountry;
+
+ /** The Service Provider ID. */
+ private String sPID;
+
+ /** The Alias used at the keystore for saving this certificate. */
+ private String alias;
+
+ /**
+ * Gets the SP's Certificate Alias.
+ *
+ * @return alias The SP's Certificate Alias.
+ */
+ public String getAlias() {
+ return alias;
+ }
+
+ /**
+ * Sets the SP's Certificate Alias.
+ *
+ * @param nAlias The SP's Certificate Alias.
+ */
+ public void setAlias(final String nAlias) {
+ this.alias = nAlias;
+ }
+
+ /**
+ * Gets the SP ID.
+ *
+ * @return sPID The SP ID.
+ */
+ public String getSPID() {
+ return sPID;
+ }
+
+ /**
+ * Sets the SP ID.
+ *
+ * @param sPId The new sp samlId.
+ */
+ public void setSPID(final String sPId) {
+ this.sPID = sPId;
+ }
+
+ /**
+ * Gets the citizen country code.
+ *
+ * @return The citizen country code value.
+ */
+ public String getCitizenCountryCode() {
+ return citizenCountry;
+ }
+
+ /**
+ * Sets the citizen country code.
+ *
+ * @param countryCode the new citizen country code value.
+ */
+ public void setCitizenCountryCode(final String countryCode) {
+ this.citizenCountry = countryCode;
+ }
+
+ /**
+ * Gets the sp country.
+ *
+ * @return The sp country value.
+ */
+ public String getSpCountry() {
+ return spCountry;
+ }
+
+ /**
+ * Sets the sp country.
+ *
+ * @param sPCountry the new sp country value.
+ */
+ public void setSpCountry(final String sPCountry) {
+ this.spCountry = sPCountry;
+ }
+
+ /**
+ * Gets the issuer.
+ *
+ * @return The issuer value.
+ */
+ public String getIssuer() {
+ return issuer;
+ }
+
+ /**
+ * Sets the issuer.
+ *
+ * @param samlIssuer the new issuer value.
+ */
+ public void setIssuer(final String samlIssuer) {
+ this.issuer = samlIssuer;
+ }
+
+ /**
+ * Gets the SAML Token.
+ *
+ * @return The SAML Token value.
+ */
+ public byte[] getTokenSaml() {
+ return tokenSaml.clone();
+ }
+
+ /**
+ * Sets the SAML Token.
+ *
+ * @param samlToken The new SAML Token value.
+ */
+ public void setTokenSaml(final byte[] samlToken) {
+ if (samlToken != null) {
+ this.tokenSaml = samlToken.clone();
+ }
+ }
+
+ /**
+ * Gets the country.
+ *
+ * @return The country value.
+ */
+ public String getCountry() {
+ return country;
+ }
+
+ /**
+ * Sets the country.
+ *
+ * @param nCountry the new country value.
+ */
+ public void setCountry(final String nCountry) {
+ this.country = nCountry;
+ }
+
+ /**
+ * Getter for the qaa value.
+ *
+ * @return The qaa value value.
+ */
+ public int getQaa() {
+ return qaa;
+ }
+
+ /**
+ * Setter for the qaa value.
+ *
+ * @param qaaLevel The new qaa value.
+ */
+ public void setQaa(final int qaaLevel) {
+ this.qaa = qaaLevel;
+ }
+
+ /**
+ * Getter for the serviceURL value.
+ *
+ * @return The serviceURL value.
+ */
+ public String getAssertionConsumerServiceURL() {
+ return serviceURL;
+ }
+
+ /**
+ * Setter for the serviceURL value.
+ *
+ * @param newServiceURL the assertion consumer service URL.
+ */
+ public void setAssertionConsumerServiceURL(final String newServiceURL) {
+ this.serviceURL = newServiceURL;
+ }
+
+ /**
+ * Getter for the destination value.
+ *
+ * @return The destination value.
+ */
+ public String getDestination() {
+ return destination;
+ }
+
+ /**
+ * Setter for the destination value.
+ *
+ * @param detination the new destination value.
+ */
+ public void setDestination(final String detination) {
+ this.destination = detination;
+ }
+
+ /**
+ * Getter for the samlId value.
+ *
+ * @return The samlId value.
+ */
+ public String getSamlId() {
+ return samlId;
+ }
+
+ /**
+ * Setter for the samlId value.
+ *
+ * @param newSamlId the new samlId value.
+ */
+ public void setSamlId(final String newSamlId) {
+ this.samlId = newSamlId;
+ }
+
+ /**
+ * Getter for the providerName value.
+ *
+ * @return The provider name value.
+ */
+ public String getProviderName() {
+ return providerName;
+ }
+
+ /**
+ * Setter for the providerName value.
+ *
+ * @param samlProvider the provider name value.
+ */
+ public void setProviderName(final String samlProvider) {
+ this.providerName = samlProvider;
+ }
+
+ /**
+ * Getter for the attributeList value.
+ *
+ * @return The attributeList value.
+ *
+ * @see IPersonalAttributeList
+ */
+ public IPersonalAttributeList getPersonalAttributeList() {
+ IPersonalAttributeList personnalAttributeList = null;
+ try {
+ personnalAttributeList = (IPersonalAttributeList) attributeList.clone();
+ } catch (CloneNotSupportedException e1) {
+ LOG.trace("[PersonalAttribute] Nothing to do.");
+ }
+ return personnalAttributeList;
+ }
+
+ /**
+ * Setter for the attributeList value.
+ *
+ * @param attrList the personal attribute list value.
+ *
+ * @see IPersonalAttributeList
+ */
+ public void setPersonalAttributeList(final IPersonalAttributeList attrList) {
+ if (attrList != null) {
+ this.attributeList = attrList;
+ }
+ }
+
+ /**
+ * Getter for the distinguishedName value.
+ *
+ * @return The distinguishedName value.
+ */
+ public String getDistinguishedName() {
+ return distinguishedName;
+ }
+
+ /**
+ * Setter for the distinguishedName value.
+ *
+ * @param certDN the distinguished name value.
+ */
+ public void setDistinguishedName(final String certDN) {
+ this.distinguishedName = certDN;
+ }
+
+ /**
+ * Gets the service provider sector.
+ *
+ * @return The service provider sector value.
+ */
+ public String getSpSector() {
+ return spSector;
+ }
+
+ /**
+ * Sets the service provider sector.
+ *
+ * @param samlSPSector the new service provider sector value.
+ */
+ public void setSpSector(final String samlSPSector) {
+ this.spSector = samlSPSector;
+ }
+
+ /**
+ * Gets the service provider institution.
+ *
+ * @return The service provider institution value.
+ */
+ public String getSpInstitution() {
+ return spInstitution;
+ }
+
+ /**
+ * Sets the service provider institution.
+ *
+ * @param samlSPInst the new service provider institution value.
+ */
+ public void setSpInstitution(final String samlSPInst) {
+ this.spInstitution = samlSPInst;
+ }
+
+ /**
+ * Gets the service provider application.
+ *
+ * @return The service provider application value.
+ */
+ public String getSpApplication() {
+ return spApplication;
+ }
+
+ /**
+ * Sets the service provider application.
+ *
+ * @param samlSPApp the new service provider application value.
+ */
+ public void setSpApplication(final String samlSPApp) {
+ this.spApplication = samlSPApp;
+ }
+
+ /**
+ * Checks if is eId sector share.
+ *
+ * @return true, if is eId sector share.
+ */
+ public boolean isEIDSectorShare() {
+ return eIDSectorShare;
+ }
+
+ /**
+ * Sets the eId sector share.
+ *
+ * @param eIdSectorShare the new eId sector share value.
+ */
+ public void setEIDSectorShare(final boolean eIdSectorShare) {
+ this.eIDSectorShare = eIdSectorShare;
+ }
+
+ /**
+ * Checks if is eId cross sector share.
+ *
+ * @return true, if is eId cross sector share.
+ */
+ public boolean isEIDCrossSectorShare() {
+ return eIDCrossSectorShare;
+ }
+
+ /**
+ * Sets the eId cross sector share.
+ *
+ * @param eIdCrossSectorShare the new eId cross sector share value.
+ */
+ public void setEIDCrossSectorShare(final boolean eIdCrossSectorShare) {
+ this.eIDCrossSectorShare = eIdCrossSectorShare;
+ }
+
+ /**
+ * Checks if is eId cross border share.
+ *
+ * @return true, if is eId cross border share.
+ */
+ public boolean isEIDCrossBorderShare() {
+ return eIDCrossBorderShare;
+ }
+
+ /**
+ * Sets the eId cross border share.
+ *
+ * @param eIdCrossBorderShare the new eId cross border share value.
+ */
+ public void setEIDCrossBorderShare(final boolean eIdCrossBorderShare) {
+ this.eIDCrossBorderShare = eIdCrossBorderShare;
+ }
+
+ /**
+ * Returns a copy of this <tt>STORKAuthnRequest</tt> instance.
+ *
+ * @return The copy of this STORKAuthnRequest.
+ * @throws CloneNotSupportedException on clone exception
+ */
+ @Override
+ public Object clone() throws CloneNotSupportedException{
+ STORKAuthnRequest storkAuthnReq = null;
+ try {
+ storkAuthnReq = (STORKAuthnRequest) super.clone();
+ storkAuthnReq.setPersonalAttributeList(getPersonalAttributeList());
+ storkAuthnReq.setTokenSaml(getTokenSaml());
+ } catch (final CloneNotSupportedException e) {
+ // assert false;
+ LOG.trace("[PersonalAttribute] Nothing to do.");
+ }
+
+ return storkAuthnReq;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKAuthnResponse.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKAuthnResponse.java.svn-base
new file mode 100644
index 000000000..84fadd023
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKAuthnResponse.java.svn-base
@@ -0,0 +1,383 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.util.List;
+
+import org.apache.log4j.Logger;
+import org.joda.time.DateTime;
+import org.opensaml.saml2.core.Assertion;
+
+/**
+ * This class is a bean used to store the information relative to the
+ * STORKAuthnResponse.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.15 $, $Date: 2010-11-17 05:15:28 $
+ */
+public final class STORKAuthnResponse {
+
+ /** Response Id. */
+ private String samlId;
+
+ /** Authentication failed? */
+ private boolean fail;
+
+ /** Status code. */
+ private String statusCode;
+
+ /** Secondary status code. */
+ private String subStatusCode;
+
+ /** Audience restriction. */
+ private transient String audienceRest;
+
+ /** Error message. */
+ private String message;
+
+ /** Id of the request that originated this response. */
+ private String inResponseTo;
+
+ /** Expiration date. */
+ private DateTime notOnOrAfter;
+
+ /** Creation date. */
+ private DateTime notBefore;
+
+ /** The SAML token. */
+ private byte[] tokenSaml = new byte[0];
+
+ /** Country. */
+ private String country;
+
+ /** Citizen's personal attribute list. */
+ private transient IPersonalAttributeList attributeList = new PersonalAttributeList();
+
+ /** List of all assertions in response **/
+ private List<Assertion> assertions;
+
+ /** The complete list from all assertions **/
+ private transient IPersonalAttributeList totalAttributeList = new PersonalAttributeList();
+
+ /** All personal attribute lists **/
+ private List<IPersonalAttributeList> attributeLists;
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(STORKAuthnResponse.class.getName());
+
+ /**
+ * Getter for the subStatusCode.
+ *
+ * @return The subStatusCode value.
+ */
+ public String getSubStatusCode() {
+ return subStatusCode;
+ }
+
+ /**
+ * Setter for the subStatusCode.
+ *
+ * @param samlSubStatusCode the new subStatusCode value.
+ */
+ public void setSubStatusCode(final String samlSubStatusCode) {
+ this.subStatusCode = samlSubStatusCode;
+ }
+
+ /**
+ * Getter for audienceRest.
+ *
+ * @return The audienceRest value.
+ */
+ public String getAudienceRestriction() {
+ return audienceRest;
+ }
+
+ /**
+ * Setter for audienceRest.
+ *
+ * @param audRest the new audienceRest value.
+ */
+ public void setAudienceRestriction(final String audRest) {
+ this.audienceRest = audRest;
+ }
+
+ /**
+ * Getter for the samlToken.
+ *
+ * @return The samlToken value.
+ */
+ public byte[] getTokenSaml() {
+ return tokenSaml.clone();
+ }
+
+ /**
+ * Setter for samlToken.
+ *
+ * @param samlToken the new tokenSaml value.
+ */
+ public void setTokenSaml(final byte[] samlToken) {
+ if (samlToken != null) {
+ this.tokenSaml = samlToken.clone();
+ }
+ }
+
+ /**
+ * Getter for the country name.
+ *
+ * @return The country name value.
+ */
+ public String getCountry() {
+ return country;
+ }
+
+ /**
+ * Setter for the country name.
+ *
+ * @param cCountry the new country name value.
+ */
+ public void setCountry(final String cCountry) {
+ this.country = cCountry;
+ }
+
+ /**
+ * Getter for pal value.
+ *
+ * @return The pal value.
+ *
+ * @see PersonalAttributeList
+ */
+ public IPersonalAttributeList getPersonalAttributeList() {
+ IPersonalAttributeList personnalAttributeList = null;
+ try {
+ personnalAttributeList = (IPersonalAttributeList) attributeList.clone();
+ } catch (CloneNotSupportedException e1) {
+ LOG.trace("[PersonalAttribute] Nothing to do.");
+ }
+ return personnalAttributeList;
+ }
+
+ /**
+ * Setter for the Personal Attribute List value.
+ *
+ * @param attrList the new value.
+ *
+ * @see PersonalAttributeList
+ */
+ public void setPersonalAttributeList(final IPersonalAttributeList attrList) {
+ if (attrList != null) {
+ this.attributeList = attrList;
+ }
+ }
+
+ /**
+ * Getter for the inResponseTo value.
+ *
+ * @return The inResponseTo value.
+ */
+ public String getInResponseTo() {
+ return inResponseTo;
+ }
+
+ /**
+ * Setter for the inResponseTo value.
+ *
+ * @param samlInResponseTo the new inResponseTo value.
+ */
+ public void setInResponseTo(final String samlInResponseTo) {
+ this.inResponseTo = samlInResponseTo;
+ }
+
+ /**
+ * Getter for the fail value.
+ *
+ * @return The fail value.
+ */
+ public boolean isFail() {
+ return fail;
+ }
+
+ /**
+ * Setter for the fail value.
+ *
+ * @param failVal the new fail value.
+ */
+ public void setFail(final boolean failVal) {
+ this.fail = failVal;
+ }
+
+ /**
+ * Getter for the message value.
+ *
+ * @return The message value.
+ */
+ public String getMessage() {
+ return message;
+ }
+
+ /**
+ * Setter for the message value.
+ *
+ * @param msg the new message value.
+ */
+ public void setMessage(final String msg) {
+ this.message = msg;
+ }
+
+ /**
+ * Getter for the statusCode value.
+ *
+ * @return The statusCode value.
+ */
+ public String getStatusCode() {
+ return statusCode;
+ }
+
+ /**
+ * Setter for the statusCode value.
+ *
+ * @param status the new statusCode value.
+ */
+ public void setStatusCode(final String status) {
+ this.statusCode = status;
+ }
+
+ /**
+ * Getter for the samlId value.
+ *
+ * @return The samlId value.
+ */
+ public String getSamlId() {
+ return samlId;
+ }
+
+ /**
+ * Setter for the samlId value.
+ *
+ * @param nSamlId the new samlId value.
+ */
+ public void setSamlId(final String nSamlId) {
+ this.samlId = nSamlId;
+ }
+
+ /**
+ * Getter for the notOnOrAfter value.
+ *
+ * @return The notOnOrAfter value.
+ *
+ * @see DateTime
+ */
+ public DateTime getNotOnOrAfter() {
+ return this.notOnOrAfter;
+ }
+
+ /**
+ * Setter for the notOnOrAfter value.
+ *
+ * @param nOnOrAfter the new notOnOrAfter value.
+ *
+ * @see DateTime
+ */
+ public void setNotOnOrAfter(final DateTime nOnOrAfter) {
+ this.notOnOrAfter = nOnOrAfter;
+ }
+
+ /**
+ * Getter for the notBefore value.
+ *
+ * @return The notBefore value.
+ *
+ * @see DateTime
+ */
+ public DateTime getNotBefore() {
+ return notBefore;
+ }
+
+ /**
+ * Setter for the notBefore value.
+ *
+ * @param nBefore the new notBefore value.
+ *
+ * @see DateTime
+ */
+ public void setNotBefore(final DateTime nBefore) {
+ this.notBefore = nBefore;
+ }
+
+ public void setAssertions(List<Assertion> newAssert) {
+ this.assertions = newAssert;
+ }
+
+ public List<Assertion> getAssertions() {
+ return assertions;
+ }
+
+ /**
+ * Getter for the toal pal value.
+ *
+ * @return The total pal value.
+ *
+ * @see PersonalAttributeList
+ */
+ public IPersonalAttributeList getTotalPersonalAttributeList() {
+ IPersonalAttributeList personnalAttributeList = null;
+ try {
+ personnalAttributeList = (IPersonalAttributeList) totalAttributeList.clone();
+ } catch (CloneNotSupportedException e1) {
+ LOG.trace("[PersonalAttribute] Nothing to do.");
+ }
+ return personnalAttributeList;
+ }
+
+ /**
+ * Setter for the total Personal Attribute List value.
+ *
+ * @param attrList the new value.
+ *
+ * @see PersonalAttributeList
+ */
+ public void setTotalPersonalAttributeList(final IPersonalAttributeList attrList) {
+ if (attrList != null) {
+ this.totalAttributeList = attrList;
+ }
+ }
+
+ /**
+ * Getter for personal attribute lists
+ *
+ * @return The lists
+ *
+ * @see PersonalAttributeList
+ */
+ public List<IPersonalAttributeList> getPersonalAttributeLists() {
+ return attributeLists;
+ }
+
+ /**
+ * Setter for the Personal Attribute List value.
+ *
+ * @param attrList the new value.
+ *
+ * @see PersonalAttributeList
+ */
+ public void setPersonalAttributeLists(final List<IPersonalAttributeList> attrLists) {
+ if (attrLists != null) {
+ this.attributeLists = attrLists;
+ }
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKLogoutRequest.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKLogoutRequest.java.svn-base
new file mode 100644
index 000000000..44811aee2
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKLogoutRequest.java.svn-base
@@ -0,0 +1,197 @@
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+
+public class STORKLogoutRequest implements Serializable, Cloneable {
+ private static final long serialVersionUID = 4778480781609392750L;
+
+ /** The samlId. */
+ private String samlId;
+
+ /** The destination. */
+ private String destination;
+
+ /** The distinguished name. */
+ private String distinguishedName;
+
+ /** The qaa. */
+ private int qaa;
+
+ /** The token saml. */
+ private byte[] tokenSaml = new byte[0];
+
+ /** The issuer. */
+ private String issuer;
+
+ /** The country. */
+ private String country;
+
+ /** The Alias used at the keystore for saving this certificate. */
+ private String alias;
+
+ /** The ID of principal as known to SP **/
+ private String spProvidedId;
+
+ /**
+ * Gets the SP's Certificate Alias.
+ *
+ * @return alias The SP's Certificate Alias.
+ */
+ public String getAlias() {
+ return alias;
+ }
+
+ /**
+ * Sets the SP's Certificate Alias.
+ *
+ * @param nAlias The SP's Certificate Alias.
+ */
+ public void setAlias(final String nAlias) {
+ this.alias = nAlias;
+ }
+
+ /**
+ * Gets the issuer.
+ *
+ * @return The issuer value.
+ */
+ public String getIssuer() {
+ return issuer;
+ }
+
+ /**
+ * Sets the issuer.
+ *
+ * @param samlIssuer the new issuer value.
+ */
+ public void setIssuer(final String samlIssuer) {
+ this.issuer = samlIssuer;
+ }
+
+ /**
+ * Gets the SAML Token.
+ *
+ * @return The SAML Token value.
+ */
+ public byte[] getTokenSaml() {
+ return tokenSaml.clone();
+ }
+
+ /**
+ * Sets the SAML Token.
+ *
+ * @param samlToken The new SAML Token value.
+ */
+ public void setTokenSaml(final byte[] samlToken) {
+ if (samlToken != null) {
+ this.tokenSaml = samlToken.clone();
+ }
+ }
+
+ /**
+ * Gets the country.
+ *
+ * @return The country value.
+ */
+ public String getCountry() {
+ return country;
+ }
+
+ /**
+ * Sets the country.
+ *
+ * @param nCountry the new country value.
+ */
+ public void setCountry(final String nCountry) {
+ this.country = nCountry;
+ }
+
+ /**
+ * Getter for the qaa value.
+ *
+ * @return The qaa value value.
+ */
+ public int getQaa() {
+ return qaa;
+ }
+
+ /**
+ * Setter for the qaa value.
+ *
+ * @param qaaLevel The new qaa value.
+ */
+ public void setQaa(final int qaaLevel) {
+ this.qaa = qaaLevel;
+ }
+
+ /**
+ * Getter for the destination value.
+ *
+ * @return The destination value.
+ */
+ public String getDestination() {
+ return destination;
+ }
+
+ /**
+ * Setter for the destination value.
+ *
+ * @param detination the new destination value.
+ */
+ public void setDestination(final String detination) {
+ this.destination = detination;
+ }
+
+ /**
+ * Getter for the samlId value.
+ *
+ * @return The samlId value.
+ */
+ public String getSamlId() {
+ return samlId;
+ }
+
+ /**
+ * Setter for the samlId value.
+ *
+ * @param newSamlId the new samlId value.
+ */
+ public void setSamlId(final String newSamlId) {
+ this.samlId = newSamlId;
+ }
+
+ /**
+ * Getter for the distinguishedName value.
+ *
+ * @return The distinguishedName value.
+ */
+ public String getDistinguishedName() {
+ return distinguishedName;
+ }
+
+ /**
+ * Setter for the distinguishedName value.
+ *
+ * @param certDN the distinguished name value.
+ */
+ public void setDistinguishedName(final String certDN) {
+ this.distinguishedName = certDN;
+ }
+
+ /** Getter for spProvidedId **/
+ public String getSpProvidedId() {
+ return spProvidedId;
+ }
+
+ public void setSpProvidedId(final String nSpProvidedId) {
+ this.spProvidedId = nSpProvidedId;
+ }
+
+ @Override
+ public Object clone() throws CloneNotSupportedException{
+ STORKLogoutRequest storkLogoutRequest = null;
+ storkLogoutRequest = (STORKLogoutRequest) super.clone();
+ storkLogoutRequest.setTokenSaml(getTokenSaml());
+ return storkLogoutRequest;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKLogoutResponse.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKLogoutResponse.java.svn-base
new file mode 100644
index 000000000..21b53a652
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKLogoutResponse.java.svn-base
@@ -0,0 +1,250 @@
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+
+public class STORKLogoutResponse implements Serializable, Cloneable {
+ private static final long serialVersionUID = 4778480781609392750L;
+
+ /** The samlId. */
+ private String samlId;
+
+ /** The destination. */
+ private String destination;
+
+ /** The distinguished name. */
+ private String distinguishedName;
+
+ /** The token saml. */
+ private byte[] tokenSaml = new byte[0];
+
+ /** The issuer. */
+ private String issuer;
+
+ /** The country. */
+ private String country;
+
+ /** The Alias used at the keystore for saving this certificate. */
+ private String alias;
+
+ /** Status code. */
+ private String statusCode;
+
+ /** Secondary status code. */
+ private String subStatusCode;
+
+ /** Status message. */
+ private String statusMessage;
+
+ /** Logout failed? */
+ private boolean fail;
+
+ /**
+ * Gets the SP's Certificate Alias.
+ *
+ * @return alias The SP's Certificate Alias.
+ */
+ public String getAlias() {
+ return alias;
+ }
+
+ /**
+ * Sets the SP's Certificate Alias.
+ *
+ * @param nAlias The SP's Certificate Alias.
+ */
+ public void setAlias(final String nAlias) {
+ this.alias = nAlias;
+ }
+
+ /**
+ * Gets the issuer.
+ *
+ * @return The issuer value.
+ */
+ public String getIssuer() {
+ return issuer;
+ }
+
+ /**
+ * Sets the issuer.
+ *
+ * @param samlIssuer the new issuer value.
+ */
+ public void setIssuer(final String samlIssuer) {
+ this.issuer = samlIssuer;
+ }
+
+ /**
+ * Gets the SAML Token.
+ *
+ * @return The SAML Token value.
+ */
+ public byte[] getTokenSaml() {
+ return tokenSaml.clone();
+ }
+
+ /**
+ * Sets the SAML Token.
+ *
+ * @param samlToken The new SAML Token value.
+ */
+ public void setTokenSaml(final byte[] samlToken) {
+ if (samlToken != null) {
+ this.tokenSaml = samlToken.clone();
+ }
+ }
+
+ /**
+ * Gets the country.
+ *
+ * @return The country value.
+ */
+ public String getCountry() {
+ return country;
+ }
+
+ /**
+ * Sets the country.
+ *
+ * @param nCountry the new country value.
+ */
+ public void setCountry(final String nCountry) {
+ this.country = nCountry;
+ }
+
+ /**
+ * Getter for the destination value.
+ *
+ * @return The destination value.
+ */
+ public String getDestination() {
+ return destination;
+ }
+
+ /**
+ * Setter for the destination value.
+ *
+ * @param detination the new destination value.
+ */
+ public void setDestination(final String detination) {
+ this.destination = detination;
+ }
+
+ /**
+ * Getter for the samlId value.
+ *
+ * @return The samlId value.
+ */
+ public String getSamlId() {
+ return samlId;
+ }
+
+ /**
+ * Setter for the samlId value.
+ *
+ * @param newSamlId the new samlId value.
+ */
+ public void setSamlId(final String newSamlId) {
+ this.samlId = newSamlId;
+ }
+
+ /**
+ * Getter for the distinguishedName value.
+ *
+ * @return The distinguishedName value.
+ */
+ public String getDistinguishedName() {
+ return distinguishedName;
+ }
+
+ /**
+ * Setter for the distinguishedName value.
+ *
+ * @param certDN the distinguished name value.
+ */
+ public void setDistinguishedName(final String certDN) {
+ this.distinguishedName = certDN;
+ }
+
+
+ /**
+ * Getter for the fail value.
+ *
+ * @return The fail value.
+ */
+ public boolean isFail() {
+ return fail;
+ }
+
+ /**
+ * Setter for the fail value.
+ *
+ * @param failVal the new fail value.
+ */
+ public void setFail(final boolean failVal) {
+ this.fail = failVal;
+ }
+
+ /**
+ * Getter for the statusCode value.
+ *
+ * @return The statusCode value.
+ */
+ public String getStatusCode() {
+ return statusCode;
+ }
+
+ /**
+ * Getter for the subStatusCode.
+ *
+ * @return The subStatusCode value.
+ */
+ public String getSubStatusCode() {
+ return subStatusCode;
+ }
+
+ /**
+ * Setter for the subStatusCode.
+ *
+ * @param samlSubStatusCode the new subStatusCode value.
+ */
+ public void setSubStatusCode(final String samlSubStatusCode) {
+ this.subStatusCode = samlSubStatusCode;
+ }
+
+ /**
+ * Setter for the statusMessage value.
+ *
+ * @param status the new statusMessage value.
+ */
+ public void setStatusMessage(final String status) {
+ this.statusMessage = status;
+ }
+
+ /**
+ * Getter for the statusMessage value.
+ *
+ * @return The statusMessage value.
+ */
+ public String getStatusMessage() {
+ return statusMessage;
+ }
+
+ /**
+ * Setter for the statusCode value.
+ *
+ * @param status the new statusCode value.
+ */
+ public void setStatusCode(final String status) {
+ this.statusCode = status;
+ }
+
+ @Override
+ public Object clone() throws CloneNotSupportedException{
+ STORKLogoutResponse storkLogoutResponse = null;
+ storkLogoutResponse = (STORKLogoutResponse) super.clone();
+ storkLogoutResponse.setTokenSaml(getTokenSaml());
+ return storkLogoutResponse;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKStatusCode.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKStatusCode.java.svn-base
new file mode 100644
index 000000000..a9c4a156b
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKStatusCode.java.svn-base
@@ -0,0 +1,68 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+/**
+ * This enum class contains the SAML Token Status Code.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.13 $, $Date: 2010-11-17 05:15:28 $
+ */
+public enum STORKStatusCode {
+
+ /** URI for Requester status code. */
+ REQUESTER_URI("urn:oasis:names:tc:SAML:2.0:status:Requester"),
+
+ /** URI for Responder status code. */
+ RESPONDER_URI("urn:oasis:names:tc:SAML:2.0:status:Responder"),
+
+ /** URI for Success status code. */
+ SUCCESS_URI("urn:oasis:names:tc:SAML:2.0:status:Success"),
+
+ /** Attribute is Available. */
+ STATUS_AVAILABLE("Available"),
+
+ /** Attribute is NotAvailable. */
+ STATUS_NOT_AVAILABLE("NotAvailable"),
+
+ /** Attribute is Withheld. */
+ STATUS_WITHHELD("Withheld");
+
+ /**
+ * Represents the constant's value.
+ */
+ private String value;
+
+ /**
+ * Solo Constructor.
+ *
+ * @param val The Constant value.
+ */
+ private STORKStatusCode(final String val) {
+
+ this.value = val;
+ }
+
+ /**
+ * Return the Constant Value.
+ *
+ * @return The constant value.
+ */
+ public String toString() {
+
+ return value;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKSubStatusCode.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKSubStatusCode.java.svn-base
new file mode 100644
index 000000000..0a711c9b7
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/STORKSubStatusCode.java.svn-base
@@ -0,0 +1,71 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+/**
+ * This enum class contains the SAML Token Sub Status Code.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.7 $, $Date: 2010-11-17 05:15:28 $
+ */
+public enum STORKSubStatusCode {
+
+ /** URI for AuthnFailed status code. */
+ AUTHN_FAILED_URI("urn:oasis:names:tc:SAML:2.0:status:AuthnFailed"),
+
+ /** URI for InvalidAttrNameOrValue status code. */
+ INVALID_ATTR_NAME_VALUE_URI(
+ "urn:oasis:names:tc:SAML:2.0:status:InvalidAttrNameOrValue"),
+
+ /** URI for InvalidNameIDPolicy status code. */
+ INVALID_NAMEID_POLICY_URI(
+ "urn:oasis:names:tc:SAML:2.0:status:InvalidNameIDPolicy"),
+
+ /** URI for VersionMismatch status code. */
+ VERSION_MISMATCH_URI("urn:oasis:names:tc:SAML:2.0:status:VersionMismatch"),
+
+ /** URI for RequestDenied status code. */
+ REQUEST_DENIED_URI("urn:oasis:names:tc:SAML:2.0:status:RequestDenied"),
+
+ /** URI for QaaNotSupported status code. */
+ QAA_NOT_SUPPORTED(
+ "http://www.stork.gov.eu/saml20/statusCodes/QAANotSupported");
+
+ /**
+ * Represents the constant's value.
+ */
+ private String value;
+
+ /**
+ * Solo Constructor.
+ *
+ * @param val The Constant value.
+ */
+ private STORKSubStatusCode(final String val) {
+
+ this.value = val;
+ }
+
+ /**
+ * Return the Constant Value.
+ *
+ * @return The constant value.
+ */
+ public String toString() {
+
+ return value;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/package-info.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/package-info.java.svn-base
new file mode 100644
index 000000000..19d45aaa2
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/.svn/text-base/package-info.java.svn-base
@@ -0,0 +1,9 @@
+/**
+ * Common Authentication Service functionalities to be deployed in every PEPS
+ * is contained in this package.
+ * In particular, it contains the SAML Engine that implements the SAML messages
+ * management
+ *
+ * @since 1.0
+ */
+package eu.stork.peps.auth.commons;
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeConstants.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeConstants.java
new file mode 100644
index 000000000..09769641c
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeConstants.java
@@ -0,0 +1,72 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+/**
+ * This enum class contains all the STORK PEPS, Commons and Specific errors
+ * constant identifiers.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.2 $, $Date: 2010-11-17 05:15:28 $
+ */
+public enum AttributeConstants {
+
+ /**
+ * Represents the attribute's name index.
+ */
+ ATTR_NAME_INDEX(0),
+ /**
+ * Represents the attribute's type index.
+ */
+ ATTR_TYPE_INDEX(1),
+ /**
+ * Represents the attribute's value index.
+ */
+ ATTR_VALUE_INDEX(2),
+ /**
+ * Represents the attribute's status index.
+ */
+ ATTR_STATUS_INDEX(3),
+ /**
+ * Represents the number of allowed tuples.
+ */
+ NUMBER_TUPLES(4);
+
+ /**
+ * Represents the constant's value.
+ */
+ private int attribute;
+
+ /**
+ * Solo Constructor.
+ *
+ * @param attr The Attribute Constant value.
+ */
+ AttributeConstants(final int attr) {
+
+ this.attribute = attr;
+ }
+
+ /**
+ * Return the Constant Value.
+ *
+ * @return The constant value.
+ */
+ public int intValue() {
+
+ return attribute;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeName.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeName.java
new file mode 100644
index 000000000..a44768c7e
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeName.java
@@ -0,0 +1,74 @@
+package eu.stork.peps.auth.commons;
+
+/**
+ * This class is a bean used to store information relative to Attribute Names.
+ *
+ * @author Stelios Lelis (stelios.lelis@aegean.gr), Elias Pastos (ilias@aegean.gr)
+ *
+ * @version $Revision: 1.00 $, $Date: 2013-11-26 $
+ */
+public final class AttributeName {
+
+ /**
+ * Attribute Id.
+ */
+ private String attributeId;
+
+ /**
+ * Attribute Name.
+ */
+ private String attributeName;
+
+ /**
+ * Attribute Name Constructor.
+ *
+ * @param aId Id of the Attribute Name.
+ * @param aName Name of the Attribute Name.
+ */
+ public AttributeName(final String aId, final String aName) {
+
+ this.attributeId = aId;
+ this.attributeName = aName;
+ }
+
+ /**
+ * Getter for the attributeId value.
+ *
+ * @return The attributeId value.
+ */
+ public String getAttributeId() {
+
+ return attributeId;
+ }
+
+ /**
+ * Setter for the attributeId value.
+ *
+ * @param aId Id of the Attribute Name.
+ */
+ public void setAttributeId(final String aId) {
+
+ this.attributeId = aId;
+ }
+
+ /**
+ * Getter for the attributeName value.
+ *
+ * @return The attributeName value.
+ */
+ public String getAttributeName() {
+
+ return attributeName;
+ }
+
+ /**
+ * Setter for the attributeName value.
+ *
+ * @param name Name of the Attribute Name.
+ */
+ public void setAttributeName(final String name) {
+
+ this.attributeName = name;
+ }
+
+} \ No newline at end of file
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeProvider.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeProvider.java
new file mode 100644
index 000000000..575732e27
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeProvider.java
@@ -0,0 +1,123 @@
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+import java.util.List;
+
+/**
+ * This class is a bean used to store the information relative to the Attribute Provider.
+ *
+ * @author Stelios Lelis (stelios.lelis@aegean.gr), Elias Pastos (ilias@aegean.gr)
+ *
+ * @version $Revision: 1.01 $, $Date: 2014-01-13 $
+ */
+public final class AttributeProvider implements Serializable {
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 7210186241917444559L;
+
+ /**
+ * Provider Id.
+ */
+ private String providerId;
+
+ /**
+ * Provider Name.
+ */
+ private String providerName;
+
+ /**
+ * Allowed groups of attribute names.
+ */
+ private List<String> allowedGroups;
+
+ /**
+ * Attribute Provider Constructor.
+ *
+ * @param pId Id of the Attribute Provider.
+ * @param pName Name of the Attribute Provider.
+ */
+ public AttributeProvider(final String pId, final String pName, final List<String> pAllowedGroups) {
+
+ this.providerId = pId;
+ this.providerName = pName;
+ this.allowedGroups = pAllowedGroups;
+ }
+
+ /**
+ * Getter for the providerId value.
+ *
+ * @return The providerId value.
+ */
+ public String getProviderId() {
+
+ return providerId;
+ }
+
+ /**
+ * Setter for the providerId value.
+ *
+ * @param pId Id of the Attribute Provider.
+ */
+ public void setProviderId(final String pId) {
+
+ this.providerId = pId;
+ }
+
+ /**
+ * Getter for the providerName value.
+ *
+ * @return The providerName value.
+ */
+ public String getProviderName() {
+
+ return providerName;
+ }
+
+ /**
+ * Setter for the providerName value.
+ *
+ * @param name Name of the Attribute Provider.
+ */
+ public void setProviderName(final String name) {
+
+ this.providerName = name;
+ }
+
+ /**
+ * Getter for the allowedGroups value.
+ *
+ * @return The allowedGroups value.
+ */
+ public List<String> getAllowedGroups() {
+
+ return allowedGroups;
+ }
+
+ /**
+ * Setter for the allowedGroups value.
+ *
+ * @param name AllowedGroups of the Attribute Provider.
+ */
+ public void setAllowedGroups(final List<String> pAllowedGroups) {
+
+ this.allowedGroups = pAllowedGroups;
+ }
+
+ /**
+ * Check if an attribute name is allowed for this Attribute Provider
+ *
+ * @param pAttrName the Attribute Name to check
+ * @return true if the name is allowed, false otherwise
+ */
+ public boolean isAttributeNameAllowed(final String pAttrName) {
+ if ( allowedGroups==null || pAttrName==null )
+ return false;
+ else if ( allowedGroups.contains(PEPSParameters.ATTRIBUTE_GROUPS_ALL.toString()) )
+ return true;
+ else if ( allowedGroups.contains(PEPSParameters.ATTRIBUTE_GROUPS_NONE.toString()) )
+ return false;
+ else
+ return allowedGroups.contains(pAttrName);
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeProvidersMap.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeProvidersMap.java
new file mode 100644
index 000000000..85aec2625
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeProvidersMap.java
@@ -0,0 +1,96 @@
+package eu.stork.peps.auth.commons;
+
+import java.util.Iterator;
+import java.util.LinkedHashMap;
+
+import org.apache.log4j.Logger;
+
+/**
+ * Implementation of the AttributeProviderMap using a LinkedHashMap.
+ *
+ * @author Stelios Lelis (stelios.lelis@aegean.gr), Elias Pastos (ilias@aegean.gr)
+ *
+ * @version $Revision: 1.01 $, $Date: 2013-09-20 $
+ *
+ * @see LinkedHashMap
+ */
+public class AttributeProvidersMap extends LinkedHashMap<AttributeSource, IPersonalAttributeList>
+ implements IAttributeProvidersMap {
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(AttributeProvidersMap.class.getName());
+
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 8949081185106296122L;
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public IPersonalAttributeList get(final AttributeSource key) {
+ return this.get((Object) key);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public IPersonalAttributeList remove(final AttributeSource key) {
+ return this.remove((Object) key);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public boolean containsKey(final AttributeSource key) {
+ return this.containsKey((Object) key);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public Iterator<AttributeSource> keyIterator() {
+ return this.keySet().iterator();
+ }
+
+ public void trace() {
+ Iterator<AttributeSource> iterator;
+ Iterator<PersonalAttribute> iterator2;
+ AttributeSource source;
+ IPersonalAttributeList pal;
+ PersonalAttribute pa;
+
+ iterator = this.keyIterator();
+ LOG.trace("Start dumping of AttributeProvidersMap\n=======================");
+ while (iterator.hasNext()) {
+ source = iterator.next();
+
+ LOG.trace("Source details: type [" + source.getSourceType() + "], URL [" + source.getProviderURL() + "]");
+
+ if(source.getSourceType() == AttributeSource.SOURCE_LOCAL_APROVIDER) {
+ LOG.trace("-> Attribute Provider: ID [" + source.getProvider().getProviderId() + "], name [" + source.getProvider().getProviderName() + "]");
+ }
+ else {
+ LOG.trace("-> Country: ID [" + source.getCountry().getCountryId() + "], name [" + source.getCountry().getCountryName() + "]");
+ }
+
+ pal = this.get(source);
+ LOG.trace("++++++++=>");
+ iterator2 = pal.iterator();
+ while (iterator2.hasNext()) {
+ pa = iterator2.next();
+
+ LOG.trace("-> Citizen Attribute: name [" + pa.getName() + "], required [" + pa.isRequired() + "]");
+ }
+ LOG.trace("<=++++++++");
+
+ LOG.trace("-----------------------");
+ }
+ LOG.trace("END\n=======================");
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeSource.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeSource.java
new file mode 100644
index 000000000..846f54f67
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeSource.java
@@ -0,0 +1,188 @@
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+
+import org.apache.log4j.Logger;
+
+/**
+ * This class is a bean used to store the information relative to the Attribute Source (either AttributeProvider or Country).
+ *
+ * @author Stelios Lelis (stelios.lelis@aegean.gr), Elias Pastos (ilias@aegean.gr)
+ *
+ * @version $Revision: 1.10 $, $Date: 2013-11-29 $
+ */
+public final class AttributeSource implements Serializable {
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 432243595968469014L;
+
+ public static final int SOURCE_LOCAL_APROVIDER = 1;
+ public static final int SOURCE_REMOTE_COUNTRY = 2;
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(AttributeSource.class.getName());
+
+ /**
+ * Provider source.
+ */
+ private int sourceType;
+
+ /**
+ * Provider URL.
+ */
+ private String providerURL;
+
+ /**
+ * The local Attribute Provider.
+ */
+ private AttributeProvider provider;
+
+ /**
+ * The remote Country.
+ */
+ private Country country;
+
+ /**
+ * Attribute Source Constructor.
+ *
+ * @param provider The local Attribute Provider.
+ * @param pURL URL of the Attribute Provider.
+ */
+ public AttributeSource(final AttributeProvider provider, final String pURL) {
+ this.setSourceType(SOURCE_LOCAL_APROVIDER);
+
+ this.setProvider(provider);
+ this.setProviderURL(pURL);
+ }
+
+ /**
+ * Attribute Source Constructor.
+ *
+ * @param country The remote Country.
+ * @param pURL URL of the Country.
+ */
+ public AttributeSource(final Country country, final String pURL) {
+ this.setSourceType(SOURCE_REMOTE_COUNTRY);
+
+ this.setCountry(country);
+ this.setProviderURL(pURL);
+ }
+
+ /**
+ * @param sourceType the sourceType to set
+ */
+ public void setSourceType(final int sourceType) {
+ this.sourceType = sourceType;
+ }
+
+ /**
+ * @return the sourceType
+ */
+ public int getSourceType() {
+ return sourceType;
+ }
+
+ /**
+ * @param providerURL the providerURL to set
+ */
+ public void setProviderURL(final String providerURL) {
+ this.providerURL = providerURL;
+ }
+
+ /**
+ * @return the providerURL
+ */
+ public String getProviderURL() {
+ return providerURL;
+ }
+
+ /**
+ * @param provider the provider to set
+ */
+ public void setProvider(final AttributeProvider provider) {
+ this.setSourceType(SOURCE_LOCAL_APROVIDER);
+
+ this.provider = provider;
+ }
+
+ /**
+ * @return the provider
+ */
+ public AttributeProvider getProvider() {
+ return provider;
+ }
+
+ /**
+ * @param country the country to set
+ */
+ public void setCountry(final Country country) {
+ this.setSourceType(SOURCE_REMOTE_COUNTRY);
+
+ this.country = country;
+ }
+
+ /**
+ * @return the country
+ */
+ public Country getCountry() {
+ return country;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public boolean equals(Object obj) {
+ boolean outcome = false;
+
+ LOG.debug("Calling equals with Object.");
+ if ( obj instanceof AttributeSource ) {
+ LOG.debug("Calling equals with AttributeSource.");
+ outcome = this.equals((AttributeSource)obj);
+ }
+
+ LOG.debug("Object equals outcome: " + outcome);
+ return outcome;
+ }
+
+ /**
+ * Compare the given AttributeSource with the current object in order to determinine
+ * if they are equal.
+ *
+ * @param obj The AttributeSource to compare to
+ *
+ * @return true if the two objects are equal
+ */
+ public boolean equals(AttributeSource obj) {
+ boolean outcome = false;
+
+ if ( this.sourceType==obj.getSourceType() ) {
+ if ( this.sourceType==AttributeSource.SOURCE_LOCAL_APROVIDER ) {
+ if ( this.provider.getProviderId().equals(obj.getProvider().getProviderId()) )
+ outcome = true;
+ }
+ else if ( this.sourceType==AttributeSource.SOURCE_REMOTE_COUNTRY ) {
+ if ( this.country.getCountryId().equals(obj.getCountry().getCountryId()) )
+ outcome = true;
+ }
+ }
+
+ LOG.debug("AttributeSource equals outcome: " + outcome);
+ return outcome;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public int hashCode() {
+ int hash = 1;
+ hash = hash * 17 + this.sourceType;
+ if ( this.sourceType==AttributeSource.SOURCE_LOCAL_APROVIDER )
+ hash = hash * 31 + this.provider.getProviderName().hashCode();
+ else
+ hash = hash * 31 + this.country.getCountryName().hashCode();
+ return hash;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeUtil.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeUtil.java
new file mode 100644
index 000000000..af7ab6cf3
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/AttributeUtil.java
@@ -0,0 +1,231 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.Map.Entry;
+
+import org.apache.commons.lang.StringUtils;
+
+/**
+ * This class holds static helper methods.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.5 $, $Date: 2010-12-15 23:19:59 $
+ */
+public final class AttributeUtil {
+
+ /**
+ * Private constructor. Prevents the class from being instantiated.
+ */
+ private AttributeUtil() {
+ // empty constructor
+ }
+
+ /**
+ * Safe escape any given string.
+ *
+ * @param value The HTTP Value to escaped.
+ *
+ * @return The value escaped value.
+ */
+ public static String escape(final String value) {
+
+ final String attrSep = PEPSValues.ATTRIBUTE_SEP.toString();
+ final String attrTupleSep = PEPSValues.ATTRIBUTE_TUPLE_SEP.toString();
+ final String attrValueSep = PEPSValues.ATTRIBUTE_VALUE_SEP.toString();
+
+ final String escAttrSep = "%" + (int) attrSep.charAt(0);
+ final String escAttrTupleSep = "%" + (int) attrTupleSep.charAt(0);
+ final String escAttrValueSep = "%" + (int) attrValueSep.charAt(0);
+
+ return value.replace(attrSep, escAttrSep)
+ .replace(attrTupleSep, escAttrTupleSep)
+ .replace(attrValueSep, escAttrValueSep);
+ }
+
+ /**
+ * Unescape any given string.
+ *
+ * @param value The HTTP Value to be unescaped.
+ *
+ * @return The value unescaped value.
+ */
+ public static String unescape(final String value) {
+ final String attrSep = PEPSValues.ATTRIBUTE_SEP.toString();
+ final String attrTupleSep = PEPSValues.ATTRIBUTE_TUPLE_SEP.toString();
+ final String attrValueSep = PEPSValues.ATTRIBUTE_VALUE_SEP.toString();
+
+ final String escAttrSep = "%" + (int) attrSep.charAt(0);
+ final String escAttrTupleSep = "%" + (int) attrTupleSep.charAt(0);
+ final String escAttrValueSep = "%" + (int) attrValueSep.charAt(0);
+
+ return value.replace(escAttrSep, attrSep)
+ .replace(escAttrTupleSep, attrTupleSep)
+ .replace(escAttrValueSep, attrValueSep);
+ }
+
+ /**
+ * Appends the string representation of an object to a StringBuilder.
+ *
+ * @param strBuilder The StringBuilder to append to.
+ * @param val The string representation of an object.
+ */
+ public static void appendIfNotNull(final StringBuilder strBuilder,
+ final Object val) {
+
+ if (val != null) {
+ strBuilder.append(val);
+ }
+ }
+
+ /**
+ * Given a separator and a list of strings, joins the list, as a string,
+ * separated by the separator string.
+ *
+ * @param list The list of strings to join.
+ * @param separator The separator string.
+ * @return the list, as a string, separated by the separator string.
+ */
+ public static String listToString(final List<String> list,
+ final String separator) {
+
+ final StringBuilder strBuilder = new StringBuilder();
+ for (final String s : list) {
+ if (!StringUtils.isEmpty(s)) {
+ strBuilder.append(AttributeUtil.escape(s) + separator);
+ }
+ }
+ return strBuilder.toString();
+ }
+
+ /**
+ * Given a separator and a map of strings to strings, joins the map, as a
+ * string, separated by the separator string with the pair key/value
+ * concatenated with a '='.
+ *
+ * @param map The map of strings to join.
+ * @param separator The separator string.
+ *
+ * @return the map of strings, as a string, separated by the separator string
+ * with the pair key/value concatenated with a '='.
+ */
+ public static String mapToString(final Map<String, String> map,
+ final String separator) {
+
+ final StringBuilder strBuilder = new StringBuilder();
+ final Iterator<Entry<String, String>> valuesIt = map.entrySet().iterator();
+ while (valuesIt.hasNext()) {
+ final Entry<String, String> entry = valuesIt.next();
+ strBuilder.append(entry.getKey());
+ strBuilder.append('=');
+ strBuilder.append(AttributeUtil.escape(entry.getValue()));
+ strBuilder.append(separator);
+ }
+ return strBuilder.toString();
+ }
+
+ /**
+ * Validates the attribute value format.
+ *
+ * @param value The attribute value to validate.
+ *
+ * @return true if value has a valid format.
+ */
+ public static boolean isValidValue(final String value) {
+ boolean retVal = false;
+ if (value != null && value.charAt(0) == '[' && value.endsWith("]")) {
+ final String tmpAttrValue = value.substring(1, value.length() - 1);
+ final String[] vals =
+ tmpAttrValue.split(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+
+ if (tmpAttrValue.length() >= 0
+ || (vals.length > 0 && vals[0].length() > 0)) {
+ retVal = true;
+ }
+ }
+ return retVal;
+ }
+
+ /**
+ * Validates the attribute type value. It's case insensitive. E.g. return true
+ * value to: a) "true", "TRUE", "True", ... b) "false", "FALSE", "False", ...
+ *
+ * @param type The attribute type value.
+ *
+ * @return true if type has a true or false (case insensitive) value.
+ */
+ public static boolean isValidType(final String type) {
+ return StringUtils.isNotEmpty(type) && (PEPSValues.TRUE.toString().equalsIgnoreCase(type) || PEPSValues.FALSE.toString().equalsIgnoreCase(type)) ;
+ }
+
+ /**
+ * Validates the Personal attribute tuple. E.g. name:type:[value]:status
+ *
+ * @param tuples The Personal attribute's tuple.
+ *
+ * @return true if the tuples' format is valid.
+ *
+ * @see PEPSUtil#validateParameter(String, String, String)
+ * @see String#equalsIgnoreCase(String)
+ */
+ public static boolean hasValidTuples(final String[] tuples) {
+ boolean retVal = false;
+
+ final int numberTuples = AttributeConstants.NUMBER_TUPLES.intValue();
+ if (tuples != null && tuples.length == numberTuples) {
+ // validate attrName
+ final int attrNameIndex = AttributeConstants.ATTR_NAME_INDEX.intValue();
+ final int attrTypeIndex = AttributeConstants.ATTR_TYPE_INDEX.intValue();
+ final int attrValueIndex = AttributeConstants.ATTR_VALUE_INDEX.intValue();
+
+ retVal =
+ StringUtils.isNotEmpty(tuples[attrNameIndex])
+ && StringUtils.isNotEmpty(tuples[attrTypeIndex])
+ && StringUtils.isNotEmpty(tuples[attrValueIndex])
+ && AttributeUtil.isValidType(tuples[attrTypeIndex])
+ && AttributeUtil.isValidValue(tuples[attrValueIndex]);
+ }
+ return retVal;
+ }
+
+ /**
+ * Check if all mandatory attributes have values.
+ *
+ * @param personalAttrList The Personal Attributes List.
+ *
+ * @return true if all mandatory attributes have values, false if at least one
+ * attribute doesn't have value.
+ */
+ public static boolean checkMandatoryAttributes(
+ final IPersonalAttributeList personalAttrList) {
+
+ final Iterator<PersonalAttribute> itAttributes =
+ personalAttrList.values().iterator();
+ boolean retVal = true;
+ while (itAttributes.hasNext() && retVal) {
+ final PersonalAttribute attr = itAttributes.next();
+ if (attr.isRequired()
+ && !STORKStatusCode.STATUS_AVAILABLE.toString()
+ .equals(attr.getStatus())) {
+ retVal = false;
+ }
+ }
+ return retVal;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/CitizenConsent.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/CitizenConsent.java
new file mode 100644
index 000000000..9ebcfbd5a
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/CitizenConsent.java
@@ -0,0 +1,123 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * This class is a bean used to store the information relative to the Citizen
+ * Consent.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.15 $, $Date: 2010-11-17 05:15:28 $
+ */
+public final class CitizenConsent {
+
+ /**
+ * Mandatory attributes list.
+ */
+ private List<String> mandatoryList;
+
+ /**
+ * Optional attributes list.
+ */
+ private List<String> optionalList;
+
+ /**
+ * Citizen Consent default Constructor.
+ */
+ public CitizenConsent() {
+ this.mandatoryList = new ArrayList<String>();
+ this.optionalList = new ArrayList<String>();
+ }
+
+ /**
+ * Getter for the mandatoryList value.
+ *
+ * @return The mandatoryList value.
+ */
+ public List<String> getMandatoryList() {
+ return this.mandatoryList;
+ }
+
+ /**
+ * Setter for the mandatoryList value.
+ *
+ * @param mandatoryAttrList Mandatory parameters list.
+ */
+ public void setMandatoryList(final List<String> mandatoryAttrList) {
+ this.mandatoryList = mandatoryAttrList;
+ }
+
+ /**
+ * Setter for some mandatoryAttribute. Adds the input parameter to the
+ * mandatoryList.
+ *
+ * @param mandatoryAttr Attribute to add to the mandatoryList.
+ */
+ public void setMandatoryAttribute(final String mandatoryAttr) {
+ this.mandatoryList.add(mandatoryAttr);
+ }
+
+ /**
+ * Getter for the optionalList value.
+ *
+ * @return The optionalList value.
+ */
+ public List<String> getOptionalList() {
+ return optionalList;
+ }
+
+ /**
+ * Setter for the optionalList value.
+ *
+ * @param optAttrList Optional parameters list.
+ */
+ public void setOptionalList(final List<String> optAttrList) {
+ this.optionalList = optAttrList;
+ }
+
+ /**
+ * Setter for some optionalAttr. Adds the input parameter to the optionalList.
+ *
+ * @param optionalAttr Attribute to add to the optionalList.
+ */
+ public void setOptionalAttribute(final String optionalAttr) {
+ this.optionalList.add(optionalAttr);
+ }
+
+ /**
+ * Returns a string in the following format. "Mandatory attributes:
+ * mandatoryAttr1;mandatoryAttr2;mandatoryAttrN Optional attributes:
+ * optionalAttr1;optionalAttr2;optionalAttrN"
+ *
+ * @return {@inheritDoc}
+ */
+ public String toString() {
+ final StringBuilder strbldr = new StringBuilder(46);
+ strbldr.append("Mandatory attributes: ");
+ for (final String str : mandatoryList) {
+ strbldr.append(str).append(';');
+ }
+ strbldr.append(" Optional attributes: ");
+ for (final String str : optionalList) {
+ strbldr.append(str).append(';');
+ }
+ return strbldr.toString();
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/Country.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/Country.java
new file mode 100644
index 000000000..001f9317a
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/Country.java
@@ -0,0 +1,95 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+
+/**
+ * This class is a bean used to store the information relative to the Country.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.10 $, $Date: 2010-11-17 05:15:28 $
+ */
+public final class Country implements Serializable {
+
+ /**
+ *
+ */
+ private static final long serialVersionUID = 1135994036496370993L;
+
+/**
+ * Country Id.
+ */
+ private String countryId;
+
+ /**
+ * Country Name.
+ */
+ private String countryName;
+
+ /**
+ * Country Constructor.
+ *
+ * @param cId Id of the Country.
+ * @param cName Name of the Country.
+ */
+ public Country(final String cId, final String cName) {
+
+ this.countryId = cId;
+ this.countryName = cName;
+ }
+
+ /**
+ * Getter for the countryId value.
+ *
+ * @return The countryId value.
+ */
+ public String getCountryId() {
+
+ return countryId;
+ }
+
+ /**
+ * Setter for the countryId value.
+ *
+ * @param cId Id of the Country.
+ */
+ public void setCountryId(final String cId) {
+
+ this.countryId = cId;
+ }
+
+ /**
+ * Getter for the countryName value.
+ *
+ * @return The countryName value.
+ */
+ public String getCountryName() {
+
+ return countryName;
+ }
+
+ /**
+ * Setter for the countryName value.
+ *
+ * @param name Name of the Country.
+ */
+ public void setCountryName(final String name) {
+
+ this.countryName = name;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/CountryCodes.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/CountryCodes.java
new file mode 100644
index 000000000..54345f3ea
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/CountryCodes.java
@@ -0,0 +1,79 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.util.Arrays;
+import java.util.List;
+
+/**
+ * This class contains all the ISO 3166-1 Alpha 3 Country Codes.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.2 $, $Date: 2011-04-14 00:24:56 $
+ */
+public final class CountryCodes {
+
+ /**
+ * Private Constructor.
+ */
+ private CountryCodes() {
+
+ }
+
+ /**
+ * ISO 3166-1 Alpha 3 Country Codes.
+ */
+ private static List<String> countrysAlpha3 = Arrays.asList("ABW", "AFG",
+ "AGO", "AIA", "ALA", "ALB", "AND", "ANT", "ARE", "ARG", "ARM", "ASM",
+ "ATA", "ATF", "ATG", "AUS", "AUT", "AZE", "BDI", "BEL", "BEN", "BES",
+ "BFA", "BGD", "BGR", "BHR", "BHS", "BIH", "BLM", "BLR", "BLZ", "BMU",
+ "BOL", "BRA", "BRB", "BRN", "BTN", "BUR", "BVT", "BWA", "BYS", "CAF",
+ "CAN", "CCK", "CHE", "CHL", "CHN", "CIV", "CMR", "COD", "COG", "COK",
+ "COL", "COM", "CPV", "CRI", "CSK", "CUB", "CUW", "CXR", "CYM", "CYP",
+ "CZE", "DEU", "DJI", "DMA", "DNK", "DOM", "DZA", "ECU", "EGY", "ERI",
+ "ESH", "ESP", "EST", "ETH", "FIN", "FJI", "FLK", "FRA", "FRO", "FSM",
+ "GAB", "GBR", "GEO", "GGY", "GHA", "GIB", "GIN", "GLP", "GMB", "GNB",
+ "GNQ", "GRC", "GRD", "GRL", "GTM", "GUF", "GUM", "GUY", "HKG", "HMD",
+ "HND", "HRV", "HTI", "HUN", "IDN", "IMN", "IND", "IOT", "IRL", "IRN",
+ "IRQ", "ISL", "ISR", "ITA", "JAM", "JEY", "JOR", "JPN", "KAZ", "KEN",
+ "KGZ", "KHM", "KIR", "KNA", "KOR", "KWT", "LAO", "LBN", "LBR", "LBY",
+ "LCA", "LIE", "LKA", "LSO", "LTU", "LUX", "LVA", "MAC", "MAF", "MAR",
+ "MCO", "MDA", "MDG", "MDV", "MEX", "MHL", "MKD", "MLI", "MLT", "MMR",
+ "MNE", "MNG", "MNP", "MOZ", "MRT", "MSR", "MTQ", "MUS", "MWI", "MYS",
+ "MYT", "NAM", "NCL", "NER", "NFK", "NGA", "NIC", "NIU", "NLD", "NOR",
+ "NPL", "NRU", "NZL", "OMN", "PAK", "PAN", "PCN", "PER", "PHL", "PLW",
+ "PNG", "POL", "PRI", "PRK", "PRT", "PRY", "PSE", "PYF", "QAT", "REU",
+ "ROM", "ROU", "RUS", "RWA", "SAU", "SCG", "SDN", "SEN", "SGP", "SGS",
+ "SHN", "SJM", "SLB", "SLE", "SLV", "SMR", "SOM", "SPM", "SRB", "STP",
+ "SUR", "SVK", "SVN", "SXW", "SWE", "SWZ", "SYC", "SYR", "TCA", "TCD",
+ "TGO", "THA", "TJK", "TKL", "TKM", "TLS", "TMP", "TON", "TTO", "TUN",
+ "TUR", "TUV", "TWN", "TZA", "UGA", "UKR", "UMI", "URY", "USA", "UZB",
+ "VAT", "VCT", "VEN", "VGB", "VIR", "VNM", "VUT", "WLF", "WSM", "YEM",
+ "YUG", "ZAF", "ZAR", "ZMB", "ZWE");
+
+ /**
+ * Searches the CountryCode (3166-1 alpha3 format) an return true if it
+ * exists.
+ *
+ * @param countryCode The Country code to search.
+ *
+ * @return true if the CountryCode exists, false otherwise.
+ */
+ public static boolean hasCountryCodeAlpha3(final String countryCode) {
+
+ return CountryCodes.countrysAlpha3.contains(countryCode);
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/DateUtil.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/DateUtil.java
new file mode 100644
index 000000000..9c0bd6775
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/DateUtil.java
@@ -0,0 +1,169 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.sql.Timestamp;
+import java.util.GregorianCalendar;
+
+import org.apache.log4j.Logger;
+import org.joda.time.DateTime;
+import org.joda.time.Years;
+import org.joda.time.format.DateTimeFormat;
+import org.joda.time.format.DateTimeFormatter;
+
+import eu.stork.peps.auth.commons.exceptions.SecurityPEPSException;
+
+/**
+ * This class holds static helper methods for Date Operations.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.4 $, $Date: 2010-11-17 05:15:28 $
+ */
+public final class DateUtil {
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(DateUtil.class.getName());
+
+ /**
+ * yyyy Date format size.
+ */
+ private static final int YEAR_DATE_SIZE = 4;
+
+ /**
+ * yyyyMM Date format size.
+ */
+ private static final int MONTH_DATE_SIZE = 6;
+
+ /**
+ * Private constructor. Prevents the class from being instantiated.
+ */
+ private DateUtil() {
+ // empty constructor
+ }
+
+ /**
+ * Fulfils dateValue with a valid date. The following roles are applied: a) If
+ * the dateValue only contains the year then fulfils with last year's day.
+ * e.g. this method returns 19951231 to the 1995 dateValue. b) If the
+ * dateValue contains the year and the month then fulfils with last month's
+ * day. e.g. this method returns 19950630 to the 199505 dateValue.
+ *
+ * @param dateValue The date to be fulfilled.
+ *
+ * @return The dateValue fulfilled.
+ */
+ private static String fulfilDate(final String dateValue) {
+
+ final StringBuffer strBuf = new StringBuffer();
+ strBuf.append(dateValue);
+ // if the IdP just provides the year then we must fullfil the date.
+ if (dateValue.length() == YEAR_DATE_SIZE) {
+ strBuf.append(PEPSValues.LAST_MONTH.toString());
+ }
+ // if the IdP provides the year and the month then we must fullfil the
+ // date.
+ if (dateValue.length() == MONTH_DATE_SIZE
+ || strBuf.length() == MONTH_DATE_SIZE) {
+ // IdP doesn't provide the day, so we will use DateTime to
+ // calculate it.
+ final String noDayCons = PEPSValues.NO_DAY_DATE_FORMAT.toString();
+ final DateTimeFormatter fmt = DateTimeFormat.forPattern(noDayCons);
+ final DateTime dateTime = fmt.parseDateTime(strBuf.toString());
+ // Append the last month's day.
+ strBuf.append(dateTime.dayOfMonth().withMaximumValue().getDayOfMonth());
+ }
+
+ return strBuf.toString();
+ }
+
+ /**
+ * Validates the dateValue format: a) if has a valid size; b) if has a numeric
+ * value; Note: dateValue must have the format yyyyMMdd.
+ *
+ * @param dateValueTmp The date to be validated.
+ * @param pattern The accepted date format.
+ *
+ * @return true if the date has a valid format.
+ */
+ public static boolean isValidFormatDate(final String dateValueTmp,
+ final String pattern) {
+
+ boolean retVal = true;
+ try {
+ final String dateValue = DateUtil.fulfilDate(dateValueTmp);
+
+ final DateTimeFormatter fmt = DateTimeFormat.forPattern(pattern);
+ fmt.parseDateTime(dateValue);
+ } catch (final Exception e) {
+ // We catch Exception because we only have to return false
+ // value!
+ retVal = false;
+ }
+ return retVal;
+ }
+
+ /**
+ * Calculates the age for a given date string.
+ *
+ * @param dateVal The date to be validated.
+ * @param now The current date.
+ * @param pattern The date pattern.
+ *
+ * @return The age value.
+ */
+ public static int calculateAge(final String dateVal, final DateTime now,
+ final String pattern) {
+
+ if (DateUtil.isValidFormatDate(dateVal, pattern)) {
+ try {
+ final String dateValueTemp = DateUtil.fulfilDate(dateVal);
+ final DateTimeFormatter fmt = DateTimeFormat.forPattern(pattern);
+ final DateTime dateTime = fmt.parseDateTime(dateValueTemp);
+ // Calculating age
+ final Years age = Years.yearsBetween(dateTime, now);
+
+ return age.getYears();
+ } catch (final IllegalArgumentException e) {
+ LOG.warn("Invalid date format (" + pattern
+ + ") or an invalid dateValue.");
+ throw new SecurityPEPSException(
+ PEPSUtil.getConfig(PEPSErrors.INVALID_ATTRIBUTE_VALUE.errorCode()),
+ PEPSUtil.getConfig(PEPSErrors.INVALID_ATTRIBUTE_VALUE.errorMessage()),
+ e);
+ }
+ } else {
+ LOG.warn("Couldn't calculate Age, invalid date!");
+ throw new SecurityPEPSException(
+ PEPSUtil.getConfig(PEPSErrors.INVALID_ATTRIBUTE_VALUE.errorCode()),
+ PEPSUtil.getConfig(PEPSErrors.INVALID_ATTRIBUTE_VALUE.errorMessage()));
+ }
+
+ }
+
+ /**
+ * Generates the current timestamp.
+ *
+ * @return timestamp The current timestamp
+ */
+ public static Timestamp currentTimeStamp() {
+ final GregorianCalendar cal = new GregorianCalendar();
+ final long millis = cal.getTimeInMillis();
+ return new Timestamp(millis);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IAttributeListProcessor.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IAttributeListProcessor.java
new file mode 100644
index 000000000..b13c70f04
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IAttributeListProcessor.java
@@ -0,0 +1,148 @@
+package eu.stork.peps.auth.commons;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * Interface for {@link AttributeListProcessor}.
+ *
+ * @author ricardo.ferreira@multicert.com
+ *
+ * @version $Revision: $, $Date: $
+ *
+ * @see IPersonalAttributeList
+ */
+public interface IAttributeListProcessor {
+
+ /**
+ * Checks if attribute list only contains allowed attributes.
+ *
+ * @param attrList the requested attribute list
+ * @param attributes the allowed attributes
+ *
+ * @return true is all the attributes are allowed.
+ *
+ * @see IPersonalAttributeList
+ */
+ boolean hasAllowedAttributes(final IPersonalAttributeList attrList, final List<String> attributes);
+
+ /**
+ * Lookup for business attribute.
+ *
+ * @param attrList the requested attribute list
+ * @param normalAttributes the normal attributes
+ *
+ * @return true is at least one business attribute was requested.
+ *
+ * @see IPersonalAttributeList
+ */
+ boolean hasBusinessAttributes(final IPersonalAttributeList attrList, final List<String> normalAttributes);
+
+ /**
+ * Lookup for business attribute in normal attribute list (loaded by
+ * implementation).
+ *
+ * @param attrList the requested attribute list
+ *
+ * @return true is at least one business attribute was requested.
+ *
+ * @see IPersonalAttributeList
+ */
+ boolean hasBusinessAttributes(final IPersonalAttributeList attrList);
+
+ /**
+ * Adds eIdentifier, name, surname, and DateOfBirth attributes to get business
+ * attributes from some AP.
+ *
+ * @param attrList the requested attribute list
+ * @param attributes the list of attributes to add (eIdentifier, name,
+ * surname, and DateOfBirth).
+ *
+ * @return the requested attribute list and the new attributes added
+ * (eIdentifier, name, surname, and DateOfBirth).
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList addAPMandatoryAttributes(final IPersonalAttributeList attrList, final List<String> attributes);
+
+ /**
+ * Adds eIdentifier, name, surname, and DateOfBirth attributes, loaded by
+ * implementation, to get business attributes from some AP.
+ *
+ * @param attrList the requested attribute list
+ *
+ * @return the requested attribute list and the new attributes added
+ * (eIdentifier, name, surname, and DateOfBirth).
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList addAPMandatoryAttributes(final IPersonalAttributeList attrList);
+
+ /**
+ * Removes from attribute list the given list of attributes.
+ *
+ * @param attrList the requested attribute list
+ * @param attributes the list of attributes to remove.
+ *
+ * @return the requested attribute list and the attributes removed.
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList removeAPMandatoryAttributes(final IPersonalAttributeList attrList, final List<String> attributes);
+
+ /**
+ * Removes from attribute list the given list of attributes and change
+ * attributes status if attribute was optional in the request.
+ *
+ * @param attrList the requested attribute list
+ * @param attributes the map of attributes (attribute name, mandatory/optional) to remove.
+ *
+ * @return the requested attribute list and the attributes removed
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList removeAPMandatoryAttributes(IPersonalAttributeList attrList, Map<String, Boolean> attributes);
+
+ /**
+ * Checks if mandate attribute exist in the requested Attribute List. Power
+ * attribute name to lookup is loaded by implementation.
+ *
+ * @param attrList the requested attribute list.
+ *
+ * @return true if mandate attribute exists or false otherwise.
+ *
+ * @see IPersonalAttributeList
+ */
+ boolean hasPowerAttribute(final IPersonalAttributeList attrList);
+
+ /**
+ * Checks if attribute name was requested and has value.
+ *
+ * @param attrList the requested attribute list.
+ * @param attrName the attribute name to lookup for .
+ *
+ * @return true if attribute was requested and has value or false otherwise.
+ *
+ * @see IPersonalAttributeList
+ */
+ boolean hasAttributeValue(final IPersonalAttributeList attrList, final String attrName);
+
+ /**
+ * Checks if attribute has value.
+ *
+ * @param attr the attribute to check.
+ *
+ * @return true if has value;
+ *
+ * @see PersonalAttribute
+ */
+ boolean hasAttributeValue(final PersonalAttribute attr);
+
+ /**
+ * Gets a map (attribute name, attribute isRequired) of attributes added to attribute list.
+ *
+ * @return the Map of attributes added and if is required to attribute list.
+ */
+ Map<String, Boolean> getNormalAttributesAdded();
+
+} \ No newline at end of file
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IAttributeProvidersMap.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IAttributeProvidersMap.java
new file mode 100644
index 000000000..733399ca3
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IAttributeProvidersMap.java
@@ -0,0 +1,82 @@
+package eu.stork.peps.auth.commons;
+
+import java.util.Iterator;
+
+/**
+ * Interface for Attributes Providers map.
+ *
+ * @author Stelios Lelis (stelios.lelis@aegean.gr), Elias Pastos (ilias@aegean.gr)
+ *
+ * @version $Revision: 1.00 $, $Date: 2013-09-20 $
+ */
+public interface IAttributeProvidersMap {
+
+ /**
+ * Returns the object associated the the given key.
+ *
+ * @param key with which the specified value is to be associated.
+ *
+ * @return The object associated the the given key.
+ */
+ IPersonalAttributeList get(AttributeSource key);
+
+ /**
+ * Associates a key to a value, and inserts them in the session object.
+ *
+ * @param key with which the specified value is to be associated.
+ * @param value to be associated with the specified key.
+ *
+ * @return previous value associated with specified key, or null if there was
+ * no mapping for key. A null return can also indicate that the map
+ * previously associated null with the specified key.
+ */
+ Object put(AttributeSource key, IPersonalAttributeList value);
+
+ /**
+ * Removes the mapping for this key.
+ *
+ * @param key with which the specified value is to be associated.
+ *
+ * @return previous value associated with specified key, or null if there was
+ * no mapping for key. A null return can also indicate that the map
+ * previously associated null with the specified key.
+ */
+ IPersonalAttributeList remove(AttributeSource key);
+
+ /**
+ * Returns the number of key-value mappings in this map.
+ *
+ * @return the number of key-value mappings in this map.
+ */
+ int size();
+
+ /**
+ * Returns true if this map contains a mapping for the specified key.
+ *
+ * @param key with which the specified value is to be associated.
+ *
+ * @return true if this map contains a mapping for the specified key.
+ */
+ boolean containsKey(AttributeSource key);
+
+ /**
+ * Removes all mappings from this map.
+ */
+ void clear();
+
+ /**
+ * Returns true if this map contains no key-value mappings.
+ *
+ * @return true if this map contains no key-value mappings.
+ */
+ boolean isEmpty();
+
+ /**
+ * Returns an Iterator of the keys contained in this map. The implementation must
+ * take care in order for the Iterator to have predictable order of the returned
+ * keys.
+ *
+ * @return an iterator of the keys contained in this map
+ */
+ Iterator<AttributeSource> keyIterator();
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IPersonalAttributeList.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IPersonalAttributeList.java
new file mode 100644
index 000000000..b24c915c0
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IPersonalAttributeList.java
@@ -0,0 +1,194 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.Set;
+
+/**
+ * Interface for {@link PersonalAttributeList}.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.16 $, $Date: 2010-11-17 05:15:28 $
+ *
+ * @see PersonalAttribute
+ */
+@SuppressWarnings("PMD.CloneMethodMustImplementCloneable")
+public interface IPersonalAttributeList extends Iterable<PersonalAttribute>,
+ Cloneable {
+
+ /**
+ * Associates the specified value with the specified key in this Personal
+ * Attribute List.
+ *
+ * @param key with which the specified value is to be associated.
+ * @param value to be associated with the specified key.
+ *
+ * @return the previous value associated with key, or null if there was no
+ * mapping for key.
+ *
+ * @see PersonalAttribute
+ */
+ PersonalAttribute put(String key, PersonalAttribute value);
+
+ /**
+ * Returns the value to which the specified key is mapped, or null if this map
+ * contains no mapping for the key.
+ *
+ * @param key whose associated value is to be returned.
+ *
+ * @return The value to which the specified key is mapped, or null if this map
+ * contains no mapping for the key.
+ *
+ * @see PersonalAttribute
+ */
+ PersonalAttribute get(Object key);
+
+ /**
+ * Adds to the PersonalAttributeList the given PersonalAttribute. It sets the
+ * attribute name as the key to the attribute value.
+ *
+ * @param value PersonalAttribute to add to the PersonalAttributeList
+ */
+ void add(PersonalAttribute value);
+
+ /**
+ * Get the size of the Personal Attribute List.
+ *
+ * @return size of the Personal Attribute List.
+ */
+ int size();
+
+ /**
+ * Checks if the Personal Attribute List contains the given key.
+ *
+ * @param key with which the specified value is to be associated.
+ *
+ * @return true if the Personal Attribute List contains the given key, false
+ * otherwise.
+ */
+ boolean containsKey(Object key);
+
+ /**
+ * Getter for the iterator of the Personal Attribute List values.
+ *
+ * @return The iterator for the Personal Attribute List values.
+ *
+ * @see PersonalAttribute
+ */
+ Iterator<PersonalAttribute> iterator();
+
+ /**
+ * Creates a Personal Attribute List from a String representing an Attribute
+ * List.
+ *
+ * @param attrList String Object representing the attribute list.
+ */
+ void populate(String attrList);
+
+ /**
+ * Removes the mapping for this key from this map if present.
+ *
+ * @param key key whose mapping is to be removed from the map.
+ * @return previous value associated with specified key, or <tt>null</tt> if
+ * there was no mapping for key. A <tt>null</tt> return can also
+ * indicate that the map previously associated <tt>null</tt> with the
+ * specified key.
+ */
+ PersonalAttribute remove(Object key);
+
+ /**
+ * Returns a collection view of the values contained in this map. The
+ * collection is backed by the map, so changes to the map are reflected in the
+ * collection, and vice-versa. The collection supports element removal, which
+ * removes the corresponding mapping from this map, via the
+ * <tt>Iterator.remove</tt>, <tt>Collection.remove</tt>, <tt>removeAll</tt>,
+ * <tt>retainAll</tt>, and <tt>clear</tt> operations. It does not support the
+ * <tt>add</tt> or <tt>addAll</tt> operations.
+ *
+ * @return a collection view of the values contained in this map.
+ */
+ Collection<PersonalAttribute> values();
+
+ /**
+ * Returns a {@link Set} view of the keys contained in this map.
+ * The set is backed by the map, so changes to the map are
+ * reflected in the set, and vice-versa. If the map is modified
+ * while an iteration over the set is in progress (except through
+ * the iterator's own <tt>remove</tt> operation), the results of
+ * the iteration are undefined. The set supports element removal,
+ * which removes the corresponding mapping from the map, via the
+ * <tt>Iterator.remove</tt>, <tt>Set.remove</tt>,
+ * <tt>removeAll</tt>, <tt>retainAll</tt>, and <tt>clear</tt>
+ * operations. It does not support the <tt>add</tt> or <tt>addAll</tt>
+ * operations.
+ *
+ * @return a set view of the keys contained in this map
+ */
+ Set<String> keySet();
+
+
+ /**
+ * Returns a IPersonalAttributeList of the complex attributes.
+ *
+ * @return an IPersonalAttributeList of the complex attributes.
+ */
+ IPersonalAttributeList getComplexAttributes();
+
+ /**
+ * Returns a IPersonalAttributeList of the simple value attributes.
+ *
+ * @return an IPersonalAttributeList of the simple value attributes.
+ */
+ IPersonalAttributeList getSimpleValueAttributes();
+
+ /**
+ * Returns a IPersonalAttributeList of the mandatory attributes in this map.
+ *
+ * @return an IPersonalAttributeList of the mandatory attributes contained in this map.
+ */
+ IPersonalAttributeList getMandatoryAttributes();
+
+ /**
+ * Returns a IPersonalAttributeList of the optional attributes in this map.
+ *
+ * @return an IPersonalAttributeList of the optional attributes contained in this map.
+ */
+ IPersonalAttributeList getOptionalAttributes();
+
+ /**
+ * Returns <tt>true</tt> if this map contains no key-value mappings.
+ *
+ * @return <tt>true</tt> if this map contains no key-value mappings.
+ */
+ boolean isEmpty();
+
+ /**
+ * Returns <tt>true</tt> if this map contains at least one element that doesn't have value.
+ *
+ * @return <tt>true</tt> if this map contains at least one element that doesn't have value.
+ */
+ boolean hasMissingValues();
+
+ /**
+ * Returns a copy of this <tt>IPersonalAttributeList</tt> instance.
+ *
+ * @return The copy of this IPersonalAttributeList.
+ */
+ Object clone() throws CloneNotSupportedException;
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IStorkLogger.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IStorkLogger.java
new file mode 100644
index 000000000..33eb618f0
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IStorkLogger.java
@@ -0,0 +1,239 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+/**
+ * Interface for stork logging.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.10 $, $Date: 2011-02-17 22:44:34 $
+ */
+public interface IStorkLogger {
+
+ /**
+ * Getter for SpApplication.
+ *
+ * @return The SpApplication value.
+ */
+ String getSpApplication();
+
+ /**
+ * Setter for SpApplication.
+ *
+ * @param spApplication The SP Application.
+ */
+ void setSpApplication(String spApplication);
+
+ /**
+ * Getter for ProviderName.
+ *
+ * @return The ProviderName value.
+ */
+ String getProviderName();
+
+ /**
+ * Setter for ProviderName.
+ *
+ * @param providerName The provider name.
+ */
+ void setProviderName(String providerName);
+
+ /**
+ *
+ * Getter for Origin.
+ *
+ * @return The Origin value.
+ *
+ */
+ String getOrigin();
+
+ /**
+ * Setter for Origin.
+ *
+ * @param origin The origin.
+ */
+ void setOrigin(String origin);
+
+ /**
+ *
+ * Getter for QAA Level.
+ *
+ * @return The QAA Level value.
+ *
+ */
+ int getQaaLevel();
+
+ /**
+ * Setter for QAA Level.
+ *
+ * @param qaaLevel The qaa level.
+ */
+ void setQaaLevel(int qaaLevel);
+
+ /**
+ *
+ * Getter for timestamp.
+ *
+ * @return The timestamp value.
+ *
+ */
+ String getTimestamp();
+
+ /**
+ * Setter for timestamp.
+ *
+ * @param timestamp The request's timestamp.
+ */
+ void setTimestamp(String timestamp);
+
+ /**
+ * Getter for InResponseTo.
+ *
+ * @return The InResponseTo value.
+ */
+ String getInResponseTo();
+
+ /**
+ * Setter for InResponseTo.
+ *
+ * @param inResponseTo The Saml's response id.
+ */
+ void setInResponseTo(String inResponseTo);
+
+ /**
+ * Getter for InResponseToSPReq.
+ *
+ * @return The InResponseToSPReq value.
+ */
+ String getInResponseToSPReq();
+
+ /**
+ * Setter for InResponseToSPRequ.
+ *
+ * @param inResponseToSPReq The Saml's response id.
+ */
+ void setInResponseToSPReq(String inResponseToSPReq);
+
+ /**
+ * Getter for opType.
+ *
+ * @return The opType value.
+ */
+ String getOpType();
+
+ /**
+ * Setter for opType.
+ *
+ * @param opType The operation type.
+ */
+ void setOpType(String opType);
+
+ /**
+ * Getter for destination.
+ *
+ * @return The destination value.
+ */
+ String getDestination();
+
+ /**
+ * Setter for destinationIp.
+ *
+ * @param destination The remote IP.
+ */
+ void setDestination(String destination);
+
+ /**
+ * Getter for message or assertion consumer.
+ *
+ * @return The message or assertion consumer.
+ */
+ String getMessage();
+
+ /**
+ * Setter for message or assertion consumer.
+ *
+ * @param message or assertion consumer.
+ */
+ void setMessage(String message);
+
+ /**
+ * Getter for country.
+ *
+ * @return The country value.
+ */
+ String getCountry();
+
+ /**
+ * Setter for country.
+ *
+ * @param country The country.
+ */
+ void setCountry(String country);
+
+ /**
+ * Getter for samlHash.
+ *
+ * @return The samlHash value.
+ */
+ byte[] getSamlHash();
+
+ /**
+ * Setter for samlHash.
+ *
+ * @param samlHash the encrypted SAML token
+ */
+ void setSamlHash(byte[] samlHash);
+
+ /**
+ * Getter for msgId.
+ *
+ * @return the msgId
+ */
+ String getMsgId();
+
+ /**
+ * Setter for msgId.
+ *
+ * @param msgId the ID of the originator of this message
+ */
+ void setMsgId(String msgId);
+
+ /**
+ * Getter for sPMsgId.
+ *
+ * @return the sPMsgId
+ */
+ String getSPMsgId();
+
+ /**
+ * Setter for sPMsgId.
+ *
+ * @param sPMsgId the ID of the originator of this message
+ */
+ void setSPMsgId(String sPMsgId);
+
+ /**
+ * The format of the returned String must be the following:
+ * "requestCounter#ddMMMyyyykk:mm:ss#opType#originIp#originName
+ * #destinationIp#destinationName#samlHash#[originatorName#msgId#]"
+ *
+ * The values enclosed in '[]' only apply when logging responses.
+ *
+ * @return {@inheritDoc}
+ */
+ @Override
+ String toString();
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IStorkSession.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IStorkSession.java
new file mode 100644
index 000000000..f38b41838
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/IStorkSession.java
@@ -0,0 +1,85 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+/**
+ * Interface for stork session.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.9 $, $Date: 2010-11-17 05:15:28 $
+ */
+public interface IStorkSession {
+
+ /**
+ * Returns the object associated the the given key.
+ *
+ * @param key with which the specified value is to be associated.
+ *
+ * @return The object associated the the given key.
+ */
+ Object get(Object key);
+
+ /**
+ * Associates a key to a value, and inserts them in the session object.
+ *
+ * @param key with which the specified value is to be associated.
+ * @param value to be associated with the specified key.
+ *
+ * @return previous value associated with specified key, or null if there was
+ * no mapping for key. A null return can also indicate that the map
+ * previously associated null with the specified key.
+ */
+ Object put(String key, Object value);
+
+ /**
+ * Removes the mapping for this key.
+ *
+ * @param key with which the specified value is to be associated.
+ *
+ * @return previous value associated with specified key, or null if there was
+ * no mapping for key. A null return can also indicate that the map
+ * previously associated null with the specified key.
+ */
+ Object remove(Object key);
+
+ /**
+ * Returns the number of key-value mappings in this map.
+ *
+ * @return the number of key-value mappings in this map.
+ */
+ int size();
+
+ /**
+ * Returns true if this map contains a mapping for the specified key.
+ *
+ * @param key with which the specified value is to be associated.
+ *
+ * @return true if this map contains a mapping for the specified key.
+ */
+ boolean containsKey(Object key);
+
+ /**
+ * Removes all mappings from this map.
+ */
+ void clear();
+
+ /**
+ * Returns true if this map contains no key-value mappings.
+ *
+ * @return true if this map contains no key-value mappings.
+ */
+ boolean isEmpty();
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/Linker.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/Linker.java
new file mode 100644
index 000000000..6e7c891da
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/Linker.java
@@ -0,0 +1,316 @@
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.LinkedHashMap;
+import java.util.List;
+
+import org.apache.log4j.Logger;
+
+/**
+ * This class is a bean used to store the information of Attribute Providers, the Attribute
+ * List to be requested, the Assertions returned by the Attribute Providers and the values
+ * that each Attribute has. This information along with the current status of the Linker (the
+ * attribute providers that were queried and the remaining providers) is used by the PEPS
+ * actions in order to complete the Attribute gathering.
+ *
+ * @author Stelios Lelis (stelios.lelis@aegean.gr), Elias Pastos (ilias@aegean.gr)
+ *
+ * @version $Revision: 1.50 $, $Date: 2013-11-28 $
+ */
+public final class Linker implements Serializable {
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = -3268006381745987237L;
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(Linker.class.getName());
+
+ /**
+ * Attributes Providers map.
+ */
+ private IAttributeProvidersMap attributeProvidersMap;
+
+ /**
+ * Assertion map.
+ */
+ private LinkedHashMap<AttributeSource, STORKAttrQueryResponse> assertions;
+
+ /**
+ * The current index of local (domestic) Attribute Providers.
+ */
+ private int localIndex;
+
+ /**
+ * The current index of remote (foreign) Attribute Providers - countries.
+ */
+ private int remoteIndex;
+
+ /**
+ * Constructs an empty Linker object.
+ */
+ public Linker() {
+ localIndex = 0;
+ remoteIndex = 0;
+
+ assertions = new LinkedHashMap<AttributeSource, STORKAttrQueryResponse>();
+ }
+
+ /**
+ * Based on the internal state of the Linker it returns the next local Attribute Source
+ *
+ * @return The next Attribute Source or null if not found
+ *
+ * @see AttributeSource
+ */
+ public AttributeSource getNextLocalProvider() {
+ Iterator<AttributeSource> iterator;
+ AttributeSource source, found;
+ int curIndex = 0;
+
+ found = null;
+
+ if ( attributeProvidersMap!=null && !attributeProvidersMap.isEmpty() ) {
+ iterator = attributeProvidersMap.keyIterator();
+ while (iterator.hasNext()) {
+ source = iterator.next();
+
+ if ( source.getSourceType()==AttributeSource.SOURCE_LOCAL_APROVIDER ) {
+ if ( curIndex>=localIndex ) {
+ found = source;
+
+ break;
+ }
+
+ curIndex++;
+ }
+ }
+ }
+
+ return found;
+ }
+
+ /**
+ * Based on the internal state of the Linker it returns the next remote Attribute Source
+ *
+ * @return The next Attribute Source or null if not found
+ *
+ * @see AttributeSource
+ */
+ public AttributeSource getNextRemoteProvider() {
+ Iterator<AttributeSource> iterator;
+ AttributeSource source, found;
+ int curIndex = 0;
+
+ found = null;
+
+ if ( attributeProvidersMap !=null && !attributeProvidersMap.isEmpty() ) {
+ iterator = attributeProvidersMap.keyIterator();
+ while (iterator.hasNext()) {
+ source = iterator.next();
+
+ if ( source.getSourceType()==AttributeSource.SOURCE_REMOTE_COUNTRY ) {
+ if ( curIndex>=remoteIndex ) {
+ found = source;
+
+ break;
+ }
+
+ curIndex++;
+ }
+ }
+ }
+
+ return found;
+ }
+
+ /**
+ * It updates the Linker with the values returned by the Attribute Source. It also advances
+ * to the next index in order to mark this attribute source as completed.
+ *
+ * @param source The Attribute Source that was queried for attribute values.
+ * @param attrResponse The attrResponse returned by the Attribute Source that contains the attribute values.
+ *
+ * @see AttributeSource, STORKAttrQueryResponse
+ */
+ public void setProviderReponse(AttributeSource source, STORKAttrQueryResponse attrResponse) {
+ if ( source.getSourceType()==AttributeSource.SOURCE_REMOTE_COUNTRY )
+ remoteIndex++;
+ else
+ localIndex++;
+
+ //Assertion storage
+ this.assertions.put(source, attrResponse);
+
+ this.attributeProvidersMap.put(source, attrResponse.getPersonalAttributeList());
+ //this.attributeProvidersMap.put(source, attrResponse.getTotalPersonalAttributeList());
+ }
+
+ /**
+ * Reset the internal state of the local Attribute Source in order to start over.
+ */
+ public void resetLocalIndex() {
+ localIndex = 0;
+ }
+
+ /**
+ * Reset the internal state of the remote Attribute Source in order to start over.
+ */
+ public void resetRemoteIndex() {
+ remoteIndex = 0;
+ }
+
+ /**
+ * Setter for attributeProvidersMap.
+ *
+ * @param attributeProvidersMap The attributeProvidersMap to set.
+ */
+ public void setAttributeProvidersMap(IAttributeProvidersMap attributeProvidersMap) {
+ this.attributeProvidersMap = attributeProvidersMap;
+ }
+
+ /**
+ * Getter for attributeProvidersMap.
+ *
+ * @return attributeProvidersMap
+ */
+ public IAttributeProvidersMap getAttributeProvidersMap() {
+ return attributeProvidersMap;
+ }
+
+ /**
+ * Returns the Personal Attribute list of the provided Attribute Source.
+ *
+ * @param source The attributeSource in reference
+ *
+ * @return The IPersonalAttributeList assosiated with this source or null if empty
+ *
+ * @see IPersonalAttributeList
+ */
+ public IPersonalAttributeList getProviderAttributes(AttributeSource source) {
+ if ( attributeProvidersMap.containsKey(source) )
+ return attributeProvidersMap.get(source);
+ else
+ return null;
+ }
+
+ /**
+ * Returns the merged Personal Attribute list from all the Attribute Sources.
+ *
+ * @return The IPersonalAttributeList merged Personal Attribute list or null if empty
+ *
+ * @see IPersonalAttributeList
+ */
+ public IPersonalAttributeList getAllAttributes() {
+ Iterator<AttributeSource> iterator;
+ AttributeSource source;
+ IPersonalAttributeList list, merged;
+
+ merged = null;
+
+ if ( attributeProvidersMap !=null && !attributeProvidersMap.isEmpty() ) {
+ iterator = attributeProvidersMap.keyIterator();
+
+ merged = new PersonalAttributeList();
+ while (iterator.hasNext()) {
+ source = iterator.next();
+ list = this.getProviderAttributes(source);
+
+ for (final PersonalAttribute pa : list) {
+ merged.add(pa);
+ }
+ }
+ }
+
+ return merged;
+ }
+
+ /**
+ * Returns a List with all the assertions gathered by the AAS-PEPS module
+ * returned both by local APs or remote A-PEPS.
+ *
+ * @return The assertions returned from the APs and A-PEPS
+ */
+ public List<STORKAttrQueryResponse> getAttrQueryResponseList() {
+ List<STORKAttrQueryResponse> originalAssertions;
+
+ originalAssertions = new ArrayList<STORKAttrQueryResponse>();
+
+ //Gather all assertions
+ for (STORKAttrQueryResponse element : this.assertions.values()) {
+ originalAssertions.add(element);
+ }
+
+ return originalAssertions;
+ }
+
+ /**
+ * Checks the internal state of the Linker and if all Attribute Sources where visited
+ * returns true, otherwise it returns false. So if you go directly from AtPLinkerAction
+ * to MoreAttributesAction the call will have, since the method setProviderReponse
+ * was not executed from every Attribute Source.
+ *
+ * @return true if everything is OK, false otherwise
+ */
+ public boolean isComplete() {
+ boolean outcome = false;
+
+ LOG.debug("Check if linkder is complete: R[" + remoteIndex + "], L[" + localIndex + "], S[" + attributeProvidersMap.size() + "]");
+ if ( attributeProvidersMap !=null && !attributeProvidersMap.isEmpty() ) {
+ if ( (remoteIndex + localIndex)==attributeProvidersMap.size() )
+ outcome = true;
+ }
+ else {
+ outcome = true;
+ }
+
+ return outcome;
+ }
+
+ /**
+ * Merge the two Linker objects.
+ *
+ * @param previous The other Linker object to merge with this one.
+ */
+ public void mergeWith(Linker previous) {
+ //BEFORE
+ if ( LOG.isDebugEnabled() ) {
+ LOG.debug("The attributeProvidersMap from the current object.");
+ ((AttributeProvidersMap)this.attributeProvidersMap).trace();
+ LOG.debug("The attributeProvidersMap from the provided object.");
+ ((AttributeProvidersMap)previous.getAttributeProvidersMap()).trace();
+ }
+
+ IAttributeProvidersMap map = previous.getAttributeProvidersMap();
+ Iterator<AttributeSource> items = map.keyIterator();
+ while( items.hasNext() ) {
+ AttributeSource item = items.next();
+ IPersonalAttributeList pal = map.get(item);
+
+ if ( this.attributeProvidersMap.containsKey(item) ) {
+ IPersonalAttributeList new_pal = this.attributeProvidersMap.get(item);
+
+ for(PersonalAttribute pa : pal)
+ new_pal.add(pa);
+ }
+ else {
+ if ( item.getSourceType()==AttributeSource.SOURCE_REMOTE_COUNTRY )
+ remoteIndex++;
+ else
+ localIndex++;
+
+ this.attributeProvidersMap.put(item, pal);
+ }
+ }
+
+ //AFTER
+ if ( LOG.isDebugEnabled() ) {
+ LOG.debug("The attributeProvidersMap after the merge.");
+ ((AttributeProvidersMap)this.attributeProvidersMap).trace();
+ }
+ }
+} \ No newline at end of file
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PEPSErrors.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PEPSErrors.java
new file mode 100644
index 000000000..5da9ba494
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PEPSErrors.java
@@ -0,0 +1,392 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+/**
+ * This enum class contains all the STORK PEPS, Commons and Specific errors
+ * constant identifiers.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.10 $, $Date: 2011-02-17 22:44:34 $
+ */
+public enum PEPSErrors {
+
+ /**
+ * Represents the 'authenticationFailed' constant error identifier.
+ */
+ AUTHENTICATION_FAILED_ERROR("authenticationFailed"),
+ /**
+ * Represents the 'spCountrySelector.errorCreatingSAML' constant error
+ * identifier.
+ */
+ SP_COUNTRY_SELECTOR_ERROR_CREATE_SAML("spCountrySelector.errorCreatingSAML"),
+ /**
+ * Represents the 'spCountrySelector.destNull' constant error identifier.
+ */
+ SP_COUNTRY_SELECTOR_DESTNULL("spCountrySelector.destNull"),
+ /**
+ * Represents the 'spCountrySelector.invalidAttr' constant error identifier.
+ */
+ SP_COUNTRY_SELECTOR_INVALID_ATTR("spCountrySelector.invalidAttr"),
+ /**
+ * Represents the 'spCountrySelector.invalidProviderName' constant error
+ * identifier.
+ */
+ SP_COUNTRY_SELECTOR_INVALID_PROVIDER_NAME(
+ "spCountrySelector.invalidProviderName"),
+ /**
+ * Represents the 'spCountrySelector.invalidQaaSPid' constant error
+ * identifier.
+ */
+ SP_COUNTRY_SELECTOR_INVALID_QAASPID("spCountrySelector.invalidQaaSPid"),
+ /**
+ * Represents the 'spCountrySelector.invalidSpId' constant error identifier.
+ */
+ SP_COUNTRY_SELECTOR_INVALID_SPID("spCountrySelector.invalidSpId"),
+ /**
+ * Represents the 'spCountrySelector.invalidSPQAA' constant error identifier.
+ */
+ SP_COUNTRY_SELECTOR_INVALID_SPQAA("spCountrySelector.invalidSPQAA"),
+ /**
+ * Represents the 'spCountrySelector.invalidSpURL' constant error identifier.
+ */
+ SP_COUNTRY_SELECTOR_INVALID_SPURL("spCountrySelector.invalidSpURL"),
+ /**
+ * Represents the 'spCountrySelector.spNotAllowed' constant error identifier.
+ */
+ SP_COUNTRY_SELECTOR_SPNOTALLOWED("spCountrySelector.spNotAllowed"),
+
+ /**
+ * Represents the 'sProviderAction.errorCreatingSAML' constant error
+ * identifier.
+ */
+ SPROVIDER_SELECTOR_ERROR_CREATE_SAML("sProviderAction.errorCreatingSAML"),
+ /**
+ * Represents the 'sProviderAction.attr' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_ATTR("sProviderAction.invalidAttr"),
+ /**
+ * Represents the 'sProviderAction.country' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_COUNTRY("sProviderAction.invalidCountry"),
+ /**
+ * Represents the 'sProviderAction.relayState' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_RELAY_STATE("sProviderAction.invalidRelayState"),
+ /**
+ * Represents the 'sProviderAction.saml' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_SAML("sProviderAction.invalidSaml"),
+ /**
+ * Represents the 'sProviderAction.spAlias' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_SPALIAS("sProviderAction.invalidSPAlias"),
+ /**
+ * Represents the 'sProviderAction.spDomain' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_SPDOMAIN("sProviderAction.invalidSPDomain"),
+ /**
+ * Represents the 'sProviderAction.spId' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_SPID("sProviderAction.invalidSPId"),
+ /**
+ * Represents the 'sProviderAction.spQAA' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_SPQAA("sProviderAction.invalidSPQAA"),
+ /**
+ * Represents the 'sProviderAction.spQAAId' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_SPQAAID("sProviderAction.invalidSPQAAId"),
+ /**
+ * Represents the 'sProviderAction.spRedirect' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_SPREDIRECT("sProviderAction.invalidSPRedirect"),
+ /**
+ * Represents the 'sPPowerValidationAction.invalidSPPVAttrList' constant error identifier.
+ */
+ SPPOWERVALIDATION_SELECTOR_INVALID_SP_PV_ATTR_LIST("sPPowerValidationAction.invalidSPPVAttrList"),
+
+ /**
+ * Represents the 'sProviderAction.invalidSPProviderName' constant error
+ * identifier.
+ */
+ SPROVIDER_SELECTOR_INVALID_SP_PROVIDERNAME(
+ "sProviderAction.invalidSPProviderName"),
+ /**
+ * Represents the 'sProviderAction.spNotAllowed' constant error identifier.
+ */
+ SPROVIDER_SELECTOR_SPNOTALLOWED("sProviderAction.spNotAllowed"),
+
+
+ /**
+ * Represents the 'internalError' constant error identifier.
+ */
+ INTERNAL_ERROR("internalError"),
+
+ /**
+ * Represents the 'colleagueRequest.attrNull' constant error identifier.
+ */
+ COLLEAGUE_REQ_ATTR_NULL("colleagueRequest.attrNull"),
+ /**
+ * Represents the 'colleagueRequest.errorCreatingSAML' constant error
+ * identifier.
+ */
+ COLLEAGUE_REQ_ERROR_CREATE_SAML("colleagueRequest.errorCreatingSAML"),
+ /**
+ * Represents the 'colleagueRequest.invalidCountryCode' constant error
+ * identifier.
+ */
+ COLLEAGUE_REQ_INVALID_COUNTRYCODE("colleagueRequest.invalidCountryCode"),
+ /**
+ * Represents the 'colleagueRequest.invalidDestUrl' constant error identifier.
+ */
+ COLLEAGUE_REQ_INVALID_DEST_URL("colleagueRequest.invalidDestUrl"),
+ /**
+ * Represents the 'colleagueRequest.invalidQaa' constant error identifier.
+ */
+ COLLEAGUE_REQ_INVALID_QAA("colleagueRequest.invalidQaa"),
+ /**
+ * Represents the 'colleagueRequest.invalidRedirect' constant error
+ * identifier.
+ */
+ COLLEAGUE_REQ_INVALID_REDIRECT("colleagueRequest.invalidRedirect"),
+ /**
+ * Represents the 'colleagueRequest.invalidSAML' constant error identifier.
+ */
+ COLLEAGUE_REQ_INVALID_SAML("colleagueRequest.invalidSAML"),
+
+ /**
+ * Represents the 'colleaguePVRequest.invalidPVAttrList' constant error identifier.
+ */
+ COLLEAGUE_PV_REQ_INVALID_PV_ATTR_LIST("colleaguePVRequest.invalidPVAttrList"),
+
+
+ /**
+ * Represents the 'cpepsRedirectUrl' constant error identifier.
+ */
+ CPEPS_REDIRECT_URL("cpepsRedirectUrl"),
+ /**
+ * Represents the 'spepsRedirectUrl' constant error identifier.
+ */
+ SPEPS_REDIRECT_URL("spepsRedirectUrl"),
+ /**
+ * Represents the 'sProviderAction.invCountry' constant error identifier.
+ */
+ SP_ACTION_INV_COUNTRY("sProviderAction.invCountry"),
+
+ /**
+ * Represents the 'providernameAlias.invalid' constant error identifier.
+ */
+ PROVIDER_ALIAS_INVALID("providernameAlias.invalid"),
+
+
+ /**
+ * Represents the 'cPeps.attrNull' constant error identifier.
+ */
+ CPEPS_ATTR_NULL("cPeps.attrNull"),
+
+ /**
+ * Represents the 'colleagueResponse.invalidSAML' constant error identifier.
+ */
+ COLLEAGUE_RESP_INVALID_SAML("colleagueResponse.invalidSAML"),
+
+ /**
+ * Represents the 'citizenNoConsent.mandatory' constant error identifier.
+ */
+ CITIZEN_NO_CONSENT_MANDATORY("citizenNoConsent.mandatory"),
+ /**
+ * Represents the 'citizenResponse.mandatory' constant error identifier.
+ */
+ CITIZEN_RESPONSE_MANDATORY("citizenResponse.mandatory"),
+ /**
+ * Represents the 'attVerification.mandatory' constant error identifier.
+ */
+ ATT_VERIFICATION_MANDATORY("attVerification.mandatory"),
+ /**
+ * Represents the 'attrValue.verification' constant error identifier.
+ */
+ ATTR_VALUE_VERIFICATION("attrValue.verification"),
+
+ /**
+ * Represents the 'audienceRestrictionError' constant error identifier.
+ */
+ AUDIENCE_RESTRICTION("audienceRestrictionError"),
+ /**
+ * Represents the 'auRequestIdError' constant error identifier.
+ */
+ AU_REQUEST_ID("auRequestIdError"),
+ /**
+ * Represents the 'domain' constant error identifier.
+ */
+ DOMAIN("domain"),
+ /**
+ * Represents the 'hash.error' constant error identifier.
+ */
+ HASH_ERROR("hash.error"),
+ /**
+ * Represents the 'invalidAttributeList' constant error identifier.
+ */
+ INVALID_ATTRIBUTE_LIST("invalidAttributeList"),
+ /**
+ * Represents the 'invalidAttributeValue' constant error identifier.
+ */
+ INVALID_ATTRIBUTE_VALUE("invalidAttributeValue"),
+ /**
+ * Represents the 'qaaLevel' constant error identifier.
+ */
+ QAALEVEL("qaaLevel"),
+ /**
+ * Represents the 'requests' constant error identifier.
+ */
+ REQUESTS("requests"),
+ /**
+ * Represents the 'SPSAMLRequest' constant error identifier.
+ */
+ SP_SAML_REQUEST("SPSAMLRequest"),
+ /**
+ * Represents the 'spepsSAMLRequest' constant error identifier.
+ */
+ SPEPS_SAML_REQUEST("spepsSAMLRequest"),
+ /**
+ * Represents the 'IdPSAMLResponse' constant error identifier.
+ */
+ IDP_SAML_RESPONSE("IdPSAMLResponse"),
+ /**
+ * Represents the 'cpepsSAMLResponse' constant error identifier.
+ */
+ CPEPS_SAML_RESPONSE("cpepsSAMLResponse"),
+ /**
+ * Represents the 'cpepsSAMLResponse' constant error identifier.
+ */
+ SPEPS_SAML_RESPONSE("spepsSAMLResponse"),
+ /**
+ * Represents the 'session' constant error identifier.
+ */
+ SESSION("session"),
+ /**
+ * Represents the 'invalid.session' constant error identifier.
+ */
+ INVALID_SESSION("invalid.session"),
+ /**
+ * Represents the 'invalid.sessionId' constant error identifier.
+ */
+ INVALID_SESSION_ID("invalid.sessionId"),
+ /**
+ * Represents the 'missing.sessionId' constant error identifier.
+ */
+ MISSING_SESSION_ID("sessionError"),
+ /**
+ * Represents the 'missing.mandate' constant error identifier.
+ */
+ MISSING_MANDATE("missing.mandate"),
+ /**
+ * Represents the 'AtPSAMLResponse' constant error identifier.
+ */
+ ATP_SAML_RESPONSE("AtPSAMLResponse"),
+
+ /**
+ * Represents the 'AtPSAMLResponse' constant error identifier.
+ */
+ ATP_RESPONSE_ERROR("atp.response.error"),
+
+ /**
+ * Represents the 'apepsSAMLRequest' constant error identifier.
+ */
+ APEPS_SAML_REQUEST("apepsSAMLRequest"),
+
+ /**
+ * Represents the 'apepsSAMLResponse' constant error identifier.
+ */
+ APEPS_SAML_RESPONSE("apepsSAMLResponse"),
+
+ /**
+ * Represents the 'invalid.apepsRedirectUrl' constant error identifier.
+ */
+ INVALID_APEPS_REDIRECT_URL("invalid.apepsRedirectUrl"),
+
+ /**
+ * Represents the 'invalid.apepsCallbackUrl' constant error identifier.
+ */
+ INVALID_APEPS_CALLBACK_URL("invalid.apepsCallbackUrl"),
+
+ /**
+ * Represents the 'colleagueAttributeRequest.invalidSAML' constant error identifier.
+ */
+ COLLEAGUE_ATTR_REQ_INVALID_SAML("colleagueAttributeRequest.invalidSAML");
+
+ /**
+ * Represents the constant's value.
+ */
+ private String error;
+
+ /**
+ * Solo Constructor.
+ *
+ * @param nError The Constant error value.
+ */
+ PEPSErrors(final String nError) {
+ this.error = nError;
+ }
+
+ /**
+ * Construct the errorCode Constant value.
+ *
+ * @return The errorCode Constant.
+ */
+ public String errorCode() {
+ return error + ".code";
+ }
+
+ /**
+ * Construct the errorCode Constant value with the given code text.
+ *
+ * @param text the code text to append to the constant.
+ *
+ * @return The errorCode Constant for the given code text.
+ */
+ public String errorCode(final String text) {
+ return error + "." + text + ".code";
+ }
+
+ /**
+ * Construct the errorMessage constant value.
+ *
+ * @return The errorMessage constant.
+ */
+ public String errorMessage() {
+ return error + ".message";
+ }
+
+ /**
+ * Construct the errorMessage Constant value with the given message text.
+ *
+ * @param text the message text to append to the constant.
+ *
+ * @return The errorMessage Constant for the given text.
+ */
+ public String errorMessage(final String text) {
+ return error + "." + text + ".message";
+ }
+
+ /**
+ * Return the Constant Value.
+ *
+ * @return The constant value.
+ */
+ public String toString() {
+ return error;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PEPSParameters.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PEPSParameters.java
new file mode 100644
index 000000000..15c2ae552
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PEPSParameters.java
@@ -0,0 +1,625 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+/**
+ * This enum class contains all the STORK PEPS, Commons and Specific Parameters.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.13 $, $Date: 2011-07-07 20:48:45 $
+ */
+public enum PEPSParameters {
+
+ /**
+ * Represents the 'apId' parameter constant.
+ */
+ AP_ID("apId"),
+ /**
+ * Represents the 'apUrl' parameter constant.
+ */
+ AP_URL("apUrl"),
+ /**
+ * Represents the 'ap.number' parameter constant.
+ */
+ AP_NUMBER("ap.number"),
+
+ /**
+ * Represents the 'assertionConsumerServiceURL' parameter constant.
+ */
+ ASSERTION_CONSUMER_S_URL("assertionConsumerServiceURL"),
+
+ /**
+ * Represents the 'auth' parameter constant.
+ */
+ AUTHENTICATION("auth"),
+
+ /**
+ * Represents the 'attr' parameter constant.
+ */
+ ATTRIBUTE("attr"),
+ /**
+ * Represents the 'attrName' parameter constant.
+ */
+ ATTRIBUTE_NAME("attrName"),
+ /**
+ * Represents the 'attrStatus' parameter constant.
+ */
+ ATTRIBUTE_STATUS("attrStatus"),
+ /**
+ * Represents the 'attrType' parameter constant.
+ */
+ ATTRIBUTE_TYPE("attrType"),
+ /**
+ * Represents the 'attrValue' parameter constant.
+ */
+ ATTRIBUTE_VALUE("attrValue"),
+ /**
+ * Represents the 'attrList' parameter constant.
+ */
+ ATTRIBUTE_LIST("attrList"),
+ /**
+ * Represents the 'apMandAttrList' parameter constant.
+ */
+ AP_MANDATORY_ATTRIBUTE_LIST("apMandAttrList"),
+ /**
+ * Represents the 'attrTuple' parameter constant.
+ */
+ ATTRIBUTE_TUPLE("attrTuple"),
+ /**
+ * Represents the 'attribute-missing' parameter constant.
+ */
+ ATTRIBUTE_MISSING("attribute-missing"),
+ /**
+ * Represents the 'attributesNotAllowed' parameter constant.
+ */
+ ATTRIBUTES_NOT_ALLOWED("attributesNotAllowed"),
+ /**
+ * Represents the 'authnRequest' parameter constant.
+ */
+ AUTH_REQUEST("authnRequest"),
+
+ /**
+ * Represents the 'attrValue.number' parameter constant.
+ */
+ ATTR_VALUE_NUMBER("attrValue.number"),
+
+ /**
+ * Represents the 'derivation.date.format' parameter constant.
+ */
+ DERIVATION_DATE_FORMAT("derivation.date.format"),
+ /**
+ * Represents the 'deriveAttr.number' parameter constant.
+ */
+ DERIVE_ATTRIBUTE_NUMBER("deriveAttr.number"),
+
+ /**
+ * Represents the complex attributes parameter constant.
+ */
+ COMPLEX_ADDRESS_VALUE("canonicalResidenceAddress"),
+ COMPLEX_NEWATTRIBUTE_VALUE("newAttribute2"),
+ COMPLEX_HASDEGREE_VALUE("hasDegree"),
+ COMPLEX_MANDATECONTENT_VALUE("mandateContent"),
+ /**
+ * Represents the 'consent-type' parameter constant.
+ */
+ CONSENT_TYPE("consent-type"),
+ /**
+ * Represents the 'consent-value' parameter constant.
+ */
+ CONSENT_VALUE("consent-value"),
+ /**
+ * Represents the 'country' parameter constant.
+ */
+ COUNTRY("country"),
+ /**
+ * Represents the 'countryOrigin' parameter constant.
+ */
+ COUNTRY_ORIGIN("countryOrigin"),
+
+ /**
+ * Represents the 'cpepsURL' parameter constant.
+ */
+ CPEPS_URL("cpepsURL"),
+ /**
+ * Represents the 'callback' parameter constant.
+ */
+ CPEPS_CALLBACK("callback"),
+ /**
+ * Represents the 'peps.specificidpredirect.url' parameter constant.
+ */
+ CPEPS_IDP_CALLBACK_VALUE("peps.specificidpredirect.url"),
+ /**
+ * Represents the 'peps.specificapredirect.url' parameter constant.
+ */
+ CPEPS_AP_CALLBACK_VALUE("peps.specificapredirect.url"),
+
+ /**
+ * Represents the 'errorCode' parameter constant.
+ */
+ ERROR_CODE("errorCode"),
+ /**
+ * Represents the 'subCode' parameter constant.
+ */
+ ERROR_SUBCODE("subCode"),
+ /**
+ * Represents the 'errorMessage' parameter constant.
+ */
+ ERROR_MESSAGE("errorMessage"),
+ /**
+ * Represents the 'errorRedirectUrl' parameter constant.
+ */
+ ERROR_REDIRECT_URL("errorRedirectUrl"),
+
+ /**
+ * errorRedirectUrl Represents the 'external-authentication' parameter
+ * constant.
+ */
+ EXTERNAL_AUTH("external-authentication"),
+ /**
+ * Represents the 'external-ap' parameter constant.
+ */
+ EXTERNAL_AP("external-ap"),
+ /**
+ * Represents the 'external-pv' parameter constant.
+ */
+ EXTERNAL_PV("external-pv"),
+ /**
+ * Represents the 'external-sig-module' parameter constant.
+ */
+ EXT_SIG_CREATOR_MOD("external-sig-module"),
+
+ /**
+ * Represents the 'http-x-forwarded-for' parameter constant.
+ */
+ HTTP_X_FORWARDED_FOR("http-x-forwarded-for"),
+
+ /**
+ * Represents the 'idp.url' parameter constant.
+ */
+ IDP_URL("idp.url"),
+ /**
+ * Represents the 'internal-authentication' parameter constant.
+ */
+ INTERNAL_AUTH("internal-authentication"),
+ /**
+ * Represents the 'internal-ap' parameter constant.
+ */
+ INTERNAL_AP("internal-ap"),
+ /**
+ * Represents the 'internal-pv' parameter constant.
+ */
+ INTERNAL_PV("internal-pv"),
+
+ /**
+ * Represents the 'samlIssuer' parameter constant.
+ */
+ ISSUER("samlIssuer"),
+ /**
+ * Represents the 'samlIssuer.idp' parameter constant.
+ */
+ ISSUER_IDP("samlIssuer.idp"),
+ /**
+ * Represents the 'samlIssuer.atp' parameter constant.
+ */
+ ISSUER_ATP("samlIssuer.atp"),
+
+ /**
+ * Represents the 'mandatory' parameter constant.
+ */
+ MANDATORY("mandatory"),
+ /**
+ * Represents the 'mandatoryAttributeMissing' parameter constant.
+ */
+ MANDATORY_ATTR_MISSING("mandatoryAttributeMissing"),
+ /**
+ * Represents the 'mandatoryConsentAttrMissing' parameter constant.
+ */
+ MANDATORY_CONSENT_MISSING("mandatoryConsentAttrMissing"),
+ /**
+ * Represents the 'missing-attrs' parameter constant.
+ */
+ MISSING_ATTRS("missing-attrs"),
+ /**
+ * Represents the 'no-more-attrs' parameter constant.
+ */
+ NO_MORE_ATTRS("no-more-attrs"),
+
+ /**
+ * Represents the 'optional' parameter constant.
+ */
+ OPTIONAL("optional"),
+
+ /**
+ * Represents the 'no-consent-type' parameter constant.
+ */
+ NO_CONSENT_TYPE("no-consent-type"),
+ /**
+ * Represents the 'no-consent-value' parameter constant.
+ */
+ NO_CONSENT_VALUE("no-consent-value"),
+
+ /**
+ * Represents the 'provider.name' parameter constant.
+ */
+ PROVIDER_NAME_VALUE("providerName"),
+ /**
+ * Represents the 'cpeps.askconsent' parameter constant.
+ */
+ PEPS_ASK_CONSENT("cpeps.askconsent"),
+ /**
+ * Represents the 'cpeps.askconsentvalue' parameter constant.
+ */
+ PEPS_ASK_CONSENT_VALUE("cpeps.askconsentvalue"),
+ /**
+ * Represents the 'pepsAuth' parameter constant.
+ */
+ PEPS_AUTH_CONSENT("pepsAuth"),
+ /**
+ * Represents the 'validation.bypass' parameter constant.
+ */
+ PEPS_BYPASS("validation.bypass"),
+ /**
+ * Represents the 'cpeps.number' parameter constant.
+ */
+ PEPS_NUMBER("cpeps.number"),
+ /**
+ * Represents the 'cpeps.specificapredirect.url' parameter constant.
+ */
+ PEPS_SPECIFIC_URL("cpeps.specificapredirect.url"),
+ /**
+ * Represents the 'pv.url' parameter constant.
+ */
+ PV_URL("pv.url"),
+
+ /**
+ * Represents the 'qaaLevel' parameter constant.
+ */
+ QAALEVEL("qaaLevel"),
+
+ /**
+ * Represents the 'speps.redirectUrl' parameter constant.
+ */
+ SPEPS_REDIRECT_URL("speps.redirectUrl"),
+
+ /**
+ * Represents the 'sp.redirectUrl' parameter constant.
+ */
+ SP_REDIRECT_URL("sp.redirectUrl"),
+ /**
+ * Represents the 'cpeps.redirectUrl' parameter constant.
+ */
+ CPEPS_REDIRECT_URL("cpeps.redirectUrl"),
+ /**
+ * Represents the 'RelayState' parameter constant.
+ */
+ RELAY_STATE("RelayState"),
+ /**
+ * Represents the 'remoteAddr' parameter constant.
+ */
+ REMOTE_ADDR("remoteAddr"),
+ /**
+ * Represents the 'remoteUser' parameter constant.
+ */
+ REMOTE_USER("remoteUser"),
+
+ /**
+ * Represents the 'SAMLRequest' parameter constant.
+ */
+ SAML_REQUEST("SAMLRequest"),
+ /**
+ * Represents the 'SAMLResponse' parameter constant.
+ */
+ SAML_RESPONSE("SAMLResponse"),
+ /**
+ * Represents the 'SAMLFail' parameter constant.
+ */
+ SAML_TOKEN_FAIL("SAMLFail"),
+ /**
+ * Represents the 'TokenId' parameter constant.
+ */
+ SAML_TOKEN_ID("TokenId"),
+ /**
+ * Represents the 'inResponseTo' parameter constant.
+ */
+ SAML_IN_RESPONSE_TO("inResponseTo"),
+ /**
+ * Represents the 'inResponseTo.idp' parameter constant.
+ */
+ SAML_IN_RESPONSE_TO_IDP("inResponseTo.idp"),
+ /**
+ * Represents the 'inResponseTo.atp' parameter constant.
+ */
+ SAML_IN_RESPONSE_TO_ATP("inResponseTo.atp"),
+ /**
+ * Represents the 'SignatureResponse' parameter constant.
+ */
+ SIGNATURE_RESPONSE("SignatureResponse"),
+
+ /**
+ * Represents the 'cPepsSession' parameter constant.
+ */
+ SESSION_ID_URL("cPepsSession"),
+ /**
+ * Represents the 'spId' parameter constant.
+ */
+ SP_ID("spId"),
+ /**
+ * Represents the 'spQaaLevel' parameter constant.
+ */
+ SP_QAALEVEL("spQaaLevel"),
+ /**
+ * Represents the 'spUrl' parameter constant.
+ */
+ SP_URL("spUrl"),
+
+ /**
+ * Represents the 'allow.derivation.all' parameter constant.
+ */
+ SPECIFIC_ALLOW_DERIVATION_ALL("allow.derivation.all"),
+ /**
+ * Represents the ''allow.unknowns parameter constant.
+ */
+ SPECIFIC_ALLOW_UNKNOWNS("allow.unknowns"),
+ /**
+ * Represents the 'derivation.date.separator' parameter constant.
+ */
+ SPECIFIC_DERIVATION_DATE_SEP("derivation.date.separator"),
+ /**
+ * Represents the 'derivation.month.position' parameter constant.
+ */
+ SPECIFIC_DERIVATION_MONTH_POS("derivation.month.position"),
+ /**
+ * Represents the 'derivation.day.position' parameter constant.
+ */
+ SPECIFIC_DERIVATION_DAY_POS("derivation.day.position"),
+ /**
+ * Represents the 'derivation.year.position' parameter constant.
+ */
+ SPECIFIC_DERIVATION_YEAR_POS("derivation.year.position"),
+
+ /**
+ * sp.authorized.parameters Represents the '' parameter constant.
+ */
+ SPEPS_AUTHORIZED("sp.authorized.parameters"),
+
+ /**
+ * Represents the 'spSector' constant value.
+ */
+ SPSECTOR("spSector"),
+ /**
+ * Represents the 'spApplication' constant value.
+ */
+ SPAPPLICATION("spApplication"),
+ /**
+ * Represents the 'spCountry' constant value.
+ */
+ SPCOUNTRY("spCountry"),
+ /**
+ * Represents the 'spInstitution' constant value.
+ */
+ SPINSTITUTION("spInstitution"),
+ /**
+ * Represents the 'storkAttribute.number' parameter constant.
+ */
+ STORK_ATTRIBUTE_NUMBER("storkAttribute.number"),
+ /**
+ * Represents the 'storkAttributeValue.number' parameter constant.
+ */
+ STORK_ATTRIBUTE_VALUE_NUMBER("storkAttributeValue.number"),
+
+ /**
+ * Represents the 'username' parameter constant.
+ */
+ USERNAME("username"),
+
+ /**
+ * Represents the 'tooManyParameters' parameter constant.
+ */
+ TOO_MANY_PARAMETERS("tooManyParameters"),
+ /**
+ * Represents the 'validation.active' parameter constant.
+ */
+ VALIDATION_ACTIVE("validation.active"),
+
+ /**
+ * Represents the 'x-forwarded-for' parameter constant.
+ */
+ X_FORWARDED_FOR("x-forwarded-for"),
+ /**
+ * Represents the 'x-forwarded-host' parameter constant.
+ */
+ X_FORWARDED_HOST("x-forwarded-host"),
+ /**
+ * Represents the 'XMLResponse' parameter constant.
+ */
+ XML_RESPONSE("XMLResponse"),
+
+ /**
+ * Represents the 'ap-cpeps.number' parameter constant.
+ */
+ AP_PEPS_NUMBER("ap-cpeps.number"),
+
+ /**
+ * Represents the 'atp.number' parameter constant.
+ */
+ ATTRIBUTE_PROVIDER_NUMBER("atp.number"),
+
+ /**
+ * Represents the 'atn.number' parameter constant.
+ */
+ ATTRIBUTE_NAME_NUMBER("atn.number"),
+
+ /**
+ * Represents the 'apLinker' parameter constant.
+ */
+ AP_LINKER("apLinker"),
+
+ /**
+ * Represents the 'prevApLinker' parameter constant.
+ */
+ PREV_AP_LINKER("prevApLinker"),
+
+ /**
+ * Represents the 'NOSEL' parameter constant (no attribute provider selected).
+ */
+ AP_NO_SELECTION("NOSEL"),
+
+ /**
+ * Represents the 'OCSEL' parameter constant (attribute provider in another country).
+ */
+ AP_OTHER_COUNTRY("OCSEL"),
+
+ /**
+ * Represents the '_provider' suffix parameter constant.
+ */
+ AP_PROVIDER_SELECT_SUFFIX("_provider"),
+
+ /**
+ * Represents the '_country' suffix parameter constant.
+ */
+ AP_COUNTRY_SELECT_SUFFIX("_country"),
+
+ /**
+ * Represents the '_name' suffix parameter constant.
+ */
+ AP_NAME_SELECT_SUFFIX("_name"),
+
+ /**
+ * Represents the 'next-ap' parameter constant.
+ */
+ NEXT_AP("next-ap"),
+
+ /**
+ * Represents the 'next-apeps' parameter constant.
+ */
+ NEXT_APEPS("next-apeps"),
+
+ /**
+ * Represents the 'back-to-apeps' parameter constant.
+ */
+ BACK_TO_APEPS("back-to-apeps"),
+
+ /**
+ * Represents the 'is-remote-apeps' parameter constant.
+ */
+ IS_REMOTE_APEPS("is-remote-apeps"),
+
+ /**
+ * Represents the 'more-attributes' parameter constant.
+ */
+ MORE_ATTRIBUTES("more-attributes"),
+
+ /**
+ * Represents the 'attr-filter.number' parameter constant.
+ */
+ ATTRIBUTES_FILTER_NUMBER("attr-filter.number"),
+
+ /**
+ * Represents the 'attr-group' parameter constant.
+ */
+ ATTRIBUTE_GROUPS("attr-group"),
+
+ /**
+ * Represents the 'all' parameter constant for attribute groups.
+ */
+ ATTRIBUTE_GROUPS_ALL("all"),
+
+ /**
+ * Represents the 'none' parameter constant for attribute groups.
+ */
+ ATTRIBUTE_GROUPS_NONE("none"),
+
+ /**
+ * Represents the 'atp.url' parameter constant.
+ */
+ ATP_URL("atp.url"),
+ /**
+ * Represents the 'apepsURL' parameter constant.
+ */
+ APEPS_URL("apepsUrl"),
+
+ /**
+ * Represents the 'apepsCountry' parameter constant.
+ */
+ APEPS_COUNTRY("apepsCountry"),
+
+ /**
+ * Represents the 'apepsAuthRequest' parameter constant.
+ */
+ APEPS_ATTR_REQUEST("apepsAttrRequest"),
+
+ /**
+ * Represents the 'isApepsRequest' parameter constant.
+ */
+ APEPS_REQUEST_COMPLETE("apeps-request-complete"),
+
+ /**
+ * Represents the 'apeps.callbackUrl' parameter constant.
+ */
+ APEPS_CALLBACK_URL("apeps.callbackUrl"),
+ /**
+ * Represents the 'attrListMand' parameter constant.
+ */
+ ATTR_LIST_MAND("attrListMand"),
+
+ /**
+ * Represents the 'attrListOpt' parameter constant.
+ */
+ ATTR_LIST_OPT("attrListOpt"),
+
+ /**
+ * Represents the 'simpleAttrListMand' parameter constant.
+ */
+ SIMPLE_ATTR_LIST_MAND("simpleAttrListMand"),
+
+ /**
+ * Represents the 'simpleAttrListOpt' parameter constant.
+ */
+ SIMPLE_ATTR_LIST_OPT("simpleAttrListOpt"),
+
+ /**
+ * Represents the 'complexAttrListMand' parameter constant.
+ */
+ COMPLEX_ATTR_LIST_MAND("complexAttrListMand"),
+
+ /**
+ * Represents the 'complexAttrListOpt' parameter constant.
+ */
+ COMPLEX_ATTR_LIST_OPT("complexAttrListOpt");
+
+ /**
+ * Represents the constant's value.
+ */
+ private String value;
+
+ /**
+ * Solo Constructor.
+ *
+ * @param nValue The Constant value.
+ */
+ PEPSParameters(final String nValue) {
+ this.value = nValue;
+ }
+
+ /**
+ * Return the Constant Value.
+ *
+ * @return The constant value.
+ */
+ public String toString() {
+ return value;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PEPSUtil.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PEPSUtil.java
new file mode 100644
index 000000000..69729c0bb
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PEPSUtil.java
@@ -0,0 +1,391 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.io.ByteArrayInputStream;
+import java.io.InputStream;
+import java.io.UnsupportedEncodingException;
+import java.util.Properties;
+
+import org.apache.commons.lang.StringUtils;
+import org.apache.log4j.Logger;
+import org.bouncycastle.crypto.Digest;
+import org.bouncycastle.util.encoders.Base64;
+import org.bouncycastle.util.encoders.UrlBase64;
+
+import eu.stork.peps.auth.commons.exceptions.InternalErrorPEPSException;
+import eu.stork.peps.auth.commons.exceptions.InvalidParameterPEPSException;
+
+/**
+ * This class holds static helper methods.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.75 $, $Date: 2010-11-23 00:05:35 $
+ */
+public final class PEPSUtil {
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(PEPSUtil.class.getName());
+
+ /**
+ * Configurations object.
+ */
+ private static Properties configs;
+
+ /**
+ * Max prefix.
+ */
+ private static final String MAX_PARAM_PREFIX = "max.";
+
+ /**
+ * Code prefix to get error code.
+ */
+ private static final String CODE_PARAM_SUFFIX = ".code";
+
+ /**
+ * param's size prefix to get max param size.
+ */
+ private static final String MAX_PARAM_SUFFIX = ".size";
+
+ /**
+ * Message prefix to get error message.
+ */
+ private static final String MSG_PARAM_SUFFIX = ".message";
+
+ /**
+ * Private constructor. Prevents the class from being instantiated.
+ */
+ private PEPSUtil() {
+ // empty constructor
+ }
+
+ /**
+ * Creates a single instance of this class and sets the properties.
+ *
+ * @param nConfigs The set of available configurations.
+ *
+ * @return The created PEPSUtil's class.
+ */
+ public static PEPSUtil createInstance(final Properties nConfigs) {
+ if (nConfigs != null) {
+ PEPSUtil.configs = nConfigs;
+ }
+ return new PEPSUtil();
+ }
+
+ /**
+ * Getter for the Properties.
+ *
+ * @return configs The properties value.
+ */
+ public Properties getConfigs() {
+ return configs;
+ }
+
+ /**
+ * Setter for the Properties.
+ *
+ * @param nConfigs The new properties value.
+ */
+ public static void setConfigs(final Properties nConfigs) {
+ if (nConfigs != null) {
+ PEPSUtil.configs = nConfigs;
+ }
+ }
+
+ /**
+ * Returns the identifier of some configuration given a set of configurations
+ * and the corresponding configuration key.
+ *
+ * @param configKey The key that IDs some configuration.
+ *
+ * @return The configuration String value.
+ */
+ public static String getConfig(final String configKey) {
+ return configs.getProperty(configKey);
+ }
+
+ /**
+ * Validates the input paramValue identified by the paramName.
+ *
+ * @param paramName The name of the parameter to validate.
+ * @param paramValue The value of the parameter to validate.
+ *
+ * @return true if the parameter is valid.
+ */
+ public static boolean isValidParameter(final String paramName,
+ final String paramValue) {
+
+ final String validationParam =
+ PEPSUtil.getConfig(PEPSParameters.VALIDATION_ACTIVE.toString());
+ boolean retVal = true;
+
+ final String paramConf = MAX_PARAM_PREFIX + paramName + MAX_PARAM_SUFFIX;
+
+ if (PEPSValues.TRUE.toString().equals(validationParam)) {
+ final String paramSizeStr = PEPSUtil.getConfig(paramConf);
+ // Checking if the parameter size exists and if it's numeric
+ if (StringUtils.isNumeric(paramSizeStr)) {
+ final int maxParamSize = Integer.valueOf(paramSizeStr);
+ if (StringUtils.isEmpty(paramValue)
+ || paramValue.length() > maxParamSize) {
+ retVal = false;
+ LOG.warn("Invalid parameter [" + paramName + "] value " + paramValue);
+ }
+ } else {
+ retVal = false;
+ LOG.error("Missing " + paramConf
+ + " configuration in the pepsUtils.properties configuration file");
+ }
+ }
+ return retVal;
+ }
+
+ /**
+ * Validates the Parameter and throws an exception if an error occurs. Throws
+ * an InvalidParameterPEPSException runtime exception if the parameter is
+ * invalid.
+ *
+ * @param className The Class Name that invoked the method.
+ * @param paramName The name of the parameter to validate.
+ * @param paramValue The value of the parameter to validate.
+ */
+ public static void validateParameter(final String className,
+ final String paramName, final Object paramValue) {
+
+ if (paramValue == null) {
+ PEPSUtil.validateParameter(className, paramName, "");
+ } else {
+ PEPSUtil.validateParameter(className, paramName, paramValue.toString());
+ }
+ }
+
+ /**
+ * Validates the Parameters and throws an exception if an error occurs.
+ *
+ * @param className The Class Name that invoked the method.
+ * @param paramName The name of the parameter to validate.
+ * @param paramValue The value of the parameter to validate.
+ */
+ public static void validateParameter(final String className,
+ final String paramName, final String paramValue) {
+
+ PEPSUtil.validateParameter(className, paramName, paramValue,
+ PEPSUtil.getErrorCode(paramName), PEPSUtil.getErrorMessage(paramName));
+ }
+
+ /**
+ * Validates the Parameters and throws an exception if an error occurs.
+ *
+ * @param className The Class Name that invoked the method.
+ * @param paramName The name of the parameter to validate.
+ * @param paramValue The value of the parameter to validate.
+ * @param error The PEPSError to get error code and messages from configs.
+ */
+ public static void validateParameter(final String className,
+ final String paramName, final String paramValue, final PEPSErrors error) {
+
+ PEPSUtil.validateParameter(className, paramName, paramValue,
+ PEPSUtil.getConfig(error.errorCode()),
+ PEPSUtil.getConfig(error.errorMessage()));
+ }
+
+ /**
+ * Validates the HTTP Parameter and throws an exception if an error occurs.
+ * Throws an InvalidParameterPEPSException runtime exception if the parameter
+ * is invalid.
+ *
+ * @param className The Class Name that invoked the method.
+ * @param paramName The name of the parameter to validate.
+ * @param paramValue The value of the parameter to validate.
+ * @param errorCode The error code to include on the exception.
+ * @param errorMessage The error message to include on the exception.
+ */
+ public static void validateParameter(final String className,
+ final String paramName, final String paramValue, final String errorCode,
+ final String errorMessage) {
+
+ if (!isValidParameter(paramName, paramValue)) {
+ LOG.warn("Invalid parameter [" + paramName + "] value found at "
+ + className);
+ throw new InvalidParameterPEPSException(errorCode, errorMessage);
+ }
+ }
+
+ /**
+ * Getter for the error code of some given error related to the input param.
+ *
+ * @param paramName The name of the parameter associated with the error.
+ *
+ * @return The code of the error.
+ */
+ private static String getErrorCode(final String paramName) {
+ return getConfig(paramName + CODE_PARAM_SUFFIX);
+ }
+
+ /**
+ * Getter for the error message of some given error related to the input
+ * parameter.
+ *
+ * @param paramName The name of the parameter associated with the message.
+ *
+ * @return The message for the error.
+ */
+ private static String getErrorMessage(final String paramName) {
+ return getConfig(paramName + MSG_PARAM_SUFFIX);
+ }
+
+ /**
+ * {@link Base64} encodes the input samlToken parameter.
+ *
+ * @param samlToken the SAML Token to be encoded.
+ *
+ * @return The Base64 String representing the samlToken.
+ *
+ * @see Base64#encode
+ */
+ public static String encodeSAMLToken(final byte[] samlToken) {
+ try {
+ return new String(Base64.encode(samlToken), "UTF8");
+ } catch (final UnsupportedEncodingException e) {
+ LOG.error(PEPSErrors.INTERNAL_ERROR.errorMessage(), e);
+ return null;
+ }
+ }
+
+ /**
+ * Encode samltoken url safe
+ * @param samlToken the saml token to encode
+ * @return the bas64 encoded string
+ */
+ public static String encodeSAMLTokenUrlSafe(final byte[] samlToken) {
+ try {
+ return new String(UrlBase64.encode(samlToken), "UTF8");
+ } catch (final UnsupportedEncodingException e) {
+ LOG.error(PEPSErrors.INTERNAL_ERROR.errorMessage(), e);
+ return null;
+ }
+ }
+
+ /**
+ * Decodes the {@link Base64} String input parameter representing a samlToken.
+ *
+ * @param samlToken the SAML Token to be decoded.
+ *
+ * @return The samlToken decoded bytes.
+ *
+ * @see Base64#decode
+ */
+ public static byte[] decodeSAMLToken(final String samlToken) {
+ return Base64.decode(samlToken);
+ }
+
+ /**
+ * Decode URL save base64 saml token
+ * @param samlToken the SAML toke to decode
+ * @return The decoded bytes
+ */
+ public static byte[] decodeSAMLTokenUrlSafe(final String samlToken) {
+ return UrlBase64.decode(samlToken);
+ }
+
+ /**
+ * Hashes a SAML token. Throws an InternalErrorPEPSException runtime exception
+ * if the Cryptographic Engine fails.
+ *
+ * @param samlToken the SAML Token to be hashed.
+ *
+ * @return byte[] with the hashed SAML Token.
+ */
+ public static byte[] hashPersonalToken(final byte[] samlToken) {
+ try {
+ final String className =
+ PEPSUtil.getConfig(PEPSValues.HASH_DIGEST_CLASS.toString());
+
+ final Digest digest =
+ (Digest) Class.forName(className).getConstructor()
+ .newInstance((Object[]) null);
+ digest.update(samlToken, 0, samlToken.length);
+
+ final int retLength = digest.getDigestSize();
+ final byte[] ret = new byte[retLength];
+
+ digest.doFinal(ret, 0);
+ return ret;
+
+ } catch (final Exception e) {
+ // For all those exceptions that could be thrown, we always log it and
+ // thrown an InternalErrorPEPSException.
+ LOG.error(PEPSErrors.HASH_ERROR.errorMessage(), e);
+ throw new InternalErrorPEPSException(
+ PEPSUtil.getConfig(PEPSErrors.HASH_ERROR.errorCode()),
+ PEPSUtil.getConfig(PEPSErrors.HASH_ERROR.errorMessage()), e);
+ }
+ }
+
+ /**
+ * Gets the Stork error code in the error message if exists!
+ *
+ * @param errorMessage The message to get the error code if exists;
+ *
+ * @return the error code if exists. Returns null otherwise.
+ */
+ public static String getStorkErrorCode(final String errorMessage) {
+ if (StringUtils.isNotBlank(errorMessage)
+ && errorMessage.indexOf(PEPSValues.ERROR_MESSAGE_SEP.toString()) >= 0) {
+ final String[] msgSplitted =
+ errorMessage.split(PEPSValues.ERROR_MESSAGE_SEP.toString());
+ if (msgSplitted.length == 2 && StringUtils.isNumeric(msgSplitted[0])) {
+ return msgSplitted[0];
+ }
+ }
+ return null;
+ }
+
+ /**
+ * Gets the Stork error message in the saml message if exists!
+ *
+ * @param errorMessage The message to get in the saml message if exists;
+ *
+ * @return the error message if exists. Returns the original message
+ * otherwise.
+ */
+ public static String getStorkErrorMessage(final String errorMessage) {
+ if (StringUtils.isNotBlank(errorMessage)
+ && errorMessage.indexOf(PEPSValues.ERROR_MESSAGE_SEP.toString()) >= 0) {
+ final String[] msgSplitted =
+ errorMessage.split(PEPSValues.ERROR_MESSAGE_SEP.toString());
+ if (msgSplitted.length == 2 && StringUtils.isNumeric(msgSplitted[0])) {
+ return msgSplitted[1];
+ }
+ }
+ return errorMessage;
+ }
+
+ /**
+ * Get inputstream from string
+ * @param string the string to convert
+ * @param codePage the codepage of string
+ * @return an inputstream
+ * @throws UnsupportedEncodingException
+ */
+ public static InputStream getStream(final String string, final String codePage) throws UnsupportedEncodingException
+ {
+ return new ByteArrayInputStream(string.getBytes(codePage));
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PEPSValues.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PEPSValues.java
new file mode 100644
index 000000000..89cf8fa9b
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PEPSValues.java
@@ -0,0 +1,342 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+/**
+ * This enum class contains all the value constants.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.17 $, $Date: 2011-07-07 20:48:45 $
+ */
+public enum PEPSValues {
+
+ /**
+ * Represents the 'all' constant value.
+ */
+ ALL("all"),
+ /**
+ * Represents the 'none' constant value.
+ */
+ NONE("none"),
+ /**
+ * Represents the 'true' constant value.
+ */
+ TRUE("true"),
+ /**
+ * Represents the 'false' constant value.
+ */
+ FALSE("false"),
+ /**
+ * Represents the empty string constant value.
+ */
+ EMPTY_STRING(""),
+
+ /**
+ * Represents the ',' separator constant value.
+ */
+ ATTRIBUTE_VALUE_SEP(","),
+ /**
+ * Represents the ';' separator constant value.
+ */
+ ATTRIBUTE_SEP(";"),
+ /**
+ * Represents the ':' separator constant value.
+ */
+ ATTRIBUTE_TUPLE_SEP(":"),
+ /**
+ * Represents the '/' separator constant value.
+ */
+ EID_SEPARATOR("/"),
+ /**
+ * Represents the ' - ' separator constant value.
+ */
+ ERROR_MESSAGE_SEP(" - "),
+ /**
+ * Represents the '#' parameter constant value.
+ */
+ LOGGER_SEP("#"),
+ /**
+ * Represents the 'NOT_AVAILABLE' parameter constant value.
+ */
+ NOT_AVAILABLE("NotAvailable"),
+ /**
+ * Represents the ';' parameter constant value.
+ */
+ SPEPS_AUTHORIZED_SEP(";"),
+
+ /**
+ * Represents the 'ap' constant value.
+ */
+ AP("ap"),
+ /**
+ * Represents the 'C-PEPS' constant value.
+ */
+ CPEPS("C-PEPS"),
+ /**
+ * Represents the 'cpeps' constant value.
+ */
+ CPEPS_PREFIX("cpeps"),
+ /**
+ * Represents the 'peps' constant value.
+ */
+ PEPS("peps"),
+ /**
+ * Represents the '-PEPS' constant value.
+ */
+ PEPS_SUFFIX("-PEPS"),
+ /**
+ * Represents the 'SP' constant value.
+ */
+ SP("SP"),
+ /**
+ * Represents the 'S-PEPS' constant value.
+ */
+ SPEPS("S-PEPS"),
+ /**
+ * Represents the 'speps' constant value.
+ */
+ SPEPS_PREFIX("speps"),
+ /**
+ * Represents the 'sp.default.parameters' constant value.
+ */
+ DEFAULT("sp.default.parameters"),
+ /**
+ * Represents the default saml id constant value.
+ */
+ DEFAULT_SAML_ID("1"),
+ /**
+ * Represents the 'hashDigest.className' constant value.
+ */
+ HASH_DIGEST_CLASS("hashDigest.className"),
+
+ /**
+ * Represents the 'eu.stork.communication.requests' constant value.
+ */
+ STORK_PACKAGE_REQUEST_LOGGER_VALUE("eu.stork.communication.requests"),
+ /**
+ * Represents the 'eu.stork.communication.responses' constant value.
+ */
+ STORK_PACKAGE_RESPONSE_LOGGER_VALUE("eu.stork.communication.responses"),
+
+ /**
+ * Represents the 'S-PEPS receives request from SP' constant value.
+ */
+ SP_REQUEST("S-PEPS receives request from SP"),
+ /**
+ * Represents the 'Get Citizen Consent' constant value.
+ */
+ CITIZEN_CONSENT_LOG("Get Citizen Consent"),
+ /**
+ * Represents the 'C-PEPS receives request from S-PEPS' constant value.
+ */
+ CPEPS_REQUEST("C-PEPS receives request from S-PEPS"),
+ /**
+ * Represents the 'C-PEPS generates response to S-PEPS' constant value.
+ */
+ CPEPS_RESPONSE("C-PEPS generates response to S-PEPS"),
+ /**
+ * Represents the 'S-PEPS generates request to C-PEPS' constant value.
+ */
+ SPEPS_REQUEST("S-PEPS generates request to C-PEPS"),
+ /**
+ * Represents the 'S-PEPS receives response from C-PEPS' constant value.
+ */
+ SPEPS_RESPONSE("S-PEPS receives response from C-PEPS"),
+ /**
+ * Represents the 'S-PEPS generates response to SP' constant value.
+ */
+ SP_RESPONSE("S-PEPS generates response to SP"),
+ /**
+ * Represents the 'Success' constant value.
+ */
+ SUCCESS("Success"),
+ /**
+ * Represents the December's month number constant value.
+ */
+ LAST_MONTH("12"),
+ /**
+ * Represents the yyyyMM constant value.
+ */
+ NO_DAY_DATE_FORMAT("yyyyMM"),
+
+ /**
+ * Represents the 'attrValue' constant value.
+ */
+ ATTRIBUTE("attrValue"),
+ /**
+ * Represents the 'derivedAttr' constant value.
+ */
+ DERIVE_ATTRIBUTE("deriveAttr"),
+ /**
+ * Represents the 'storkAttribute' constant value.
+ */
+ STORK_ATTRIBUTE("storkAttribute"),
+
+ /**
+ * Represents the 'properties' constant value.
+ */
+ PROPERTIES("properties"),
+ /**
+ * Represents the 'referer' constant value.
+ */
+ REFERER("referer"),
+ /**
+ * Represents the 'host' constant value.
+ */
+ HOST("host"),
+ /**
+ * Represents the 'spid' constant value.
+ */
+ SPID("spid"),
+ /**
+ * Represents the 'domain' constant value.
+ */
+ DOMAIN("domain"),
+ /**
+ * Represents the '.validation' constant value.
+ */
+ VALIDATION_SUFFIX(".validation"),
+ /**
+ * Represents the 'jsessionid' constant value.
+ */
+ EQUAL("="),
+ /**
+ * Represents the 'HttpOnly' constant value.
+ */
+ HTTP_ONLY("HttpOnly"),
+ /**
+ * Represents the 'SET-COOKIE' constant value.
+ */
+ JSSESSION("JSESSIONID"),
+ /**
+ * Represents the '=' constant value.
+ */
+ SETCOOKIE("SET-COOKIE"),
+ /**
+ * Represents the ';' constant value.
+ */
+ SEMICOLON(";"),
+ /**
+ * Represents the ' ' constant value.
+ */
+ SPACE(" "),
+ /**
+ * Represents the 'atp' constant value.
+ */
+ APROVIDER_PREFIX("atp"),
+ /**
+ * Represents the 'atn' constant value.
+ */
+ ANAME_PREFIX("atn"),
+ /**
+ * Represents the 'ap-cpeps' constant value.
+ */
+ AP_CPEPS_PREFIX("ap-cpeps"),
+ /**
+ * Represents the 'attr-filter' constant value.
+ */
+ AP_ATTRFILTER_PREFIX("attr-filter");
+
+ /**
+ * Represents the constant's value.
+ */
+ private String value;
+
+ /**
+ * Solo Constructor.
+ *
+ * @param val The Constant value.
+ */
+ PEPSValues(final String val) {
+
+ this.value = val;
+ }
+
+ /**
+ * Return the Constant Value.
+ *
+ * @return The constant value.
+ */
+ public String toString() {
+
+ return value;
+ }
+
+ /**
+ * Construct the return value with the following structure
+ * CONSTANT_VALUE+index+".id".
+ *
+ * @param index the number.
+ *
+ * @return The concatenated String value.
+ */
+ public String index(final int index) {
+
+ return value + index + ".id";
+ }
+
+ /**
+ * Construct the return value with the following structure
+ * CONSTANT_VALUE+index+".value".
+ *
+ * @param index the number.
+ *
+ * @return The concatenated string value.
+ */
+ public String value(final int index) {
+
+ return value + index + ".value";
+ }
+
+ /**
+ * Construct the return value with the following structure
+ * CONSTANT_VALUE+index+".name".
+ *
+ * @param index the number.
+ *
+ * @return The concatenated String value.
+ */
+ public String name(final int index) {
+
+ return value + index + ".name";
+ }
+
+ /**
+ * Construct the return value with the following structure
+ * CONSTANT_VALUE+index+".url".
+ *
+ * @param index the number.
+ *
+ * @return The concatenated String value.
+ */
+ public String url(final int index) {
+
+ return value + index + ".url";
+ }
+
+ /**
+ * Construct the return value with the following structure
+ * CONSTANT_VALUE+index+".allowedGroups".
+ *
+ * @param index the number.
+ *
+ * @return The concatenated String value.
+ */
+ public String allowedGroups(final int index) {
+
+ return value + index + ".allowedGroups";
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PersonalAttribute.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PersonalAttribute.java
new file mode 100644
index 000000000..5d8281445
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PersonalAttribute.java
@@ -0,0 +1,348 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.concurrent.ConcurrentHashMap;
+
+import org.apache.log4j.Logger;
+
+import eu.stork.peps.auth.commons.exceptions.InternalErrorPEPSException;
+
+/**
+ * This class is a bean used to store the information relative to the
+ * PersonalAttribute.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.22 $, $Date: 2010-11-17 05:15:28 $
+ */
+public final class PersonalAttribute implements Serializable, Cloneable {
+
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 2612951678412632174L;
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(PersonalAttribute.class
+ .getName());
+
+ /**
+ * Name of the personal attribute.
+ */
+ private String name;
+
+ /**
+ * Values of the personal attribute.
+ */
+ private List<String> value = new ArrayList<String>();
+
+ /**
+ * Type of the personal attribute.
+ */
+ private String type;
+
+ /**
+ * Complex values of the personal attribute.
+ */
+ private Map<String, String> complexValue = new ConcurrentHashMap<String, String>();
+
+ /**
+ * Is the personal attribute mandatory?
+ */
+ private transient boolean required;
+
+ /**
+ * Returned status of the attribute from the IdP.
+ */
+ private String status;
+
+ /**
+ * Name of the personal attribute.
+ */
+ private String friendlyName;
+
+ /**
+ * Empty Constructor.
+ */
+ public PersonalAttribute() {
+ super();
+ }
+
+ /**
+ * PersonalAttribute Constructor for complex values.
+ *
+ * @param attrName The attribute name.
+ * @param attrIsRequired The attribute type value.
+ * @param attrComplexValue The attribute's value.
+ * @param attrStatus The attribute's status value.
+ */
+ public PersonalAttribute(final String attrName, final boolean attrIsRequired,
+ final List<String> attrComplexValue, final String attrStatus) {
+ this.setName(attrName);
+ this.setIsRequired(attrIsRequired);
+ this.setValue(attrComplexValue);
+ this.setStatus(attrStatus);
+ }
+
+ /**
+ * PersonalAttribute Constructor for complex values.
+ *
+ * @param attrName The attribute name.
+ * @param attrIsRequired The attribute type value.
+ * @param attrComplexValue The attribute's complex value.
+ * @param attrStatus The attribute's status value.
+ */
+ public PersonalAttribute(final String attrName, final boolean attrIsRequired,
+ final Map<String, String> attrComplexValue, final String attrStatus) {
+ this.setName(attrName);
+ this.setIsRequired(attrIsRequired);
+ this.setComplexValue(attrComplexValue);
+ this.setStatus(attrStatus);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @SuppressWarnings("unchecked")
+ public Object clone() {
+
+ try {
+ final PersonalAttribute personalAttr = (PersonalAttribute) super.clone();
+ personalAttr.setIsRequired(this.isRequired());
+ personalAttr.setName(this.getName());
+ personalAttr.setStatus(this.getStatus());
+ if (!isEmptyValue()) {
+ final List<String> val =
+ (List<String>) ((ArrayList<String>) this.getValue()).clone();
+ personalAttr.setValue(val);
+ }
+ if (!isEmptyComplexValue()) {
+ final Map<String, String> complexVal =
+ (Map<String, String>) ((HashMap<String, String>) this
+ .getComplexValue()).clone();
+ personalAttr.setComplexValue(complexVal);
+ }
+ return personalAttr;
+ } catch (final CloneNotSupportedException e) {
+ // assert false;
+ LOG.trace("Nothing to do.");
+ throw new InternalErrorPEPSException(
+ PEPSUtil.getConfig(PEPSErrors.INTERNAL_ERROR.errorCode()),
+ PEPSUtil.getConfig(PEPSErrors.INTERNAL_ERROR.errorMessage()), e);
+ }
+ }
+
+ /**
+ * Getter for the required value.
+ *
+ * @return The required value.
+ */
+ public boolean isRequired() {
+ return required;
+ }
+
+ /**
+ * Setter for the required value.
+ *
+ * @param attrIsRequired this attribute?
+ */
+ public void setIsRequired(final boolean attrIsRequired) {
+ this.required = attrIsRequired;
+ }
+
+ /**
+ * Getter for the name value.
+ *
+ * @return The name value.
+ */
+ public String getName() {
+ return name;
+ }
+
+ /**
+ * Setter for the name value.
+ *
+ * @param attrName The personal attribute name.
+ */
+ public void setName(final String attrName) {
+ this.name = attrName;
+ }
+
+ /**
+ * Getter for the value.
+ *
+ * @return The list of values.
+ */
+ public List<String> getValue() {
+ return value;
+ }
+
+ /**
+ * Setter for the list of values.
+ *
+ * @param attrValue The personal attribute value.
+ */
+ public void setValue(final List<String> attrValue) {
+ if (attrValue != null) {
+ this.value = attrValue;
+ }
+ }
+
+
+ /**
+ * Getter for the type value.
+ *
+ * @return The name value.
+ */
+ public String getType() {
+ return type;
+ }
+
+ /**
+ * Setter for the type value.
+ *
+ * @param attrName The personal attribute type.
+ */
+ public void setType(final String attrType) {
+ this.type = attrType;
+ }
+
+ /**
+ * Getter for the status.
+ *
+ * @return The status value.
+ */
+ public String getStatus() {
+ return status;
+ }
+
+ /**
+ * Setter for the status value.
+ *
+ * @param attrStatus The personal attribute status.
+ */
+ public void setStatus(final String attrStatus) {
+ this.status = attrStatus;
+ }
+
+ /**
+ * Getter for the complex value.
+ *
+ * @return The complex value.
+ */
+ public Map<String, String> getComplexValue() {
+ return complexValue;
+ }
+
+ /**
+ * Setter for the complex value.
+ *
+ * @param complexVal The personal attribute Complex value.
+ */
+ public void setComplexValue(final Map<String, String> complexVal) {
+ if (complexVal != null) {
+ this.complexValue = complexVal;
+ }
+ }
+
+ /**
+ * Getter for the personal's friendly name.
+ *
+ * @return The personal's friendly name value.
+ */
+ public String getFriendlyName() {
+ return friendlyName;
+ }
+
+ /**
+ * Setter for the personal's friendly name.
+ *
+ * @param fName The personal's friendly name.
+ */
+ public void setFriendlyName(final String fName) {
+ this.friendlyName = fName;
+ }
+
+ /**
+ * Return true the value is empty.
+ *
+ * @return True if the value is empty "[]";
+ */
+ public boolean isEmptyValue() {
+ return value.isEmpty() || (value.size() == 1 && value.get(0).length() == 0);
+ }
+
+ /**
+ * Returns true if the Complex Value is empty.
+ *
+ * @return True if the Complex Value is empty;
+ */
+ public boolean isEmptyComplexValue() {
+ return complexValue.isEmpty();
+ }
+
+ /**
+ * Returns true if the Status is empty.
+ *
+ * @return True if the Status is empty;
+ */
+ public boolean isEmptyStatus() {
+ return (status == null || status.length() == 0);
+ }
+
+ /**
+ * Prints the PersonalAttribute in the following format.
+ * name:required:[v,a,l,u,e,s]|[v=a,l=u,e=s]:status;
+ *
+ * @return The PersonalAttribute as a string.
+ */
+ public String toString() {
+ final StringBuilder strBuild = new StringBuilder();
+
+ AttributeUtil.appendIfNotNull(strBuild, getName());
+ strBuild.append(PEPSValues.ATTRIBUTE_TUPLE_SEP.toString());
+ AttributeUtil.appendIfNotNull(strBuild, String.valueOf(isRequired()));
+ strBuild.append(PEPSValues.ATTRIBUTE_TUPLE_SEP.toString());
+ strBuild.append('[');
+
+ if (isEmptyValue()) {
+ if (!isEmptyComplexValue()) {
+ AttributeUtil.appendIfNotNull(strBuild, AttributeUtil.mapToString(
+ getComplexValue(), PEPSValues.ATTRIBUTE_VALUE_SEP.toString()));
+ }
+ } else {
+ AttributeUtil.appendIfNotNull(
+ strBuild,
+ AttributeUtil.listToString(getValue(),
+ PEPSValues.ATTRIBUTE_VALUE_SEP.toString()));
+ }
+
+ strBuild.append(']');
+ strBuild.append(PEPSValues.ATTRIBUTE_TUPLE_SEP.toString());
+ AttributeUtil.appendIfNotNull(strBuild, getStatus());
+ strBuild.append(PEPSValues.ATTRIBUTE_SEP.toString());
+
+ return strBuild.toString();
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PersonalAttributeList.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PersonalAttributeList.java
new file mode 100644
index 000000000..9a0f87488
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/PersonalAttributeList.java
@@ -0,0 +1,397 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.StringTokenizer;
+
+import org.apache.commons.lang.StringUtils;
+import org.apache.log4j.Logger;
+
+/**
+ * This class is a bean used to store the information relative to the
+ * PersonalAttributeList.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.27 $, $Date: 2010-11-18 22:54:56 $
+ *
+ * @see PersonalAttribute
+ */
+@SuppressWarnings("PMD")
+public final class PersonalAttributeList extends
+ ConcurrentHashMap<String, PersonalAttribute> implements IPersonalAttributeList, Serializable {
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger
+ .getLogger(PersonalAttributeList.class.getName());
+
+ /**
+ * Serial id.
+ */
+ private static final long serialVersionUID = 7375127363889975062L;
+
+ /**
+ * Hash with the latest fetched attribute name alias.
+ */
+ private final Map<String, Integer> latestAttrAlias =
+ new HashMap<String, Integer>();
+
+ /**
+ * Hash with mapping number of alias or the attribute name.
+ */
+ private final Map<String, Integer> attrAliasNumber =
+ new HashMap<String, Integer>();
+
+ /**
+ * Default constructor.
+ */
+ public PersonalAttributeList() {
+ // The best practices recommend to call the super constructor.
+ super();
+ }
+
+ /**
+ * Constructor with initial capacity for the PersonalAttributeList size.
+ *
+ * @param capacity The initial capacity for the PersonalAttributeList.
+ */
+ public PersonalAttributeList(final int capacity) {
+ super(capacity);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public Iterator<PersonalAttribute> iterator() {
+ return this.values().iterator();
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public PersonalAttribute get(final Object key) {
+ String attrName = (String) key;
+
+ if (this.latestAttrAlias.containsKey(key)) {
+ attrName = attrName + this.latestAttrAlias.get(key);
+ } else {
+ if (this.attrAliasNumber.containsKey(key)) {
+ this.latestAttrAlias.put(attrName, this.attrAliasNumber.get(key));
+ }
+ }
+ return super.get(attrName);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public void add(final PersonalAttribute value) {
+ if (value != null) {
+ this.put(value.getName(), value);
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public PersonalAttribute put(final String key, final PersonalAttribute val) {
+ if (StringUtils.isNotEmpty(key) && val != null) {
+ // Validate if attribute name already exists!
+ String attrAlias = key;
+ if (this.containsKey(attrAlias)) {
+ //TODO isAgeOver should not be hardcoded, a better way of handling multipe isAgeOver requests should be implemented.
+ if (!val.isEmptyValue() && StringUtils.isNumeric(val.getValue().get(0)) && "isAgeOver".equals( val.getName() ) ) {
+ final String attrValue = val.getValue().get(0);
+ attrAlias = key + attrValue;
+ this.attrAliasNumber.put(key, Integer.valueOf(attrValue));
+ } else {
+ final PersonalAttribute attr = super.get(key);
+ if (!attr.isEmptyValue()
+ && StringUtils.isNumeric(attr.getValue().get(0))) {
+ attrAlias = key + attr.getValue().get(0);
+ super.put(key, (PersonalAttribute) attr);
+ this.attrAliasNumber.put(key, null);
+ }
+ }
+ }
+ return super.put(attrAlias, val);
+ } else {
+ return null;
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public void populate(final String attrList) {
+ final StringTokenizer strToken =
+ new StringTokenizer(attrList, PEPSValues.ATTRIBUTE_SEP.toString());
+
+ while (strToken.hasMoreTokens()) {
+ final PersonalAttribute persAttr = new PersonalAttribute();
+ String[] tuples =
+ strToken.nextToken().split(PEPSValues.ATTRIBUTE_TUPLE_SEP.toString(),
+ AttributeConstants.NUMBER_TUPLES.intValue());
+
+ // Convert to the new format if needed!
+ tuples = convertFormat(tuples);
+
+ if (AttributeUtil.hasValidTuples(tuples)) {
+ final int attrValueIndex =
+ AttributeConstants.ATTR_VALUE_INDEX.intValue();
+ final String tmpAttrValue =
+ tuples[attrValueIndex].substring(1,
+ tuples[attrValueIndex].length() - 1);
+ final String[] vals =
+ tmpAttrValue.split(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+
+ persAttr.setName(tuples[AttributeConstants.ATTR_NAME_INDEX.intValue()]);
+ persAttr.setIsRequired(Boolean
+ .valueOf(tuples[AttributeConstants.ATTR_TYPE_INDEX.intValue()]));
+
+ // check if it is a complex value
+ if (isComplexValue(vals)) {
+ persAttr.setComplexValue(createComplexValue(vals));
+ }
+ else
+ {
+ persAttr.setValue(createValues(vals));
+ }
+
+ if (tuples.length == AttributeConstants.NUMBER_TUPLES.intValue()) {
+ persAttr.setStatus(tuples[AttributeConstants.ATTR_STATUS_INDEX
+ .intValue()]);
+ }
+ this.put(tuples[AttributeConstants.ATTR_NAME_INDEX.intValue()],
+ persAttr);
+
+ } else {
+ LOG.warn("Invalid personal attribute list tuples");
+ }
+
+ }
+ }
+
+ /**
+ * Returns a copy of this <tt>IPersonalAttributeList</tt> instance.
+ *
+ * @return The copy of this IPersonalAttributeList.
+ */
+ public Object clone() {
+ try {
+ return (PersonalAttributeList) super.clone();
+ } catch (CloneNotSupportedException e) {
+ return null;
+ }
+ }
+
+ /**
+ * Creates a string in the following format.
+ *
+ * attrName:attrType:[attrValue1,attrValue2=attrComplexValue]:attrStatus;
+ *
+ * @return {@inheritDoc}
+ */
+ @Override
+ public String toString() {
+ final Iterator<Entry<String, PersonalAttribute>> itAttrs =
+ this.entrySet().iterator();
+ final StringBuilder strBuilder = new StringBuilder();
+
+ while (itAttrs.hasNext()) {
+ final Entry<String, PersonalAttribute> attrEntry = itAttrs.next();
+ final PersonalAttribute attr = attrEntry.getValue();
+ //strBuilder.append(attr.toString());
+ strBuilder.insert(0, attr.toString());
+ }
+
+ return strBuilder.toString();
+ }
+
+ /**
+ * Validates and creates the attribute's complex values.
+ *
+ * @param values The complex values.
+ *
+ * @return The {@link Map} with the complex values.
+ *
+ * @see Map
+ */
+ private Map<String, String> createComplexValue(final String[] values) {
+ final Map<String, String> complexValue = new HashMap<String, String>();
+ for (final String val : values) {
+ final String[] tVal = val.split("=");
+ if (StringUtils.isNotEmpty(val) && tVal.length == 2) {
+ complexValue.put(tVal[0], AttributeUtil.unescape(tVal[1]));
+ }
+ }
+ return complexValue;
+ }
+
+ /**
+ * Checks if value is complex or not
+ * @param values The values to check
+ * @return True if succesful
+ */
+ private boolean isComplexValue(final String[] values) {
+ boolean isComplex = false;
+ if (values.length > 0) {
+ final String[] tVal = values[0].split("=");
+ if (StringUtils.isNotEmpty(values[0]) && tVal.length == 2) {
+ isComplex = true;
+ }
+ }
+ return isComplex;
+ }
+
+ /**
+ * Validates and creates the attribute values.
+ *
+ * @param vals The attribute values.
+ *
+ * @return The {@link List} with the attribute values.
+ *
+ * @see List
+ */
+ private List<String> createValues(final String[] vals) {
+ final List<String> values = new ArrayList<String>();
+ for (final String val : vals) {
+ if (StringUtils.isNotEmpty(val)) {
+ values.add(AttributeUtil.unescape(val));
+ }
+ }
+ return values;
+ }
+
+ /**
+ * Converts the attribute tuple (attrName:attrType...) to the new format.
+ *
+ * @param tuples The attribute tuples to convert.
+ *
+ * @return The attribute tuples in the new format.
+ */
+ private String[] convertFormat(final String[] tuples) {
+ final String[] newFormatTuples =
+ new String[AttributeConstants.NUMBER_TUPLES.intValue()];
+ if (tuples != null) {
+ System.arraycopy(tuples, 0, newFormatTuples, 0, tuples.length);
+
+ for (int i = tuples.length; i < newFormatTuples.length; i++) {
+ if (i == AttributeConstants.ATTR_VALUE_INDEX.intValue()) {
+ newFormatTuples[i] = "[]";
+ } else {
+ newFormatTuples[i] = "";
+ }
+ }
+ }
+ return newFormatTuples;
+ }
+
+ /**
+ * Returns a IPersonalAttributeList of the complex attributes in this map.
+ *
+ * @return an IPersonalAttributeList of the complex attributes contained in this map.
+ */
+ public IPersonalAttributeList getComplexAttributes() {
+ LOG.info("get complex attributes");
+ IPersonalAttributeList attrList = new PersonalAttributeList();
+ for(PersonalAttribute attr: this) {
+ if(!attr.getComplexValue().isEmpty()) {
+ attrList.put(attr.getName(), attr);
+ LOG.info("adding complex attribute:"+attr.getName());
+ }
+ }
+ return attrList;
+ }
+
+ /**
+ * Returns a IPersonalAttributeList of the mandatory attributes in this map.
+ *
+ * @return an IPersonalAttributeList of the mandatory attributes contained in this map.
+ */
+ public IPersonalAttributeList getSimpleValueAttributes() {
+ LOG.info("get simple attributes");
+ IPersonalAttributeList attrList = new PersonalAttributeList();
+ for(PersonalAttribute attr: this) {
+ if(attr.getComplexValue().isEmpty()) {
+ attrList.put(attr.getName(), attr);
+ LOG.info("adding simple attribute:"+attr.getName());
+ }
+ }
+ return attrList;
+ }
+
+
+
+ /**
+ * Returns a IPersonalAttributeList of the mandatory attributes in this map.
+ *
+ * @return an IPersonalAttributeList of the mandatory attributes contained in this map.
+ */
+ public IPersonalAttributeList getMandatoryAttributes() {
+ return getAttributesByParam(true);
+ }
+
+
+ /**
+ * Returns a IPersonalAttributeList of the attributes in this map by parameter value.
+ *
+ * @param compareValue The boolean to get mandatory (true) or optional (false) attributes.
+ *
+ * @return an IPersonalAttributeList of the mandatory attributes contained in this map if compareValue is true or optional otherwise.
+ */
+ private IPersonalAttributeList getAttributesByParam(final boolean compareValue) {
+ LOG.info("get attributes by param :"+compareValue);
+ IPersonalAttributeList attrList = new PersonalAttributeList();
+ for(PersonalAttribute attr: this) {
+ if(attr.isRequired() == compareValue) {
+ attrList.put(attr.getName(), attr);
+ LOG.info("adding attribute:"+attr.getName());
+ }
+ }
+ return attrList;
+ }
+
+
+ /**
+ * Returns a IPersonalAttributeList of the optional attributes in this map.
+ *
+ * @return an IPersonalAttributeList of the optional attributes contained in this map.
+ */
+ public IPersonalAttributeList getOptionalAttributes() {
+ return getAttributesByParam(false);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public boolean hasMissingValues() {
+ for(PersonalAttribute attr: this) {
+ if(attr.isEmptyValue() && attr.isEmptyComplexValue()) {
+ return true;
+ }
+ }
+ return false;
+ }
+} \ No newline at end of file
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKAttrQueryRequest.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKAttrQueryRequest.java
new file mode 100644
index 000000000..65936f1a8
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKAttrQueryRequest.java
@@ -0,0 +1,447 @@
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+
+import org.apache.log4j.Logger;
+
+public class STORKAttrQueryRequest implements Serializable, Cloneable {
+
+ /** The Constant serialVersionUID. */
+ private static final long serialVersionUID = 4778480781609392750L;
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(STORKAttrQueryRequest.class
+ .getName());
+
+ /** The samlId. */
+ private String samlId;
+
+ /** The destination. */
+ private String destination;
+
+ /** The assertion consumer service url. */
+ private String serviceURL;
+
+ /** The distinguished name. */
+ private String distinguishedName;
+
+ /** The e id sector share. */
+ private boolean eIDSectorShare;
+
+ /** The e id cross sector share. */
+ private boolean eIDCrossSectorShare;
+
+ /** The e id cross border share. */
+ private boolean eIDCrossBorderShare;
+
+ /** The personal attribute list. */
+ private IPersonalAttributeList attributeList = new PersonalAttributeList();
+
+ /** The qaa. */
+ private int qaa;
+
+ /** The token saml. */
+ private byte[] tokenSaml = new byte[0];
+
+ /** The issuer. */
+ private String issuer;
+
+ /** The service provider sector. */
+ private String spSector;
+
+ /** The service provider institution. */
+ private String spInstitution;
+
+ /** The service provider application. */
+ private String spApplication;
+
+ /** The service provider country. */
+ private String spCountry;
+
+ /** The country. */
+ private String country;
+
+ /** The citizen country code. */
+ private String citizenCountry;
+
+ /** The Service Provider ID. */
+ private String sPID;
+
+ /** The Alias used at the keystore for saving this certificate. */
+ private String alias;
+
+ /**
+ * Gets the SP's Certificate Alias.
+ *
+ * @return alias The SP's Certificate Alias.
+ */
+ public String getAlias() {
+ return alias;
+ }
+
+ /**
+ * Sets the SP's Certificate Alias.
+ *
+ * @param nAlias The SP's Certificate Alias.
+ */
+ public void setAlias(final String nAlias) {
+ this.alias = nAlias;
+ }
+
+ /**
+ * Gets the SP ID.
+ *
+ * @return sPID The SP ID.
+ */
+ public String getSPID() {
+ return sPID;
+ }
+
+ /**
+ * Sets the SP ID.
+ *
+ * @param sPId The new sp samlId.
+ */
+ public void setSPID(final String sPId) {
+ this.sPID = sPId;
+ }
+
+ /**
+ * Gets the citizen country code.
+ *
+ * @return The citizen country code value.
+ */
+ public String getCitizenCountryCode() {
+ return citizenCountry;
+ }
+
+ /**
+ * Sets the citizen country code.
+ *
+ * @param countryCode the new citizen country code value.
+ */
+ public void setCitizenCountryCode(final String countryCode) {
+ this.citizenCountry = countryCode;
+ }
+
+ /**
+ * Gets the sp country.
+ *
+ * @return The sp country value.
+ */
+ public String getSpCountry() {
+ return spCountry;
+ }
+
+ /**
+ * Sets the sp country.
+ *
+ * @param sPCountry the new sp country value.
+ */
+ public void setSpCountry(final String sPCountry) {
+ this.spCountry = sPCountry;
+ }
+
+ /**
+ * Gets the issuer.
+ *
+ * @return The issuer value.
+ */
+ public String getIssuer() {
+ return issuer;
+ }
+
+ /**
+ * Sets the issuer.
+ *
+ * @param samlIssuer the new issuer value.
+ */
+ public void setIssuer(final String samlIssuer) {
+ this.issuer = samlIssuer;
+ }
+
+ /**
+ * Gets the SAML Token.
+ *
+ * @return The SAML Token value.
+ */
+ public byte[] getTokenSaml() {
+ return tokenSaml.clone();
+ }
+
+ /**
+ * Sets the SAML Token.
+ *
+ * @param samlToken The new SAML Token value.
+ */
+ public void setTokenSaml(final byte[] samlToken) {
+ if (samlToken != null) {
+ this.tokenSaml = samlToken.clone();
+ }
+ }
+
+ /**
+ * Gets the country.
+ *
+ * @return The country value.
+ */
+ public String getCountry() {
+ return country;
+ }
+
+ /**
+ * Sets the country.
+ *
+ * @param nCountry the new country value.
+ */
+ public void setCountry(final String nCountry) {
+ this.country = nCountry;
+ }
+
+ /**
+ * Getter for the qaa value.
+ *
+ * @return The qaa value value.
+ */
+ public int getQaa() {
+ return qaa;
+ }
+
+ /**
+ * Setter for the qaa value.
+ *
+ * @param qaaLevel The new qaa value.
+ */
+ public void setQaa(final int qaaLevel) {
+ this.qaa = qaaLevel;
+ }
+
+ /**
+ * Getter for the serviceURL value.
+ *
+ * @return The serviceURL value.
+ */
+ public String getAssertionConsumerServiceURL() {
+ return serviceURL;
+ }
+
+ /**
+ * Setter for the serviceURL value.
+ *
+ * @param newServiceURL the assertion consumer service URL.
+ */
+ public void setAssertionConsumerServiceURL(final String newServiceURL) {
+ this.serviceURL = newServiceURL;
+ }
+
+ /**
+ * Getter for the destination value.
+ *
+ * @return The destination value.
+ */
+ public String getDestination() {
+ return destination;
+ }
+
+ /**
+ * Setter for the destination value.
+ *
+ * @param detination the new destination value.
+ */
+ public void setDestination(final String detination) {
+ this.destination = detination;
+ }
+
+ /**
+ * Getter for the samlId value.
+ *
+ * @return The samlId value.
+ */
+ public String getSamlId() {
+ return samlId;
+ }
+
+ /**
+ * Setter for the samlId value.
+ *
+ * @param newSamlId the new samlId value.
+ */
+ public void setSamlId(final String newSamlId) {
+ this.samlId = newSamlId;
+ }
+
+
+ /**
+ * Getter for the attributeList value.
+ *
+ * @return The attributeList value.
+ *
+ * @see IPersonalAttributeList
+ */
+ public IPersonalAttributeList getPersonalAttributeList() {
+ IPersonalAttributeList personnalAttributeList = null;
+ try {
+ personnalAttributeList = (IPersonalAttributeList) attributeList.clone();
+ } catch (CloneNotSupportedException e1) {
+ LOG.trace("[PersonalAttribute] Nothing to do.");
+ }
+ return personnalAttributeList;
+ }
+
+ /**
+ * Setter for the attributeList value.
+ *
+ * @param attrList the personal attribute list value.
+ *
+ * @see IPersonalAttributeList
+ */
+ public void setPersonalAttributeList(final IPersonalAttributeList attrList) {
+ if (attrList != null) {
+ this.attributeList = attrList;
+ }
+ }
+
+ /**
+ * Getter for the distinguishedName value.
+ *
+ * @return The distinguishedName value.
+ */
+ public String getDistinguishedName() {
+ return distinguishedName;
+ }
+
+ /**
+ * Setter for the distinguishedName value.
+ *
+ * @param certDN the distinguished name value.
+ */
+ public void setDistinguishedName(final String certDN) {
+ this.distinguishedName = certDN;
+ }
+
+ /**
+ * Gets the service provider sector.
+ *
+ * @return The service provider sector value.
+ */
+ public String getSpSector() {
+ return spSector;
+ }
+
+ /**
+ * Sets the service provider sector.
+ *
+ * @param samlSPSector the new service provider sector value.
+ */
+ public void setSpSector(final String samlSPSector) {
+ this.spSector = samlSPSector;
+ }
+
+ /**
+ * Gets the service provider institution.
+ *
+ * @return The service provider institution value.
+ */
+ public String getSpInstitution() {
+ return spInstitution;
+ }
+
+ /**
+ * Sets the service provider institution.
+ *
+ * @param samlSPInst the new service provider institution value.
+ */
+ public void setSpInstitution(final String samlSPInst) {
+ this.spInstitution = samlSPInst;
+ }
+
+ /**
+ * Gets the service provider application.
+ *
+ * @return The service provider application value.
+ */
+ public String getSpApplication() {
+ return spApplication;
+ }
+
+ /**
+ * Sets the service provider application.
+ *
+ * @param samlSPApp the new service provider application value.
+ */
+ public void setSpApplication(final String samlSPApp) {
+ this.spApplication = samlSPApp;
+ }
+
+ /**
+ * Checks if is eId sector share.
+ *
+ * @return true, if is eId sector share.
+ */
+ public boolean isEIDSectorShare() {
+ return eIDSectorShare;
+ }
+
+ /**
+ * Sets the eId sector share.
+ *
+ * @param eIdSectorShare the new eId sector share value.
+ */
+ public void setEIDSectorShare(final boolean eIdSectorShare) {
+ this.eIDSectorShare = eIdSectorShare;
+ }
+
+ /**
+ * Checks if is eId cross sector share.
+ *
+ * @return true, if is eId cross sector share.
+ */
+ public boolean isEIDCrossSectorShare() {
+ return eIDCrossSectorShare;
+ }
+
+ /**
+ * Sets the eId cross sector share.
+ *
+ * @param eIdCrossSectorShare the new eId cross sector share value.
+ */
+ public void setEIDCrossSectorShare(final boolean eIdCrossSectorShare) {
+ this.eIDCrossSectorShare = eIdCrossSectorShare;
+ }
+
+ /**
+ * Checks if is eId cross border share.
+ *
+ * @return true, if is eId cross border share.
+ */
+ public boolean isEIDCrossBorderShare() {
+ return eIDCrossBorderShare;
+ }
+
+ /**
+ * Sets the eId cross border share.
+ *
+ * @param eIdCrossBorderShare the new eId cross border share value.
+ */
+ public void setEIDCrossBorderShare(final boolean eIdCrossBorderShare) {
+ this.eIDCrossBorderShare = eIdCrossBorderShare;
+ }
+
+ /**
+ * Returns a copy of this <tt>STORKAttrQueryRequest</tt> instance.
+ *
+ * @return The copy of this STORKAttrQueryRequest.
+ * @throws CloneNotSupportedException on clone exception
+ */
+ @Override
+ public Object clone() throws CloneNotSupportedException{
+ STORKAttrQueryRequest storkAttrQueryReq = null;
+ storkAttrQueryReq = (STORKAttrQueryRequest) super.clone();
+ storkAttrQueryReq.setPersonalAttributeList(getPersonalAttributeList());
+ storkAttrQueryReq.setTokenSaml(getTokenSaml());
+ return storkAttrQueryReq;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKAttrQueryResponse.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKAttrQueryResponse.java
new file mode 100644
index 000000000..1974f4f66
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKAttrQueryResponse.java
@@ -0,0 +1,392 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+import java.util.List;
+
+import org.apache.log4j.Logger;
+import org.joda.time.DateTime;
+import org.opensaml.saml2.core.Assertion;
+
+public class STORKAttrQueryResponse implements Serializable {
+
+ /** The Constant serialVersionUID. */
+ private static final long serialVersionUID = 7653893041391541235L;
+
+ /** Response Id. */
+ private String samlId;
+
+ /** Request failed? */
+ private boolean fail;
+
+ /** Status code. */
+ private String statusCode;
+
+ /** Secondary status code. */
+ private String subStatusCode;
+
+ /** Audience restriction. */
+ private transient String audienceRest;
+
+ /** Error message. */
+ private String message;
+
+ /** Id of the request that originated this response. */
+ private String inResponseTo;
+
+ /** Expiration date. */
+ private DateTime notOnOrAfter;
+
+ /** Creation date. */
+ private DateTime notBefore;
+
+ /** The SAML token. */
+ private byte[] tokenSaml = new byte[0];
+
+ /** Country. */
+ private String country;
+
+ /** The complete assertion **/
+ private Assertion assertion;
+
+ /** List of all assertions in response **/
+ private List<Assertion> assertions;
+
+ /** The complete list from all assertions **/
+ private transient IPersonalAttributeList totalAttributeList = new PersonalAttributeList();
+
+ /** All personal attribute lists **/
+ private List<IPersonalAttributeList> attributeLists;
+
+ /** Citizen's personal attribute list. */
+ private IPersonalAttributeList attributeList = new PersonalAttributeList();
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(STORKAttrQueryResponse.class.getName());
+
+ /**
+ * Getter for the subStatusCode.
+ *
+ * @return The subStatusCode value.
+ */
+ public String getSubStatusCode() {
+ return subStatusCode;
+ }
+
+ /**
+ * Setter for the subStatusCode.
+ *
+ * @param samlSubStatusCode the new subStatusCode value.
+ */
+ public void setSubStatusCode(final String samlSubStatusCode) {
+ this.subStatusCode = samlSubStatusCode;
+ }
+
+ /**
+ * Getter for audienceRest.
+ *
+ * @return The audienceRest value.
+ */
+ public String getAudienceRestriction() {
+ return audienceRest;
+ }
+
+ /**
+ * Setter for audienceRest.
+ *
+ * @param audRest the new audienceRest value.
+ */
+ public void setAudienceRestriction(final String audRest) {
+ this.audienceRest = audRest;
+ }
+
+ /**
+ * Getter for the samlToken.
+ *
+ * @return The samlToken value.
+ */
+ public byte[] getTokenSaml() {
+ return tokenSaml.clone();
+ }
+
+ /**
+ * Setter for samlToken.
+ *
+ * @param samlToken the new tokenSaml value.
+ */
+ public void setTokenSaml(final byte[] samlToken) {
+ if (samlToken != null) {
+ this.tokenSaml = samlToken.clone();
+ }
+ }
+
+ /**
+ * Getter for the country name.
+ *
+ * @return The country name value.
+ */
+ public String getCountry() {
+ return country;
+ }
+
+ /**
+ * Setter for the country name.
+ *
+ * @param cCountry the new country name value.
+ */
+ public void setCountry(final String cCountry) {
+ this.country = cCountry;
+ }
+
+ /**
+ * Getter for pal value.
+ *
+ * @return The pal value.
+ *
+ * @see PersonalAttributeList
+ */
+ public IPersonalAttributeList getPersonalAttributeList() {
+ IPersonalAttributeList personnalAttributeList = null;
+ try {
+ personnalAttributeList = (IPersonalAttributeList) attributeList.clone();
+ } catch (CloneNotSupportedException e1) {
+ LOG.trace("[PersonalAttribute] Nothing to do.");
+ }
+ return personnalAttributeList;
+ }
+
+ /**
+ * Setter for the Personal Attribute List value.
+ *
+ * @param attrList the new value.
+ *
+ * @see PersonalAttributeList
+ */
+ public void setPersonalAttributeList(final IPersonalAttributeList attrList) {
+ if (attrList != null) {
+ this.attributeList = attrList;
+ }
+ }
+
+ /**
+ * Getter for the inResponseTo value.
+ *
+ * @return The inResponseTo value.
+ */
+ public String getInResponseTo() {
+ return inResponseTo;
+ }
+
+ /**
+ * Setter for the inResponseTo value.
+ *
+ * @param samlInResponseTo the new inResponseTo value.
+ */
+ public void setInResponseTo(final String samlInResponseTo) {
+ this.inResponseTo = samlInResponseTo;
+ }
+
+ /**
+ * Getter for the fail value.
+ *
+ * @return The fail value.
+ */
+ public boolean isFail() {
+ return fail;
+ }
+
+ /**
+ * Setter for the fail value.
+ *
+ * @param failVal the new fail value.
+ */
+ public void setFail(final boolean failVal) {
+ this.fail = failVal;
+ }
+
+ /**
+ * Getter for the message value.
+ *
+ * @return The message value.
+ */
+ public String getMessage() {
+ return message;
+ }
+
+ /**
+ * Setter for the message value.
+ *
+ * @param msg the new message value.
+ */
+ public void setMessage(final String msg) {
+ this.message = msg;
+ }
+
+ /**
+ * Getter for the statusCode value.
+ *
+ * @return The statusCode value.
+ */
+ public String getStatusCode() {
+ return statusCode;
+ }
+
+ /**
+ * Setter for the statusCode value.
+ *
+ * @param status the new statusCode value.
+ */
+ public void setStatusCode(final String status) {
+ this.statusCode = status;
+ }
+
+ /**
+ * Getter for the samlId value.
+ *
+ * @return The samlId value.
+ */
+ public String getSamlId() {
+ return samlId;
+ }
+
+ /**
+ * Setter for the samlId value.
+ *
+ * @param nSamlId the new samlId value.
+ */
+ public void setSamlId(final String nSamlId) {
+ this.samlId = nSamlId;
+ }
+
+ /**
+ * Getter for the notOnOrAfter value.
+ *
+ * @return The notOnOrAfter value.
+ *
+ * @see DateTime
+ */
+ public DateTime getNotOnOrAfter() {
+ return this.notOnOrAfter;
+ }
+
+ /**
+ * Setter for the notOnOrAfter value.
+ *
+ * @param nOnOrAfter the new notOnOrAfter value.
+ *
+ * @see DateTime
+ */
+ public void setNotOnOrAfter(final DateTime nOnOrAfter) {
+ this.notOnOrAfter = nOnOrAfter;
+ }
+
+ /**
+ * Getter for the notBefore value.
+ *
+ * @return The notBefore value.
+ *
+ * @see DateTime
+ */
+ public DateTime getNotBefore() {
+ return notBefore;
+ }
+
+ /**
+ * Setter for the notBefore value.
+ *
+ * @param nBefore the new notBefore value.
+ *
+ * @see DateTime
+ */
+ public void setNotBefore(final DateTime nBefore) {
+ this.notBefore = nBefore;
+ }
+
+ /** Get the assertion from the response **/
+ public Assertion getAssertion() {
+ return assertion;
+ }
+
+ /** Set the assertion in the response **/
+ public void setAssertion(final Assertion nAssertion) {
+ this.assertion = nAssertion;
+ }
+
+ public void setAssertions(List<Assertion> newAssert) {
+ this.assertions = newAssert;
+ }
+
+ public List<Assertion> getAssertions() {
+ return assertions;
+ }
+
+ /**
+ * Getter for the toal pal value.
+ *
+ * @return The total pal value.
+ *
+ * @see PersonalAttributeList
+ */
+ public IPersonalAttributeList getTotalPersonalAttributeList() {
+ IPersonalAttributeList personnalAttributeList = null;
+ try {
+ personnalAttributeList = (IPersonalAttributeList) totalAttributeList.clone();
+ } catch (CloneNotSupportedException e1) {
+ LOG.trace("[PersonalAttribute] Nothing to do.");
+ }
+ return personnalAttributeList;
+ }
+
+ /**
+ * Setter for the total Personal Attribute List value.
+ *
+ * @param attrList the new value.
+ *
+ * @see PersonalAttributeList
+ */
+ public void setTotalPersonalAttributeList(final IPersonalAttributeList attrList) {
+ if (attrList != null) {
+ this.totalAttributeList = attrList;
+ }
+ }
+
+ /**
+ * Getter for personal attribute lists
+ *
+ * @return The lists
+ *
+ * @see PersonalAttributeList
+ */
+ public List<IPersonalAttributeList> getPersonalAttributeLists() {
+ return attributeLists;
+ }
+
+ /**
+ * Setter for the Personal Attribute List value.
+ *
+ * @param attrList the new value.
+ *
+ * @see PersonalAttributeList
+ */
+ public void setPersonalAttributeLists(final List<IPersonalAttributeList> attrLists) {
+ if (attrLists != null) {
+ this.attributeLists = attrLists;
+ }
+ }
+
+}
+
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKAuthnRequest.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKAuthnRequest.java
new file mode 100644
index 000000000..2354d0eb1
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKAuthnRequest.java
@@ -0,0 +1,495 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+
+import org.apache.log4j.Logger;
+
+/**
+ * This class is a bean used to store the information relative to the
+ * STORKAuthnRequest (SAML Token Request).
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.21 $, $Date: 2011-02-17 22:44:34 $
+ */
+public final class STORKAuthnRequest implements Serializable, Cloneable {
+
+ /** The Constant serialVersionUID. */
+ private static final long serialVersionUID = 4778480781609392750L;
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(STORKAuthnRequest.class
+ .getName());
+
+ /** The samlId. */
+ private String samlId;
+
+ /** The assertion consumer service url. */
+ private String serviceURL;
+
+ /** The destination. */
+ private String destination;
+
+ /** The provider name. */
+ private String providerName;
+
+ /** The distinguished name. */
+ private String distinguishedName;
+
+ /** The e id sector share. */
+ private boolean eIDSectorShare;
+
+ /** The e id cross sector share. */
+ private boolean eIDCrossSectorShare;
+
+ /** The e id cross border share. */
+ private boolean eIDCrossBorderShare;
+
+ /** The personal attribute list. */
+ private IPersonalAttributeList attributeList = new PersonalAttributeList();
+
+ /** The qaa. */
+ private int qaa;
+
+ /** The token saml. */
+ private byte[] tokenSaml = new byte[0];
+
+ /** The issuer. */
+ private String issuer;
+
+ /** The service provider sector. */
+ private String spSector;
+
+ /** The service provider institution. */
+ private String spInstitution;
+
+ /** The service provider application. */
+ private String spApplication;
+
+ /** The service provider country. */
+ private String spCountry;
+
+ /** The country. */
+ private String country;
+
+ /** The citizen country code. */
+ private String citizenCountry;
+
+ /** The Service Provider ID. */
+ private String sPID;
+
+ /** The Alias used at the keystore for saving this certificate. */
+ private String alias;
+
+ /**
+ * Gets the SP's Certificate Alias.
+ *
+ * @return alias The SP's Certificate Alias.
+ */
+ public String getAlias() {
+ return alias;
+ }
+
+ /**
+ * Sets the SP's Certificate Alias.
+ *
+ * @param nAlias The SP's Certificate Alias.
+ */
+ public void setAlias(final String nAlias) {
+ this.alias = nAlias;
+ }
+
+ /**
+ * Gets the SP ID.
+ *
+ * @return sPID The SP ID.
+ */
+ public String getSPID() {
+ return sPID;
+ }
+
+ /**
+ * Sets the SP ID.
+ *
+ * @param sPId The new sp samlId.
+ */
+ public void setSPID(final String sPId) {
+ this.sPID = sPId;
+ }
+
+ /**
+ * Gets the citizen country code.
+ *
+ * @return The citizen country code value.
+ */
+ public String getCitizenCountryCode() {
+ return citizenCountry;
+ }
+
+ /**
+ * Sets the citizen country code.
+ *
+ * @param countryCode the new citizen country code value.
+ */
+ public void setCitizenCountryCode(final String countryCode) {
+ this.citizenCountry = countryCode;
+ }
+
+ /**
+ * Gets the sp country.
+ *
+ * @return The sp country value.
+ */
+ public String getSpCountry() {
+ return spCountry;
+ }
+
+ /**
+ * Sets the sp country.
+ *
+ * @param sPCountry the new sp country value.
+ */
+ public void setSpCountry(final String sPCountry) {
+ this.spCountry = sPCountry;
+ }
+
+ /**
+ * Gets the issuer.
+ *
+ * @return The issuer value.
+ */
+ public String getIssuer() {
+ return issuer;
+ }
+
+ /**
+ * Sets the issuer.
+ *
+ * @param samlIssuer the new issuer value.
+ */
+ public void setIssuer(final String samlIssuer) {
+ this.issuer = samlIssuer;
+ }
+
+ /**
+ * Gets the SAML Token.
+ *
+ * @return The SAML Token value.
+ */
+ public byte[] getTokenSaml() {
+ return tokenSaml.clone();
+ }
+
+ /**
+ * Sets the SAML Token.
+ *
+ * @param samlToken The new SAML Token value.
+ */
+ public void setTokenSaml(final byte[] samlToken) {
+ if (samlToken != null) {
+ this.tokenSaml = samlToken.clone();
+ }
+ }
+
+ /**
+ * Gets the country.
+ *
+ * @return The country value.
+ */
+ public String getCountry() {
+ return country;
+ }
+
+ /**
+ * Sets the country.
+ *
+ * @param nCountry the new country value.
+ */
+ public void setCountry(final String nCountry) {
+ this.country = nCountry;
+ }
+
+ /**
+ * Getter for the qaa value.
+ *
+ * @return The qaa value value.
+ */
+ public int getQaa() {
+ return qaa;
+ }
+
+ /**
+ * Setter for the qaa value.
+ *
+ * @param qaaLevel The new qaa value.
+ */
+ public void setQaa(final int qaaLevel) {
+ this.qaa = qaaLevel;
+ }
+
+ /**
+ * Getter for the serviceURL value.
+ *
+ * @return The serviceURL value.
+ */
+ public String getAssertionConsumerServiceURL() {
+ return serviceURL;
+ }
+
+ /**
+ * Setter for the serviceURL value.
+ *
+ * @param newServiceURL the assertion consumer service URL.
+ */
+ public void setAssertionConsumerServiceURL(final String newServiceURL) {
+ this.serviceURL = newServiceURL;
+ }
+
+ /**
+ * Getter for the destination value.
+ *
+ * @return The destination value.
+ */
+ public String getDestination() {
+ return destination;
+ }
+
+ /**
+ * Setter for the destination value.
+ *
+ * @param detination the new destination value.
+ */
+ public void setDestination(final String detination) {
+ this.destination = detination;
+ }
+
+ /**
+ * Getter for the samlId value.
+ *
+ * @return The samlId value.
+ */
+ public String getSamlId() {
+ return samlId;
+ }
+
+ /**
+ * Setter for the samlId value.
+ *
+ * @param newSamlId the new samlId value.
+ */
+ public void setSamlId(final String newSamlId) {
+ this.samlId = newSamlId;
+ }
+
+ /**
+ * Getter for the providerName value.
+ *
+ * @return The provider name value.
+ */
+ public String getProviderName() {
+ return providerName;
+ }
+
+ /**
+ * Setter for the providerName value.
+ *
+ * @param samlProvider the provider name value.
+ */
+ public void setProviderName(final String samlProvider) {
+ this.providerName = samlProvider;
+ }
+
+ /**
+ * Getter for the attributeList value.
+ *
+ * @return The attributeList value.
+ *
+ * @see IPersonalAttributeList
+ */
+ public IPersonalAttributeList getPersonalAttributeList() {
+ IPersonalAttributeList personnalAttributeList = null;
+ try {
+ personnalAttributeList = (IPersonalAttributeList) attributeList.clone();
+ } catch (CloneNotSupportedException e1) {
+ LOG.trace("[PersonalAttribute] Nothing to do.");
+ }
+ return personnalAttributeList;
+ }
+
+ /**
+ * Setter for the attributeList value.
+ *
+ * @param attrList the personal attribute list value.
+ *
+ * @see IPersonalAttributeList
+ */
+ public void setPersonalAttributeList(final IPersonalAttributeList attrList) {
+ if (attrList != null) {
+ this.attributeList = attrList;
+ }
+ }
+
+ /**
+ * Getter for the distinguishedName value.
+ *
+ * @return The distinguishedName value.
+ */
+ public String getDistinguishedName() {
+ return distinguishedName;
+ }
+
+ /**
+ * Setter for the distinguishedName value.
+ *
+ * @param certDN the distinguished name value.
+ */
+ public void setDistinguishedName(final String certDN) {
+ this.distinguishedName = certDN;
+ }
+
+ /**
+ * Gets the service provider sector.
+ *
+ * @return The service provider sector value.
+ */
+ public String getSpSector() {
+ return spSector;
+ }
+
+ /**
+ * Sets the service provider sector.
+ *
+ * @param samlSPSector the new service provider sector value.
+ */
+ public void setSpSector(final String samlSPSector) {
+ this.spSector = samlSPSector;
+ }
+
+ /**
+ * Gets the service provider institution.
+ *
+ * @return The service provider institution value.
+ */
+ public String getSpInstitution() {
+ return spInstitution;
+ }
+
+ /**
+ * Sets the service provider institution.
+ *
+ * @param samlSPInst the new service provider institution value.
+ */
+ public void setSpInstitution(final String samlSPInst) {
+ this.spInstitution = samlSPInst;
+ }
+
+ /**
+ * Gets the service provider application.
+ *
+ * @return The service provider application value.
+ */
+ public String getSpApplication() {
+ return spApplication;
+ }
+
+ /**
+ * Sets the service provider application.
+ *
+ * @param samlSPApp the new service provider application value.
+ */
+ public void setSpApplication(final String samlSPApp) {
+ this.spApplication = samlSPApp;
+ }
+
+ /**
+ * Checks if is eId sector share.
+ *
+ * @return true, if is eId sector share.
+ */
+ public boolean isEIDSectorShare() {
+ return eIDSectorShare;
+ }
+
+ /**
+ * Sets the eId sector share.
+ *
+ * @param eIdSectorShare the new eId sector share value.
+ */
+ public void setEIDSectorShare(final boolean eIdSectorShare) {
+ this.eIDSectorShare = eIdSectorShare;
+ }
+
+ /**
+ * Checks if is eId cross sector share.
+ *
+ * @return true, if is eId cross sector share.
+ */
+ public boolean isEIDCrossSectorShare() {
+ return eIDCrossSectorShare;
+ }
+
+ /**
+ * Sets the eId cross sector share.
+ *
+ * @param eIdCrossSectorShare the new eId cross sector share value.
+ */
+ public void setEIDCrossSectorShare(final boolean eIdCrossSectorShare) {
+ this.eIDCrossSectorShare = eIdCrossSectorShare;
+ }
+
+ /**
+ * Checks if is eId cross border share.
+ *
+ * @return true, if is eId cross border share.
+ */
+ public boolean isEIDCrossBorderShare() {
+ return eIDCrossBorderShare;
+ }
+
+ /**
+ * Sets the eId cross border share.
+ *
+ * @param eIdCrossBorderShare the new eId cross border share value.
+ */
+ public void setEIDCrossBorderShare(final boolean eIdCrossBorderShare) {
+ this.eIDCrossBorderShare = eIdCrossBorderShare;
+ }
+
+ /**
+ * Returns a copy of this <tt>STORKAuthnRequest</tt> instance.
+ *
+ * @return The copy of this STORKAuthnRequest.
+ * @throws CloneNotSupportedException on clone exception
+ */
+ @Override
+ public Object clone() throws CloneNotSupportedException{
+ STORKAuthnRequest storkAuthnReq = null;
+ try {
+ storkAuthnReq = (STORKAuthnRequest) super.clone();
+ storkAuthnReq.setPersonalAttributeList(getPersonalAttributeList());
+ storkAuthnReq.setTokenSaml(getTokenSaml());
+ } catch (final CloneNotSupportedException e) {
+ // assert false;
+ LOG.trace("[PersonalAttribute] Nothing to do.");
+ }
+
+ return storkAuthnReq;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKAuthnResponse.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKAuthnResponse.java
new file mode 100644
index 000000000..c4a3e2b6c
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKAuthnResponse.java
@@ -0,0 +1,387 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+import java.util.List;
+
+import org.apache.log4j.Logger;
+import org.joda.time.DateTime;
+import org.opensaml.saml2.core.Assertion;
+
+/**
+ * This class is a bean used to store the information relative to the
+ * STORKAuthnResponse.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.15 $, $Date: 2010-11-17 05:15:28 $
+ */
+public final class STORKAuthnResponse implements Serializable {
+
+ /** The Constant serialVersionUID. */
+ private static final long serialVersionUID = -9100982727074068660L;
+
+ /** Response Id. */
+ private String samlId;
+
+ /** Authentication failed? */
+ private boolean fail;
+
+ /** Status code. */
+ private String statusCode;
+
+ /** Secondary status code. */
+ private String subStatusCode;
+
+ /** Audience restriction. */
+ private transient String audienceRest;
+
+ /** Error message. */
+ private String message;
+
+ /** Id of the request that originated this response. */
+ private String inResponseTo;
+
+ /** Expiration date. */
+ private DateTime notOnOrAfter;
+
+ /** Creation date. */
+ private DateTime notBefore;
+
+ /** The SAML token. */
+ private byte[] tokenSaml = new byte[0];
+
+ /** Country. */
+ private String country;
+
+ /** Citizen's personal attribute list. */
+ private IPersonalAttributeList attributeList = new PersonalAttributeList();
+
+ /** List of all assertions in response **/
+ private List<Assertion> assertions;
+
+ /** The complete list from all assertions **/
+ private transient IPersonalAttributeList totalAttributeList = new PersonalAttributeList();
+
+ /** All personal attribute lists **/
+ private List<IPersonalAttributeList> attributeLists;
+
+ /**
+ * Logger object.
+ */
+ private static final Logger LOG = Logger.getLogger(STORKAuthnResponse.class.getName());
+
+ /**
+ * Getter for the subStatusCode.
+ *
+ * @return The subStatusCode value.
+ */
+ public String getSubStatusCode() {
+ return subStatusCode;
+ }
+
+ /**
+ * Setter for the subStatusCode.
+ *
+ * @param samlSubStatusCode the new subStatusCode value.
+ */
+ public void setSubStatusCode(final String samlSubStatusCode) {
+ this.subStatusCode = samlSubStatusCode;
+ }
+
+ /**
+ * Getter for audienceRest.
+ *
+ * @return The audienceRest value.
+ */
+ public String getAudienceRestriction() {
+ return audienceRest;
+ }
+
+ /**
+ * Setter for audienceRest.
+ *
+ * @param audRest the new audienceRest value.
+ */
+ public void setAudienceRestriction(final String audRest) {
+ this.audienceRest = audRest;
+ }
+
+ /**
+ * Getter for the samlToken.
+ *
+ * @return The samlToken value.
+ */
+ public byte[] getTokenSaml() {
+ return tokenSaml.clone();
+ }
+
+ /**
+ * Setter for samlToken.
+ *
+ * @param samlToken the new tokenSaml value.
+ */
+ public void setTokenSaml(final byte[] samlToken) {
+ if (samlToken != null) {
+ this.tokenSaml = samlToken.clone();
+ }
+ }
+
+ /**
+ * Getter for the country name.
+ *
+ * @return The country name value.
+ */
+ public String getCountry() {
+ return country;
+ }
+
+ /**
+ * Setter for the country name.
+ *
+ * @param cCountry the new country name value.
+ */
+ public void setCountry(final String cCountry) {
+ this.country = cCountry;
+ }
+
+ /**
+ * Getter for pal value.
+ *
+ * @return The pal value.
+ *
+ * @see PersonalAttributeList
+ */
+ public IPersonalAttributeList getPersonalAttributeList() {
+ IPersonalAttributeList personnalAttributeList = null;
+ try {
+ personnalAttributeList = (IPersonalAttributeList) attributeList.clone();
+ } catch (CloneNotSupportedException e1) {
+ LOG.trace("[PersonalAttribute] Nothing to do.");
+ }
+ return personnalAttributeList;
+ }
+
+ /**
+ * Setter for the Personal Attribute List value.
+ *
+ * @param attrList the new value.
+ *
+ * @see PersonalAttributeList
+ */
+ public void setPersonalAttributeList(final IPersonalAttributeList attrList) {
+ if (attrList != null) {
+ this.attributeList = attrList;
+ }
+ }
+
+ /**
+ * Getter for the inResponseTo value.
+ *
+ * @return The inResponseTo value.
+ */
+ public String getInResponseTo() {
+ return inResponseTo;
+ }
+
+ /**
+ * Setter for the inResponseTo value.
+ *
+ * @param samlInResponseTo the new inResponseTo value.
+ */
+ public void setInResponseTo(final String samlInResponseTo) {
+ this.inResponseTo = samlInResponseTo;
+ }
+
+ /**
+ * Getter for the fail value.
+ *
+ * @return The fail value.
+ */
+ public boolean isFail() {
+ return fail;
+ }
+
+ /**
+ * Setter for the fail value.
+ *
+ * @param failVal the new fail value.
+ */
+ public void setFail(final boolean failVal) {
+ this.fail = failVal;
+ }
+
+ /**
+ * Getter for the message value.
+ *
+ * @return The message value.
+ */
+ public String getMessage() {
+ return message;
+ }
+
+ /**
+ * Setter for the message value.
+ *
+ * @param msg the new message value.
+ */
+ public void setMessage(final String msg) {
+ this.message = msg;
+ }
+
+ /**
+ * Getter for the statusCode value.
+ *
+ * @return The statusCode value.
+ */
+ public String getStatusCode() {
+ return statusCode;
+ }
+
+ /**
+ * Setter for the statusCode value.
+ *
+ * @param status the new statusCode value.
+ */
+ public void setStatusCode(final String status) {
+ this.statusCode = status;
+ }
+
+ /**
+ * Getter for the samlId value.
+ *
+ * @return The samlId value.
+ */
+ public String getSamlId() {
+ return samlId;
+ }
+
+ /**
+ * Setter for the samlId value.
+ *
+ * @param nSamlId the new samlId value.
+ */
+ public void setSamlId(final String nSamlId) {
+ this.samlId = nSamlId;
+ }
+
+ /**
+ * Getter for the notOnOrAfter value.
+ *
+ * @return The notOnOrAfter value.
+ *
+ * @see DateTime
+ */
+ public DateTime getNotOnOrAfter() {
+ return this.notOnOrAfter;
+ }
+
+ /**
+ * Setter for the notOnOrAfter value.
+ *
+ * @param nOnOrAfter the new notOnOrAfter value.
+ *
+ * @see DateTime
+ */
+ public void setNotOnOrAfter(final DateTime nOnOrAfter) {
+ this.notOnOrAfter = nOnOrAfter;
+ }
+
+ /**
+ * Getter for the notBefore value.
+ *
+ * @return The notBefore value.
+ *
+ * @see DateTime
+ */
+ public DateTime getNotBefore() {
+ return notBefore;
+ }
+
+ /**
+ * Setter for the notBefore value.
+ *
+ * @param nBefore the new notBefore value.
+ *
+ * @see DateTime
+ */
+ public void setNotBefore(final DateTime nBefore) {
+ this.notBefore = nBefore;
+ }
+
+ public void setAssertions(List<Assertion> newAssert) {
+ this.assertions = newAssert;
+ }
+
+ public List<Assertion> getAssertions() {
+ return assertions;
+ }
+
+ /**
+ * Getter for the toal pal value.
+ *
+ * @return The total pal value.
+ *
+ * @see PersonalAttributeList
+ */
+ public IPersonalAttributeList getTotalPersonalAttributeList() {
+ IPersonalAttributeList personnalAttributeList = null;
+ try {
+ personnalAttributeList = (IPersonalAttributeList) totalAttributeList.clone();
+ } catch (CloneNotSupportedException e1) {
+ LOG.trace("[PersonalAttribute] Nothing to do.");
+ }
+ return personnalAttributeList;
+ }
+
+ /**
+ * Setter for the total Personal Attribute List value.
+ *
+ * @param attrList the new value.
+ *
+ * @see PersonalAttributeList
+ */
+ public void setTotalPersonalAttributeList(final IPersonalAttributeList attrList) {
+ if (attrList != null) {
+ this.totalAttributeList = attrList;
+ }
+ }
+
+ /**
+ * Getter for personal attribute lists
+ *
+ * @return The lists
+ *
+ * @see PersonalAttributeList
+ */
+ public List<IPersonalAttributeList> getPersonalAttributeLists() {
+ return attributeLists;
+ }
+
+ /**
+ * Setter for the Personal Attribute List value.
+ *
+ * @param attrList the new value.
+ *
+ * @see PersonalAttributeList
+ */
+ public void setPersonalAttributeLists(final List<IPersonalAttributeList> attrLists) {
+ if (attrLists != null) {
+ this.attributeLists = attrLists;
+ }
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKLogoutRequest.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKLogoutRequest.java
new file mode 100644
index 000000000..44811aee2
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKLogoutRequest.java
@@ -0,0 +1,197 @@
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+
+public class STORKLogoutRequest implements Serializable, Cloneable {
+ private static final long serialVersionUID = 4778480781609392750L;
+
+ /** The samlId. */
+ private String samlId;
+
+ /** The destination. */
+ private String destination;
+
+ /** The distinguished name. */
+ private String distinguishedName;
+
+ /** The qaa. */
+ private int qaa;
+
+ /** The token saml. */
+ private byte[] tokenSaml = new byte[0];
+
+ /** The issuer. */
+ private String issuer;
+
+ /** The country. */
+ private String country;
+
+ /** The Alias used at the keystore for saving this certificate. */
+ private String alias;
+
+ /** The ID of principal as known to SP **/
+ private String spProvidedId;
+
+ /**
+ * Gets the SP's Certificate Alias.
+ *
+ * @return alias The SP's Certificate Alias.
+ */
+ public String getAlias() {
+ return alias;
+ }
+
+ /**
+ * Sets the SP's Certificate Alias.
+ *
+ * @param nAlias The SP's Certificate Alias.
+ */
+ public void setAlias(final String nAlias) {
+ this.alias = nAlias;
+ }
+
+ /**
+ * Gets the issuer.
+ *
+ * @return The issuer value.
+ */
+ public String getIssuer() {
+ return issuer;
+ }
+
+ /**
+ * Sets the issuer.
+ *
+ * @param samlIssuer the new issuer value.
+ */
+ public void setIssuer(final String samlIssuer) {
+ this.issuer = samlIssuer;
+ }
+
+ /**
+ * Gets the SAML Token.
+ *
+ * @return The SAML Token value.
+ */
+ public byte[] getTokenSaml() {
+ return tokenSaml.clone();
+ }
+
+ /**
+ * Sets the SAML Token.
+ *
+ * @param samlToken The new SAML Token value.
+ */
+ public void setTokenSaml(final byte[] samlToken) {
+ if (samlToken != null) {
+ this.tokenSaml = samlToken.clone();
+ }
+ }
+
+ /**
+ * Gets the country.
+ *
+ * @return The country value.
+ */
+ public String getCountry() {
+ return country;
+ }
+
+ /**
+ * Sets the country.
+ *
+ * @param nCountry the new country value.
+ */
+ public void setCountry(final String nCountry) {
+ this.country = nCountry;
+ }
+
+ /**
+ * Getter for the qaa value.
+ *
+ * @return The qaa value value.
+ */
+ public int getQaa() {
+ return qaa;
+ }
+
+ /**
+ * Setter for the qaa value.
+ *
+ * @param qaaLevel The new qaa value.
+ */
+ public void setQaa(final int qaaLevel) {
+ this.qaa = qaaLevel;
+ }
+
+ /**
+ * Getter for the destination value.
+ *
+ * @return The destination value.
+ */
+ public String getDestination() {
+ return destination;
+ }
+
+ /**
+ * Setter for the destination value.
+ *
+ * @param detination the new destination value.
+ */
+ public void setDestination(final String detination) {
+ this.destination = detination;
+ }
+
+ /**
+ * Getter for the samlId value.
+ *
+ * @return The samlId value.
+ */
+ public String getSamlId() {
+ return samlId;
+ }
+
+ /**
+ * Setter for the samlId value.
+ *
+ * @param newSamlId the new samlId value.
+ */
+ public void setSamlId(final String newSamlId) {
+ this.samlId = newSamlId;
+ }
+
+ /**
+ * Getter for the distinguishedName value.
+ *
+ * @return The distinguishedName value.
+ */
+ public String getDistinguishedName() {
+ return distinguishedName;
+ }
+
+ /**
+ * Setter for the distinguishedName value.
+ *
+ * @param certDN the distinguished name value.
+ */
+ public void setDistinguishedName(final String certDN) {
+ this.distinguishedName = certDN;
+ }
+
+ /** Getter for spProvidedId **/
+ public String getSpProvidedId() {
+ return spProvidedId;
+ }
+
+ public void setSpProvidedId(final String nSpProvidedId) {
+ this.spProvidedId = nSpProvidedId;
+ }
+
+ @Override
+ public Object clone() throws CloneNotSupportedException{
+ STORKLogoutRequest storkLogoutRequest = null;
+ storkLogoutRequest = (STORKLogoutRequest) super.clone();
+ storkLogoutRequest.setTokenSaml(getTokenSaml());
+ return storkLogoutRequest;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKLogoutResponse.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKLogoutResponse.java
new file mode 100644
index 000000000..21b53a652
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKLogoutResponse.java
@@ -0,0 +1,250 @@
+package eu.stork.peps.auth.commons;
+
+import java.io.Serializable;
+
+public class STORKLogoutResponse implements Serializable, Cloneable {
+ private static final long serialVersionUID = 4778480781609392750L;
+
+ /** The samlId. */
+ private String samlId;
+
+ /** The destination. */
+ private String destination;
+
+ /** The distinguished name. */
+ private String distinguishedName;
+
+ /** The token saml. */
+ private byte[] tokenSaml = new byte[0];
+
+ /** The issuer. */
+ private String issuer;
+
+ /** The country. */
+ private String country;
+
+ /** The Alias used at the keystore for saving this certificate. */
+ private String alias;
+
+ /** Status code. */
+ private String statusCode;
+
+ /** Secondary status code. */
+ private String subStatusCode;
+
+ /** Status message. */
+ private String statusMessage;
+
+ /** Logout failed? */
+ private boolean fail;
+
+ /**
+ * Gets the SP's Certificate Alias.
+ *
+ * @return alias The SP's Certificate Alias.
+ */
+ public String getAlias() {
+ return alias;
+ }
+
+ /**
+ * Sets the SP's Certificate Alias.
+ *
+ * @param nAlias The SP's Certificate Alias.
+ */
+ public void setAlias(final String nAlias) {
+ this.alias = nAlias;
+ }
+
+ /**
+ * Gets the issuer.
+ *
+ * @return The issuer value.
+ */
+ public String getIssuer() {
+ return issuer;
+ }
+
+ /**
+ * Sets the issuer.
+ *
+ * @param samlIssuer the new issuer value.
+ */
+ public void setIssuer(final String samlIssuer) {
+ this.issuer = samlIssuer;
+ }
+
+ /**
+ * Gets the SAML Token.
+ *
+ * @return The SAML Token value.
+ */
+ public byte[] getTokenSaml() {
+ return tokenSaml.clone();
+ }
+
+ /**
+ * Sets the SAML Token.
+ *
+ * @param samlToken The new SAML Token value.
+ */
+ public void setTokenSaml(final byte[] samlToken) {
+ if (samlToken != null) {
+ this.tokenSaml = samlToken.clone();
+ }
+ }
+
+ /**
+ * Gets the country.
+ *
+ * @return The country value.
+ */
+ public String getCountry() {
+ return country;
+ }
+
+ /**
+ * Sets the country.
+ *
+ * @param nCountry the new country value.
+ */
+ public void setCountry(final String nCountry) {
+ this.country = nCountry;
+ }
+
+ /**
+ * Getter for the destination value.
+ *
+ * @return The destination value.
+ */
+ public String getDestination() {
+ return destination;
+ }
+
+ /**
+ * Setter for the destination value.
+ *
+ * @param detination the new destination value.
+ */
+ public void setDestination(final String detination) {
+ this.destination = detination;
+ }
+
+ /**
+ * Getter for the samlId value.
+ *
+ * @return The samlId value.
+ */
+ public String getSamlId() {
+ return samlId;
+ }
+
+ /**
+ * Setter for the samlId value.
+ *
+ * @param newSamlId the new samlId value.
+ */
+ public void setSamlId(final String newSamlId) {
+ this.samlId = newSamlId;
+ }
+
+ /**
+ * Getter for the distinguishedName value.
+ *
+ * @return The distinguishedName value.
+ */
+ public String getDistinguishedName() {
+ return distinguishedName;
+ }
+
+ /**
+ * Setter for the distinguishedName value.
+ *
+ * @param certDN the distinguished name value.
+ */
+ public void setDistinguishedName(final String certDN) {
+ this.distinguishedName = certDN;
+ }
+
+
+ /**
+ * Getter for the fail value.
+ *
+ * @return The fail value.
+ */
+ public boolean isFail() {
+ return fail;
+ }
+
+ /**
+ * Setter for the fail value.
+ *
+ * @param failVal the new fail value.
+ */
+ public void setFail(final boolean failVal) {
+ this.fail = failVal;
+ }
+
+ /**
+ * Getter for the statusCode value.
+ *
+ * @return The statusCode value.
+ */
+ public String getStatusCode() {
+ return statusCode;
+ }
+
+ /**
+ * Getter for the subStatusCode.
+ *
+ * @return The subStatusCode value.
+ */
+ public String getSubStatusCode() {
+ return subStatusCode;
+ }
+
+ /**
+ * Setter for the subStatusCode.
+ *
+ * @param samlSubStatusCode the new subStatusCode value.
+ */
+ public void setSubStatusCode(final String samlSubStatusCode) {
+ this.subStatusCode = samlSubStatusCode;
+ }
+
+ /**
+ * Setter for the statusMessage value.
+ *
+ * @param status the new statusMessage value.
+ */
+ public void setStatusMessage(final String status) {
+ this.statusMessage = status;
+ }
+
+ /**
+ * Getter for the statusMessage value.
+ *
+ * @return The statusMessage value.
+ */
+ public String getStatusMessage() {
+ return statusMessage;
+ }
+
+ /**
+ * Setter for the statusCode value.
+ *
+ * @param status the new statusCode value.
+ */
+ public void setStatusCode(final String status) {
+ this.statusCode = status;
+ }
+
+ @Override
+ public Object clone() throws CloneNotSupportedException{
+ STORKLogoutResponse storkLogoutResponse = null;
+ storkLogoutResponse = (STORKLogoutResponse) super.clone();
+ storkLogoutResponse.setTokenSaml(getTokenSaml());
+ return storkLogoutResponse;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKStatusCode.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKStatusCode.java
new file mode 100644
index 000000000..a9c4a156b
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKStatusCode.java
@@ -0,0 +1,68 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+/**
+ * This enum class contains the SAML Token Status Code.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.13 $, $Date: 2010-11-17 05:15:28 $
+ */
+public enum STORKStatusCode {
+
+ /** URI for Requester status code. */
+ REQUESTER_URI("urn:oasis:names:tc:SAML:2.0:status:Requester"),
+
+ /** URI for Responder status code. */
+ RESPONDER_URI("urn:oasis:names:tc:SAML:2.0:status:Responder"),
+
+ /** URI for Success status code. */
+ SUCCESS_URI("urn:oasis:names:tc:SAML:2.0:status:Success"),
+
+ /** Attribute is Available. */
+ STATUS_AVAILABLE("Available"),
+
+ /** Attribute is NotAvailable. */
+ STATUS_NOT_AVAILABLE("NotAvailable"),
+
+ /** Attribute is Withheld. */
+ STATUS_WITHHELD("Withheld");
+
+ /**
+ * Represents the constant's value.
+ */
+ private String value;
+
+ /**
+ * Solo Constructor.
+ *
+ * @param val The Constant value.
+ */
+ private STORKStatusCode(final String val) {
+
+ this.value = val;
+ }
+
+ /**
+ * Return the Constant Value.
+ *
+ * @return The constant value.
+ */
+ public String toString() {
+
+ return value;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKSubStatusCode.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKSubStatusCode.java
new file mode 100644
index 000000000..0a711c9b7
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/STORKSubStatusCode.java
@@ -0,0 +1,71 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons;
+
+/**
+ * This enum class contains the SAML Token Sub Status Code.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.7 $, $Date: 2010-11-17 05:15:28 $
+ */
+public enum STORKSubStatusCode {
+
+ /** URI for AuthnFailed status code. */
+ AUTHN_FAILED_URI("urn:oasis:names:tc:SAML:2.0:status:AuthnFailed"),
+
+ /** URI for InvalidAttrNameOrValue status code. */
+ INVALID_ATTR_NAME_VALUE_URI(
+ "urn:oasis:names:tc:SAML:2.0:status:InvalidAttrNameOrValue"),
+
+ /** URI for InvalidNameIDPolicy status code. */
+ INVALID_NAMEID_POLICY_URI(
+ "urn:oasis:names:tc:SAML:2.0:status:InvalidNameIDPolicy"),
+
+ /** URI for VersionMismatch status code. */
+ VERSION_MISMATCH_URI("urn:oasis:names:tc:SAML:2.0:status:VersionMismatch"),
+
+ /** URI for RequestDenied status code. */
+ REQUEST_DENIED_URI("urn:oasis:names:tc:SAML:2.0:status:RequestDenied"),
+
+ /** URI for QaaNotSupported status code. */
+ QAA_NOT_SUPPORTED(
+ "http://www.stork.gov.eu/saml20/statusCodes/QAANotSupported");
+
+ /**
+ * Represents the constant's value.
+ */
+ private String value;
+
+ /**
+ * Solo Constructor.
+ *
+ * @param val The Constant value.
+ */
+ private STORKSubStatusCode(final String val) {
+
+ this.value = val;
+ }
+
+ /**
+ * Return the Constant Value.
+ *
+ * @return The constant value.
+ */
+ public String toString() {
+
+ return value;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/all-wcprops b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/all-wcprops
new file mode 100644
index 000000000..14f05b17c
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/all-wcprops
@@ -0,0 +1,53 @@
+K 25
+svn:wc:ra_dav:version-url
+V 96
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/exceptions
+END
+InvalidParameterPEPSException.java
+K 25
+svn:wc:ra_dav:version-url
+V 131
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/exceptions/InvalidParameterPEPSException.java
+END
+SecurityPEPSException.java
+K 25
+svn:wc:ra_dav:version-url
+V 123
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/exceptions/SecurityPEPSException.java
+END
+InvalidSessionPEPSException.java
+K 25
+svn:wc:ra_dav:version-url
+V 129
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/exceptions/InvalidSessionPEPSException.java
+END
+package-info.java
+K 25
+svn:wc:ra_dav:version-url
+V 114
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/exceptions/package-info.java
+END
+CPEPSException.java
+K 25
+svn:wc:ra_dav:version-url
+V 116
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/exceptions/CPEPSException.java
+END
+StorkPEPSException.java
+K 25
+svn:wc:ra_dav:version-url
+V 120
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/exceptions/StorkPEPSException.java
+END
+AbstractPEPSException.java
+K 25
+svn:wc:ra_dav:version-url
+V 123
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/exceptions/AbstractPEPSException.java
+END
+InternalErrorPEPSException.java
+K 25
+svn:wc:ra_dav:version-url
+V 128
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/exceptions/InternalErrorPEPSException.java
+END
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/entries b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/entries
new file mode 100644
index 000000000..8ca1e325f
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/entries
@@ -0,0 +1,300 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/main/java/eu/stork/peps/auth/commons/exceptions
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+CPEPSException.java
+file
+
+
+
+
+2013-12-20T12:27:56.626475Z
+5d3cb4a7303baeaf2104aaa7da301b21
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+3570
+
+StorkPEPSException.java
+file
+
+
+
+
+2013-12-20T12:27:56.626475Z
+fea01f750728ea5f15b449acb517f4b2
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+1690
+
+AbstractPEPSException.java
+file
+
+
+
+
+2013-12-20T12:27:56.626475Z
+c9aedb030e6dbc9f002c7cd3d52cf03f
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+4422
+
+InternalErrorPEPSException.java
+file
+
+
+
+
+2013-12-20T12:27:56.626475Z
+36d8f6310e84c550f65bef78d5dc4238
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2471
+
+InvalidParameterPEPSException.java
+file
+
+
+
+
+2013-12-20T12:27:56.626475Z
+c6ad53378b03a346ca0fc48a381ed771
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+1800
+
+SecurityPEPSException.java
+file
+
+
+
+
+2013-12-20T12:27:56.626475Z
+78d50b78a69cb0c630e4e14420e3b7be
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2199
+
+InvalidSessionPEPSException.java
+file
+
+
+
+
+2013-12-20T12:27:56.626475Z
+5fd7f04ad6f6cc121084e682b2a4e678
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+1555
+
+package-info.java
+file
+
+
+
+
+2013-12-20T12:27:56.626475Z
+7055c01b74382c525c7fcf110646d8fc
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+129
+
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/AbstractPEPSException.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/AbstractPEPSException.java.svn-base
new file mode 100644
index 000000000..e9a96d7c2
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/AbstractPEPSException.java.svn-base
@@ -0,0 +1,173 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons.exceptions;
+
+import java.io.Serializable;
+
+/**
+ * Abstract class to represent the various PEPS exceptions.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.13 $, $Date: 2010-11-17 05:15:28 $
+ */
+public abstract class AbstractPEPSException extends RuntimeException implements
+ Serializable {
+
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = -1884417567740138022L;
+
+ /**
+ * Error code.
+ */
+ private String errorCode;
+
+ /**
+ * Error message.
+ */
+ private String errorMessage;
+
+ /**
+ * SAML token.
+ */
+ private String samlTokenFail;
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters.
+ *
+ * @param code The error code value.
+ * @param message The error message value.
+ */
+ public AbstractPEPSException(final String code, final String message) {
+
+ super(message);
+ this.errorCode = code;
+ this.errorMessage = message;
+ }
+
+ /**
+ * Exception Constructor with the errorMessage as parameters and the Throwable
+ * cause.
+ *
+ * @param message The error message value.
+ * @param cause The throwable object.
+ */
+ public AbstractPEPSException(final String message, final Throwable cause) {
+
+ super(message, cause);
+ this.errorMessage = message;
+ }
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters and the Throwable cause.
+ *
+ * @param code The error code value.
+ * @param message The error message value.
+ * @param cause The throwable object.
+ */
+ public AbstractPEPSException(final String code, final String message,
+ final Throwable cause) {
+
+ super(message, cause);
+ this.errorCode = code;
+ this.errorMessage = message;
+ }
+
+ /**
+ * Exception Constructor with three Strings representing the errorCode,
+ * errorMessage and encoded samlToken as parameters.
+ *
+ * @param code The error code value.
+ * @param message The error message value.
+ * @param samlToken The error SAML Token.
+ */
+ public AbstractPEPSException(final String code, final String message,
+ final String samlToken) {
+
+ super(message);
+ this.errorCode = code;
+ this.errorMessage = message;
+ this.samlTokenFail = samlToken;
+ }
+
+ /**
+ * Constructor with SAML Token as argument. Error message and error code are
+ * embedded in the SAML.
+ *
+ * @param samlToken The error SAML Token.
+ */
+ public AbstractPEPSException(final String samlToken) {
+ super();
+ this.samlTokenFail = samlToken;
+ }
+
+ /**
+ * Getter for errorCode.
+ *
+ * @return The errorCode value.
+ */
+ public final String getErrorCode() {
+ return errorCode;
+ }
+
+ /**
+ * Setter for errorCode.
+ *
+ * @param code The error code value.
+ */
+ public final void setErrorCode(final String code) {
+ this.errorCode = code;
+ }
+
+ /**
+ * Getter for errorMessage.
+ *
+ * @return The error Message value.
+ */
+ public final String getErrorMessage() {
+ return errorMessage;
+ }
+
+ /**
+ * Setter for errorMessage.
+ *
+ * @param message The error message value.
+ */
+ public final void setErrorMessage(final String message) {
+ this.errorMessage = message;
+ }
+
+ /**
+ * Getter for SAMLTokenFail.
+ *
+ * @return The error SAML Token.
+ */
+ public final String getSamlTokenFail() {
+ return samlTokenFail;
+ }
+
+ /**
+ * Setter for SAMLTokenFail.
+ *
+ * @param samlToken The error SAML token.
+ */
+ public final void setSamlTokenFail(final String samlToken) {
+ this.samlTokenFail = samlToken;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/CPEPSException.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/CPEPSException.java.svn-base
new file mode 100644
index 000000000..69cb20fdd
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/CPEPSException.java.svn-base
@@ -0,0 +1,143 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons.exceptions;
+
+/**
+ * This exception is thrown by the C-PEPS service and holds the relative
+ * information to present to the citizen.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.9 $, $Date: 2010-11-17 05:15:28 $
+ */
+public final class CPEPSException extends RuntimeException {
+
+ /**
+ * Serial id.
+ */
+ private static final long serialVersionUID = -4012295047127999362L;
+
+ /**
+ * Error code.
+ */
+ private String errorCode;
+
+ /**
+ * Error message.
+ */
+ private String errorMessage;
+
+ /**
+ * SAML token.
+ */
+ private String samlTokenFail;
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters.
+ *
+ * @param samlToken The SAML Token.
+ * @param code The error code value.
+ * @param message The error message value.
+ */
+ public CPEPSException(final String samlToken, final String code,
+ final String message) {
+
+ super(message);
+ this.setErrorCode(code);
+ this.setErrorMessage(message);
+ this.setSamlTokenFail(samlToken);
+ }
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters.
+ *
+ * @param samlToken The SAML Token.
+ * @param code The error code value.
+ * @param message The error message value.
+ * @param cause The original exception;
+ */
+ public CPEPSException(final String samlToken, final String code,
+ final String message, final Throwable cause) {
+
+ super(message, cause);
+ this.setErrorCode(code);
+ this.setErrorMessage(message);
+ this.setSamlTokenFail(samlToken);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public String getMessage() {
+ return this.getErrorMessage() + " (" + this.getErrorCode() + ")";
+ }
+
+ /**
+ * Getter for the error code.
+ *
+ * @return The errorCode value.
+ */
+ public String getErrorCode() {
+ return errorCode;
+ }
+
+ /**
+ * Setter for the error code.
+ *
+ * @param code The error code.
+ */
+ public void setErrorCode(final String code) {
+ this.errorCode = code;
+ }
+
+ /**
+ * Getter for the error message.
+ *
+ * @return The errorMessage value.
+ */
+ public String getErrorMessage() {
+ return errorMessage;
+ }
+
+ /**
+ * Setter for the error message.
+ *
+ * @param message The error message.
+ */
+ public void setErrorMessage(final String message) {
+ this.errorMessage = message;
+ }
+
+ /**
+ * Getter for the samlTokenFail.
+ *
+ * @return The samlTokenFail value.
+ */
+ public String getSamlTokenFail() {
+ return samlTokenFail;
+ }
+
+ /**
+ * Setter for the samlTokenFail.
+ *
+ * @param samlToken The error Saml Token.
+ */
+ public void setSamlTokenFail(final String samlToken) {
+ this.samlTokenFail = samlToken;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/InternalErrorPEPSException.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/InternalErrorPEPSException.java.svn-base
new file mode 100644
index 000000000..67514d4fe
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/InternalErrorPEPSException.java.svn-base
@@ -0,0 +1,74 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons.exceptions;
+
+/**
+ * Internal Error Exception class.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.13 $, $Date: 2010-11-17 05:15:28 $
+ *
+ * @see AbstractPEPSException
+ */
+public final class InternalErrorPEPSException extends AbstractPEPSException {
+
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 1193001455410319795L;
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters and the Throwable cause.
+ *
+ * @param errorCode The error code value.
+ * @param errorMessage The error message value.
+ * @param cause The throwable object.
+ */
+ public InternalErrorPEPSException(final String errorCode,
+ final String errorMessage, final Throwable cause) {
+
+ super(errorCode, errorMessage, cause);
+ }
+
+ /**
+ * Exception Constructor with three strings representing the errorCode,
+ * errorMessage and encoded samlToken as parameters.
+ *
+ * @param errorCode The error code value.
+ * @param errorMessage The error message value.
+ * @param samlTokenFail The error SAML Token.
+ */
+ public InternalErrorPEPSException(final String errorCode,
+ final String errorMessage, final String samlTokenFail) {
+
+ super(errorCode, errorMessage, samlTokenFail);
+ }
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters.
+ *
+ * @param errorCode The error code value.
+ * @param errorMessage The error message value.
+ */
+ public InternalErrorPEPSException(final String errorCode,
+ final String errorMessage) {
+
+ super(errorCode, errorMessage);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/InvalidParameterPEPSException.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/InvalidParameterPEPSException.java.svn-base
new file mode 100644
index 000000000..12c83b589
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/InvalidParameterPEPSException.java.svn-base
@@ -0,0 +1,54 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons.exceptions;
+
+/**
+ * Invalid Parameter Exception class.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.11 $, $Date: 2010-11-17 05:15:28 $
+ *
+ * @see InvalidParameterPEPSException
+ */
+public class InvalidParameterPEPSException extends AbstractPEPSException {
+
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 2046282148740524875L;
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters.
+ *
+ * @param errorCode The error code value.
+ * @param errorMessage The error code message value.
+ */
+ public InvalidParameterPEPSException(final String errorCode,
+ final String errorMessage) {
+ super(errorCode, errorMessage);
+ }
+
+ /**
+ * Exception Constructor with one String representing the encoded samlToken.
+ *
+ * @param samlTokenFail The error SAML Token.
+ */
+ public InvalidParameterPEPSException(final String samlTokenFail) {
+ super(samlTokenFail);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/InvalidSessionPEPSException.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/InvalidSessionPEPSException.java.svn-base
new file mode 100644
index 000000000..800525eee
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/InvalidSessionPEPSException.java.svn-base
@@ -0,0 +1,46 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons.exceptions;
+
+/**
+ * Invalid session Exception class.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.14 $, $Date: 2010-11-17 05:15:28 $
+ *
+ * @see InvalidParameterPEPSException
+ */
+public class InvalidSessionPEPSException extends InvalidParameterPEPSException {
+
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 7147090160978319016L;
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters.
+ *
+ * @param errorCode The error code value.
+ * @param errorMessage The error message value.
+ */
+ public InvalidSessionPEPSException(final String errorCode,
+ final String errorMessage) {
+
+ super(errorCode, errorMessage);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/SecurityPEPSException.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/SecurityPEPSException.java.svn-base
new file mode 100644
index 000000000..fc27371d2
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/SecurityPEPSException.java.svn-base
@@ -0,0 +1,67 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons.exceptions;
+
+/**
+ * Security PEPS Exception class.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.18 $, $Date: 2010-11-17 05:15:28 $
+ *
+ * @see AbstractPEPSException
+ */
+public final class SecurityPEPSException extends AbstractPEPSException {
+
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 5605743302478554967L;
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters.
+ *
+ * @param errorCode The error code value.
+ * @param errorMsg The error message value.
+ */
+ public SecurityPEPSException(final String errorCode, final String errorMsg) {
+ super(errorCode, errorMsg);
+ }
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters and the Throwable cause.
+ *
+ * @param errorCode The error code value.
+ * @param errorMessage The error message value.
+ * @param cause The throwable object.
+ */
+ public SecurityPEPSException(final String errorCode,
+ final String errorMessage, final Throwable cause) {
+
+ super(errorCode, errorMessage, cause);
+ }
+
+ /**
+ * Exception Constructor with one String representing the encoded samlToken.
+ *
+ * @param samlTokenFail The error SAML Token.
+ */
+ public SecurityPEPSException(final String samlTokenFail) {
+ super(samlTokenFail);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/StorkPEPSException.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/StorkPEPSException.java.svn-base
new file mode 100644
index 000000000..a2da61a02
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/StorkPEPSException.java.svn-base
@@ -0,0 +1,53 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons.exceptions;
+
+/**
+ * Security PEPS Exception class.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.15 $, $Date: 2010-11-17 05:15:28 $
+ *
+ * @see AbstractPEPSException
+ */
+public final class StorkPEPSException extends AbstractPEPSException {
+
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 8048033129798427574L;
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters.
+ *
+ * @param errorCode The error code value.
+ * @param errorMsg The error message value.
+ */
+ public StorkPEPSException(final String errorCode, final String errorMsg) {
+ super(errorCode, errorMsg);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public String getMessage() {
+
+ return "Security Error (" + this.getErrorCode() + ") processing request : "
+ + this.getErrorMessage();
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/package-info.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/package-info.java.svn-base
new file mode 100644
index 000000000..d83068beb
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/.svn/text-base/package-info.java.svn-base
@@ -0,0 +1,7 @@
+/**
+ * Package for the PEPS’ Exceptions handling.
+ *
+ * @since 1.0
+ */
+package eu.stork.peps.auth.commons.exceptions;
+
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/AbstractPEPSException.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/AbstractPEPSException.java
new file mode 100644
index 000000000..e9a96d7c2
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/AbstractPEPSException.java
@@ -0,0 +1,173 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons.exceptions;
+
+import java.io.Serializable;
+
+/**
+ * Abstract class to represent the various PEPS exceptions.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.13 $, $Date: 2010-11-17 05:15:28 $
+ */
+public abstract class AbstractPEPSException extends RuntimeException implements
+ Serializable {
+
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = -1884417567740138022L;
+
+ /**
+ * Error code.
+ */
+ private String errorCode;
+
+ /**
+ * Error message.
+ */
+ private String errorMessage;
+
+ /**
+ * SAML token.
+ */
+ private String samlTokenFail;
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters.
+ *
+ * @param code The error code value.
+ * @param message The error message value.
+ */
+ public AbstractPEPSException(final String code, final String message) {
+
+ super(message);
+ this.errorCode = code;
+ this.errorMessage = message;
+ }
+
+ /**
+ * Exception Constructor with the errorMessage as parameters and the Throwable
+ * cause.
+ *
+ * @param message The error message value.
+ * @param cause The throwable object.
+ */
+ public AbstractPEPSException(final String message, final Throwable cause) {
+
+ super(message, cause);
+ this.errorMessage = message;
+ }
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters and the Throwable cause.
+ *
+ * @param code The error code value.
+ * @param message The error message value.
+ * @param cause The throwable object.
+ */
+ public AbstractPEPSException(final String code, final String message,
+ final Throwable cause) {
+
+ super(message, cause);
+ this.errorCode = code;
+ this.errorMessage = message;
+ }
+
+ /**
+ * Exception Constructor with three Strings representing the errorCode,
+ * errorMessage and encoded samlToken as parameters.
+ *
+ * @param code The error code value.
+ * @param message The error message value.
+ * @param samlToken The error SAML Token.
+ */
+ public AbstractPEPSException(final String code, final String message,
+ final String samlToken) {
+
+ super(message);
+ this.errorCode = code;
+ this.errorMessage = message;
+ this.samlTokenFail = samlToken;
+ }
+
+ /**
+ * Constructor with SAML Token as argument. Error message and error code are
+ * embedded in the SAML.
+ *
+ * @param samlToken The error SAML Token.
+ */
+ public AbstractPEPSException(final String samlToken) {
+ super();
+ this.samlTokenFail = samlToken;
+ }
+
+ /**
+ * Getter for errorCode.
+ *
+ * @return The errorCode value.
+ */
+ public final String getErrorCode() {
+ return errorCode;
+ }
+
+ /**
+ * Setter for errorCode.
+ *
+ * @param code The error code value.
+ */
+ public final void setErrorCode(final String code) {
+ this.errorCode = code;
+ }
+
+ /**
+ * Getter for errorMessage.
+ *
+ * @return The error Message value.
+ */
+ public final String getErrorMessage() {
+ return errorMessage;
+ }
+
+ /**
+ * Setter for errorMessage.
+ *
+ * @param message The error message value.
+ */
+ public final void setErrorMessage(final String message) {
+ this.errorMessage = message;
+ }
+
+ /**
+ * Getter for SAMLTokenFail.
+ *
+ * @return The error SAML Token.
+ */
+ public final String getSamlTokenFail() {
+ return samlTokenFail;
+ }
+
+ /**
+ * Setter for SAMLTokenFail.
+ *
+ * @param samlToken The error SAML token.
+ */
+ public final void setSamlTokenFail(final String samlToken) {
+ this.samlTokenFail = samlToken;
+ }
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/CPEPSException.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/CPEPSException.java
new file mode 100644
index 000000000..69cb20fdd
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/CPEPSException.java
@@ -0,0 +1,143 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons.exceptions;
+
+/**
+ * This exception is thrown by the C-PEPS service and holds the relative
+ * information to present to the citizen.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.9 $, $Date: 2010-11-17 05:15:28 $
+ */
+public final class CPEPSException extends RuntimeException {
+
+ /**
+ * Serial id.
+ */
+ private static final long serialVersionUID = -4012295047127999362L;
+
+ /**
+ * Error code.
+ */
+ private String errorCode;
+
+ /**
+ * Error message.
+ */
+ private String errorMessage;
+
+ /**
+ * SAML token.
+ */
+ private String samlTokenFail;
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters.
+ *
+ * @param samlToken The SAML Token.
+ * @param code The error code value.
+ * @param message The error message value.
+ */
+ public CPEPSException(final String samlToken, final String code,
+ final String message) {
+
+ super(message);
+ this.setErrorCode(code);
+ this.setErrorMessage(message);
+ this.setSamlTokenFail(samlToken);
+ }
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters.
+ *
+ * @param samlToken The SAML Token.
+ * @param code The error code value.
+ * @param message The error message value.
+ * @param cause The original exception;
+ */
+ public CPEPSException(final String samlToken, final String code,
+ final String message, final Throwable cause) {
+
+ super(message, cause);
+ this.setErrorCode(code);
+ this.setErrorMessage(message);
+ this.setSamlTokenFail(samlToken);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public String getMessage() {
+ return this.getErrorMessage() + " (" + this.getErrorCode() + ")";
+ }
+
+ /**
+ * Getter for the error code.
+ *
+ * @return The errorCode value.
+ */
+ public String getErrorCode() {
+ return errorCode;
+ }
+
+ /**
+ * Setter for the error code.
+ *
+ * @param code The error code.
+ */
+ public void setErrorCode(final String code) {
+ this.errorCode = code;
+ }
+
+ /**
+ * Getter for the error message.
+ *
+ * @return The errorMessage value.
+ */
+ public String getErrorMessage() {
+ return errorMessage;
+ }
+
+ /**
+ * Setter for the error message.
+ *
+ * @param message The error message.
+ */
+ public void setErrorMessage(final String message) {
+ this.errorMessage = message;
+ }
+
+ /**
+ * Getter for the samlTokenFail.
+ *
+ * @return The samlTokenFail value.
+ */
+ public String getSamlTokenFail() {
+ return samlTokenFail;
+ }
+
+ /**
+ * Setter for the samlTokenFail.
+ *
+ * @param samlToken The error Saml Token.
+ */
+ public void setSamlTokenFail(final String samlToken) {
+ this.samlTokenFail = samlToken;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/InternalErrorPEPSException.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/InternalErrorPEPSException.java
new file mode 100644
index 000000000..67514d4fe
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/InternalErrorPEPSException.java
@@ -0,0 +1,74 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons.exceptions;
+
+/**
+ * Internal Error Exception class.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.13 $, $Date: 2010-11-17 05:15:28 $
+ *
+ * @see AbstractPEPSException
+ */
+public final class InternalErrorPEPSException extends AbstractPEPSException {
+
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 1193001455410319795L;
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters and the Throwable cause.
+ *
+ * @param errorCode The error code value.
+ * @param errorMessage The error message value.
+ * @param cause The throwable object.
+ */
+ public InternalErrorPEPSException(final String errorCode,
+ final String errorMessage, final Throwable cause) {
+
+ super(errorCode, errorMessage, cause);
+ }
+
+ /**
+ * Exception Constructor with three strings representing the errorCode,
+ * errorMessage and encoded samlToken as parameters.
+ *
+ * @param errorCode The error code value.
+ * @param errorMessage The error message value.
+ * @param samlTokenFail The error SAML Token.
+ */
+ public InternalErrorPEPSException(final String errorCode,
+ final String errorMessage, final String samlTokenFail) {
+
+ super(errorCode, errorMessage, samlTokenFail);
+ }
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters.
+ *
+ * @param errorCode The error code value.
+ * @param errorMessage The error message value.
+ */
+ public InternalErrorPEPSException(final String errorCode,
+ final String errorMessage) {
+
+ super(errorCode, errorMessage);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/InvalidParameterPEPSException.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/InvalidParameterPEPSException.java
new file mode 100644
index 000000000..12c83b589
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/InvalidParameterPEPSException.java
@@ -0,0 +1,54 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons.exceptions;
+
+/**
+ * Invalid Parameter Exception class.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.11 $, $Date: 2010-11-17 05:15:28 $
+ *
+ * @see InvalidParameterPEPSException
+ */
+public class InvalidParameterPEPSException extends AbstractPEPSException {
+
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 2046282148740524875L;
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters.
+ *
+ * @param errorCode The error code value.
+ * @param errorMessage The error code message value.
+ */
+ public InvalidParameterPEPSException(final String errorCode,
+ final String errorMessage) {
+ super(errorCode, errorMessage);
+ }
+
+ /**
+ * Exception Constructor with one String representing the encoded samlToken.
+ *
+ * @param samlTokenFail The error SAML Token.
+ */
+ public InvalidParameterPEPSException(final String samlTokenFail) {
+ super(samlTokenFail);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/InvalidSessionPEPSException.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/InvalidSessionPEPSException.java
new file mode 100644
index 000000000..800525eee
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/InvalidSessionPEPSException.java
@@ -0,0 +1,46 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons.exceptions;
+
+/**
+ * Invalid session Exception class.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.14 $, $Date: 2010-11-17 05:15:28 $
+ *
+ * @see InvalidParameterPEPSException
+ */
+public class InvalidSessionPEPSException extends InvalidParameterPEPSException {
+
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 7147090160978319016L;
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters.
+ *
+ * @param errorCode The error code value.
+ * @param errorMessage The error message value.
+ */
+ public InvalidSessionPEPSException(final String errorCode,
+ final String errorMessage) {
+
+ super(errorCode, errorMessage);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/SecurityPEPSException.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/SecurityPEPSException.java
new file mode 100644
index 000000000..fc27371d2
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/SecurityPEPSException.java
@@ -0,0 +1,67 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons.exceptions;
+
+/**
+ * Security PEPS Exception class.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.18 $, $Date: 2010-11-17 05:15:28 $
+ *
+ * @see AbstractPEPSException
+ */
+public final class SecurityPEPSException extends AbstractPEPSException {
+
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 5605743302478554967L;
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters.
+ *
+ * @param errorCode The error code value.
+ * @param errorMsg The error message value.
+ */
+ public SecurityPEPSException(final String errorCode, final String errorMsg) {
+ super(errorCode, errorMsg);
+ }
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters and the Throwable cause.
+ *
+ * @param errorCode The error code value.
+ * @param errorMessage The error message value.
+ * @param cause The throwable object.
+ */
+ public SecurityPEPSException(final String errorCode,
+ final String errorMessage, final Throwable cause) {
+
+ super(errorCode, errorMessage, cause);
+ }
+
+ /**
+ * Exception Constructor with one String representing the encoded samlToken.
+ *
+ * @param samlTokenFail The error SAML Token.
+ */
+ public SecurityPEPSException(final String samlTokenFail) {
+ super(samlTokenFail);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/StorkPEPSException.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/StorkPEPSException.java
new file mode 100644
index 000000000..a2da61a02
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/StorkPEPSException.java
@@ -0,0 +1,53 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.commons.exceptions;
+
+/**
+ * Security PEPS Exception class.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.15 $, $Date: 2010-11-17 05:15:28 $
+ *
+ * @see AbstractPEPSException
+ */
+public final class StorkPEPSException extends AbstractPEPSException {
+
+ /**
+ * Unique identifier.
+ */
+ private static final long serialVersionUID = 8048033129798427574L;
+
+ /**
+ * Exception Constructor with two Strings representing the errorCode and
+ * errorMessage as parameters.
+ *
+ * @param errorCode The error code value.
+ * @param errorMsg The error message value.
+ */
+ public StorkPEPSException(final String errorCode, final String errorMsg) {
+ super(errorCode, errorMsg);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public String getMessage() {
+
+ return "Security Error (" + this.getErrorCode() + ") processing request : "
+ + this.getErrorMessage();
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/package-info.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/package-info.java
new file mode 100644
index 000000000..d83068beb
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/exceptions/package-info.java
@@ -0,0 +1,7 @@
+/**
+ * Package for the PEPS’ Exceptions handling.
+ *
+ * @since 1.0
+ */
+package eu.stork.peps.auth.commons.exceptions;
+
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/package-info.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/package-info.java
new file mode 100644
index 000000000..19d45aaa2
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/commons/package-info.java
@@ -0,0 +1,9 @@
+/**
+ * Common Authentication Service functionalities to be deployed in every PEPS
+ * is contained in this package.
+ * In particular, it contains the SAML Engine that implements the SAML messages
+ * management
+ *
+ * @since 1.0
+ */
+package eu.stork.peps.auth.commons;
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/all-wcprops b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/all-wcprops
new file mode 100644
index 000000000..3cd5d5378
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/all-wcprops
@@ -0,0 +1,41 @@
+K 25
+svn:wc:ra_dav:version-url
+V 87
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/specific
+END
+IDeriveAttribute.java
+K 25
+svn:wc:ra_dav:version-url
+V 108
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/specific/IDeriveAttribute.java
+END
+IAUService.java
+K 25
+svn:wc:ra_dav:version-url
+V 103
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/specific/IAUService.java
+END
+INormaliseValue.java
+K 25
+svn:wc:ra_dav:version-url
+V 107
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/specific/INormaliseValue.java
+END
+ITranslatorService.java
+K 25
+svn:wc:ra_dav:version-url
+V 111
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/main/java/eu/stork/peps/auth/specific/ITranslatorService.java
+END
+package-info.java
+K 25
+svn:wc:ra_dav:version-url
+V 104
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/specific/package-info.java
+END
+ICheckAttributeValue.java
+K 25
+svn:wc:ra_dav:version-url
+V 112
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/java/eu/stork/peps/auth/specific/ICheckAttributeValue.java
+END
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/entries b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/entries
new file mode 100644
index 000000000..acd798b61
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/entries
@@ -0,0 +1,232 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/main/java/eu/stork/peps/auth/specific
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+ITranslatorService.java
+file
+
+
+
+
+2014-01-21T08:38:55.228702Z
+c027ed5506150c744b8e586b325de5fb
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+3120
+
+package-info.java
+file
+
+
+
+
+2013-12-20T12:27:56.654475Z
+eef7721d55c2edb02a432fc08ae9e487
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+164
+
+ICheckAttributeValue.java
+file
+
+
+
+
+2013-12-20T12:27:56.654475Z
+b0472ff15d1c86f175da134b0f0eda71
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+1321
+
+IDeriveAttribute.java
+file
+
+
+
+
+2013-12-20T12:27:56.654475Z
+dce3856a97583f739cdf50ca78491277
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+1504
+
+IAUService.java
+file
+
+
+
+
+2014-01-21T08:38:55.228702Z
+b622aaaa29b0cd72261ca7799db691b9
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+7023
+
+INormaliseValue.java
+file
+
+
+
+
+2013-12-20T12:27:56.654475Z
+09f6e376875762fca294be4dfecb71f1
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+1237
+
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/IAUService.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/IAUService.java.svn-base
new file mode 100644
index 000000000..5c24cc5a8
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/IAUService.java.svn-base
@@ -0,0 +1,215 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.specific;
+
+import java.util.Map;
+
+import eu.stork.peps.auth.commons.IPersonalAttributeList;
+import eu.stork.peps.auth.commons.IStorkSession;
+import eu.stork.peps.auth.commons.STORKAttrQueryResponse;
+import eu.stork.peps.auth.commons.STORKAuthnResponse;
+
+/**
+ * Interface for Specific Authentication methods.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com
+ */
+public interface IAUService {
+
+ /**
+ * Prepares the citizen to be redirected to the IdP.
+ *
+ * @param personalList The Personal Attribute List.
+ * @param parameters The parameters.
+ * @param session The session object.
+ * @param requestAttributes The Requested attributes.
+ *
+ * @return byte[] containing a SAML Request.
+ *
+ * @see IPersonalAttributeList
+ * @see IStorkSession
+ */
+ byte[] prepareCitizenAuthentication(IPersonalAttributeList personalList,
+ Map<String, Object> parameters, Map<String, Object> requestAttributes,
+ IStorkSession session);
+
+ /**
+ * Prepares the citizen to be redirected to the PV.
+ *
+ * @param personalList The Personal Attribute List.
+ * @param parameters The parameters.
+ * @param session The session object.
+ * @param requestAttributes The Requested attributes.
+ *
+ * @return byte[] containing a SAML Request.
+ *
+ * @see IPersonalAttributeList
+ * @see IStorkSession
+ */
+ byte[] preparePVRequest(IPersonalAttributeList personalList,
+ Map<String, Object> parameters, Map<String, Object> requestAttributes,
+ IStorkSession session);
+
+ /**
+ * Authenticates a citizen.
+ *
+ * @param personalList The Personal Attribute List.
+ * @param parameters The parameters.
+ * @param requestAttributes The requested attributes.
+ *
+ * @return The updated Personal Attribute List.
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList authenticateCitizen(
+ IPersonalAttributeList personalList, Map<String, Object> parameters,
+ Map<String, Object> requestAttributes);
+
+ /**
+ * Validates a power.
+ *
+ * @param personalList The Personal Attribute List.
+ * @param parameters The parameters.
+ * @param requestAttributes The requested attributes.
+ *
+ * @return The updated Personal Attribute List (power validated).
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList powerValidation(
+ IPersonalAttributeList personalList, Map<String, Object> parameters,
+ Map<String, Object> requestAttributes);
+
+ /**
+ * Prepares the Citizen browser to be redirected to the AP.
+ *
+ * @param personalList The Personal Attribute List.
+ * @param parameters The parameters.
+ * @param session The session object.
+ * @param requestAttributes The requested attributes.
+ *
+ * @return true in case of no error.
+ *
+ * @see IPersonalAttributeList
+ * @see IStorkSession
+ */
+ boolean prepareAPRedirect(IPersonalAttributeList personalList,
+ Map<String, Object> parameters, Map<String, Object> requestAttributes,
+ IStorkSession session);
+
+ /**
+ * Returns the attributes values from the AP.
+ *
+ * @param personalList The Personal Attribute List.
+ * @param parameters The parameters.
+ * @param requestAttributes The request attributes.
+ *
+ * @return The updated Personal Attribute List.
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList getAttributesFromAttributeProviders(
+ IPersonalAttributeList personalList, Map<String, Object> parameters,
+ Map<String, Object> requestAttributes);
+
+ /**
+ * Get the attributes from the AP with verification.
+ *
+ * @param personalList The Personal Attribute List.
+ * @param parameters The HTTP Parameters.
+ * @param requestAttributes The requested Attributes.
+ * @param session The session object.
+ * @param auProcessId The SAML identifier.
+ *
+ * @return true if the attributes were correctly verified.
+ *
+ * @see IPersonalAttributeList
+ * @see IStorkSession
+ */
+ boolean getAttributesWithVerification(IPersonalAttributeList personalList,
+ Map<String, Object> parameters, Map<String, Object> requestAttributes,
+ IStorkSession session, String auProcessId);
+
+ /**
+ * Validates a SAML Response.
+ *
+ * @param samlToken The SAML Token.
+ * @param session The session object.
+ *
+ * @return the STORKAuthnResponse associated with the validated response.
+ *
+ * @see IStorkSession
+ */
+ STORKAuthnResponse processAuthenticationResponse(byte[] samlToken,
+ IStorkSession session);
+
+ /**
+ * Generates a SAML Response in case of error.
+ *
+ * @param inResponseTo The SAML's identifier to response.
+ * @param issuer The issuer value.
+ * @param assertionURL The assertion URL.
+ * @param code The error code.
+ * @param subcode The sub error code.
+ * @param message The error message.
+ * @param ipUserAddress The user IP address.
+ *
+ * @return byte[] containing the SAML Response.
+ */
+ byte[] generateErrorAuthenticationResponse(String inResponseTo,
+ String issuer, String assertionURL, String code, String subcode,
+ String message, String ipUserAddress);
+
+ /**
+ * Compares two given personal attribute lists.
+ *
+ * @param original The original Personal Attribute List.
+ * @param modified The modified Personal Attribute List.
+ * @return true if the original list contains the modified one. False
+ * otherwise.
+ *
+ * @see IPersonalAttributeList
+ */
+ boolean comparePersonalAttributeLists(IPersonalAttributeList original,
+ IPersonalAttributeList modified);
+
+ /**
+ * Prepares the citizen to be redirected to the AtP.
+ *
+ * @param personalList The Personal Attribute List.
+ * @param parameters The parameters.
+ * @param session The session object.
+ *
+ * @return byte[] containing a SAML Request.
+ *
+ * @see IPersonalAttributeList
+ * @see IStorkSession
+ */
+ byte[] prepareAttributeRequest(IPersonalAttributeList personalList,
+ Map<String, Object> parameters, IStorkSession session);
+
+ /**
+ * Validates a SAML Response.
+ *
+ * @param samlToken The SAML Token.
+ * @param session The session object.
+ *
+ * @return the STORKAttrQueryResponse associated with the validated response.
+ *
+ * @see IStorkSession
+ */
+ STORKAttrQueryResponse processAttributeResponse(byte[] samlToken,
+ IStorkSession session);
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/ICheckAttributeValue.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/ICheckAttributeValue.java.svn-base
new file mode 100644
index 000000000..31a8d78ff
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/ICheckAttributeValue.java.svn-base
@@ -0,0 +1,37 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.specific;
+
+import java.util.List;
+
+/**
+ * Interface that defines the methods to work with the validation of attributes.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com
+ */
+public interface ICheckAttributeValue {
+
+ /**
+ * Checks if the list of values contains the expected value.
+ *
+ * @param values The List of values.
+ * @param expectedValue The value to check if it exists on the list.
+ *
+ * @return boolean true, if the value is present in the list. False,
+ * otherwise.
+ */
+ boolean checkValue(List<String> values, String expectedValue);
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/IDeriveAttribute.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/IDeriveAttribute.java.svn-base
new file mode 100644
index 000000000..78eb53004
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/IDeriveAttribute.java.svn-base
@@ -0,0 +1,40 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.specific;
+
+import eu.stork.peps.auth.commons.IStorkSession;
+import eu.stork.peps.auth.commons.PersonalAttribute;
+
+/**
+ * Interface that defines the methods to work with derivation of attributes.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com
+ */
+public interface IDeriveAttribute {
+
+ /**
+ * Derives the attribute value. Set the Personal Attribute value to null if
+ * the value in session or the value of age are invalid (non-numeric or null).
+ *
+ * @param personalAttrList The Personal Attribute List.
+ * @param session The session object.
+ *
+ * @see PersonalAttribute The personal Attribute
+ * @see IStorkSession The session object.
+ */
+ void deriveAttributeToData(PersonalAttribute personalAttrList,
+ IStorkSession session);
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/INormaliseValue.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/INormaliseValue.java.svn-base
new file mode 100644
index 000000000..ca2114e32
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/INormaliseValue.java.svn-base
@@ -0,0 +1,35 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.specific;
+
+import eu.stork.peps.auth.commons.PersonalAttribute;
+
+/**
+ * Interface for attribute's value normalisation.
+ *
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com
+ */
+public interface INormaliseValue {
+
+ /**
+ * Translates the attribute's value from local format to STORK format.
+ *
+ * @param personalAttribute The Personal Attribute to normalise the value.
+ *
+ * @see PersonalAttribute
+ */
+ void normaliseAttributeValueToStork(PersonalAttribute personalAttribute);
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/ITranslatorService.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/ITranslatorService.java.svn-base
new file mode 100644
index 000000000..8a33897d8
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/ITranslatorService.java.svn-base
@@ -0,0 +1,100 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.specific;
+
+import eu.stork.peps.auth.commons.IPersonalAttributeList;
+import eu.stork.peps.auth.commons.IStorkSession;
+import eu.stork.peps.auth.commons.STORKAuthnRequest;
+
+/**
+ * Interface for attributes normalization.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com
+ */
+public interface ITranslatorService {
+
+ /**
+ * Translates the attributes from local format to STORK format.
+ *
+ * @param personalList The Personal Attribute List.
+ *
+ * @return The Personal Attribute List with normalised attributes.
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList normaliseAttributeNamesToStork(
+ IPersonalAttributeList personalList);
+
+ /**
+ * Translates the attributes values from local format to STORK format.
+ *
+ * @param personalList The Personal Attribute List.
+ *
+ * @return The PersonalAttributeList with normalised values.
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList normaliseAttributeValuesToStork(
+ IPersonalAttributeList personalList);
+
+ /**
+ * Translates the attributes from STORK format to local format.
+ *
+ * @param personalList The Personal Attribute List.
+ *
+ * @return The PersonalAttributeList with normalised attributes.
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList normaliseAttributeNamesFromStork(
+ IPersonalAttributeList personalList);
+
+ /**
+ * Derive Attribute Names To Stork format.
+ *
+ * @param personalList The Personal Attribute List,
+ *
+ * @return The PersonalAttributeList with derived attributes.
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList deriveAttributeFromStork(
+ IPersonalAttributeList personalList);
+
+ /**
+ * Derive Attribute Names from Stork format.
+ *
+ * @param session The session object.
+ * @param modifiedList The Personal Attribute List.
+ *
+ * @return The PersonalAttributeList with derived attributes.
+ *
+ * @see IStorkSession
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList deriveAttributeToStork(IStorkSession session,
+ IPersonalAttributeList modifiedList);
+
+ /**
+ * Validate the values of the attributes.
+ *
+ * @param pal The attribute list
+ *
+ * @return True, if all the attributes have values. False, otherwise.
+ *
+ * @see STORKAuthnRequest
+ */
+ boolean checkAttributeValues(IPersonalAttributeList pa);
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/package-info.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/package-info.java.svn-base
new file mode 100644
index 000000000..a25c52311
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/.svn/text-base/package-info.java.svn-base
@@ -0,0 +1,8 @@
+/**
+ * Specific PEPS Interfaces that implements functionality of the Authentication
+ * Service.
+ *
+ * @since 1.0
+ */
+package eu.stork.peps.auth.specific;
+
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/IAUService.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/IAUService.java
new file mode 100644
index 000000000..5c24cc5a8
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/IAUService.java
@@ -0,0 +1,215 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.specific;
+
+import java.util.Map;
+
+import eu.stork.peps.auth.commons.IPersonalAttributeList;
+import eu.stork.peps.auth.commons.IStorkSession;
+import eu.stork.peps.auth.commons.STORKAttrQueryResponse;
+import eu.stork.peps.auth.commons.STORKAuthnResponse;
+
+/**
+ * Interface for Specific Authentication methods.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com
+ */
+public interface IAUService {
+
+ /**
+ * Prepares the citizen to be redirected to the IdP.
+ *
+ * @param personalList The Personal Attribute List.
+ * @param parameters The parameters.
+ * @param session The session object.
+ * @param requestAttributes The Requested attributes.
+ *
+ * @return byte[] containing a SAML Request.
+ *
+ * @see IPersonalAttributeList
+ * @see IStorkSession
+ */
+ byte[] prepareCitizenAuthentication(IPersonalAttributeList personalList,
+ Map<String, Object> parameters, Map<String, Object> requestAttributes,
+ IStorkSession session);
+
+ /**
+ * Prepares the citizen to be redirected to the PV.
+ *
+ * @param personalList The Personal Attribute List.
+ * @param parameters The parameters.
+ * @param session The session object.
+ * @param requestAttributes The Requested attributes.
+ *
+ * @return byte[] containing a SAML Request.
+ *
+ * @see IPersonalAttributeList
+ * @see IStorkSession
+ */
+ byte[] preparePVRequest(IPersonalAttributeList personalList,
+ Map<String, Object> parameters, Map<String, Object> requestAttributes,
+ IStorkSession session);
+
+ /**
+ * Authenticates a citizen.
+ *
+ * @param personalList The Personal Attribute List.
+ * @param parameters The parameters.
+ * @param requestAttributes The requested attributes.
+ *
+ * @return The updated Personal Attribute List.
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList authenticateCitizen(
+ IPersonalAttributeList personalList, Map<String, Object> parameters,
+ Map<String, Object> requestAttributes);
+
+ /**
+ * Validates a power.
+ *
+ * @param personalList The Personal Attribute List.
+ * @param parameters The parameters.
+ * @param requestAttributes The requested attributes.
+ *
+ * @return The updated Personal Attribute List (power validated).
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList powerValidation(
+ IPersonalAttributeList personalList, Map<String, Object> parameters,
+ Map<String, Object> requestAttributes);
+
+ /**
+ * Prepares the Citizen browser to be redirected to the AP.
+ *
+ * @param personalList The Personal Attribute List.
+ * @param parameters The parameters.
+ * @param session The session object.
+ * @param requestAttributes The requested attributes.
+ *
+ * @return true in case of no error.
+ *
+ * @see IPersonalAttributeList
+ * @see IStorkSession
+ */
+ boolean prepareAPRedirect(IPersonalAttributeList personalList,
+ Map<String, Object> parameters, Map<String, Object> requestAttributes,
+ IStorkSession session);
+
+ /**
+ * Returns the attributes values from the AP.
+ *
+ * @param personalList The Personal Attribute List.
+ * @param parameters The parameters.
+ * @param requestAttributes The request attributes.
+ *
+ * @return The updated Personal Attribute List.
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList getAttributesFromAttributeProviders(
+ IPersonalAttributeList personalList, Map<String, Object> parameters,
+ Map<String, Object> requestAttributes);
+
+ /**
+ * Get the attributes from the AP with verification.
+ *
+ * @param personalList The Personal Attribute List.
+ * @param parameters The HTTP Parameters.
+ * @param requestAttributes The requested Attributes.
+ * @param session The session object.
+ * @param auProcessId The SAML identifier.
+ *
+ * @return true if the attributes were correctly verified.
+ *
+ * @see IPersonalAttributeList
+ * @see IStorkSession
+ */
+ boolean getAttributesWithVerification(IPersonalAttributeList personalList,
+ Map<String, Object> parameters, Map<String, Object> requestAttributes,
+ IStorkSession session, String auProcessId);
+
+ /**
+ * Validates a SAML Response.
+ *
+ * @param samlToken The SAML Token.
+ * @param session The session object.
+ *
+ * @return the STORKAuthnResponse associated with the validated response.
+ *
+ * @see IStorkSession
+ */
+ STORKAuthnResponse processAuthenticationResponse(byte[] samlToken,
+ IStorkSession session);
+
+ /**
+ * Generates a SAML Response in case of error.
+ *
+ * @param inResponseTo The SAML's identifier to response.
+ * @param issuer The issuer value.
+ * @param assertionURL The assertion URL.
+ * @param code The error code.
+ * @param subcode The sub error code.
+ * @param message The error message.
+ * @param ipUserAddress The user IP address.
+ *
+ * @return byte[] containing the SAML Response.
+ */
+ byte[] generateErrorAuthenticationResponse(String inResponseTo,
+ String issuer, String assertionURL, String code, String subcode,
+ String message, String ipUserAddress);
+
+ /**
+ * Compares two given personal attribute lists.
+ *
+ * @param original The original Personal Attribute List.
+ * @param modified The modified Personal Attribute List.
+ * @return true if the original list contains the modified one. False
+ * otherwise.
+ *
+ * @see IPersonalAttributeList
+ */
+ boolean comparePersonalAttributeLists(IPersonalAttributeList original,
+ IPersonalAttributeList modified);
+
+ /**
+ * Prepares the citizen to be redirected to the AtP.
+ *
+ * @param personalList The Personal Attribute List.
+ * @param parameters The parameters.
+ * @param session The session object.
+ *
+ * @return byte[] containing a SAML Request.
+ *
+ * @see IPersonalAttributeList
+ * @see IStorkSession
+ */
+ byte[] prepareAttributeRequest(IPersonalAttributeList personalList,
+ Map<String, Object> parameters, IStorkSession session);
+
+ /**
+ * Validates a SAML Response.
+ *
+ * @param samlToken The SAML Token.
+ * @param session The session object.
+ *
+ * @return the STORKAttrQueryResponse associated with the validated response.
+ *
+ * @see IStorkSession
+ */
+ STORKAttrQueryResponse processAttributeResponse(byte[] samlToken,
+ IStorkSession session);
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/ICheckAttributeValue.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/ICheckAttributeValue.java
new file mode 100644
index 000000000..31a8d78ff
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/ICheckAttributeValue.java
@@ -0,0 +1,37 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.specific;
+
+import java.util.List;
+
+/**
+ * Interface that defines the methods to work with the validation of attributes.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com
+ */
+public interface ICheckAttributeValue {
+
+ /**
+ * Checks if the list of values contains the expected value.
+ *
+ * @param values The List of values.
+ * @param expectedValue The value to check if it exists on the list.
+ *
+ * @return boolean true, if the value is present in the list. False,
+ * otherwise.
+ */
+ boolean checkValue(List<String> values, String expectedValue);
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/IDeriveAttribute.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/IDeriveAttribute.java
new file mode 100644
index 000000000..78eb53004
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/IDeriveAttribute.java
@@ -0,0 +1,40 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.specific;
+
+import eu.stork.peps.auth.commons.IStorkSession;
+import eu.stork.peps.auth.commons.PersonalAttribute;
+
+/**
+ * Interface that defines the methods to work with derivation of attributes.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com
+ */
+public interface IDeriveAttribute {
+
+ /**
+ * Derives the attribute value. Set the Personal Attribute value to null if
+ * the value in session or the value of age are invalid (non-numeric or null).
+ *
+ * @param personalAttrList The Personal Attribute List.
+ * @param session The session object.
+ *
+ * @see PersonalAttribute The personal Attribute
+ * @see IStorkSession The session object.
+ */
+ void deriveAttributeToData(PersonalAttribute personalAttrList,
+ IStorkSession session);
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/INormaliseValue.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/INormaliseValue.java
new file mode 100644
index 000000000..ca2114e32
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/INormaliseValue.java
@@ -0,0 +1,35 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.specific;
+
+import eu.stork.peps.auth.commons.PersonalAttribute;
+
+/**
+ * Interface for attribute's value normalisation.
+ *
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com
+ */
+public interface INormaliseValue {
+
+ /**
+ * Translates the attribute's value from local format to STORK format.
+ *
+ * @param personalAttribute The Personal Attribute to normalise the value.
+ *
+ * @see PersonalAttribute
+ */
+ void normaliseAttributeValueToStork(PersonalAttribute personalAttribute);
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/ITranslatorService.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/ITranslatorService.java
new file mode 100644
index 000000000..8a33897d8
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/ITranslatorService.java
@@ -0,0 +1,100 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.auth.specific;
+
+import eu.stork.peps.auth.commons.IPersonalAttributeList;
+import eu.stork.peps.auth.commons.IStorkSession;
+import eu.stork.peps.auth.commons.STORKAuthnRequest;
+
+/**
+ * Interface for attributes normalization.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com
+ */
+public interface ITranslatorService {
+
+ /**
+ * Translates the attributes from local format to STORK format.
+ *
+ * @param personalList The Personal Attribute List.
+ *
+ * @return The Personal Attribute List with normalised attributes.
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList normaliseAttributeNamesToStork(
+ IPersonalAttributeList personalList);
+
+ /**
+ * Translates the attributes values from local format to STORK format.
+ *
+ * @param personalList The Personal Attribute List.
+ *
+ * @return The PersonalAttributeList with normalised values.
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList normaliseAttributeValuesToStork(
+ IPersonalAttributeList personalList);
+
+ /**
+ * Translates the attributes from STORK format to local format.
+ *
+ * @param personalList The Personal Attribute List.
+ *
+ * @return The PersonalAttributeList with normalised attributes.
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList normaliseAttributeNamesFromStork(
+ IPersonalAttributeList personalList);
+
+ /**
+ * Derive Attribute Names To Stork format.
+ *
+ * @param personalList The Personal Attribute List,
+ *
+ * @return The PersonalAttributeList with derived attributes.
+ *
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList deriveAttributeFromStork(
+ IPersonalAttributeList personalList);
+
+ /**
+ * Derive Attribute Names from Stork format.
+ *
+ * @param session The session object.
+ * @param modifiedList The Personal Attribute List.
+ *
+ * @return The PersonalAttributeList with derived attributes.
+ *
+ * @see IStorkSession
+ * @see IPersonalAttributeList
+ */
+ IPersonalAttributeList deriveAttributeToStork(IStorkSession session,
+ IPersonalAttributeList modifiedList);
+
+ /**
+ * Validate the values of the attributes.
+ *
+ * @param pal The attribute list
+ *
+ * @return True, if all the attributes have values. False, otherwise.
+ *
+ * @see STORKAuthnRequest
+ */
+ boolean checkAttributeValues(IPersonalAttributeList pa);
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/package-info.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/package-info.java
new file mode 100644
index 000000000..a25c52311
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/auth/specific/package-info.java
@@ -0,0 +1,8 @@
+/**
+ * Specific PEPS Interfaces that implements functionality of the Authentication
+ * Service.
+ *
+ * @since 1.0
+ */
+package eu.stork.peps.auth.specific;
+
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/.svn/all-wcprops b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/.svn/all-wcprops
new file mode 100644
index 000000000..d792fc132
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/.svn/all-wcprops
@@ -0,0 +1,5 @@
+K 25
+svn:wc:ra_dav:version-url
+V 81
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex
+END
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/.svn/entries b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/.svn/entries
new file mode 100644
index 000000000..e43413c41
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/.svn/entries
@@ -0,0 +1,31 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/main/java/eu/stork/peps/complex
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+attributes
+dir
+
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/all-wcprops b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/all-wcprops
new file mode 100644
index 000000000..76286973c
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/all-wcprops
@@ -0,0 +1,125 @@
+K 25
+svn:wc:ra_dav:version-url
+V 92
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes
+END
+ObjectFactory.java
+K 25
+svn:wc:ra_dav:version-url
+V 111
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/ObjectFactory.java
+END
+IsTeacherOfType.java
+K 25
+svn:wc:ra_dav:version-url
+V 113
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/IsTeacherOfType.java
+END
+CanonicalAddressType.java
+K 25
+svn:wc:ra_dav:version-url
+V 118
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/CanonicalAddressType.java
+END
+IsCourseCoordinatorType.java
+K 25
+svn:wc:ra_dav:version-url
+V 121
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/IsCourseCoordinatorType.java
+END
+MandateContentType.java
+K 25
+svn:wc:ra_dav:version-url
+V 116
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/MandateContentType.java
+END
+Habilitation.java
+K 25
+svn:wc:ra_dav:version-url
+V 110
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/Habilitation.java
+END
+IsHCPType.java
+K 25
+svn:wc:ra_dav:version-url
+V 107
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/IsHCPType.java
+END
+IsAcademicStaffType.java
+K 25
+svn:wc:ra_dav:version-url
+V 117
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/IsAcademicStaffType.java
+END
+AttributeStatusType.java
+K 25
+svn:wc:ra_dav:version-url
+V 117
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/AttributeStatusType.java
+END
+HabilitationType.java
+K 25
+svn:wc:ra_dav:version-url
+V 114
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/HabilitationType.java
+END
+IsAdminStaffType.java
+K 25
+svn:wc:ra_dav:version-url
+V 114
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/IsAdminStaffType.java
+END
+MandateType.java
+K 25
+svn:wc:ra_dav:version-url
+V 109
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/MandateType.java
+END
+HasAccountInBankType.java
+K 25
+svn:wc:ra_dav:version-url
+V 118
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/HasAccountInBankType.java
+END
+IsHealthCareProfessionalType.java
+K 25
+svn:wc:ra_dav:version-url
+V 126
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/IsHealthCareProfessionalType.java
+END
+IsStudentType.java
+K 25
+svn:wc:ra_dav:version-url
+V 111
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/IsStudentType.java
+END
+package-info.java
+K 25
+svn:wc:ra_dav:version-url
+V 110
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/package-info.java
+END
+AcTitleType.java
+K 25
+svn:wc:ra_dav:version-url
+V 109
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/AcTitleType.java
+END
+RequestedAttributeType.java
+K 25
+svn:wc:ra_dav:version-url
+V 120
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/RequestedAttributeType.java
+END
+HasDegreeType.java
+K 25
+svn:wc:ra_dav:version-url
+V 111
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/HasDegreeType.java
+END
+RepresentationPersonType.java
+K 25
+svn:wc:ra_dav:version-url
+V 122
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes/RepresentationPersonType.java
+END
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/entries b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/entries
new file mode 100644
index 000000000..434de60f8
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/entries
@@ -0,0 +1,708 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/main/java/eu/stork/peps/complex/attributes
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+IsHCPType.java
+file
+
+
+
+
+2014-03-05T09:36:07.898515Z
+c7794f438dce3f5e4e27e605a642a22a
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+3801
+
+IsAcademicStaffType.java
+file
+
+
+
+
+2014-03-05T09:36:07.898515Z
+43d67ea6cedb4601555d0394db95417a
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+3818
+
+HabilitationType.java
+file
+
+
+
+
+2014-03-05T09:36:07.898515Z
+6e9cc940cbe5298156c5e7b524936f11
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2314
+
+AttributeStatusType.java
+file
+
+
+
+
+2014-03-05T09:36:07.898515Z
+4e30a60177a9ab03aececf580482fad1
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+1734
+
+IsAdminStaffType.java
+file
+
+
+
+
+2014-03-05T09:36:07.898515Z
+5a49a39f1d260a3c306216069751260f
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2341
+
+MandateType.java
+file
+
+
+
+
+2014-03-05T09:36:07.898515Z
+2fbb38548efd320e4df27959a9842731
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+3581
+
+HasAccountInBankType.java
+file
+
+
+
+
+2014-03-05T09:36:07.894515Z
+f71b4c28dd5c9580fb87c3573435837b
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2339
+
+IsHealthCareProfessionalType.java
+file
+
+
+
+
+2014-03-05T09:36:07.894515Z
+2a4106ac8c87cc056b853b7f9ffb6fbc
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+3834
+
+package-info.java
+file
+
+
+
+
+2014-03-05T09:36:07.894515Z
+5a2f7df8040e53c9e0dc7beacc8f3457
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+549
+
+IsStudentType.java
+file
+
+
+
+
+2014-03-05T09:36:07.894515Z
+a576b2ef395482c49cb968e91e33ec89
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+3714
+
+AcTitleType.java
+file
+
+
+
+
+2014-03-05T09:36:07.894515Z
+df18729d7dbd509aeeac2f17ef036e19
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2388
+
+RequestedAttributeType.java
+file
+
+
+
+
+2014-03-05T09:36:07.894515Z
+c6ada26a7ff439713e9a4588d1b62b0a
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+6089
+
+HasDegreeType.java
+file
+
+
+
+
+2014-03-05T09:36:07.894515Z
+3a54a31f40c97b44d31f1a70e0767daa
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+4432
+
+RepresentationPersonType.java
+file
+
+
+
+
+2014-03-05T09:36:07.898515Z
+84b6c9432085cf590c3ed06e58b4307f
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+7205
+
+ObjectFactory.java
+file
+
+
+
+
+2014-03-05T09:36:07.898515Z
+bc36df4b11e93ab03119dfb25626bfb1
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+18679
+
+IsTeacherOfType.java
+file
+
+
+
+
+2014-03-05T09:36:07.898515Z
+1575bd6840471d713bd61c5d337d3900
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+3668
+
+CanonicalAddressType.java
+file
+
+
+
+
+2014-03-05T09:36:07.898515Z
+63bc0e23343775a0c252a03a5a3b09d1
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+6847
+
+IsCourseCoordinatorType.java
+file
+
+
+
+
+2014-03-05T09:36:07.898515Z
+9927ea145575d05bd2984bee0e3550be
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2423
+
+MandateContentType.java
+file
+
+
+
+
+2014-03-05T09:36:07.898515Z
+debc98ce374d669b7621dea674120dfc
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+6205
+
+Habilitation.java
+file
+
+
+
+
+2014-03-05T09:36:07.898515Z
+248b26e8c89ddc3366c528cf3852d27b
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2298
+
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/AcTitleType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/AcTitleType.java.svn-base
new file mode 100644
index 000000000..3c214cb7b
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/AcTitleType.java.svn-base
@@ -0,0 +1,89 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for acTitleType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="acTitleType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="titleNormalised" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}titleNormalisedType"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "acTitleType", propOrder = {
+ "titleNormalised",
+ "aqaa"
+})
+public class AcTitleType {
+
+ @XmlElement(required = true)
+ protected String titleNormalised;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the titleNormalised property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getTitleNormalised() {
+ return titleNormalised;
+ }
+
+ /**
+ * Sets the value of the titleNormalised property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setTitleNormalised(String value) {
+ this.titleNormalised = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/AttributeStatusType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/AttributeStatusType.java.svn-base
new file mode 100644
index 000000000..1a815e944
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/AttributeStatusType.java.svn-base
@@ -0,0 +1,61 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlEnum;
+import javax.xml.bind.annotation.XmlEnumValue;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for AttributeStatusType.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ * <p>
+ * <pre>
+ * &lt;simpleType name="AttributeStatusType">
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ * &lt;enumeration value="Available"/>
+ * &lt;enumeration value="NotAvailable"/>
+ * &lt;enumeration value="Withheld"/>
+ * &lt;/restriction>
+ * &lt;/simpleType>
+ * </pre>
+ *
+ */
+@XmlType(name = "AttributeStatusType")
+@XmlEnum
+public enum AttributeStatusType {
+
+ @XmlEnumValue("Available")
+ AVAILABLE("Available"),
+ @XmlEnumValue("NotAvailable")
+ NOT_AVAILABLE("NotAvailable"),
+ @XmlEnumValue("Withheld")
+ WITHHELD("Withheld");
+ private final String value;
+
+ AttributeStatusType(String v) {
+ value = v;
+ }
+
+ public String value() {
+ return value;
+ }
+
+ public static AttributeStatusType fromValue(String v) {
+ for (AttributeStatusType c: AttributeStatusType.values()) {
+ if (c.value.equals(v)) {
+ return c;
+ }
+ }
+ throw new IllegalArgumentException(v);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/CanonicalAddressType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/CanonicalAddressType.java.svn-base
new file mode 100644
index 000000000..fa0289cfa
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/CanonicalAddressType.java.svn-base
@@ -0,0 +1,264 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+
+
+/**
+ * <p>Java class for canonicalAddressType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="canonicalAddressType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="countryCodeAddress" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}CountryCodeType"/>
+ * &lt;element name="state" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ * &lt;element name="municipalityCode" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ * &lt;element name="town" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="postalCode" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="streetName" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="streetNumber" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ * &lt;element name="apartmentNumber" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "canonicalAddressType", propOrder = {
+ "countryCodeAddress",
+ "state",
+ "municipalityCode",
+ "town",
+ "postalCode",
+ "streetName",
+ "streetNumber",
+ "apartmentNumber"
+})
+public class CanonicalAddressType {
+
+ @XmlElement(required = true)
+ @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+ protected String countryCodeAddress;
+ protected String state;
+ protected String municipalityCode;
+ @XmlElement(required = true)
+ protected String town;
+ @XmlElement(required = true)
+ protected String postalCode;
+ @XmlElement(required = true)
+ protected String streetName;
+ protected String streetNumber;
+ protected String apartmentNumber;
+
+ /**
+ * Gets the value of the countryCodeAddress property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getCountryCodeAddress() {
+ return countryCodeAddress;
+ }
+
+ /**
+ * Sets the value of the countryCodeAddress property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setCountryCodeAddress(String value) {
+ this.countryCodeAddress = value;
+ }
+
+ /**
+ * Gets the value of the state property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getState() {
+ return state;
+ }
+
+ /**
+ * Sets the value of the state property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setState(String value) {
+ this.state = value;
+ }
+
+ /**
+ * Gets the value of the municipalityCode property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getMunicipalityCode() {
+ return municipalityCode;
+ }
+
+ /**
+ * Sets the value of the municipalityCode property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setMunicipalityCode(String value) {
+ this.municipalityCode = value;
+ }
+
+ /**
+ * Gets the value of the town property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getTown() {
+ return town;
+ }
+
+ /**
+ * Sets the value of the town property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setTown(String value) {
+ this.town = value;
+ }
+
+ /**
+ * Gets the value of the postalCode property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getPostalCode() {
+ return postalCode;
+ }
+
+ /**
+ * Sets the value of the postalCode property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setPostalCode(String value) {
+ this.postalCode = value;
+ }
+
+ /**
+ * Gets the value of the streetName property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getStreetName() {
+ return streetName;
+ }
+
+ /**
+ * Sets the value of the streetName property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setStreetName(String value) {
+ this.streetName = value;
+ }
+
+ /**
+ * Gets the value of the streetNumber property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getStreetNumber() {
+ return streetNumber;
+ }
+
+ /**
+ * Sets the value of the streetNumber property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setStreetNumber(String value) {
+ this.streetNumber = value;
+ }
+
+ /**
+ * Gets the value of the apartmentNumber property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getApartmentNumber() {
+ return apartmentNumber;
+ }
+
+ /**
+ * Sets the value of the apartmentNumber property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setApartmentNumber(String value) {
+ this.apartmentNumber = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/Habilitation.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/Habilitation.java.svn-base
new file mode 100644
index 000000000..3d99c9600
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/Habilitation.java.svn-base
@@ -0,0 +1,89 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for habilitation complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="habilitation">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="ability" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "habilitation", propOrder = {
+ "ability",
+ "aqaa"
+})
+public class Habilitation {
+
+ @XmlElement(required = true)
+ protected String ability;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the ability property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getAbility() {
+ return ability;
+ }
+
+ /**
+ * Sets the value of the ability property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setAbility(String value) {
+ this.ability = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/HabilitationType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/HabilitationType.java.svn-base
new file mode 100644
index 000000000..6a5cb7b00
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/HabilitationType.java.svn-base
@@ -0,0 +1,89 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for habilitationType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="habilitationType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="ability" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "habilitationType", propOrder = {
+ "ability",
+ "aqaa"
+})
+public class HabilitationType {
+
+ @XmlElement(required = true)
+ protected String ability;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the ability property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getAbility() {
+ return ability;
+ }
+
+ /**
+ * Sets the value of the ability property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setAbility(String value) {
+ this.ability = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/HasAccountInBankType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/HasAccountInBankType.java.svn-base
new file mode 100644
index 000000000..cc09f0486
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/HasAccountInBankType.java.svn-base
@@ -0,0 +1,89 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for hasAccountInBankType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="hasAccountInBankType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="bankName" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "hasAccountInBankType", propOrder = {
+ "bankName",
+ "aqaa"
+})
+public class HasAccountInBankType {
+
+ @XmlElement(required = true)
+ protected String bankName;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the bankName property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getBankName() {
+ return bankName;
+ }
+
+ /**
+ * Sets the value of the bankName property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setBankName(String value) {
+ this.bankName = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/HasDegreeType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/HasDegreeType.java.svn-base
new file mode 100644
index 000000000..ea466cb18
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/HasDegreeType.java.svn-base
@@ -0,0 +1,174 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import java.math.BigInteger;
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for hasDegreeType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="hasDegreeType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="study" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}studyType"/>
+ * &lt;element name="level" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}LevelType"/>
+ * &lt;element name="yearObtained" type="{http://www.w3.org/2001/XMLSchema}integer"/>
+ * &lt;element name="nameOfInstitution" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "hasDegreeType", propOrder = {
+ "study",
+ "level",
+ "yearObtained",
+ "nameOfInstitution",
+ "aqaa"
+})
+public class HasDegreeType {
+
+ @XmlElement(required = true)
+ protected String study;
+ @XmlElement(required = true)
+ protected String level;
+ @XmlElement(required = true)
+ protected BigInteger yearObtained;
+ @XmlElement(required = true)
+ protected String nameOfInstitution;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the study property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getStudy() {
+ return study;
+ }
+
+ /**
+ * Sets the value of the study property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setStudy(String value) {
+ this.study = value;
+ }
+
+ /**
+ * Gets the value of the level property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getLevel() {
+ return level;
+ }
+
+ /**
+ * Sets the value of the level property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setLevel(String value) {
+ this.level = value;
+ }
+
+ /**
+ * Gets the value of the yearObtained property.
+ *
+ * @return
+ * possible object is
+ * {@link BigInteger }
+ *
+ */
+ public BigInteger getYearObtained() {
+ return yearObtained;
+ }
+
+ /**
+ * Sets the value of the yearObtained property.
+ *
+ * @param value
+ * allowed object is
+ * {@link BigInteger }
+ *
+ */
+ public void setYearObtained(BigInteger value) {
+ this.yearObtained = value;
+ }
+
+ /**
+ * Gets the value of the nameOfInstitution property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getNameOfInstitution() {
+ return nameOfInstitution;
+ }
+
+ /**
+ * Sets the value of the nameOfInstitution property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setNameOfInstitution(String value) {
+ this.nameOfInstitution = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsAcademicStaffType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsAcademicStaffType.java.svn-base
new file mode 100644
index 000000000..02d9286d8
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsAcademicStaffType.java.svn-base
@@ -0,0 +1,145 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for isAcademicStaffType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="isAcademicStaffType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="nameOfInstitution" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="occupation" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}occupationType"/>
+ * &lt;element name="knowledgearea" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "isAcademicStaffType", propOrder = {
+ "nameOfInstitution",
+ "occupation",
+ "knowledgearea",
+ "aqaa"
+})
+public class IsAcademicStaffType {
+
+ @XmlElement(required = true)
+ protected String nameOfInstitution;
+ @XmlElement(required = true)
+ protected String occupation;
+ @XmlElement(required = true)
+ protected String knowledgearea;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the nameOfInstitution property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getNameOfInstitution() {
+ return nameOfInstitution;
+ }
+
+ /**
+ * Sets the value of the nameOfInstitution property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setNameOfInstitution(String value) {
+ this.nameOfInstitution = value;
+ }
+
+ /**
+ * Gets the value of the occupation property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getOccupation() {
+ return occupation;
+ }
+
+ /**
+ * Sets the value of the occupation property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setOccupation(String value) {
+ this.occupation = value;
+ }
+
+ /**
+ * Gets the value of the knowledgearea property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getKnowledgearea() {
+ return knowledgearea;
+ }
+
+ /**
+ * Sets the value of the knowledgearea property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setKnowledgearea(String value) {
+ this.knowledgearea = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsAdminStaffType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsAdminStaffType.java.svn-base
new file mode 100644
index 000000000..0de16ee77
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsAdminStaffType.java.svn-base
@@ -0,0 +1,89 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for isAdminStaffType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="isAdminStaffType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="adminStaff" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "isAdminStaffType", propOrder = {
+ "adminStaff",
+ "aqaa"
+})
+public class IsAdminStaffType {
+
+ @XmlElement(required = true)
+ protected String adminStaff;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the adminStaff property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getAdminStaff() {
+ return adminStaff;
+ }
+
+ /**
+ * Sets the value of the adminStaff property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setAdminStaff(String value) {
+ this.adminStaff = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsCourseCoordinatorType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsCourseCoordinatorType.java.svn-base
new file mode 100644
index 000000000..58caa2f22
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsCourseCoordinatorType.java.svn-base
@@ -0,0 +1,89 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for isCourseCoordinatorType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="isCourseCoordinatorType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="courseCoodinator" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "isCourseCoordinatorType", propOrder = {
+ "courseCoodinator",
+ "aqaa"
+})
+public class IsCourseCoordinatorType {
+
+ @XmlElement(required = true)
+ protected String courseCoodinator;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the courseCoodinator property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getCourseCoodinator() {
+ return courseCoodinator;
+ }
+
+ /**
+ * Sets the value of the courseCoodinator property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setCourseCoodinator(String value) {
+ this.courseCoodinator = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsHCPType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsHCPType.java.svn-base
new file mode 100644
index 000000000..17e315d2d
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsHCPType.java.svn-base
@@ -0,0 +1,145 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for isHCPType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="isHCPType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="nameOfOrganisation" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="HCPType" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}HCPType"/>
+ * &lt;element name="specialisation" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}specialisationType"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "isHCPType", propOrder = {
+ "nameOfOrganisation",
+ "hcpType",
+ "specialisation",
+ "aqaa"
+})
+public class IsHCPType {
+
+ @XmlElement(required = true)
+ protected String nameOfOrganisation;
+ @XmlElement(name = "HCPType", required = true)
+ protected String hcpType;
+ @XmlElement(required = true)
+ protected String specialisation;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the nameOfOrganisation property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getNameOfOrganisation() {
+ return nameOfOrganisation;
+ }
+
+ /**
+ * Sets the value of the nameOfOrganisation property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setNameOfOrganisation(String value) {
+ this.nameOfOrganisation = value;
+ }
+
+ /**
+ * Gets the value of the hcpType property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getHCPType() {
+ return hcpType;
+ }
+
+ /**
+ * Sets the value of the hcpType property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setHCPType(String value) {
+ this.hcpType = value;
+ }
+
+ /**
+ * Gets the value of the specialisation property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getSpecialisation() {
+ return specialisation;
+ }
+
+ /**
+ * Sets the value of the specialisation property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setSpecialisation(String value) {
+ this.specialisation = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsHealthCareProfessionalType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsHealthCareProfessionalType.java.svn-base
new file mode 100644
index 000000000..de2003a3f
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsHealthCareProfessionalType.java.svn-base
@@ -0,0 +1,145 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for isHealthCareProfessionalType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="isHealthCareProfessionalType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="nameOfOrganisation" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element ref="{urn:eu:stork:names:tc:STORK:1.0:assertion}HCPType"/>
+ * &lt;element ref="{urn:eu:stork:names:tc:STORK:1.0:assertion}specialisation"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "isHealthCareProfessionalType", propOrder = {
+ "nameOfOrganisation",
+ "hcpType",
+ "specialisation",
+ "aqaa"
+})
+public class IsHealthCareProfessionalType {
+
+ @XmlElement(required = true)
+ protected String nameOfOrganisation;
+ @XmlElement(name = "HCPType", required = true)
+ protected String hcpType;
+ @XmlElement(required = true)
+ protected String specialisation;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the nameOfOrganisation property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getNameOfOrganisation() {
+ return nameOfOrganisation;
+ }
+
+ /**
+ * Sets the value of the nameOfOrganisation property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setNameOfOrganisation(String value) {
+ this.nameOfOrganisation = value;
+ }
+
+ /**
+ * Gets the value of the hcpType property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getHCPType() {
+ return hcpType;
+ }
+
+ /**
+ * Sets the value of the hcpType property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setHCPType(String value) {
+ this.hcpType = value;
+ }
+
+ /**
+ * Gets the value of the specialisation property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getSpecialisation() {
+ return specialisation;
+ }
+
+ /**
+ * Sets the value of the specialisation property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setSpecialisation(String value) {
+ this.specialisation = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsStudentType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsStudentType.java.svn-base
new file mode 100644
index 000000000..6a7dc838a
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsStudentType.java.svn-base
@@ -0,0 +1,146 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import java.math.BigInteger;
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for isStudentType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="isStudentType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element ref="{urn:eu:stork:names:tc:STORK:1.0:assertion}study"/>
+ * &lt;element name="nameOfInstitution" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="course" type="{http://www.w3.org/2001/XMLSchema}integer"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "isStudentType", propOrder = {
+ "study",
+ "nameOfInstitution",
+ "course",
+ "aqaa"
+})
+public class IsStudentType {
+
+ @XmlElement(required = true)
+ protected String study;
+ @XmlElement(required = true)
+ protected String nameOfInstitution;
+ @XmlElement(required = true)
+ protected BigInteger course;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the study property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getStudy() {
+ return study;
+ }
+
+ /**
+ * Sets the value of the study property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setStudy(String value) {
+ this.study = value;
+ }
+
+ /**
+ * Gets the value of the nameOfInstitution property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getNameOfInstitution() {
+ return nameOfInstitution;
+ }
+
+ /**
+ * Sets the value of the nameOfInstitution property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setNameOfInstitution(String value) {
+ this.nameOfInstitution = value;
+ }
+
+ /**
+ * Gets the value of the course property.
+ *
+ * @return
+ * possible object is
+ * {@link BigInteger }
+ *
+ */
+ public BigInteger getCourse() {
+ return course;
+ }
+
+ /**
+ * Sets the value of the course property.
+ *
+ * @param value
+ * allowed object is
+ * {@link BigInteger }
+ *
+ */
+ public void setCourse(BigInteger value) {
+ this.course = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsTeacherOfType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsTeacherOfType.java.svn-base
new file mode 100644
index 000000000..810f652c1
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/IsTeacherOfType.java.svn-base
@@ -0,0 +1,145 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for isTeacherOfType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="isTeacherOfType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="nameOfInstitution" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="course" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="role" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "isTeacherOfType", propOrder = {
+ "nameOfInstitution",
+ "course",
+ "role",
+ "aqaa"
+})
+public class IsTeacherOfType {
+
+ @XmlElement(required = true)
+ protected String nameOfInstitution;
+ @XmlElement(required = true)
+ protected String course;
+ @XmlElement(required = true)
+ protected String role;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the nameOfInstitution property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getNameOfInstitution() {
+ return nameOfInstitution;
+ }
+
+ /**
+ * Sets the value of the nameOfInstitution property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setNameOfInstitution(String value) {
+ this.nameOfInstitution = value;
+ }
+
+ /**
+ * Gets the value of the course property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getCourse() {
+ return course;
+ }
+
+ /**
+ * Sets the value of the course property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setCourse(String value) {
+ this.course = value;
+ }
+
+ /**
+ * Gets the value of the role property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getRole() {
+ return role;
+ }
+
+ /**
+ * Sets the value of the role property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setRole(String value) {
+ this.role = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/MandateContentType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/MandateContentType.java.svn-base
new file mode 100644
index 000000000..84ce2727b
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/MandateContentType.java.svn-base
@@ -0,0 +1,233 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import java.math.BigInteger;
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlSchemaType;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.datatype.XMLGregorianCalendar;
+
+
+/**
+ * <p>Java class for mandateContentType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="mandateContentType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="validFrom" type="{http://www.w3.org/2001/XMLSchema}date"/>
+ * &lt;element name="validTo" type="{http://www.w3.org/2001/XMLSchema}date"/>
+ * &lt;element name="transactionLimit" type="{http://www.w3.org/2001/XMLSchema}integer"/>
+ * &lt;element name="transactionLimitCurrency" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}currencyType"/>
+ * &lt;element name="isJoint" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="ischained" type="{http://www.w3.org/2001/XMLSchema}boolean"/>
+ * &lt;element name="typePower" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "mandateContentType", propOrder = {
+ "validFrom",
+ "validTo",
+ "transactionLimit",
+ "transactionLimitCurrency",
+ "isJoint",
+ "ischained",
+ "typePower"
+})
+public class MandateContentType {
+
+ @XmlElement(required = true)
+ @XmlSchemaType(name = "date")
+ protected XMLGregorianCalendar validFrom;
+ @XmlElement(required = true)
+ @XmlSchemaType(name = "date")
+ protected XMLGregorianCalendar validTo;
+ @XmlElement(required = true)
+ protected BigInteger transactionLimit;
+ @XmlElement(required = true)
+ protected String transactionLimitCurrency;
+ @XmlElement(required = true)
+ protected String isJoint;
+ protected boolean ischained;
+ @XmlElement(required = true)
+ protected String typePower;
+
+ /**
+ * Gets the value of the validFrom property.
+ *
+ * @return
+ * possible object is
+ * {@link XMLGregorianCalendar }
+ *
+ */
+ public XMLGregorianCalendar getValidFrom() {
+ return validFrom;
+ }
+
+ /**
+ * Sets the value of the validFrom property.
+ *
+ * @param value
+ * allowed object is
+ * {@link XMLGregorianCalendar }
+ *
+ */
+ public void setValidFrom(XMLGregorianCalendar value) {
+ this.validFrom = value;
+ }
+
+ /**
+ * Gets the value of the validTo property.
+ *
+ * @return
+ * possible object is
+ * {@link XMLGregorianCalendar }
+ *
+ */
+ public XMLGregorianCalendar getValidTo() {
+ return validTo;
+ }
+
+ /**
+ * Sets the value of the validTo property.
+ *
+ * @param value
+ * allowed object is
+ * {@link XMLGregorianCalendar }
+ *
+ */
+ public void setValidTo(XMLGregorianCalendar value) {
+ this.validTo = value;
+ }
+
+ /**
+ * Gets the value of the transactionLimit property.
+ *
+ * @return
+ * possible object is
+ * {@link BigInteger }
+ *
+ */
+ public BigInteger getTransactionLimit() {
+ return transactionLimit;
+ }
+
+ /**
+ * Sets the value of the transactionLimit property.
+ *
+ * @param value
+ * allowed object is
+ * {@link BigInteger }
+ *
+ */
+ public void setTransactionLimit(BigInteger value) {
+ this.transactionLimit = value;
+ }
+
+ /**
+ * Gets the value of the transactionLimitCurrency property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getTransactionLimitCurrency() {
+ return transactionLimitCurrency;
+ }
+
+ /**
+ * Sets the value of the transactionLimitCurrency property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setTransactionLimitCurrency(String value) {
+ this.transactionLimitCurrency = value;
+ }
+
+ /**
+ * Gets the value of the isJoint property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getIsJoint() {
+ return isJoint;
+ }
+
+ /**
+ * Sets the value of the isJoint property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setIsJoint(String value) {
+ this.isJoint = value;
+ }
+
+ /**
+ * Gets the value of the ischained property.
+ *
+ */
+ public boolean isIschained() {
+ return ischained;
+ }
+
+ /**
+ * Sets the value of the ischained property.
+ *
+ */
+ public void setIschained(boolean value) {
+ this.ischained = value;
+ }
+
+ /**
+ * Gets the value of the typePower property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getTypePower() {
+ return typePower;
+ }
+
+ /**
+ * Sets the value of the typePower property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setTypePower(String value) {
+ this.typePower = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/MandateType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/MandateType.java.svn-base
new file mode 100644
index 000000000..26597dc6b
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/MandateType.java.svn-base
@@ -0,0 +1,125 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for mandateType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="mandateType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="represented" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}representationPersonType"/>
+ * &lt;element name="representing" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}representationPersonType"/>
+ * &lt;element name="mandateContent" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}mandateContentType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "mandateType", propOrder = {
+ "represented",
+ "representing",
+ "mandateContent"
+})
+public class MandateType {
+
+ @XmlElement(required = true)
+ protected RepresentationPersonType represented;
+ @XmlElement(required = true)
+ protected RepresentationPersonType representing;
+ @XmlElement(required = true)
+ protected MandateContentType mandateContent;
+
+ /**
+ * Gets the value of the represented property.
+ *
+ * @return
+ * possible object is
+ * {@link RepresentationPersonType }
+ *
+ */
+ public RepresentationPersonType getRepresented() {
+ return represented;
+ }
+
+ /**
+ * Sets the value of the represented property.
+ *
+ * @param value
+ * allowed object is
+ * {@link RepresentationPersonType }
+ *
+ */
+ public void setRepresented(RepresentationPersonType value) {
+ this.represented = value;
+ }
+
+ /**
+ * Gets the value of the representing property.
+ *
+ * @return
+ * possible object is
+ * {@link RepresentationPersonType }
+ *
+ */
+ public RepresentationPersonType getRepresenting() {
+ return representing;
+ }
+
+ /**
+ * Sets the value of the representing property.
+ *
+ * @param value
+ * allowed object is
+ * {@link RepresentationPersonType }
+ *
+ */
+ public void setRepresenting(RepresentationPersonType value) {
+ this.representing = value;
+ }
+
+ /**
+ * Gets the value of the mandateContent property.
+ *
+ * @return
+ * possible object is
+ * {@link MandateContentType }
+ *
+ */
+ public MandateContentType getMandateContent() {
+ return mandateContent;
+ }
+
+ /**
+ * Sets the value of the mandateContent property.
+ *
+ * @param value
+ * allowed object is
+ * {@link MandateContentType }
+ *
+ */
+ public void setMandateContent(MandateContentType value) {
+ this.mandateContent = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/ObjectFactory.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/ObjectFactory.java.svn-base
new file mode 100644
index 000000000..eca4ca3de
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/ObjectFactory.java.svn-base
@@ -0,0 +1,433 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.JAXBElement;
+import javax.xml.bind.annotation.XmlElementDecl;
+import javax.xml.bind.annotation.XmlRegistry;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+import javax.xml.namespace.QName;
+
+
+/**
+ * This object contains factory methods for each
+ * Java content interface and Java element interface
+ * generated in the eu.stork.peps.complex.attributes package.
+ * <p>An ObjectFactory allows you to programatically
+ * construct new instances of the Java representation
+ * for XML content. The Java representation of XML
+ * content can consist of schema derived interfaces
+ * and classes representing the binding of schema
+ * type definitions, element declarations and model
+ * groups. Factory methods for each of these are
+ * provided in this class.
+ *
+ */
+@XmlRegistry
+public class ObjectFactory {
+
+ private final static QName _Habilitation_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "habilitation");
+ private final static QName _HasDegree_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "hasDegree");
+ private final static QName _SpApplication_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "spApplication");
+ private final static QName _Specialisation_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "specialisation");
+ private final static QName _IsStudent_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "isStudent");
+ private final static QName _AQAA_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "AQAA");
+ private final static QName _HCPType_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "HCPType");
+ private final static QName _CanonicalResidenceAddress_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "canonicalResidenceAddress");
+ private final static QName _AcTitle_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "acTitle");
+ private final static QName _QualityAuthenticationAssuranceLevel_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "QualityAuthenticationAssuranceLevel");
+ private final static QName _IsAcademicStaff_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "isAcademicStaff");
+ private final static QName _IsTeacherOf_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "isTeacherOf");
+ private final static QName _IsCourseCoordinator_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "isCourseCoordinator");
+ private final static QName _CanonicalRegisteredAddress_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "canonicalRegisteredAddress");
+ private final static QName _SpCountry_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "spCountry");
+ private final static QName _IsAdminStaff_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "isAdminStaff");
+ private final static QName _CitizenCountryCode_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "CitizenCountryCode");
+ private final static QName _AttributeValue_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "AttributeValue");
+ private final static QName _HasAccountInBank_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "hasAccountInBank");
+ private final static QName _CountryCodeAddress_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "countryCodeAddress");
+ private final static QName _Study_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "study");
+ private final static QName _IsHealthCareProfessional_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "isHealthCareProfessional");
+ private final static QName _Mandate_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "mandate");
+ private final static QName _RequestedAttribute_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "RequestedAttribute");
+ private final static QName _SpSector_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "spSector");
+
+ /**
+ * Create a new ObjectFactory that can be used to create new instances of schema derived classes for package: eu.stork.peps.complex.attributes
+ *
+ */
+ public ObjectFactory() {
+ }
+
+ /**
+ * Create an instance of {@link RequestedAttributeType }
+ *
+ */
+ public RequestedAttributeType createRequestedAttributeType() {
+ return new RequestedAttributeType();
+ }
+
+ /**
+ * Create an instance of {@link MandateType }
+ *
+ */
+ public MandateType createMandateType() {
+ return new MandateType();
+ }
+
+ /**
+ * Create an instance of {@link HasAccountInBankType }
+ *
+ */
+ public HasAccountInBankType createHasAccountInBankType() {
+ return new HasAccountInBankType();
+ }
+
+ /**
+ * Create an instance of {@link IsHealthCareProfessionalType }
+ *
+ */
+ public IsHealthCareProfessionalType createIsHealthCareProfessionalType() {
+ return new IsHealthCareProfessionalType();
+ }
+
+ /**
+ * Create an instance of {@link IsAdminStaffType }
+ *
+ */
+ public IsAdminStaffType createIsAdminStaffType() {
+ return new IsAdminStaffType();
+ }
+
+ /**
+ * Create an instance of {@link CanonicalAddressType }
+ *
+ */
+ public CanonicalAddressType createCanonicalAddressType() {
+ return new CanonicalAddressType();
+ }
+
+ /**
+ * Create an instance of {@link IsCourseCoordinatorType }
+ *
+ */
+ public IsCourseCoordinatorType createIsCourseCoordinatorType() {
+ return new IsCourseCoordinatorType();
+ }
+
+ /**
+ * Create an instance of {@link IsAcademicStaffType }
+ *
+ */
+ public IsAcademicStaffType createIsAcademicStaffType() {
+ return new IsAcademicStaffType();
+ }
+
+ /**
+ * Create an instance of {@link IsTeacherOfType }
+ *
+ */
+ public IsTeacherOfType createIsTeacherOfType() {
+ return new IsTeacherOfType();
+ }
+
+ /**
+ * Create an instance of {@link AcTitleType }
+ *
+ */
+ public AcTitleType createAcTitleType() {
+ return new AcTitleType();
+ }
+
+ /**
+ * Create an instance of {@link IsStudentType }
+ *
+ */
+ public IsStudentType createIsStudentType() {
+ return new IsStudentType();
+ }
+
+ /**
+ * Create an instance of {@link HasDegreeType }
+ *
+ */
+ public HasDegreeType createHasDegreeType() {
+ return new HasDegreeType();
+ }
+
+ /**
+ * Create an instance of {@link HabilitationType }
+ *
+ */
+ public HabilitationType createHabilitationType() {
+ return new HabilitationType();
+ }
+
+ /**
+ * Create an instance of {@link MandateContentType }
+ *
+ */
+ public MandateContentType createMandateContentType() {
+ return new MandateContentType();
+ }
+
+ /**
+ * Create an instance of {@link RepresentationPersonType }
+ *
+ */
+ public RepresentationPersonType createRepresentationPersonType() {
+ return new RepresentationPersonType();
+ }
+
+ /**
+ * Create an instance of {@link Habilitation }
+ *
+ */
+ public Habilitation createHabilitation() {
+ return new Habilitation();
+ }
+
+ /**
+ * Create an instance of {@link IsHCPType }
+ *
+ */
+ public IsHCPType createIsHCPType() {
+ return new IsHCPType();
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link HabilitationType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "habilitation")
+ public JAXBElement<HabilitationType> createHabilitation(HabilitationType value) {
+ return new JAXBElement<HabilitationType>(_Habilitation_QNAME, HabilitationType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link HasDegreeType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "hasDegree")
+ public JAXBElement<HasDegreeType> createHasDegree(HasDegreeType value) {
+ return new JAXBElement<HasDegreeType>(_HasDegree_QNAME, HasDegreeType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "spApplication")
+ public JAXBElement<String> createSpApplication(String value) {
+ return new JAXBElement<String>(_SpApplication_QNAME, String.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "specialisation")
+ public JAXBElement<String> createSpecialisation(String value) {
+ return new JAXBElement<String>(_Specialisation_QNAME, String.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link IsStudentType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "isStudent")
+ public JAXBElement<IsStudentType> createIsStudent(IsStudentType value) {
+ return new JAXBElement<IsStudentType>(_IsStudent_QNAME, IsStudentType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link Integer }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "AQAA")
+ public JAXBElement<Integer> createAQAA(Integer value) {
+ return new JAXBElement<Integer>(_AQAA_QNAME, Integer.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "HCPType")
+ public JAXBElement<String> createHCPType(String value) {
+ return new JAXBElement<String>(_HCPType_QNAME, String.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link CanonicalAddressType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "canonicalResidenceAddress")
+ public JAXBElement<CanonicalAddressType> createCanonicalResidenceAddress(CanonicalAddressType value) {
+ return new JAXBElement<CanonicalAddressType>(_CanonicalResidenceAddress_QNAME, CanonicalAddressType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link AcTitleType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "acTitle")
+ public JAXBElement<AcTitleType> createAcTitle(AcTitleType value) {
+ return new JAXBElement<AcTitleType>(_AcTitle_QNAME, AcTitleType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link Integer }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "QualityAuthenticationAssuranceLevel")
+ public JAXBElement<Integer> createQualityAuthenticationAssuranceLevel(Integer value) {
+ return new JAXBElement<Integer>(_QualityAuthenticationAssuranceLevel_QNAME, Integer.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link IsAcademicStaffType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "isAcademicStaff")
+ public JAXBElement<IsAcademicStaffType> createIsAcademicStaff(IsAcademicStaffType value) {
+ return new JAXBElement<IsAcademicStaffType>(_IsAcademicStaff_QNAME, IsAcademicStaffType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link IsTeacherOfType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "isTeacherOf")
+ public JAXBElement<IsTeacherOfType> createIsTeacherOf(IsTeacherOfType value) {
+ return new JAXBElement<IsTeacherOfType>(_IsTeacherOf_QNAME, IsTeacherOfType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link IsCourseCoordinatorType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "isCourseCoordinator")
+ public JAXBElement<IsCourseCoordinatorType> createIsCourseCoordinator(IsCourseCoordinatorType value) {
+ return new JAXBElement<IsCourseCoordinatorType>(_IsCourseCoordinator_QNAME, IsCourseCoordinatorType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link CanonicalAddressType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "canonicalRegisteredAddress")
+ public JAXBElement<CanonicalAddressType> createCanonicalRegisteredAddress(CanonicalAddressType value) {
+ return new JAXBElement<CanonicalAddressType>(_CanonicalRegisteredAddress_QNAME, CanonicalAddressType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "spCountry")
+ @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+ public JAXBElement<String> createSpCountry(String value) {
+ return new JAXBElement<String>(_SpCountry_QNAME, String.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link IsAdminStaffType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "isAdminStaff")
+ public JAXBElement<IsAdminStaffType> createIsAdminStaff(IsAdminStaffType value) {
+ return new JAXBElement<IsAdminStaffType>(_IsAdminStaff_QNAME, IsAdminStaffType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "CitizenCountryCode")
+ @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+ public JAXBElement<String> createCitizenCountryCode(String value) {
+ return new JAXBElement<String>(_CitizenCountryCode_QNAME, String.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link Object }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "AttributeValue")
+ public JAXBElement<Object> createAttributeValue(Object value) {
+ return new JAXBElement<Object>(_AttributeValue_QNAME, Object.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link HasAccountInBankType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "hasAccountInBank")
+ public JAXBElement<HasAccountInBankType> createHasAccountInBank(HasAccountInBankType value) {
+ return new JAXBElement<HasAccountInBankType>(_HasAccountInBank_QNAME, HasAccountInBankType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "countryCodeAddress")
+ @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+ public JAXBElement<String> createCountryCodeAddress(String value) {
+ return new JAXBElement<String>(_CountryCodeAddress_QNAME, String.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "study")
+ public JAXBElement<String> createStudy(String value) {
+ return new JAXBElement<String>(_Study_QNAME, String.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link IsHealthCareProfessionalType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "isHealthCareProfessional")
+ public JAXBElement<IsHealthCareProfessionalType> createIsHealthCareProfessional(IsHealthCareProfessionalType value) {
+ return new JAXBElement<IsHealthCareProfessionalType>(_IsHealthCareProfessional_QNAME, IsHealthCareProfessionalType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link MandateType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "mandate")
+ public JAXBElement<MandateType> createMandate(MandateType value) {
+ return new JAXBElement<MandateType>(_Mandate_QNAME, MandateType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link RequestedAttributeType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "RequestedAttribute")
+ public JAXBElement<RequestedAttributeType> createRequestedAttribute(RequestedAttributeType value) {
+ return new JAXBElement<RequestedAttributeType>(_RequestedAttribute_QNAME, RequestedAttributeType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "spSector")
+ public JAXBElement<String> createSpSector(String value) {
+ return new JAXBElement<String>(_SpSector_QNAME, String.class, null, value);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/RepresentationPersonType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/RepresentationPersonType.java.svn-base
new file mode 100644
index 000000000..b1d993f89
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/RepresentationPersonType.java.svn-base
@@ -0,0 +1,289 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for representationPersonType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="representationPersonType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;choice>
+ * &lt;sequence>
+ * &lt;element name="eIdentifier" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="givenName" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="surname" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="dateOfBirth" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;/sequence>
+ * &lt;sequence>
+ * &lt;element name="eLPIdentifier" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="name" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="address" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="canonicalAddress" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}canonicalAddressType"/>
+ * &lt;element name="type" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;/sequence>
+ * &lt;/choice>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "representationPersonType", propOrder = {
+ "eIdentifier",
+ "givenName",
+ "surname",
+ "dateOfBirth",
+ "elpIdentifier",
+ "name",
+ "address",
+ "canonicalAddress",
+ "type"
+})
+public class RepresentationPersonType {
+
+ protected String eIdentifier;
+ protected String givenName;
+ protected String surname;
+ protected String dateOfBirth;
+ @XmlElement(name = "eLPIdentifier")
+ protected String elpIdentifier;
+ protected String name;
+ protected String address;
+ protected CanonicalAddressType canonicalAddress;
+ protected String type;
+
+ /**
+ * Gets the value of the eIdentifier property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getEIdentifier() {
+ return eIdentifier;
+ }
+
+ /**
+ * Sets the value of the eIdentifier property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setEIdentifier(String value) {
+ this.eIdentifier = value;
+ }
+
+ /**
+ * Gets the value of the givenName property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getGivenName() {
+ return givenName;
+ }
+
+ /**
+ * Sets the value of the givenName property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setGivenName(String value) {
+ this.givenName = value;
+ }
+
+ /**
+ * Gets the value of the surname property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getSurname() {
+ return surname;
+ }
+
+ /**
+ * Sets the value of the surname property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setSurname(String value) {
+ this.surname = value;
+ }
+
+ /**
+ * Gets the value of the dateOfBirth property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getDateOfBirth() {
+ return dateOfBirth;
+ }
+
+ /**
+ * Sets the value of the dateOfBirth property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setDateOfBirth(String value) {
+ this.dateOfBirth = value;
+ }
+
+ /**
+ * Gets the value of the elpIdentifier property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getELPIdentifier() {
+ return elpIdentifier;
+ }
+
+ /**
+ * Sets the value of the elpIdentifier property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setELPIdentifier(String value) {
+ this.elpIdentifier = value;
+ }
+
+ /**
+ * Gets the value of the name property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getName() {
+ return name;
+ }
+
+ /**
+ * Sets the value of the name property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setName(String value) {
+ this.name = value;
+ }
+
+ /**
+ * Gets the value of the address property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getAddress() {
+ return address;
+ }
+
+ /**
+ * Sets the value of the address property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setAddress(String value) {
+ this.address = value;
+ }
+
+ /**
+ * Gets the value of the canonicalAddress property.
+ *
+ * @return
+ * possible object is
+ * {@link CanonicalAddressType }
+ *
+ */
+ public CanonicalAddressType getCanonicalAddress() {
+ return canonicalAddress;
+ }
+
+ /**
+ * Sets the value of the canonicalAddress property.
+ *
+ * @param value
+ * allowed object is
+ * {@link CanonicalAddressType }
+ *
+ */
+ public void setCanonicalAddress(CanonicalAddressType value) {
+ this.canonicalAddress = value;
+ }
+
+ /**
+ * Gets the value of the type property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getType() {
+ return type;
+ }
+
+ /**
+ * Sets the value of the type property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setType(String value) {
+ this.type = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/RequestedAttributeType.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/RequestedAttributeType.java.svn-base
new file mode 100644
index 000000000..6a7c0b443
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/RequestedAttributeType.java.svn-base
@@ -0,0 +1,212 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAnyAttribute;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlSchemaType;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.namespace.QName;
+
+
+/**
+ * <p>Java class for RequestedAttributeType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="RequestedAttributeType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element ref="{urn:eu:stork:names:tc:STORK:1.0:assertion}AttributeValue" maxOccurs="unbounded" minOccurs="0"/>
+ * &lt;/sequence>
+ * &lt;attribute name="Name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ * &lt;attribute name="NameFormat" use="required" type="{http://www.w3.org/2001/XMLSchema}anyURI" />
+ * &lt;attribute name="FriendlyName" type="{http://www.w3.org/2001/XMLSchema}string" />
+ * &lt;attribute name="isRequired" type="{http://www.w3.org/2001/XMLSchema}boolean" />
+ * &lt;anyAttribute processContents='lax' namespace='##other'/>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "RequestedAttributeType", propOrder = {
+ "attributeValue"
+})
+public class RequestedAttributeType {
+
+ @XmlElement(name = "AttributeValue")
+ protected List<Object> attributeValue;
+ @XmlAttribute(name = "Name", required = true)
+ protected String name;
+ @XmlAttribute(name = "NameFormat", required = true)
+ @XmlSchemaType(name = "anyURI")
+ protected String nameFormat;
+ @XmlAttribute(name = "FriendlyName")
+ protected String friendlyName;
+ @XmlAttribute(name = "isRequired")
+ protected Boolean isRequired;
+ @XmlAnyAttribute
+ private Map<QName, String> otherAttributes = new HashMap<QName, String>();
+
+ /**
+ * Gets the value of the attributeValue property.
+ *
+ * <p>
+ * This accessor method returns a reference to the live list,
+ * not a snapshot. Therefore any modification you make to the
+ * returned list will be present inside the JAXB object.
+ * This is why there is not a <CODE>set</CODE> method for the attributeValue property.
+ *
+ * <p>
+ * For example, to add a new item, do as follows:
+ * <pre>
+ * getAttributeValue().add(newItem);
+ * </pre>
+ *
+ *
+ * <p>
+ * Objects of the following type(s) are allowed in the list
+ * {@link Object }
+ *
+ *
+ */
+ public List<Object> getAttributeValue() {
+ if (attributeValue == null) {
+ attributeValue = new ArrayList<Object>();
+ }
+ return this.attributeValue;
+ }
+
+ /**
+ * Gets the value of the name property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getName() {
+ return name;
+ }
+
+ /**
+ * Sets the value of the name property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setName(String value) {
+ this.name = value;
+ }
+
+ /**
+ * Gets the value of the nameFormat property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getNameFormat() {
+ return nameFormat;
+ }
+
+ /**
+ * Sets the value of the nameFormat property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setNameFormat(String value) {
+ this.nameFormat = value;
+ }
+
+ /**
+ * Gets the value of the friendlyName property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getFriendlyName() {
+ return friendlyName;
+ }
+
+ /**
+ * Sets the value of the friendlyName property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setFriendlyName(String value) {
+ this.friendlyName = value;
+ }
+
+ /**
+ * Gets the value of the isRequired property.
+ *
+ * @return
+ * possible object is
+ * {@link Boolean }
+ *
+ */
+ public Boolean isIsRequired() {
+ return isRequired;
+ }
+
+ /**
+ * Sets the value of the isRequired property.
+ *
+ * @param value
+ * allowed object is
+ * {@link Boolean }
+ *
+ */
+ public void setIsRequired(Boolean value) {
+ this.isRequired = value;
+ }
+
+ /**
+ * Gets a map that contains attributes that aren't bound to any typed property on this class.
+ *
+ * <p>
+ * the map is keyed by the name of the attribute and
+ * the value is the string value of the attribute.
+ *
+ * the map returned by this method is live, and you can add new attribute
+ * by updating the map directly. Because of this design, there's no setter.
+ *
+ *
+ * @return
+ * always non-null
+ */
+ public Map<QName, String> getOtherAttributes() {
+ return otherAttributes;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/package-info.java.svn-base b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/package-info.java.svn-base
new file mode 100644
index 000000000..47e225d22
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/.svn/text-base/package-info.java.svn-base
@@ -0,0 +1,9 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+@javax.xml.bind.annotation.XmlSchema(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", elementFormDefault = javax.xml.bind.annotation.XmlNsForm.QUALIFIED)
+package eu.stork.peps.complex.attributes;
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/AcTitleType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/AcTitleType.java
new file mode 100644
index 000000000..3c214cb7b
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/AcTitleType.java
@@ -0,0 +1,89 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for acTitleType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="acTitleType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="titleNormalised" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}titleNormalisedType"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "acTitleType", propOrder = {
+ "titleNormalised",
+ "aqaa"
+})
+public class AcTitleType {
+
+ @XmlElement(required = true)
+ protected String titleNormalised;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the titleNormalised property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getTitleNormalised() {
+ return titleNormalised;
+ }
+
+ /**
+ * Sets the value of the titleNormalised property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setTitleNormalised(String value) {
+ this.titleNormalised = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/AttributeStatusType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/AttributeStatusType.java
new file mode 100644
index 000000000..1a815e944
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/AttributeStatusType.java
@@ -0,0 +1,61 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlEnum;
+import javax.xml.bind.annotation.XmlEnumValue;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for AttributeStatusType.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ * <p>
+ * <pre>
+ * &lt;simpleType name="AttributeStatusType">
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}string">
+ * &lt;enumeration value="Available"/>
+ * &lt;enumeration value="NotAvailable"/>
+ * &lt;enumeration value="Withheld"/>
+ * &lt;/restriction>
+ * &lt;/simpleType>
+ * </pre>
+ *
+ */
+@XmlType(name = "AttributeStatusType")
+@XmlEnum
+public enum AttributeStatusType {
+
+ @XmlEnumValue("Available")
+ AVAILABLE("Available"),
+ @XmlEnumValue("NotAvailable")
+ NOT_AVAILABLE("NotAvailable"),
+ @XmlEnumValue("Withheld")
+ WITHHELD("Withheld");
+ private final String value;
+
+ AttributeStatusType(String v) {
+ value = v;
+ }
+
+ public String value() {
+ return value;
+ }
+
+ public static AttributeStatusType fromValue(String v) {
+ for (AttributeStatusType c: AttributeStatusType.values()) {
+ if (c.value.equals(v)) {
+ return c;
+ }
+ }
+ throw new IllegalArgumentException(v);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/CanonicalAddressType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/CanonicalAddressType.java
new file mode 100644
index 000000000..fa0289cfa
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/CanonicalAddressType.java
@@ -0,0 +1,264 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+
+
+/**
+ * <p>Java class for canonicalAddressType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="canonicalAddressType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="countryCodeAddress" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}CountryCodeType"/>
+ * &lt;element name="state" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ * &lt;element name="municipalityCode" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ * &lt;element name="town" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="postalCode" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="streetName" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="streetNumber" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ * &lt;element name="apartmentNumber" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "canonicalAddressType", propOrder = {
+ "countryCodeAddress",
+ "state",
+ "municipalityCode",
+ "town",
+ "postalCode",
+ "streetName",
+ "streetNumber",
+ "apartmentNumber"
+})
+public class CanonicalAddressType {
+
+ @XmlElement(required = true)
+ @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+ protected String countryCodeAddress;
+ protected String state;
+ protected String municipalityCode;
+ @XmlElement(required = true)
+ protected String town;
+ @XmlElement(required = true)
+ protected String postalCode;
+ @XmlElement(required = true)
+ protected String streetName;
+ protected String streetNumber;
+ protected String apartmentNumber;
+
+ /**
+ * Gets the value of the countryCodeAddress property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getCountryCodeAddress() {
+ return countryCodeAddress;
+ }
+
+ /**
+ * Sets the value of the countryCodeAddress property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setCountryCodeAddress(String value) {
+ this.countryCodeAddress = value;
+ }
+
+ /**
+ * Gets the value of the state property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getState() {
+ return state;
+ }
+
+ /**
+ * Sets the value of the state property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setState(String value) {
+ this.state = value;
+ }
+
+ /**
+ * Gets the value of the municipalityCode property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getMunicipalityCode() {
+ return municipalityCode;
+ }
+
+ /**
+ * Sets the value of the municipalityCode property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setMunicipalityCode(String value) {
+ this.municipalityCode = value;
+ }
+
+ /**
+ * Gets the value of the town property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getTown() {
+ return town;
+ }
+
+ /**
+ * Sets the value of the town property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setTown(String value) {
+ this.town = value;
+ }
+
+ /**
+ * Gets the value of the postalCode property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getPostalCode() {
+ return postalCode;
+ }
+
+ /**
+ * Sets the value of the postalCode property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setPostalCode(String value) {
+ this.postalCode = value;
+ }
+
+ /**
+ * Gets the value of the streetName property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getStreetName() {
+ return streetName;
+ }
+
+ /**
+ * Sets the value of the streetName property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setStreetName(String value) {
+ this.streetName = value;
+ }
+
+ /**
+ * Gets the value of the streetNumber property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getStreetNumber() {
+ return streetNumber;
+ }
+
+ /**
+ * Sets the value of the streetNumber property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setStreetNumber(String value) {
+ this.streetNumber = value;
+ }
+
+ /**
+ * Gets the value of the apartmentNumber property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getApartmentNumber() {
+ return apartmentNumber;
+ }
+
+ /**
+ * Sets the value of the apartmentNumber property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setApartmentNumber(String value) {
+ this.apartmentNumber = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/Habilitation.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/Habilitation.java
new file mode 100644
index 000000000..3d99c9600
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/Habilitation.java
@@ -0,0 +1,89 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for habilitation complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="habilitation">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="ability" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "habilitation", propOrder = {
+ "ability",
+ "aqaa"
+})
+public class Habilitation {
+
+ @XmlElement(required = true)
+ protected String ability;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the ability property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getAbility() {
+ return ability;
+ }
+
+ /**
+ * Sets the value of the ability property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setAbility(String value) {
+ this.ability = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/HabilitationType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/HabilitationType.java
new file mode 100644
index 000000000..6a5cb7b00
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/HabilitationType.java
@@ -0,0 +1,89 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for habilitationType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="habilitationType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="ability" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "habilitationType", propOrder = {
+ "ability",
+ "aqaa"
+})
+public class HabilitationType {
+
+ @XmlElement(required = true)
+ protected String ability;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the ability property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getAbility() {
+ return ability;
+ }
+
+ /**
+ * Sets the value of the ability property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setAbility(String value) {
+ this.ability = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/HasAccountInBankType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/HasAccountInBankType.java
new file mode 100644
index 000000000..cc09f0486
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/HasAccountInBankType.java
@@ -0,0 +1,89 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for hasAccountInBankType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="hasAccountInBankType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="bankName" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "hasAccountInBankType", propOrder = {
+ "bankName",
+ "aqaa"
+})
+public class HasAccountInBankType {
+
+ @XmlElement(required = true)
+ protected String bankName;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the bankName property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getBankName() {
+ return bankName;
+ }
+
+ /**
+ * Sets the value of the bankName property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setBankName(String value) {
+ this.bankName = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/HasDegreeType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/HasDegreeType.java
new file mode 100644
index 000000000..ea466cb18
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/HasDegreeType.java
@@ -0,0 +1,174 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import java.math.BigInteger;
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for hasDegreeType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="hasDegreeType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="study" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}studyType"/>
+ * &lt;element name="level" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}LevelType"/>
+ * &lt;element name="yearObtained" type="{http://www.w3.org/2001/XMLSchema}integer"/>
+ * &lt;element name="nameOfInstitution" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "hasDegreeType", propOrder = {
+ "study",
+ "level",
+ "yearObtained",
+ "nameOfInstitution",
+ "aqaa"
+})
+public class HasDegreeType {
+
+ @XmlElement(required = true)
+ protected String study;
+ @XmlElement(required = true)
+ protected String level;
+ @XmlElement(required = true)
+ protected BigInteger yearObtained;
+ @XmlElement(required = true)
+ protected String nameOfInstitution;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the study property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getStudy() {
+ return study;
+ }
+
+ /**
+ * Sets the value of the study property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setStudy(String value) {
+ this.study = value;
+ }
+
+ /**
+ * Gets the value of the level property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getLevel() {
+ return level;
+ }
+
+ /**
+ * Sets the value of the level property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setLevel(String value) {
+ this.level = value;
+ }
+
+ /**
+ * Gets the value of the yearObtained property.
+ *
+ * @return
+ * possible object is
+ * {@link BigInteger }
+ *
+ */
+ public BigInteger getYearObtained() {
+ return yearObtained;
+ }
+
+ /**
+ * Sets the value of the yearObtained property.
+ *
+ * @param value
+ * allowed object is
+ * {@link BigInteger }
+ *
+ */
+ public void setYearObtained(BigInteger value) {
+ this.yearObtained = value;
+ }
+
+ /**
+ * Gets the value of the nameOfInstitution property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getNameOfInstitution() {
+ return nameOfInstitution;
+ }
+
+ /**
+ * Sets the value of the nameOfInstitution property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setNameOfInstitution(String value) {
+ this.nameOfInstitution = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsAcademicStaffType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsAcademicStaffType.java
new file mode 100644
index 000000000..02d9286d8
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsAcademicStaffType.java
@@ -0,0 +1,145 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for isAcademicStaffType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="isAcademicStaffType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="nameOfInstitution" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="occupation" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}occupationType"/>
+ * &lt;element name="knowledgearea" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "isAcademicStaffType", propOrder = {
+ "nameOfInstitution",
+ "occupation",
+ "knowledgearea",
+ "aqaa"
+})
+public class IsAcademicStaffType {
+
+ @XmlElement(required = true)
+ protected String nameOfInstitution;
+ @XmlElement(required = true)
+ protected String occupation;
+ @XmlElement(required = true)
+ protected String knowledgearea;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the nameOfInstitution property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getNameOfInstitution() {
+ return nameOfInstitution;
+ }
+
+ /**
+ * Sets the value of the nameOfInstitution property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setNameOfInstitution(String value) {
+ this.nameOfInstitution = value;
+ }
+
+ /**
+ * Gets the value of the occupation property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getOccupation() {
+ return occupation;
+ }
+
+ /**
+ * Sets the value of the occupation property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setOccupation(String value) {
+ this.occupation = value;
+ }
+
+ /**
+ * Gets the value of the knowledgearea property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getKnowledgearea() {
+ return knowledgearea;
+ }
+
+ /**
+ * Sets the value of the knowledgearea property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setKnowledgearea(String value) {
+ this.knowledgearea = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsAdminStaffType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsAdminStaffType.java
new file mode 100644
index 000000000..0de16ee77
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsAdminStaffType.java
@@ -0,0 +1,89 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for isAdminStaffType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="isAdminStaffType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="adminStaff" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "isAdminStaffType", propOrder = {
+ "adminStaff",
+ "aqaa"
+})
+public class IsAdminStaffType {
+
+ @XmlElement(required = true)
+ protected String adminStaff;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the adminStaff property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getAdminStaff() {
+ return adminStaff;
+ }
+
+ /**
+ * Sets the value of the adminStaff property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setAdminStaff(String value) {
+ this.adminStaff = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsCourseCoordinatorType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsCourseCoordinatorType.java
new file mode 100644
index 000000000..58caa2f22
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsCourseCoordinatorType.java
@@ -0,0 +1,89 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for isCourseCoordinatorType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="isCourseCoordinatorType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="courseCoodinator" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "isCourseCoordinatorType", propOrder = {
+ "courseCoodinator",
+ "aqaa"
+})
+public class IsCourseCoordinatorType {
+
+ @XmlElement(required = true)
+ protected String courseCoodinator;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the courseCoodinator property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getCourseCoodinator() {
+ return courseCoodinator;
+ }
+
+ /**
+ * Sets the value of the courseCoodinator property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setCourseCoodinator(String value) {
+ this.courseCoodinator = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsHCPType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsHCPType.java
new file mode 100644
index 000000000..17e315d2d
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsHCPType.java
@@ -0,0 +1,145 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for isHCPType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="isHCPType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="nameOfOrganisation" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="HCPType" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}HCPType"/>
+ * &lt;element name="specialisation" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}specialisationType"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "isHCPType", propOrder = {
+ "nameOfOrganisation",
+ "hcpType",
+ "specialisation",
+ "aqaa"
+})
+public class IsHCPType {
+
+ @XmlElement(required = true)
+ protected String nameOfOrganisation;
+ @XmlElement(name = "HCPType", required = true)
+ protected String hcpType;
+ @XmlElement(required = true)
+ protected String specialisation;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the nameOfOrganisation property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getNameOfOrganisation() {
+ return nameOfOrganisation;
+ }
+
+ /**
+ * Sets the value of the nameOfOrganisation property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setNameOfOrganisation(String value) {
+ this.nameOfOrganisation = value;
+ }
+
+ /**
+ * Gets the value of the hcpType property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getHCPType() {
+ return hcpType;
+ }
+
+ /**
+ * Sets the value of the hcpType property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setHCPType(String value) {
+ this.hcpType = value;
+ }
+
+ /**
+ * Gets the value of the specialisation property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getSpecialisation() {
+ return specialisation;
+ }
+
+ /**
+ * Sets the value of the specialisation property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setSpecialisation(String value) {
+ this.specialisation = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsHealthCareProfessionalType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsHealthCareProfessionalType.java
new file mode 100644
index 000000000..de2003a3f
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsHealthCareProfessionalType.java
@@ -0,0 +1,145 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for isHealthCareProfessionalType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="isHealthCareProfessionalType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="nameOfOrganisation" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element ref="{urn:eu:stork:names:tc:STORK:1.0:assertion}HCPType"/>
+ * &lt;element ref="{urn:eu:stork:names:tc:STORK:1.0:assertion}specialisation"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "isHealthCareProfessionalType", propOrder = {
+ "nameOfOrganisation",
+ "hcpType",
+ "specialisation",
+ "aqaa"
+})
+public class IsHealthCareProfessionalType {
+
+ @XmlElement(required = true)
+ protected String nameOfOrganisation;
+ @XmlElement(name = "HCPType", required = true)
+ protected String hcpType;
+ @XmlElement(required = true)
+ protected String specialisation;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the nameOfOrganisation property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getNameOfOrganisation() {
+ return nameOfOrganisation;
+ }
+
+ /**
+ * Sets the value of the nameOfOrganisation property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setNameOfOrganisation(String value) {
+ this.nameOfOrganisation = value;
+ }
+
+ /**
+ * Gets the value of the hcpType property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getHCPType() {
+ return hcpType;
+ }
+
+ /**
+ * Sets the value of the hcpType property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setHCPType(String value) {
+ this.hcpType = value;
+ }
+
+ /**
+ * Gets the value of the specialisation property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getSpecialisation() {
+ return specialisation;
+ }
+
+ /**
+ * Sets the value of the specialisation property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setSpecialisation(String value) {
+ this.specialisation = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsStudentType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsStudentType.java
new file mode 100644
index 000000000..6a7dc838a
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsStudentType.java
@@ -0,0 +1,146 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import java.math.BigInteger;
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for isStudentType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="isStudentType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element ref="{urn:eu:stork:names:tc:STORK:1.0:assertion}study"/>
+ * &lt;element name="nameOfInstitution" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="course" type="{http://www.w3.org/2001/XMLSchema}integer"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "isStudentType", propOrder = {
+ "study",
+ "nameOfInstitution",
+ "course",
+ "aqaa"
+})
+public class IsStudentType {
+
+ @XmlElement(required = true)
+ protected String study;
+ @XmlElement(required = true)
+ protected String nameOfInstitution;
+ @XmlElement(required = true)
+ protected BigInteger course;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the study property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getStudy() {
+ return study;
+ }
+
+ /**
+ * Sets the value of the study property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setStudy(String value) {
+ this.study = value;
+ }
+
+ /**
+ * Gets the value of the nameOfInstitution property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getNameOfInstitution() {
+ return nameOfInstitution;
+ }
+
+ /**
+ * Sets the value of the nameOfInstitution property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setNameOfInstitution(String value) {
+ this.nameOfInstitution = value;
+ }
+
+ /**
+ * Gets the value of the course property.
+ *
+ * @return
+ * possible object is
+ * {@link BigInteger }
+ *
+ */
+ public BigInteger getCourse() {
+ return course;
+ }
+
+ /**
+ * Sets the value of the course property.
+ *
+ * @param value
+ * allowed object is
+ * {@link BigInteger }
+ *
+ */
+ public void setCourse(BigInteger value) {
+ this.course = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsTeacherOfType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsTeacherOfType.java
new file mode 100644
index 000000000..810f652c1
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/IsTeacherOfType.java
@@ -0,0 +1,145 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for isTeacherOfType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="isTeacherOfType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="nameOfInstitution" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="course" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="role" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="AQAA" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}QualityAuthenticationAssuranceLevelType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "isTeacherOfType", propOrder = {
+ "nameOfInstitution",
+ "course",
+ "role",
+ "aqaa"
+})
+public class IsTeacherOfType {
+
+ @XmlElement(required = true)
+ protected String nameOfInstitution;
+ @XmlElement(required = true)
+ protected String course;
+ @XmlElement(required = true)
+ protected String role;
+ @XmlElement(name = "AQAA")
+ protected int aqaa;
+
+ /**
+ * Gets the value of the nameOfInstitution property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getNameOfInstitution() {
+ return nameOfInstitution;
+ }
+
+ /**
+ * Sets the value of the nameOfInstitution property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setNameOfInstitution(String value) {
+ this.nameOfInstitution = value;
+ }
+
+ /**
+ * Gets the value of the course property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getCourse() {
+ return course;
+ }
+
+ /**
+ * Sets the value of the course property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setCourse(String value) {
+ this.course = value;
+ }
+
+ /**
+ * Gets the value of the role property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getRole() {
+ return role;
+ }
+
+ /**
+ * Sets the value of the role property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setRole(String value) {
+ this.role = value;
+ }
+
+ /**
+ * Gets the value of the aqaa property.
+ *
+ */
+ public int getAQAA() {
+ return aqaa;
+ }
+
+ /**
+ * Sets the value of the aqaa property.
+ *
+ */
+ public void setAQAA(int value) {
+ this.aqaa = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/MandateContentType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/MandateContentType.java
new file mode 100644
index 000000000..84ce2727b
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/MandateContentType.java
@@ -0,0 +1,233 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import java.math.BigInteger;
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlSchemaType;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.datatype.XMLGregorianCalendar;
+
+
+/**
+ * <p>Java class for mandateContentType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="mandateContentType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="validFrom" type="{http://www.w3.org/2001/XMLSchema}date"/>
+ * &lt;element name="validTo" type="{http://www.w3.org/2001/XMLSchema}date"/>
+ * &lt;element name="transactionLimit" type="{http://www.w3.org/2001/XMLSchema}integer"/>
+ * &lt;element name="transactionLimitCurrency" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}currencyType"/>
+ * &lt;element name="isJoint" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="ischained" type="{http://www.w3.org/2001/XMLSchema}boolean"/>
+ * &lt;element name="typePower" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "mandateContentType", propOrder = {
+ "validFrom",
+ "validTo",
+ "transactionLimit",
+ "transactionLimitCurrency",
+ "isJoint",
+ "ischained",
+ "typePower"
+})
+public class MandateContentType {
+
+ @XmlElement(required = true)
+ @XmlSchemaType(name = "date")
+ protected XMLGregorianCalendar validFrom;
+ @XmlElement(required = true)
+ @XmlSchemaType(name = "date")
+ protected XMLGregorianCalendar validTo;
+ @XmlElement(required = true)
+ protected BigInteger transactionLimit;
+ @XmlElement(required = true)
+ protected String transactionLimitCurrency;
+ @XmlElement(required = true)
+ protected String isJoint;
+ protected boolean ischained;
+ @XmlElement(required = true)
+ protected String typePower;
+
+ /**
+ * Gets the value of the validFrom property.
+ *
+ * @return
+ * possible object is
+ * {@link XMLGregorianCalendar }
+ *
+ */
+ public XMLGregorianCalendar getValidFrom() {
+ return validFrom;
+ }
+
+ /**
+ * Sets the value of the validFrom property.
+ *
+ * @param value
+ * allowed object is
+ * {@link XMLGregorianCalendar }
+ *
+ */
+ public void setValidFrom(XMLGregorianCalendar value) {
+ this.validFrom = value;
+ }
+
+ /**
+ * Gets the value of the validTo property.
+ *
+ * @return
+ * possible object is
+ * {@link XMLGregorianCalendar }
+ *
+ */
+ public XMLGregorianCalendar getValidTo() {
+ return validTo;
+ }
+
+ /**
+ * Sets the value of the validTo property.
+ *
+ * @param value
+ * allowed object is
+ * {@link XMLGregorianCalendar }
+ *
+ */
+ public void setValidTo(XMLGregorianCalendar value) {
+ this.validTo = value;
+ }
+
+ /**
+ * Gets the value of the transactionLimit property.
+ *
+ * @return
+ * possible object is
+ * {@link BigInteger }
+ *
+ */
+ public BigInteger getTransactionLimit() {
+ return transactionLimit;
+ }
+
+ /**
+ * Sets the value of the transactionLimit property.
+ *
+ * @param value
+ * allowed object is
+ * {@link BigInteger }
+ *
+ */
+ public void setTransactionLimit(BigInteger value) {
+ this.transactionLimit = value;
+ }
+
+ /**
+ * Gets the value of the transactionLimitCurrency property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getTransactionLimitCurrency() {
+ return transactionLimitCurrency;
+ }
+
+ /**
+ * Sets the value of the transactionLimitCurrency property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setTransactionLimitCurrency(String value) {
+ this.transactionLimitCurrency = value;
+ }
+
+ /**
+ * Gets the value of the isJoint property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getIsJoint() {
+ return isJoint;
+ }
+
+ /**
+ * Sets the value of the isJoint property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setIsJoint(String value) {
+ this.isJoint = value;
+ }
+
+ /**
+ * Gets the value of the ischained property.
+ *
+ */
+ public boolean isIschained() {
+ return ischained;
+ }
+
+ /**
+ * Sets the value of the ischained property.
+ *
+ */
+ public void setIschained(boolean value) {
+ this.ischained = value;
+ }
+
+ /**
+ * Gets the value of the typePower property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getTypePower() {
+ return typePower;
+ }
+
+ /**
+ * Sets the value of the typePower property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setTypePower(String value) {
+ this.typePower = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/MandateType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/MandateType.java
new file mode 100644
index 000000000..26597dc6b
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/MandateType.java
@@ -0,0 +1,125 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for mandateType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="mandateType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element name="represented" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}representationPersonType"/>
+ * &lt;element name="representing" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}representationPersonType"/>
+ * &lt;element name="mandateContent" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}mandateContentType"/>
+ * &lt;/sequence>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "mandateType", propOrder = {
+ "represented",
+ "representing",
+ "mandateContent"
+})
+public class MandateType {
+
+ @XmlElement(required = true)
+ protected RepresentationPersonType represented;
+ @XmlElement(required = true)
+ protected RepresentationPersonType representing;
+ @XmlElement(required = true)
+ protected MandateContentType mandateContent;
+
+ /**
+ * Gets the value of the represented property.
+ *
+ * @return
+ * possible object is
+ * {@link RepresentationPersonType }
+ *
+ */
+ public RepresentationPersonType getRepresented() {
+ return represented;
+ }
+
+ /**
+ * Sets the value of the represented property.
+ *
+ * @param value
+ * allowed object is
+ * {@link RepresentationPersonType }
+ *
+ */
+ public void setRepresented(RepresentationPersonType value) {
+ this.represented = value;
+ }
+
+ /**
+ * Gets the value of the representing property.
+ *
+ * @return
+ * possible object is
+ * {@link RepresentationPersonType }
+ *
+ */
+ public RepresentationPersonType getRepresenting() {
+ return representing;
+ }
+
+ /**
+ * Sets the value of the representing property.
+ *
+ * @param value
+ * allowed object is
+ * {@link RepresentationPersonType }
+ *
+ */
+ public void setRepresenting(RepresentationPersonType value) {
+ this.representing = value;
+ }
+
+ /**
+ * Gets the value of the mandateContent property.
+ *
+ * @return
+ * possible object is
+ * {@link MandateContentType }
+ *
+ */
+ public MandateContentType getMandateContent() {
+ return mandateContent;
+ }
+
+ /**
+ * Sets the value of the mandateContent property.
+ *
+ * @param value
+ * allowed object is
+ * {@link MandateContentType }
+ *
+ */
+ public void setMandateContent(MandateContentType value) {
+ this.mandateContent = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/ObjectFactory.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/ObjectFactory.java
new file mode 100644
index 000000000..eca4ca3de
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/ObjectFactory.java
@@ -0,0 +1,433 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.JAXBElement;
+import javax.xml.bind.annotation.XmlElementDecl;
+import javax.xml.bind.annotation.XmlRegistry;
+import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
+import javax.xml.namespace.QName;
+
+
+/**
+ * This object contains factory methods for each
+ * Java content interface and Java element interface
+ * generated in the eu.stork.peps.complex.attributes package.
+ * <p>An ObjectFactory allows you to programatically
+ * construct new instances of the Java representation
+ * for XML content. The Java representation of XML
+ * content can consist of schema derived interfaces
+ * and classes representing the binding of schema
+ * type definitions, element declarations and model
+ * groups. Factory methods for each of these are
+ * provided in this class.
+ *
+ */
+@XmlRegistry
+public class ObjectFactory {
+
+ private final static QName _Habilitation_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "habilitation");
+ private final static QName _HasDegree_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "hasDegree");
+ private final static QName _SpApplication_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "spApplication");
+ private final static QName _Specialisation_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "specialisation");
+ private final static QName _IsStudent_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "isStudent");
+ private final static QName _AQAA_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "AQAA");
+ private final static QName _HCPType_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "HCPType");
+ private final static QName _CanonicalResidenceAddress_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "canonicalResidenceAddress");
+ private final static QName _AcTitle_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "acTitle");
+ private final static QName _QualityAuthenticationAssuranceLevel_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "QualityAuthenticationAssuranceLevel");
+ private final static QName _IsAcademicStaff_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "isAcademicStaff");
+ private final static QName _IsTeacherOf_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "isTeacherOf");
+ private final static QName _IsCourseCoordinator_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "isCourseCoordinator");
+ private final static QName _CanonicalRegisteredAddress_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "canonicalRegisteredAddress");
+ private final static QName _SpCountry_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "spCountry");
+ private final static QName _IsAdminStaff_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "isAdminStaff");
+ private final static QName _CitizenCountryCode_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "CitizenCountryCode");
+ private final static QName _AttributeValue_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "AttributeValue");
+ private final static QName _HasAccountInBank_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "hasAccountInBank");
+ private final static QName _CountryCodeAddress_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "countryCodeAddress");
+ private final static QName _Study_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "study");
+ private final static QName _IsHealthCareProfessional_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "isHealthCareProfessional");
+ private final static QName _Mandate_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "mandate");
+ private final static QName _RequestedAttribute_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "RequestedAttribute");
+ private final static QName _SpSector_QNAME = new QName("urn:eu:stork:names:tc:STORK:1.0:assertion", "spSector");
+
+ /**
+ * Create a new ObjectFactory that can be used to create new instances of schema derived classes for package: eu.stork.peps.complex.attributes
+ *
+ */
+ public ObjectFactory() {
+ }
+
+ /**
+ * Create an instance of {@link RequestedAttributeType }
+ *
+ */
+ public RequestedAttributeType createRequestedAttributeType() {
+ return new RequestedAttributeType();
+ }
+
+ /**
+ * Create an instance of {@link MandateType }
+ *
+ */
+ public MandateType createMandateType() {
+ return new MandateType();
+ }
+
+ /**
+ * Create an instance of {@link HasAccountInBankType }
+ *
+ */
+ public HasAccountInBankType createHasAccountInBankType() {
+ return new HasAccountInBankType();
+ }
+
+ /**
+ * Create an instance of {@link IsHealthCareProfessionalType }
+ *
+ */
+ public IsHealthCareProfessionalType createIsHealthCareProfessionalType() {
+ return new IsHealthCareProfessionalType();
+ }
+
+ /**
+ * Create an instance of {@link IsAdminStaffType }
+ *
+ */
+ public IsAdminStaffType createIsAdminStaffType() {
+ return new IsAdminStaffType();
+ }
+
+ /**
+ * Create an instance of {@link CanonicalAddressType }
+ *
+ */
+ public CanonicalAddressType createCanonicalAddressType() {
+ return new CanonicalAddressType();
+ }
+
+ /**
+ * Create an instance of {@link IsCourseCoordinatorType }
+ *
+ */
+ public IsCourseCoordinatorType createIsCourseCoordinatorType() {
+ return new IsCourseCoordinatorType();
+ }
+
+ /**
+ * Create an instance of {@link IsAcademicStaffType }
+ *
+ */
+ public IsAcademicStaffType createIsAcademicStaffType() {
+ return new IsAcademicStaffType();
+ }
+
+ /**
+ * Create an instance of {@link IsTeacherOfType }
+ *
+ */
+ public IsTeacherOfType createIsTeacherOfType() {
+ return new IsTeacherOfType();
+ }
+
+ /**
+ * Create an instance of {@link AcTitleType }
+ *
+ */
+ public AcTitleType createAcTitleType() {
+ return new AcTitleType();
+ }
+
+ /**
+ * Create an instance of {@link IsStudentType }
+ *
+ */
+ public IsStudentType createIsStudentType() {
+ return new IsStudentType();
+ }
+
+ /**
+ * Create an instance of {@link HasDegreeType }
+ *
+ */
+ public HasDegreeType createHasDegreeType() {
+ return new HasDegreeType();
+ }
+
+ /**
+ * Create an instance of {@link HabilitationType }
+ *
+ */
+ public HabilitationType createHabilitationType() {
+ return new HabilitationType();
+ }
+
+ /**
+ * Create an instance of {@link MandateContentType }
+ *
+ */
+ public MandateContentType createMandateContentType() {
+ return new MandateContentType();
+ }
+
+ /**
+ * Create an instance of {@link RepresentationPersonType }
+ *
+ */
+ public RepresentationPersonType createRepresentationPersonType() {
+ return new RepresentationPersonType();
+ }
+
+ /**
+ * Create an instance of {@link Habilitation }
+ *
+ */
+ public Habilitation createHabilitation() {
+ return new Habilitation();
+ }
+
+ /**
+ * Create an instance of {@link IsHCPType }
+ *
+ */
+ public IsHCPType createIsHCPType() {
+ return new IsHCPType();
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link HabilitationType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "habilitation")
+ public JAXBElement<HabilitationType> createHabilitation(HabilitationType value) {
+ return new JAXBElement<HabilitationType>(_Habilitation_QNAME, HabilitationType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link HasDegreeType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "hasDegree")
+ public JAXBElement<HasDegreeType> createHasDegree(HasDegreeType value) {
+ return new JAXBElement<HasDegreeType>(_HasDegree_QNAME, HasDegreeType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "spApplication")
+ public JAXBElement<String> createSpApplication(String value) {
+ return new JAXBElement<String>(_SpApplication_QNAME, String.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "specialisation")
+ public JAXBElement<String> createSpecialisation(String value) {
+ return new JAXBElement<String>(_Specialisation_QNAME, String.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link IsStudentType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "isStudent")
+ public JAXBElement<IsStudentType> createIsStudent(IsStudentType value) {
+ return new JAXBElement<IsStudentType>(_IsStudent_QNAME, IsStudentType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link Integer }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "AQAA")
+ public JAXBElement<Integer> createAQAA(Integer value) {
+ return new JAXBElement<Integer>(_AQAA_QNAME, Integer.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "HCPType")
+ public JAXBElement<String> createHCPType(String value) {
+ return new JAXBElement<String>(_HCPType_QNAME, String.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link CanonicalAddressType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "canonicalResidenceAddress")
+ public JAXBElement<CanonicalAddressType> createCanonicalResidenceAddress(CanonicalAddressType value) {
+ return new JAXBElement<CanonicalAddressType>(_CanonicalResidenceAddress_QNAME, CanonicalAddressType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link AcTitleType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "acTitle")
+ public JAXBElement<AcTitleType> createAcTitle(AcTitleType value) {
+ return new JAXBElement<AcTitleType>(_AcTitle_QNAME, AcTitleType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link Integer }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "QualityAuthenticationAssuranceLevel")
+ public JAXBElement<Integer> createQualityAuthenticationAssuranceLevel(Integer value) {
+ return new JAXBElement<Integer>(_QualityAuthenticationAssuranceLevel_QNAME, Integer.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link IsAcademicStaffType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "isAcademicStaff")
+ public JAXBElement<IsAcademicStaffType> createIsAcademicStaff(IsAcademicStaffType value) {
+ return new JAXBElement<IsAcademicStaffType>(_IsAcademicStaff_QNAME, IsAcademicStaffType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link IsTeacherOfType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "isTeacherOf")
+ public JAXBElement<IsTeacherOfType> createIsTeacherOf(IsTeacherOfType value) {
+ return new JAXBElement<IsTeacherOfType>(_IsTeacherOf_QNAME, IsTeacherOfType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link IsCourseCoordinatorType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "isCourseCoordinator")
+ public JAXBElement<IsCourseCoordinatorType> createIsCourseCoordinator(IsCourseCoordinatorType value) {
+ return new JAXBElement<IsCourseCoordinatorType>(_IsCourseCoordinator_QNAME, IsCourseCoordinatorType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link CanonicalAddressType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "canonicalRegisteredAddress")
+ public JAXBElement<CanonicalAddressType> createCanonicalRegisteredAddress(CanonicalAddressType value) {
+ return new JAXBElement<CanonicalAddressType>(_CanonicalRegisteredAddress_QNAME, CanonicalAddressType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "spCountry")
+ @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+ public JAXBElement<String> createSpCountry(String value) {
+ return new JAXBElement<String>(_SpCountry_QNAME, String.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link IsAdminStaffType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "isAdminStaff")
+ public JAXBElement<IsAdminStaffType> createIsAdminStaff(IsAdminStaffType value) {
+ return new JAXBElement<IsAdminStaffType>(_IsAdminStaff_QNAME, IsAdminStaffType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "CitizenCountryCode")
+ @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+ public JAXBElement<String> createCitizenCountryCode(String value) {
+ return new JAXBElement<String>(_CitizenCountryCode_QNAME, String.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link Object }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "AttributeValue")
+ public JAXBElement<Object> createAttributeValue(Object value) {
+ return new JAXBElement<Object>(_AttributeValue_QNAME, Object.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link HasAccountInBankType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "hasAccountInBank")
+ public JAXBElement<HasAccountInBankType> createHasAccountInBank(HasAccountInBankType value) {
+ return new JAXBElement<HasAccountInBankType>(_HasAccountInBank_QNAME, HasAccountInBankType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "countryCodeAddress")
+ @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
+ public JAXBElement<String> createCountryCodeAddress(String value) {
+ return new JAXBElement<String>(_CountryCodeAddress_QNAME, String.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "study")
+ public JAXBElement<String> createStudy(String value) {
+ return new JAXBElement<String>(_Study_QNAME, String.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link IsHealthCareProfessionalType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "isHealthCareProfessional")
+ public JAXBElement<IsHealthCareProfessionalType> createIsHealthCareProfessional(IsHealthCareProfessionalType value) {
+ return new JAXBElement<IsHealthCareProfessionalType>(_IsHealthCareProfessional_QNAME, IsHealthCareProfessionalType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link MandateType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "mandate")
+ public JAXBElement<MandateType> createMandate(MandateType value) {
+ return new JAXBElement<MandateType>(_Mandate_QNAME, MandateType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link RequestedAttributeType }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "RequestedAttribute")
+ public JAXBElement<RequestedAttributeType> createRequestedAttribute(RequestedAttributeType value) {
+ return new JAXBElement<RequestedAttributeType>(_RequestedAttribute_QNAME, RequestedAttributeType.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link String }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", name = "spSector")
+ public JAXBElement<String> createSpSector(String value) {
+ return new JAXBElement<String>(_SpSector_QNAME, String.class, null, value);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/RepresentationPersonType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/RepresentationPersonType.java
new file mode 100644
index 000000000..b1d993f89
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/RepresentationPersonType.java
@@ -0,0 +1,289 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for representationPersonType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="representationPersonType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;choice>
+ * &lt;sequence>
+ * &lt;element name="eIdentifier" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="givenName" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="surname" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="dateOfBirth" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;/sequence>
+ * &lt;sequence>
+ * &lt;element name="eLPIdentifier" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="name" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="address" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;element name="canonicalAddress" type="{urn:eu:stork:names:tc:STORK:1.0:assertion}canonicalAddressType"/>
+ * &lt;element name="type" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ * &lt;/sequence>
+ * &lt;/choice>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "representationPersonType", propOrder = {
+ "eIdentifier",
+ "givenName",
+ "surname",
+ "dateOfBirth",
+ "elpIdentifier",
+ "name",
+ "address",
+ "canonicalAddress",
+ "type"
+})
+public class RepresentationPersonType {
+
+ protected String eIdentifier;
+ protected String givenName;
+ protected String surname;
+ protected String dateOfBirth;
+ @XmlElement(name = "eLPIdentifier")
+ protected String elpIdentifier;
+ protected String name;
+ protected String address;
+ protected CanonicalAddressType canonicalAddress;
+ protected String type;
+
+ /**
+ * Gets the value of the eIdentifier property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getEIdentifier() {
+ return eIdentifier;
+ }
+
+ /**
+ * Sets the value of the eIdentifier property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setEIdentifier(String value) {
+ this.eIdentifier = value;
+ }
+
+ /**
+ * Gets the value of the givenName property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getGivenName() {
+ return givenName;
+ }
+
+ /**
+ * Sets the value of the givenName property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setGivenName(String value) {
+ this.givenName = value;
+ }
+
+ /**
+ * Gets the value of the surname property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getSurname() {
+ return surname;
+ }
+
+ /**
+ * Sets the value of the surname property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setSurname(String value) {
+ this.surname = value;
+ }
+
+ /**
+ * Gets the value of the dateOfBirth property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getDateOfBirth() {
+ return dateOfBirth;
+ }
+
+ /**
+ * Sets the value of the dateOfBirth property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setDateOfBirth(String value) {
+ this.dateOfBirth = value;
+ }
+
+ /**
+ * Gets the value of the elpIdentifier property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getELPIdentifier() {
+ return elpIdentifier;
+ }
+
+ /**
+ * Sets the value of the elpIdentifier property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setELPIdentifier(String value) {
+ this.elpIdentifier = value;
+ }
+
+ /**
+ * Gets the value of the name property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getName() {
+ return name;
+ }
+
+ /**
+ * Sets the value of the name property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setName(String value) {
+ this.name = value;
+ }
+
+ /**
+ * Gets the value of the address property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getAddress() {
+ return address;
+ }
+
+ /**
+ * Sets the value of the address property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setAddress(String value) {
+ this.address = value;
+ }
+
+ /**
+ * Gets the value of the canonicalAddress property.
+ *
+ * @return
+ * possible object is
+ * {@link CanonicalAddressType }
+ *
+ */
+ public CanonicalAddressType getCanonicalAddress() {
+ return canonicalAddress;
+ }
+
+ /**
+ * Sets the value of the canonicalAddress property.
+ *
+ * @param value
+ * allowed object is
+ * {@link CanonicalAddressType }
+ *
+ */
+ public void setCanonicalAddress(CanonicalAddressType value) {
+ this.canonicalAddress = value;
+ }
+
+ /**
+ * Gets the value of the type property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getType() {
+ return type;
+ }
+
+ /**
+ * Sets the value of the type property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setType(String value) {
+ this.type = value;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/RequestedAttributeType.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/RequestedAttributeType.java
new file mode 100644
index 000000000..6a7c0b443
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/RequestedAttributeType.java
@@ -0,0 +1,212 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+
+package eu.stork.peps.complex.attributes;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlAnyAttribute;
+import javax.xml.bind.annotation.XmlAttribute;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlSchemaType;
+import javax.xml.bind.annotation.XmlType;
+import javax.xml.namespace.QName;
+
+
+/**
+ * <p>Java class for RequestedAttributeType complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * &lt;complexType name="RequestedAttributeType">
+ * &lt;complexContent>
+ * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * &lt;sequence>
+ * &lt;element ref="{urn:eu:stork:names:tc:STORK:1.0:assertion}AttributeValue" maxOccurs="unbounded" minOccurs="0"/>
+ * &lt;/sequence>
+ * &lt;attribute name="Name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
+ * &lt;attribute name="NameFormat" use="required" type="{http://www.w3.org/2001/XMLSchema}anyURI" />
+ * &lt;attribute name="FriendlyName" type="{http://www.w3.org/2001/XMLSchema}string" />
+ * &lt;attribute name="isRequired" type="{http://www.w3.org/2001/XMLSchema}boolean" />
+ * &lt;anyAttribute processContents='lax' namespace='##other'/>
+ * &lt;/restriction>
+ * &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ *
+ *
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "RequestedAttributeType", propOrder = {
+ "attributeValue"
+})
+public class RequestedAttributeType {
+
+ @XmlElement(name = "AttributeValue")
+ protected List<Object> attributeValue;
+ @XmlAttribute(name = "Name", required = true)
+ protected String name;
+ @XmlAttribute(name = "NameFormat", required = true)
+ @XmlSchemaType(name = "anyURI")
+ protected String nameFormat;
+ @XmlAttribute(name = "FriendlyName")
+ protected String friendlyName;
+ @XmlAttribute(name = "isRequired")
+ protected Boolean isRequired;
+ @XmlAnyAttribute
+ private Map<QName, String> otherAttributes = new HashMap<QName, String>();
+
+ /**
+ * Gets the value of the attributeValue property.
+ *
+ * <p>
+ * This accessor method returns a reference to the live list,
+ * not a snapshot. Therefore any modification you make to the
+ * returned list will be present inside the JAXB object.
+ * This is why there is not a <CODE>set</CODE> method for the attributeValue property.
+ *
+ * <p>
+ * For example, to add a new item, do as follows:
+ * <pre>
+ * getAttributeValue().add(newItem);
+ * </pre>
+ *
+ *
+ * <p>
+ * Objects of the following type(s) are allowed in the list
+ * {@link Object }
+ *
+ *
+ */
+ public List<Object> getAttributeValue() {
+ if (attributeValue == null) {
+ attributeValue = new ArrayList<Object>();
+ }
+ return this.attributeValue;
+ }
+
+ /**
+ * Gets the value of the name property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getName() {
+ return name;
+ }
+
+ /**
+ * Sets the value of the name property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setName(String value) {
+ this.name = value;
+ }
+
+ /**
+ * Gets the value of the nameFormat property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getNameFormat() {
+ return nameFormat;
+ }
+
+ /**
+ * Sets the value of the nameFormat property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setNameFormat(String value) {
+ this.nameFormat = value;
+ }
+
+ /**
+ * Gets the value of the friendlyName property.
+ *
+ * @return
+ * possible object is
+ * {@link String }
+ *
+ */
+ public String getFriendlyName() {
+ return friendlyName;
+ }
+
+ /**
+ * Sets the value of the friendlyName property.
+ *
+ * @param value
+ * allowed object is
+ * {@link String }
+ *
+ */
+ public void setFriendlyName(String value) {
+ this.friendlyName = value;
+ }
+
+ /**
+ * Gets the value of the isRequired property.
+ *
+ * @return
+ * possible object is
+ * {@link Boolean }
+ *
+ */
+ public Boolean isIsRequired() {
+ return isRequired;
+ }
+
+ /**
+ * Sets the value of the isRequired property.
+ *
+ * @param value
+ * allowed object is
+ * {@link Boolean }
+ *
+ */
+ public void setIsRequired(Boolean value) {
+ this.isRequired = value;
+ }
+
+ /**
+ * Gets a map that contains attributes that aren't bound to any typed property on this class.
+ *
+ * <p>
+ * the map is keyed by the name of the attribute and
+ * the value is the string value of the attribute.
+ *
+ * the map returned by this method is live, and you can add new attribute
+ * by updating the map directly. Because of this design, there's no setter.
+ *
+ *
+ * @return
+ * always non-null
+ */
+ public Map<QName, String> getOtherAttributes() {
+ return otherAttributes;
+ }
+
+}
diff --git a/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/package-info.java b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/package-info.java
new file mode 100644
index 000000000..47e225d22
--- /dev/null
+++ b/id/server/stork2-commons/src/main/java/eu/stork/peps/complex/attributes/package-info.java
@@ -0,0 +1,9 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
+// Any modifications to this file will be lost upon recompilation of the source schema.
+// Generated on: 2014.02.17 at 10:36:59 AM GMT
+//
+
+@javax.xml.bind.annotation.XmlSchema(namespace = "urn:eu:stork:names:tc:STORK:1.0:assertion", elementFormDefault = javax.xml.bind.annotation.XmlNsForm.QUALIFIED)
+package eu.stork.peps.complex.attributes;
diff --git a/id/server/stork2-commons/src/main/resources/.svn/all-wcprops b/id/server/stork2-commons/src/main/resources/.svn/all-wcprops
new file mode 100644
index 000000000..7f5879720
--- /dev/null
+++ b/id/server/stork2-commons/src/main/resources/.svn/all-wcprops
@@ -0,0 +1,17 @@
+K 25
+svn:wc:ra_dav:version-url
+V 64
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/resources
+END
+log4j.xml
+K 25
+svn:wc:ra_dav:version-url
+V 73
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/main/resources/log4j.xml
+END
+StorkcomplexAttributes.xsd
+K 25
+svn:wc:ra_dav:version-url
+V 91
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/main/resources/StorkcomplexAttributes.xsd
+END
diff --git a/id/server/stork2-commons/src/main/resources/.svn/entries b/id/server/stork2-commons/src/main/resources/.svn/entries
new file mode 100644
index 000000000..3cafa50cf
--- /dev/null
+++ b/id/server/stork2-commons/src/main/resources/.svn/entries
@@ -0,0 +1,96 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/main/resources
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+log4j.xml
+file
+
+
+
+
+2013-12-20T12:27:56.554475Z
+aa8c46e41a236b8c7049713b3eeecc49
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+660
+
+StorkcomplexAttributes.xsd
+file
+
+
+
+
+2014-03-05T09:36:07.834515Z
+312be97fd22ecb2f274bf9fdebd85b29
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+10938
+
diff --git a/id/server/stork2-commons/src/main/resources/.svn/text-base/StorkcomplexAttributes.xsd.svn-base b/id/server/stork2-commons/src/main/resources/.svn/text-base/StorkcomplexAttributes.xsd.svn-base
new file mode 100644
index 000000000..3c56bd318
--- /dev/null
+++ b/id/server/stork2-commons/src/main/resources/.svn/text-base/StorkcomplexAttributes.xsd.svn-base
@@ -0,0 +1,305 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xs:schema elementFormDefault="qualified"
+ targetNamespace="urn:eu:stork:names:tc:STORK:1.0:assertion"
+ xmlns:xs="http://www.w3.org/2001/XMLSchema"
+ xmlns:storkp="urn:eu:stork:names:tc:STORK:1.0:protocol"
+ xmlns:stork="urn:eu:stork:names:tc:STORK:1.0:assertion">
+ <!--QAA -->
+ <xs:element name="QualityAuthenticationAssuranceLevel"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ <xs:element name="spSector" type="stork:SPSectorType" />
+ <xs:element name="spApplication" type="stork:SPApplicationType" />
+ <xs:element name="spCountry" type="stork:CountryCodeType" />
+ <xs:element name="CitizenCountryCode" type="stork:CountryCodeType" />
+ <xs:element name="RequestedAttribute" type="stork:RequestedAttributeType" />
+ <xs:element name="AttributeValue" type="xs:anyType" />
+ <xs:element name="canonicalResidenceAddress" type="stork:canonicalAddressType" />
+ <xs:element name="countryCodeAddress" type="stork:CountryCodeType" />
+
+ <xs:element name="hasDegree" type="stork:hasDegreeType" />
+ <xs:element name="isStudent" type="stork:isStudentType" />
+ <xs:element name="isAcademicStaff" type="stork:isAcademicStaffType" />
+ <xs:element name="isTeacherOf" type="stork:isTeacherOfType" />
+ <xs:element name="isCourseCoordinator" type="stork:isCourseCoordinatorType" />
+ <xs:element name="isAdminStaff" type="stork:isAdminStaffType" />
+ <xs:element name="habilitation" type="stork:habilitationType" />
+ <xs:element name="acTitle" type="stork:acTitleType" />
+ <xs:element name="hasAccountInBank" type="stork:hasAccountInBankType" />
+ <xs:element name="isHealthCareProfessional" type="stork:isHealthCareProfessionalType" />
+ <xs:element name="canonicalRegisteredAddress" type="stork:canonicalAddressType" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ <xs:element name="mandate" type="stork:mandateType" />
+ <xs:element name="study" type="stork:studyType" />
+ <xs:element name="HCPType" type="stork:HCPType" />
+
+ <xs:attribute name="AttributeStatus" type="stork:AttributeStatusType" />
+
+ <xs:simpleType name="SPSectorType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="1" />
+ <xs:maxLength value="20" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="SPApplicationType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="1" />
+ <xs:maxLength value="100" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="AttributeStatusType">
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="Available" />
+ <xs:enumeration value="NotAvailable" />
+ <xs:enumeration value="Withheld" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="studyType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="2" />
+ <xs:maxLength value="5" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="LevelType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="1" />
+ <xs:maxLength value="1" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="currencyType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="3" />
+ <xs:maxLength value="3" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="occupationType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="1" />
+ <xs:maxLength value="1" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="titleNormalisedType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="1" />
+ <xs:maxLength value="1" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="HCPType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="1" />
+ <xs:maxLength value="1" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="specialisationType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="1" />
+ <xs:maxLength value="1" />
+ </xs:restriction>
+ </xs:simpleType>
+
+
+ <xs:simpleType name="QualityAuthenticationAssuranceLevelType">
+ <xs:restriction base="xs:integer">
+ <xs:minInclusive value="1" />
+ <xs:maxInclusive value="4" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:complexType name="canonicalAddressType">
+ <xs:sequence>
+ <xs:element name="countryCodeAddress" type="stork:CountryCodeType" />
+ <xs:element name="state" type="xs:string" minOccurs="0" />
+ <xs:element name="municipalityCode" type="xs:string"
+ minOccurs="0" />
+ <xs:element name="town" type="xs:string" />
+ <xs:element name="postalCode" type="xs:string" />
+ <xs:element name="streetName" type="xs:string" />
+ <xs:element name="streetNumber" type="xs:string"
+ minOccurs="0" />
+ <xs:element name="apartmentNumber" type="xs:string"
+ minOccurs="0" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="hasDegreeType">
+ <xs:sequence>
+ <xs:element name="study" type="stork:studyType" />
+ <xs:element name="level" type="stork:LevelType" />
+ <xs:element name="yearObtained" type="xs:integer" />
+ <xs:element name="nameOfInstitution" type="xs:string" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="isAcademicStaffType">
+ <xs:sequence>
+ <xs:element name="nameOfInstitution" type="xs:string" />
+ <xs:element name="occupation" type="stork:occupationType" />
+ <xs:element name="knowledgearea" type="xs:string" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="isTeacherOfType">
+ <xs:sequence>
+ <xs:element name="nameOfInstitution" type="xs:string" />
+ <xs:element name="course" type="xs:string" />
+ <xs:element name="role" type="xs:string" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="isCourseCoordinatorType">
+ <xs:sequence>
+ <xs:element name="courseCoodinator" type="xs:string" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="isAdminStaffType">
+ <xs:sequence>
+ <xs:element name="adminStaff" type="xs:string" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="habilitation">
+ <xs:sequence>
+ <xs:element name="ability" type="xs:string" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="acTitleType">
+ <xs:sequence>
+ <xs:element name="titleNormalised" type="stork:titleNormalisedType" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="hasAccountInBankType">
+ <xs:sequence>
+ <xs:element name="bankName" type="xs:string" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="isHCPType">
+ <xs:sequence>
+ <xs:element name="nameOfOrganisation" type="xs:string" />
+ <xs:element name="HCPType" type="stork:HCPType" />
+ <xs:element name="specialisation" type="stork:specialisationType" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="representationPersonType">
+ <xs:choice>
+ <xs:sequence>
+ <xs:element name="eIdentifier" type="xs:string" />
+ <xs:element name="givenName" type="xs:string" />
+ <xs:element name="surname" type="xs:string" />
+ <xs:element name="dateOfBirth" type="xs:string" />
+ </xs:sequence>
+ <xs:sequence>
+ <xs:element name="eLPIdentifier" type="xs:string" />
+ <xs:element name="name" type="xs:string" />
+ <xs:element name="address" type="xs:string" />
+ <xs:element name="canonicalAddress" type="stork:canonicalAddressType" />
+ <xs:element name="type" type="xs:string" />
+ </xs:sequence>
+ </xs:choice>
+ </xs:complexType>
+
+ <xs:complexType name="mandateType">
+ <xs:sequence>
+ <xs:element name="represented" type="stork:representationPersonType" />
+ <xs:element name="representing" type="stork:representationPersonType" />
+ <xs:element name="mandateContent" type="stork:mandateContentType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="mandateContentType">
+ <xs:sequence>
+ <xs:element name="validFrom" type="xs:date" />
+ <xs:element name="validTo" type="xs:date" />
+ <xs:element name="transactionLimit" type="xs:integer" />
+ <xs:element name="transactionLimitCurrency" type="stork:currencyType" />
+ <xs:element name="isJoint" type="xs:string" />
+ <xs:element name="ischained" type="xs:boolean" />
+ <xs:element name="typePower" type="xs:string" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:simpleType name="CountryCodeType">
+ <xs:restriction base="xs:token">
+ <xs:pattern value="[A-Z]{2}" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:complexType name="RequestedAttributeType">
+ <xs:sequence>
+ <xs:element minOccurs="0" maxOccurs="unbounded" ref="stork:AttributeValue" />
+ </xs:sequence>
+ <xs:attribute name="Name" use="required" type="xs:string" />
+ <xs:attribute name="NameFormat" use="required" type="xs:anyURI" />
+ <xs:attribute name="FriendlyName" use="optional" type="xs:string" />
+ <xs:attribute name="isRequired" use="optional" type="xs:boolean" />
+ <xs:anyAttribute namespace="##other" processContents="lax" />
+ </xs:complexType>
+
+ <xs:complexType name="isStudentType">
+ <xs:sequence>
+ <xs:element ref="stork:study" />
+ <xs:element name="nameOfInstitution" type="xs:string" />
+ <xs:element name="course" type="xs:integer" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="habilitationType">
+ <xs:sequence>
+ <xs:element name="ability" type="xs:string" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="isHealthCareProfessionalType">
+ <xs:sequence>
+ <xs:element name="nameOfOrganisation" type="xs:string" />
+ <xs:element ref="stork:HCPType" />
+ <xs:element ref="stork:specialisation" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:element name="specialisation" type="stork:specialisationType" />
+ <xs:simpleType name="medical">
+ <xs:restriction base="xs:string">
+ <xs:maxLength value="2" />
+ <xs:minLength value="2" />
+ </xs:restriction>
+ </xs:simpleType>
+
+</xs:schema>
diff --git a/id/server/stork2-commons/src/main/resources/.svn/text-base/log4j.xml.svn-base b/id/server/stork2-commons/src/main/resources/.svn/text-base/log4j.xml.svn-base
new file mode 100644
index 000000000..8bce0bec0
--- /dev/null
+++ b/id/server/stork2-commons/src/main/resources/.svn/text-base/log4j.xml.svn-base
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
+
+<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/">
+ <appender name="MainLogger" class="org.apache.log4j.DailyRollingFileAppender">
+ <param name="File" value="/opt/storklogs/stork-commons.log" />
+ <param name="DatePattern" value="'.'yyyy-MM-dd" />
+ <param name="Append" value="true" />
+ <layout class="org.apache.log4j.PatternLayout">
+ <param name="ConversionPattern" value="%d{HH:mm:ss:SSS} - %p - %C{1} - %m%n" />
+ </layout>
+ </appender>
+
+ <root>
+ <priority value="info" />
+ <appender-ref ref="MainLogger" />
+ </root>
+
+</log4j:configuration>
diff --git a/id/server/stork2-commons/src/main/resources/StorkcomplexAttributes.xsd b/id/server/stork2-commons/src/main/resources/StorkcomplexAttributes.xsd
new file mode 100644
index 000000000..3c56bd318
--- /dev/null
+++ b/id/server/stork2-commons/src/main/resources/StorkcomplexAttributes.xsd
@@ -0,0 +1,305 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xs:schema elementFormDefault="qualified"
+ targetNamespace="urn:eu:stork:names:tc:STORK:1.0:assertion"
+ xmlns:xs="http://www.w3.org/2001/XMLSchema"
+ xmlns:storkp="urn:eu:stork:names:tc:STORK:1.0:protocol"
+ xmlns:stork="urn:eu:stork:names:tc:STORK:1.0:assertion">
+ <!--QAA -->
+ <xs:element name="QualityAuthenticationAssuranceLevel"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ <xs:element name="spSector" type="stork:SPSectorType" />
+ <xs:element name="spApplication" type="stork:SPApplicationType" />
+ <xs:element name="spCountry" type="stork:CountryCodeType" />
+ <xs:element name="CitizenCountryCode" type="stork:CountryCodeType" />
+ <xs:element name="RequestedAttribute" type="stork:RequestedAttributeType" />
+ <xs:element name="AttributeValue" type="xs:anyType" />
+ <xs:element name="canonicalResidenceAddress" type="stork:canonicalAddressType" />
+ <xs:element name="countryCodeAddress" type="stork:CountryCodeType" />
+
+ <xs:element name="hasDegree" type="stork:hasDegreeType" />
+ <xs:element name="isStudent" type="stork:isStudentType" />
+ <xs:element name="isAcademicStaff" type="stork:isAcademicStaffType" />
+ <xs:element name="isTeacherOf" type="stork:isTeacherOfType" />
+ <xs:element name="isCourseCoordinator" type="stork:isCourseCoordinatorType" />
+ <xs:element name="isAdminStaff" type="stork:isAdminStaffType" />
+ <xs:element name="habilitation" type="stork:habilitationType" />
+ <xs:element name="acTitle" type="stork:acTitleType" />
+ <xs:element name="hasAccountInBank" type="stork:hasAccountInBankType" />
+ <xs:element name="isHealthCareProfessional" type="stork:isHealthCareProfessionalType" />
+ <xs:element name="canonicalRegisteredAddress" type="stork:canonicalAddressType" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ <xs:element name="mandate" type="stork:mandateType" />
+ <xs:element name="study" type="stork:studyType" />
+ <xs:element name="HCPType" type="stork:HCPType" />
+
+ <xs:attribute name="AttributeStatus" type="stork:AttributeStatusType" />
+
+ <xs:simpleType name="SPSectorType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="1" />
+ <xs:maxLength value="20" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="SPApplicationType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="1" />
+ <xs:maxLength value="100" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="AttributeStatusType">
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="Available" />
+ <xs:enumeration value="NotAvailable" />
+ <xs:enumeration value="Withheld" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="studyType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="2" />
+ <xs:maxLength value="5" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="LevelType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="1" />
+ <xs:maxLength value="1" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="currencyType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="3" />
+ <xs:maxLength value="3" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="occupationType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="1" />
+ <xs:maxLength value="1" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="titleNormalisedType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="1" />
+ <xs:maxLength value="1" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="HCPType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="1" />
+ <xs:maxLength value="1" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="specialisationType">
+ <xs:restriction base="xs:string">
+ <xs:minLength value="1" />
+ <xs:maxLength value="1" />
+ </xs:restriction>
+ </xs:simpleType>
+
+
+ <xs:simpleType name="QualityAuthenticationAssuranceLevelType">
+ <xs:restriction base="xs:integer">
+ <xs:minInclusive value="1" />
+ <xs:maxInclusive value="4" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:complexType name="canonicalAddressType">
+ <xs:sequence>
+ <xs:element name="countryCodeAddress" type="stork:CountryCodeType" />
+ <xs:element name="state" type="xs:string" minOccurs="0" />
+ <xs:element name="municipalityCode" type="xs:string"
+ minOccurs="0" />
+ <xs:element name="town" type="xs:string" />
+ <xs:element name="postalCode" type="xs:string" />
+ <xs:element name="streetName" type="xs:string" />
+ <xs:element name="streetNumber" type="xs:string"
+ minOccurs="0" />
+ <xs:element name="apartmentNumber" type="xs:string"
+ minOccurs="0" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="hasDegreeType">
+ <xs:sequence>
+ <xs:element name="study" type="stork:studyType" />
+ <xs:element name="level" type="stork:LevelType" />
+ <xs:element name="yearObtained" type="xs:integer" />
+ <xs:element name="nameOfInstitution" type="xs:string" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="isAcademicStaffType">
+ <xs:sequence>
+ <xs:element name="nameOfInstitution" type="xs:string" />
+ <xs:element name="occupation" type="stork:occupationType" />
+ <xs:element name="knowledgearea" type="xs:string" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="isTeacherOfType">
+ <xs:sequence>
+ <xs:element name="nameOfInstitution" type="xs:string" />
+ <xs:element name="course" type="xs:string" />
+ <xs:element name="role" type="xs:string" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="isCourseCoordinatorType">
+ <xs:sequence>
+ <xs:element name="courseCoodinator" type="xs:string" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="isAdminStaffType">
+ <xs:sequence>
+ <xs:element name="adminStaff" type="xs:string" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="habilitation">
+ <xs:sequence>
+ <xs:element name="ability" type="xs:string" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="acTitleType">
+ <xs:sequence>
+ <xs:element name="titleNormalised" type="stork:titleNormalisedType" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="hasAccountInBankType">
+ <xs:sequence>
+ <xs:element name="bankName" type="xs:string" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="isHCPType">
+ <xs:sequence>
+ <xs:element name="nameOfOrganisation" type="xs:string" />
+ <xs:element name="HCPType" type="stork:HCPType" />
+ <xs:element name="specialisation" type="stork:specialisationType" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="representationPersonType">
+ <xs:choice>
+ <xs:sequence>
+ <xs:element name="eIdentifier" type="xs:string" />
+ <xs:element name="givenName" type="xs:string" />
+ <xs:element name="surname" type="xs:string" />
+ <xs:element name="dateOfBirth" type="xs:string" />
+ </xs:sequence>
+ <xs:sequence>
+ <xs:element name="eLPIdentifier" type="xs:string" />
+ <xs:element name="name" type="xs:string" />
+ <xs:element name="address" type="xs:string" />
+ <xs:element name="canonicalAddress" type="stork:canonicalAddressType" />
+ <xs:element name="type" type="xs:string" />
+ </xs:sequence>
+ </xs:choice>
+ </xs:complexType>
+
+ <xs:complexType name="mandateType">
+ <xs:sequence>
+ <xs:element name="represented" type="stork:representationPersonType" />
+ <xs:element name="representing" type="stork:representationPersonType" />
+ <xs:element name="mandateContent" type="stork:mandateContentType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="mandateContentType">
+ <xs:sequence>
+ <xs:element name="validFrom" type="xs:date" />
+ <xs:element name="validTo" type="xs:date" />
+ <xs:element name="transactionLimit" type="xs:integer" />
+ <xs:element name="transactionLimitCurrency" type="stork:currencyType" />
+ <xs:element name="isJoint" type="xs:string" />
+ <xs:element name="ischained" type="xs:boolean" />
+ <xs:element name="typePower" type="xs:string" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:simpleType name="CountryCodeType">
+ <xs:restriction base="xs:token">
+ <xs:pattern value="[A-Z]{2}" />
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:complexType name="RequestedAttributeType">
+ <xs:sequence>
+ <xs:element minOccurs="0" maxOccurs="unbounded" ref="stork:AttributeValue" />
+ </xs:sequence>
+ <xs:attribute name="Name" use="required" type="xs:string" />
+ <xs:attribute name="NameFormat" use="required" type="xs:anyURI" />
+ <xs:attribute name="FriendlyName" use="optional" type="xs:string" />
+ <xs:attribute name="isRequired" use="optional" type="xs:boolean" />
+ <xs:anyAttribute namespace="##other" processContents="lax" />
+ </xs:complexType>
+
+ <xs:complexType name="isStudentType">
+ <xs:sequence>
+ <xs:element ref="stork:study" />
+ <xs:element name="nameOfInstitution" type="xs:string" />
+ <xs:element name="course" type="xs:integer" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="habilitationType">
+ <xs:sequence>
+ <xs:element name="ability" type="xs:string" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="isHealthCareProfessionalType">
+ <xs:sequence>
+ <xs:element name="nameOfOrganisation" type="xs:string" />
+ <xs:element ref="stork:HCPType" />
+ <xs:element ref="stork:specialisation" />
+ <xs:element name="AQAA"
+ type="stork:QualityAuthenticationAssuranceLevelType" />
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:element name="specialisation" type="stork:specialisationType" />
+ <xs:simpleType name="medical">
+ <xs:restriction base="xs:string">
+ <xs:maxLength value="2" />
+ <xs:minLength value="2" />
+ </xs:restriction>
+ </xs:simpleType>
+
+</xs:schema>
diff --git a/id/server/stork2-commons/src/main/resources/log4j.xml b/id/server/stork2-commons/src/main/resources/log4j.xml
new file mode 100644
index 000000000..8bce0bec0
--- /dev/null
+++ b/id/server/stork2-commons/src/main/resources/log4j.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
+
+<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/">
+ <appender name="MainLogger" class="org.apache.log4j.DailyRollingFileAppender">
+ <param name="File" value="/opt/storklogs/stork-commons.log" />
+ <param name="DatePattern" value="'.'yyyy-MM-dd" />
+ <param name="Append" value="true" />
+ <layout class="org.apache.log4j.PatternLayout">
+ <param name="ConversionPattern" value="%d{HH:mm:ss:SSS} - %p - %C{1} - %m%n" />
+ </layout>
+ </appender>
+
+ <root>
+ <priority value="info" />
+ <appender-ref ref="MainLogger" />
+ </root>
+
+</log4j:configuration>
diff --git a/id/server/stork2-commons/src/test/.svn/all-wcprops b/id/server/stork2-commons/src/test/.svn/all-wcprops
new file mode 100644
index 000000000..20c6abf40
--- /dev/null
+++ b/id/server/stork2-commons/src/test/.svn/all-wcprops
@@ -0,0 +1,5 @@
+K 25
+svn:wc:ra_dav:version-url
+V 54
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/test
+END
diff --git a/id/server/stork2-commons/src/test/.svn/entries b/id/server/stork2-commons/src/test/.svn/entries
new file mode 100644
index 000000000..2340f1ba0
--- /dev/null
+++ b/id/server/stork2-commons/src/test/.svn/entries
@@ -0,0 +1,34 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/test
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+resources
+dir
+
+java
+dir
+
diff --git a/id/server/stork2-commons/src/test/java/.svn/all-wcprops b/id/server/stork2-commons/src/test/java/.svn/all-wcprops
new file mode 100644
index 000000000..0539c7776
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/.svn/all-wcprops
@@ -0,0 +1,5 @@
+K 25
+svn:wc:ra_dav:version-url
+V 59
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/test/java
+END
diff --git a/id/server/stork2-commons/src/test/java/.svn/entries b/id/server/stork2-commons/src/test/java/.svn/entries
new file mode 100644
index 000000000..022ccbba6
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/.svn/entries
@@ -0,0 +1,31 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/test/java
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+eu
+dir
+
diff --git a/id/server/stork2-commons/src/test/java/eu/.svn/all-wcprops b/id/server/stork2-commons/src/test/java/eu/.svn/all-wcprops
new file mode 100644
index 000000000..1074db391
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/.svn/all-wcprops
@@ -0,0 +1,5 @@
+K 25
+svn:wc:ra_dav:version-url
+V 62
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/test/java/eu
+END
diff --git a/id/server/stork2-commons/src/test/java/eu/.svn/entries b/id/server/stork2-commons/src/test/java/eu/.svn/entries
new file mode 100644
index 000000000..b692975a3
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/.svn/entries
@@ -0,0 +1,31 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/test/java/eu
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+stork
+dir
+
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/.svn/all-wcprops b/id/server/stork2-commons/src/test/java/eu/stork/.svn/all-wcprops
new file mode 100644
index 000000000..7b9321684
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/.svn/all-wcprops
@@ -0,0 +1,5 @@
+K 25
+svn:wc:ra_dav:version-url
+V 68
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/test/java/eu/stork
+END
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/.svn/entries b/id/server/stork2-commons/src/test/java/eu/stork/.svn/entries
new file mode 100644
index 000000000..1b9026249
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/.svn/entries
@@ -0,0 +1,31 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/test/java/eu/stork
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+peps
+dir
+
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/.svn/all-wcprops b/id/server/stork2-commons/src/test/java/eu/stork/peps/.svn/all-wcprops
new file mode 100644
index 000000000..1a4a3889b
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/.svn/all-wcprops
@@ -0,0 +1,5 @@
+K 25
+svn:wc:ra_dav:version-url
+V 73
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/test/java/eu/stork/peps
+END
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/.svn/entries b/id/server/stork2-commons/src/test/java/eu/stork/peps/.svn/entries
new file mode 100644
index 000000000..568fa8c62
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/.svn/entries
@@ -0,0 +1,31 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/test/java/eu/stork/peps
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+tests
+dir
+
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/all-wcprops b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/all-wcprops
new file mode 100644
index 000000000..fd0288d3a
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/all-wcprops
@@ -0,0 +1,59 @@
+K 25
+svn:wc:ra_dav:version-url
+V 79
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/test/java/eu/stork/peps/tests
+END
+AttributeSourceTestCase.java
+K 25
+svn:wc:ra_dav:version-url
+V 108
+/CITnet/svn/STORK2/!svn/ver/712/trunk/Commons/src/test/java/eu/stork/peps/tests/AttributeSourceTestCase.java
+END
+ComplexAttributesMarshalling.java
+K 25
+svn:wc:ra_dav:version-url
+V 113
+/CITnet/svn/STORK2/!svn/ver/721/trunk/Commons/src/test/java/eu/stork/peps/tests/ComplexAttributesMarshalling.java
+END
+PEPSUtilTestCase.java
+K 25
+svn:wc:ra_dav:version-url
+V 100
+/CITnet/svn/STORK2/!svn/ver/96/trunk/Commons/src/test/java/eu/stork/peps/tests/PEPSUtilTestCase.java
+END
+PersonalAttributeTestCase.java
+K 25
+svn:wc:ra_dav:version-url
+V 109
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/test/java/eu/stork/peps/tests/PersonalAttributeTestCase.java
+END
+package-info.java
+K 25
+svn:wc:ra_dav:version-url
+V 96
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/test/java/eu/stork/peps/tests/package-info.java
+END
+DateUtilTestCase.java
+K 25
+svn:wc:ra_dav:version-url
+V 100
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/test/java/eu/stork/peps/tests/DateUtilTestCase.java
+END
+AttributeProvidersMapTestCase.java
+K 25
+svn:wc:ra_dav:version-url
+V 114
+/CITnet/svn/STORK2/!svn/ver/712/trunk/Commons/src/test/java/eu/stork/peps/tests/AttributeProvidersMapTestCase.java
+END
+AttributeUtilTestCase.java
+K 25
+svn:wc:ra_dav:version-url
+V 105
+/CITnet/svn/STORK2/!svn/ver/96/trunk/Commons/src/test/java/eu/stork/peps/tests/AttributeUtilTestCase.java
+END
+PersonalAttributeListTestCase.java
+K 25
+svn:wc:ra_dav:version-url
+V 114
+/CITnet/svn/STORK2/!svn/ver/484/trunk/Commons/src/test/java/eu/stork/peps/tests/PersonalAttributeListTestCase.java
+END
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/entries b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/entries
new file mode 100644
index 000000000..7c5cf8a9d
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/entries
@@ -0,0 +1,334 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/test/java/eu/stork/peps/tests
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+PersonalAttributeTestCase.java
+file
+
+
+
+
+2013-12-20T12:27:56.518475Z
+77386880d5ffadd21c9b3a3c7d51b990
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+5449
+
+package-info.java
+file
+
+
+
+
+2013-12-20T12:27:56.518475Z
+04f136539bda0caa3d5ccdfee912cfce
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+92
+
+DateUtilTestCase.java
+file
+
+
+
+
+2013-12-20T12:27:56.518475Z
+244cc6104660a7835dbf72dadb305d71
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+8907
+
+AttributeProvidersMapTestCase.java
+file
+
+
+
+
+2014-03-05T09:36:07.758515Z
+1490c44149a87308c4a6cc0e2af88a85
+2014-03-03T15:10:40.224759Z
+712
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+3995
+
+AttributeUtilTestCase.java
+file
+
+
+
+
+2013-12-20T12:27:56.518475Z
+6037f125adf7f4c2f6873a0d99ab0705
+2013-11-01T20:35:30.927048Z
+96
+emferreri
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+16318
+
+PersonalAttributeListTestCase.java
+file
+
+
+
+
+2014-01-21T08:38:55.140702Z
+ae552dce95a6b83d15e381306e2f5e59
+2014-01-15T09:44:59.969756Z
+484
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+24508
+
+AttributeSourceTestCase.java
+file
+
+
+
+
+2014-03-05T09:36:07.758515Z
+1505085e4fd6c684d4f6a8db3d5ba233
+2014-03-03T15:10:40.224759Z
+712
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+2465
+
+ComplexAttributesMarshalling.java
+file
+
+
+
+
+2014-03-05T09:36:07.758515Z
+aca1d76d312b0dc5026f852bb14ab5a5
+2014-03-04T14:10:03.192908Z
+721
+emrepisja
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+6363
+
+PEPSUtilTestCase.java
+file
+
+
+
+
+2013-12-20T12:27:56.518475Z
+f54beadeab9af936f44af326eb1116d2
+2013-11-01T20:35:30.927048Z
+96
+emferreri
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+16714
+
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/AttributeProvidersMapTestCase.java.svn-base b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/AttributeProvidersMapTestCase.java.svn-base
new file mode 100644
index 000000000..89f5adbed
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/AttributeProvidersMapTestCase.java.svn-base
@@ -0,0 +1,134 @@
+package eu.stork.peps.tests;
+
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertTrue;
+
+import org.junit.Test;
+
+import eu.stork.peps.auth.commons.AttributeProvider;
+import eu.stork.peps.auth.commons.AttributeProvidersMap;
+import eu.stork.peps.auth.commons.AttributeSource;
+import eu.stork.peps.auth.commons.Country;
+import eu.stork.peps.auth.commons.IAttributeProvidersMap;
+import eu.stork.peps.auth.commons.IPersonalAttributeList;
+import eu.stork.peps.auth.commons.PersonalAttributeList;
+
+/**
+ * The AttributeSource's Test Case.
+ *
+ * @author Stelios Lelis (stelios.lelis@aegean.gr), Elias Pastos (ilias@aegean.gr)
+ *
+ * @version $Revision: $, $Date: $
+ */
+public class AttributeProvidersMapTestCase {
+
+ @Test
+ public void testObjectOK1() {
+ final IAttributeProvidersMap map = new AttributeProvidersMap();
+ final AttributeSource source = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL");
+ final IPersonalAttributeList pal = new PersonalAttributeList();
+ boolean outcome = false;
+
+ //Add a single item
+ map.put(source, pal);
+
+ if ( map.containsKey(source) ) {
+ outcome = true;
+ }
+
+ assertTrue(outcome);
+ }
+
+ @Test
+ public void testObjectOK2() {
+ final IAttributeProvidersMap map = new AttributeProvidersMap();
+ final AttributeSource source = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL");
+ final IPersonalAttributeList pal = new PersonalAttributeList();
+ boolean outcome = false;
+
+ //Add a single item
+ map.put(source, pal);
+
+ if ( map.containsKey(source) ) {
+ if ( map.get(source)!=null ) {
+ outcome = true;
+ }
+ }
+
+ assertTrue(outcome);
+ }
+
+ @Test
+ public void testObjectOK3() {
+ final IAttributeProvidersMap map = new AttributeProvidersMap();
+ final AttributeSource source = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL");
+ final AttributeSource target = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL");
+ final IPersonalAttributeList pal = new PersonalAttributeList();
+ boolean outcome = false;
+
+ //Add a single item
+ map.put(source, pal);
+
+ if ( map.containsKey(target) ) {
+ outcome = true;
+ }
+
+ assertTrue(outcome);
+ }
+
+ @Test
+ public void testObjectOK4() {
+ final IAttributeProvidersMap map = new AttributeProvidersMap();
+ final AttributeSource source = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL");
+ final AttributeSource target = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL");
+ final IPersonalAttributeList pal = new PersonalAttributeList();
+ boolean outcome = false;
+
+ //Add a single item
+ map.put(source, pal);
+
+ if ( map.containsKey(target) ) {
+ if ( map.get(target)!=null ) {
+ outcome = true;
+ }
+ }
+
+ assertTrue(outcome);
+ }
+
+ @Test
+ public void testObjectNOK1() {
+ final IAttributeProvidersMap map = new AttributeProvidersMap();
+ final AttributeSource source = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL");
+ final AttributeSource target = new AttributeSource(new Country("ID1", "Name 1"), "URL");
+ final IPersonalAttributeList pal = new PersonalAttributeList();
+ boolean outcome = false;
+
+ //Add a single item
+ map.put(source, pal);
+
+ if ( map.containsKey(target) ) {
+ outcome = true;
+ }
+
+ assertFalse(outcome);
+ }
+
+ @Test
+ public void testObjectNOK2() {
+ final IAttributeProvidersMap map = new AttributeProvidersMap();
+ final AttributeSource source = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL");
+ final AttributeSource target = new AttributeSource(new AttributeProvider("ID2", "Name 1", null), "URL");
+ final IPersonalAttributeList pal = new PersonalAttributeList();
+ boolean outcome = false;
+
+ //Add a single item
+ map.put(source, pal);
+
+ if ( map.containsKey(target) ) {
+ outcome = true;
+ }
+
+ assertFalse(outcome);
+ }
+}
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/AttributeSourceTestCase.java.svn-base b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/AttributeSourceTestCase.java.svn-base
new file mode 100644
index 000000000..e0f685ade
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/AttributeSourceTestCase.java.svn-base
@@ -0,0 +1,88 @@
+package eu.stork.peps.tests;
+
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertTrue;
+
+import org.junit.Test;
+
+import eu.stork.peps.auth.commons.AttributeProvider;
+import eu.stork.peps.auth.commons.AttributeSource;
+import eu.stork.peps.auth.commons.Country;
+
+/**
+ * The AttributeSource's Test Case.
+ *
+ * @author Stelios Lelis (stelios.lelis@aegean.gr), Elias Pastos (ilias@aegean.gr)
+ *
+ * @version $Revision: $, $Date: $
+ */
+public final class AttributeSourceTestCase {
+ private final AttributeSource ap1 = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL1");
+ private final AttributeSource ap2 = new AttributeSource(new AttributeProvider("ID2", "Name 2", null), "URL2");
+ private final AttributeSource ap3 = new AttributeSource(new AttributeProvider("ID1", "Name 2", null), "URL2");
+ private final AttributeSource ap4 = new AttributeSource(new AttributeProvider("ID1", "Name 2", null), "URL1");
+ private final AttributeSource ap5 = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL1");
+
+ private final AttributeSource c1 = new AttributeSource(new Country("ID1", "Name 1"), "URL1");
+ private final AttributeSource c2 = new AttributeSource(new Country("ID2", "Name 2"), "URL2");
+ private final AttributeSource c3 = new AttributeSource(new Country("ID1", "Name 2"), "URL2");
+ private final AttributeSource c4 = new AttributeSource(new Country("ID1", "Name 2"), "URL1");
+ private final AttributeSource c5 = new AttributeSource(new Country("ID1", "Name 1"), "URL1");
+
+ @Test
+ public void testNotEquals1() {
+ assertFalse(ap1.equals(ap2));
+ }
+
+ @Test
+ public void testNotEquals2() {
+ assertFalse(ap1.equals(c1));
+ }
+
+ @Test
+ public void testNotEquals3() {
+ assertFalse(c1.equals(c2));
+ }
+
+ @Test
+ public void testEquals1() {
+ assertTrue(ap1.equals(ap3));
+ }
+
+ @Test
+ public void testEquals2() {
+ assertTrue(ap1.equals(ap4));
+ }
+
+ @Test
+ public void testEquals3() {
+ assertTrue(ap1.equals(ap5));
+ }
+
+ @Test
+ public void testEquals4() {
+ assertTrue(c1.equals(c3));
+ }
+
+ @Test
+ public void testEquals5() {
+ assertTrue(c1.equals(c4));
+ }
+
+ @Test
+ public void testEquals6() {
+ assertTrue(c1.equals(c5));
+ }
+
+ @Test
+ public void testEquals7() {
+ final Object obj = ap5;
+ assertTrue(ap1.equals(obj));
+ }
+
+ @Test
+ public void testEquals8() {
+ final Object obj = c5;
+ assertTrue(c1.equals(obj));
+ }
+}
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/AttributeUtilTestCase.java.svn-base b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/AttributeUtilTestCase.java.svn-base
new file mode 100644
index 000000000..77fc4b9c2
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/AttributeUtilTestCase.java.svn-base
@@ -0,0 +1,537 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.tests;
+
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.assertEquals;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+import org.junit.Test;
+
+import eu.stork.peps.auth.commons.AttributeUtil;
+import eu.stork.peps.auth.commons.IPersonalAttributeList;
+import eu.stork.peps.auth.commons.PEPSValues;
+import eu.stork.peps.auth.commons.PersonalAttributeList;
+
+/**
+ * The AttributeUtil's Test Case.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com
+ *
+ * @version $Revision: $, $Date: $
+ */
+public final class AttributeUtilTestCase {
+
+ /**
+ * Empty String to be used on the tests.
+ */
+ private static final String EMPTY_STRING = "";
+
+ /**
+ * Tuple value sample to be used on the tests.
+ */
+ private static final String[] TUPLE_STRING = new String[] { "age", "true",
+ "[18]", "Available" };
+
+ /**
+ * Complex value to be used on escape/unescape tests.
+ */
+ private static final String COMPLEX_VAL = "postalCode=4100,"
+ + "apartmentNumber=A,state=Porto,countryCodeAddress=PT,streetNumber=379,"
+ + "streetName=Avenida Sidonio Pais,town=Porto,";
+
+ /**
+ * Escaped Complex value to be used on escape/unescape tests.
+ */
+ private static final String ESC_COMPLEX_VAL = "postalCode=4100%44"
+ + "apartmentNumber=A%44state=Porto%44countryCodeAddress=PT%44"
+ + "streetNumber=379%44streetName=Avenida Sidonio Pais%44town=Porto%44";
+
+ /**
+ * Simple value to be used on escape/unescape tests.
+ */
+ private static final String SIMPLE_VAL = "Avenida da Boavista, Porto";
+
+ /**
+ * Escaped simple value to be used on escape/unescape tests.
+ */
+ private static final String ESC_SIMPLE_VAL = "Avenida da Boavista%44 Porto";
+
+ /**
+ * Simple text to be used on escape/unescape tests. Must match the escaped
+ * text.
+ */
+ private static final String SIMPLE_TEXT = "John Doe";
+
+ /**
+ * Tests the {@link AttributeUtil#escape(String)} method for the given complex
+ * attribute value (canonical address' example attribute value).
+ */
+ @Test
+ public void testEscapeSpecialCharsComplexVal() {
+ assertEquals(AttributeUtil.escape(COMPLEX_VAL), ESC_COMPLEX_VAL);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#escape(String)} method for the given
+ * attribute value.
+ */
+ @Test
+ public void testEscapeSpecialCharsVal() {
+ assertEquals(AttributeUtil.escape(SIMPLE_VAL), ESC_SIMPLE_VAL);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#escape(String)} method for the given simple
+ * text: no special characters to escape.
+ */
+ @Test
+ public void testEscapeNormalChars() {
+ assertEquals(AttributeUtil.escape(SIMPLE_TEXT), SIMPLE_TEXT);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#unescape(String)} method for the given
+ * escape complex attribute value (canonical address' example attribute
+ * value).
+ */
+ @Test
+ public void testUnescapeSpecialCharsComplexVal() {
+ assertEquals(AttributeUtil.unescape(ESC_COMPLEX_VAL), COMPLEX_VAL);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#escape(String)} method for the given escape
+ * attribute value.
+ */
+ @Test
+ public void testUnescapeSpecialCharsVal() {
+ assertEquals(AttributeUtil.unescape(ESC_SIMPLE_VAL), SIMPLE_VAL);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#escape(String)} method for the given simple
+ * text: no special characters to unescape.
+ */
+ @Test
+ public void testUnescapeNormalChars() {
+ assertEquals(AttributeUtil.unescape(SIMPLE_TEXT), SIMPLE_TEXT);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#appendIfNotNull(StringBuilder, Object)}
+ * method for the given empty string.
+ */
+ @Test
+ public void testAppendIfNotNullEmptyStr() {
+ final StringBuilder strBuilder = new StringBuilder(SIMPLE_TEXT);
+ AttributeUtil.appendIfNotNull(strBuilder, EMPTY_STRING);
+ assertEquals(strBuilder.toString(), SIMPLE_TEXT);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#appendIfNotNull(StringBuilder, Object)}
+ * method for the given string.
+ */
+ @Test
+ public void testAppendIfNotNullStr() {
+ final StringBuilder strBuilder = new StringBuilder();
+ AttributeUtil.appendIfNotNull(strBuilder, SIMPLE_TEXT);
+ assertEquals(strBuilder.toString(), SIMPLE_TEXT);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#appendIfNotNull(StringBuilder, Object)}
+ * method for the given null value.
+ */
+ @Test
+ public void testAppendIfNotNull() {
+ final StringBuilder strBuilder = new StringBuilder();
+ AttributeUtil.appendIfNotNull(strBuilder, null);
+ assertEquals(strBuilder.toString(), EMPTY_STRING);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#listToString(List, String)} method for the
+ * given List with two values.
+ */
+ @Test
+ public void testListToStringTwoVals() {
+ final List<String> vals = new ArrayList<String>();
+ vals.add(SIMPLE_VAL);
+ vals.add(SIMPLE_TEXT);
+
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append(ESC_SIMPLE_VAL);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+ strBuilder.append(SIMPLE_TEXT);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+
+ assertEquals(
+ AttributeUtil.listToString(vals,
+ PEPSValues.ATTRIBUTE_VALUE_SEP.toString()), strBuilder.toString());
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#listToString(List, String)} method for the
+ * given List with one values.
+ */
+ @Test
+ public void testListToStringOneVal() {
+ final List<String> vals = new ArrayList<String>();
+ vals.add(SIMPLE_VAL);
+
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append(ESC_SIMPLE_VAL);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+
+ assertEquals(
+ AttributeUtil.listToString(vals,
+ PEPSValues.ATTRIBUTE_VALUE_SEP.toString()), strBuilder.toString());
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#listToString(List, String)} method for the
+ * given List with one value.
+ */
+ @Test
+ public void testListToStringEmptyVal() {
+ final List<String> vals = new ArrayList<String>();
+
+ final StringBuilder strBuilder = new StringBuilder();
+
+ assertEquals(
+ AttributeUtil.listToString(vals,
+ PEPSValues.ATTRIBUTE_VALUE_SEP.toString()), strBuilder.toString());
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#mapToString(java.util.Map, String)} method
+ * for the given Map with one value.
+ */
+ @Test
+ public void testMapToStringOneVal() {
+ final Map<String, String> vals = new HashMap<String, String>();
+ vals.put("CanonicalAddress", COMPLEX_VAL);
+
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append("CanonicalAddress=");
+ strBuilder.append(ESC_COMPLEX_VAL);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+
+ assertEquals(AttributeUtil.mapToString(vals,
+ PEPSValues.ATTRIBUTE_VALUE_SEP.toString()), strBuilder.toString());
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#mapToString(java.util.Map, String)} method
+ * for the given empty Map.
+ */
+ @Test
+ public void testMapToStringEmptyVal() {
+ final Map<String, String> vals = new HashMap<String, String>();
+
+ final StringBuilder strBuilder = new StringBuilder();
+
+ assertEquals(AttributeUtil.mapToString(vals,
+ PEPSValues.ATTRIBUTE_VALUE_SEP.toString()), strBuilder.toString());
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * invalid List.
+ */
+ @Test
+ public void testIsValidValueInvalidList() {
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append(ESC_SIMPLE_VAL);
+ strBuilder.append("]");
+ assertFalse(AttributeUtil.isValidValue(strBuilder.toString()));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * null value.
+ */
+ @Test
+ public void testIsValidValueNullList() {
+ assertFalse(AttributeUtil.isValidValue(null));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * empty List.
+ */
+ @Test
+ public void testIsValidValueEmptyList() {
+ assertTrue(AttributeUtil.isValidValue("[]"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * empty List.
+ */
+ @Test
+ public void testIsValidValueEmptyCommaList() {
+ assertTrue(AttributeUtil.isValidValue("[,]"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * one simple value List.
+ */
+ @Test
+ public void testIsValidValueOneValueList() {
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append("[");
+ strBuilder.append(ESC_SIMPLE_VAL);
+ strBuilder.append("]");
+ assertTrue(AttributeUtil.isValidValue(strBuilder.toString()));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * one simple value List.
+ */
+ @Test
+ public void testIsValidValueOneValueCommaList() {
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append("[");
+ strBuilder.append(ESC_SIMPLE_VAL);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+ strBuilder.append("]");
+ assertTrue(AttributeUtil.isValidValue(strBuilder.toString()));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * one complex value List.
+ */
+ @Test
+ public void testIsValidValueOneComplexValueList() {
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append("[");
+ strBuilder.append(ESC_COMPLEX_VAL);
+ strBuilder.append("]");
+ assertTrue(AttributeUtil.isValidValue(strBuilder.toString()));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * one complex value List.
+ */
+ @Test
+ public void testIsValidValueOneComplexValueCommaList() {
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append("[");
+ strBuilder.append(ESC_COMPLEX_VAL);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+ strBuilder.append("]");
+ assertTrue(AttributeUtil.isValidValue(strBuilder.toString()));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * multi value List.
+ */
+ @Test
+ public void testIsValidValueMultiValueList() {
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append("[");
+ strBuilder.append(ESC_SIMPLE_VAL);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+ strBuilder.append(SIMPLE_TEXT);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+ strBuilder.append("]");
+ assertTrue(AttributeUtil.isValidValue(strBuilder.toString()));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * invalid multi value List.
+ */
+ @Test
+ public void testIsValidValueInvalidMultiValueList() {
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append(ESC_SIMPLE_VAL);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+ strBuilder.append(SIMPLE_TEXT);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+ strBuilder.append("]");
+ assertFalse(AttributeUtil.isValidValue(strBuilder.toString()));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidType(String)} method for the given
+ * true type.
+ */
+ @Test
+ public void testIsValidTypetrue() {
+ assertTrue(AttributeUtil.isValidType("true"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidType(String)} method for the given
+ * True type.
+ */
+ @Test
+ public void testIsValidTypeTrue() {
+ assertTrue(AttributeUtil.isValidType("True"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidType(String)} method for the given
+ * TRUE type.
+ */
+ @Test
+ public void testIsValidTypeTRUE() {
+ assertTrue(AttributeUtil.isValidType("TRUE"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidType(String)} method for the given
+ * invalid type.
+ */
+ @Test
+ public void testIsValidTypeInvalidType() {
+ assertFalse(AttributeUtil.isValidType("str"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidType(String)} method for the given
+ * false type.
+ */
+ @Test
+ public void testIsValidTypefalse() {
+ assertTrue(AttributeUtil.isValidType("false"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidType(String)} method for the given
+ * False type.
+ */
+ @Test
+ public void testIsValidTypeFalse() {
+ assertTrue(AttributeUtil.isValidType("False"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidType(String)} method for the given
+ * FALSE type.
+ */
+ @Test
+ public void testIsValidTypeFALSEVal() {
+ assertTrue(AttributeUtil.isValidType("False"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidType(String)} method for the given
+ * null.
+ */
+ @Test
+ public void testIsValidTypeNullVal() {
+ assertFalse(AttributeUtil.isValidType(null));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#hasValidTuples(String[])} method for the
+ * given valid tuple.
+ */
+ @Test
+ public void testHasValidTuples() {
+ assertTrue(AttributeUtil.hasValidTuples(TUPLE_STRING));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#hasValidTuples(String[])} method for the
+ * given invalid tuple.
+ */
+ @Test
+ public void testHasValidTuplesInvalid() {
+ final String[] tuple = new String[]{"name", "type"};
+ assertFalse(AttributeUtil.hasValidTuples(tuple));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#hasValidTuples(String[])} method for the
+ * given invalid tuple with valid size.
+ */
+ @Test
+ public void testHasValidTuplesSameSizeInvalidValues() {
+ final String[] tuple = new String[] { "age", "type", "[18]", "Available"};
+ assertFalse(AttributeUtil.hasValidTuples(tuple));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#hasValidTuples(String[])} method for the
+ * given null value.
+ */
+ @Test
+ public void testHasValidTuplesNull() {
+ assertFalse(AttributeUtil.hasValidTuples(null));
+ }
+
+ /**
+ * Tests the
+ * {@link AttributeUtil#checkMandatoryAttributes(IPersonalAttributeList)}
+ * method for the given attribute list..
+ */
+ @Test
+ public void testCheckMandatoryAttributes() {
+ final IPersonalAttributeList attrList = new PersonalAttributeList();
+ attrList.populate("isAgeOver:true:[18,]:Available;");
+ assertTrue(AttributeUtil.checkMandatoryAttributes(attrList));
+
+ }
+
+ /**
+ * Tests the
+ * {@link AttributeUtil#checkMandatoryAttributes(IPersonalAttributeList)}
+ * method for the given null value.
+ */
+ @Test(expected = NullPointerException.class)
+ public void testCheckMandatoryAttributesNullAttrList() {
+ assertTrue(AttributeUtil.checkMandatoryAttributes(null));
+ }
+
+ /**
+ * Tests the
+ * {@link AttributeUtil#checkMandatoryAttributes(IPersonalAttributeList)}
+ * method for the given empty attribute list.
+ */
+ @Test
+ public void testCheckMandatoryAttributesEmptyAttrList() {
+ final IPersonalAttributeList attrList = new PersonalAttributeList();
+ assertTrue(AttributeUtil.checkMandatoryAttributes(attrList));
+ }
+
+ /**
+ * Tests the
+ * {@link AttributeUtil#checkMandatoryAttributes(IPersonalAttributeList)}
+ * method for the given attribute list (missing mandatory attribute).
+ */
+ @Test
+ public void testCheckMandatoryAttributesMissingAttr() {
+ final IPersonalAttributeList attrList = new PersonalAttributeList();
+ attrList.populate("isAgeOver:true:[]:NotAvailable;");
+ assertFalse(AttributeUtil.checkMandatoryAttributes(attrList));
+ }
+
+}
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/ComplexAttributesMarshalling.java.svn-base b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/ComplexAttributesMarshalling.java.svn-base
new file mode 100644
index 000000000..c7e195fa6
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/ComplexAttributesMarshalling.java.svn-base
@@ -0,0 +1,187 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ *
+ * ---
+ *
+ * Test cases for marshalling complex attributes.
+ *
+ * Implemented are two testcases for marshalling and unmarshalling. These testcases are
+ * for canonical residenc address and has bank account.
+ */
+
+package eu.stork.peps.tests;
+
+import java.io.File;
+import java.io.FileNotFoundException;
+import java.io.FileOutputStream;
+
+import javax.xml.bind.JAXBContext;
+import javax.xml.bind.JAXBElement;
+import javax.xml.bind.JAXBException;
+import javax.xml.bind.Marshaller;
+import javax.xml.bind.Unmarshaller;
+import javax.xml.transform.stream.StreamSource;
+
+import org.junit.Test;
+
+import eu.stork.peps.complex.attributes.CanonicalAddressType;
+import eu.stork.peps.complex.attributes.HasAccountInBankType;
+import eu.stork.peps.complex.attributes.ObjectFactory;
+
+/**
+ * @author Advania
+ *
+ * Examples on how to use the jaxb marshaller.
+ *
+ * The classes are created from the StorkcomplexAttributes.xsd schema located in resources.
+ *
+ * @version $Revision: 1.00 $, $Date: 2014-17-02 11:15:00 $
+ *
+ */
+
+public class ComplexAttributesMarshalling {
+
+ /**
+ * Test marshalling canonical address
+ * <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+ * <canonicalResidenceAddress xmlns="urn:eu:stork:names:tc:STORK:1.0:assertion">
+ * <countryCodeAddress>IS</countryCodeAddress>
+ * <state>Reykjavik</state>
+ * <municipalityCode>RVK</municipalityCode>
+ * <town>Reykjavik</town>
+ * <postalCode>101</postalCode>
+ * <streetName>Laugavegur</streetName>
+ * <streetNumber>1</streetNumber>
+ * <apartmentNumber>10</apartmentNumber>
+ * </canonicalResidenceAddress>
+ */
+ @Test
+ public void testMarshallCanonicalResidencAddress()
+ {
+ try
+ {
+ final CanonicalAddressType object = new CanonicalAddressType();
+ object.setApartmentNumber("10");
+ object.setCountryCodeAddress("IS");
+ object.setMunicipalityCode("RVK");
+ object.setPostalCode("101");
+ object.setState("Reykjavik");
+ object.setStreetName("Laugavegur");
+ object.setStreetNumber("1");
+ object.setTown("Reykjavik");
+
+ final JAXBContext context = JAXBContext.newInstance(CanonicalAddressType.class);
+ final Marshaller m = context.createMarshaller();
+ m.setProperty(Marshaller.JAXB_FORMATTED_OUTPUT, true);
+ final ObjectFactory objf = new ObjectFactory();
+
+ m.marshal(objf.createCanonicalResidenceAddress(object), new FileOutputStream("CanonicalAddressType.xml"));
+ m.marshal(objf.createCanonicalResidenceAddress(object), System.out);
+ }
+ catch (JAXBException | FileNotFoundException e)
+ {
+ e.printStackTrace();
+ }
+ }
+
+ /**
+ * Test unmarshalling canonical address
+ * <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+ * <canonicalResidenceAddress xmlns="urn:eu:stork:names:tc:STORK:1.0:assertion">
+ * <countryCodeAddress>IS</countryCodeAddress>
+ * <state>Reykjavik</state>
+ * <municipalityCode>RVK</municipalityCode>
+ * <town>Reykjavik</town>
+ * <postalCode>101</postalCode>
+ * <streetName>Laugavegur</streetName>
+ * <streetNumber>1</streetNumber>
+ * <apartmentNumber>10</apartmentNumber>
+ * </canonicalResidenceAddress>
+ */
+ @Test
+ public void testUnmarshallCanonicalAddress()
+ {
+ JAXBContext uContext;
+ try
+ {
+ uContext = JAXBContext.newInstance(CanonicalAddressType.class);
+ final Unmarshaller u = uContext.createUnmarshaller();
+ final File file = new File("CanonicalAddressType.xml");
+
+ final JAXBElement<CanonicalAddressType> root = u.unmarshal(new StreamSource(file), CanonicalAddressType.class);
+ final CanonicalAddressType foo = root.getValue();
+
+ final String A = foo.getStreetName();
+ final String B = foo.getStreetNumber();
+
+ System.out.println("Streetname: " + A);
+ System.out.println("Streetnumber: " + B);
+
+ }
+ catch (final JAXBException e)
+ {
+ e.printStackTrace();
+ }
+ }
+
+ /**
+ * Test marshalling has bank account
+ * <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+ * <hasAccountInBank xmlns="urn:eu:stork:names:tc:STORK:1.0:assertion">
+ * <bankName>Arion</bankName>
+ * <AQAA>3</AQAA>
+ * </hasAccountInBank>
+ */
+ @Test
+ public void testMarshallHasBankAccount()
+ {
+ try
+ {
+ final HasAccountInBankType object = new HasAccountInBankType();
+ object.setAQAA(3);
+ object.setBankName("Arion Bank");
+ final JAXBContext context = JAXBContext.newInstance(HasAccountInBankType.class);
+ final Marshaller m = context.createMarshaller();
+ final ObjectFactory o = new ObjectFactory();
+ m.marshal(o.createHasAccountInBank(object), new FileOutputStream ("hasbankaccount.xml"));
+ m.marshal(o.createHasAccountInBank(object), System.out);
+
+ } catch (JAXBException | FileNotFoundException e) {
+ e.printStackTrace();
+ }
+ }
+ /**
+ * Test unmarshalling has bank account
+ * <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+ * <hasAccountInBank xmlns="urn:eu:stork:names:tc:STORK:1.0:assertion">
+ * <bankName>Arion</bankName>
+ * <AQAA>3</AQAA>
+ * </hasAccountInBank>
+ */
+ @Test
+ public void testUnmarshallHasBankAccount()
+ {
+ try
+ {
+ final JAXBContext context = JAXBContext.newInstance(HasAccountInBankType.class);
+ final Unmarshaller um = context.createUnmarshaller();
+ final File file = new File("hasbankaccount.xml");
+ final JAXBElement<HasAccountInBankType> root = um.unmarshal(new StreamSource(file), HasAccountInBankType.class);
+ final HasAccountInBankType foo = root.getValue();
+ System.out.println(foo.getBankName());
+ } catch (final JAXBException e) {
+ e.printStackTrace();
+ }
+ }
+
+}
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/DateUtilTestCase.java.svn-base b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/DateUtilTestCase.java.svn-base
new file mode 100644
index 000000000..5d2296997
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/DateUtilTestCase.java.svn-base
@@ -0,0 +1,294 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.tests;
+
+import java.sql.Timestamp;
+import java.util.Properties;
+
+import org.joda.time.DateTime;
+import org.junit.Assert;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+import eu.stork.peps.auth.commons.DateUtil;
+import eu.stork.peps.auth.commons.PEPSUtil;
+import eu.stork.peps.auth.commons.exceptions.SecurityPEPSException;
+
+/**
+ * The PersonalAttribute's Test Case.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.2 $, $Date: 2010-11-17 05:17:03 $
+ */
+public final class DateUtilTestCase {
+
+ /**
+ * Stork Format date.
+ */
+ private static final String FORMAT = "yyyyMMdd";
+
+ /**
+ * Expected 10 value.
+ */
+ private static final int TEN = 10;
+
+ /**
+ * Expected 11 value.
+ */
+ private static final int ELEVEN = 11;
+
+ /**
+ * The testing Date ("current" date).
+ */
+ private static final DateTime TESTDATE = new DateTime(2011, 10, 10, 15, 20,
+ 0, 0);
+
+ /**
+ * Init DateUtilTestCase class.
+ */
+ @BeforeClass
+ public static void runsBeforeTheTestSuite() {
+ final Properties configs = new Properties();
+ configs.setProperty("invalidAgeDateValue.code", "35");
+ configs.setProperty("invalidAttributeValue.code", "34");
+ configs
+ .setProperty(
+ "invalidAttributeValue.message",
+ "Unexpected or invalid content was encountered within a "
+ + "<saml:Attribute> or <saml:AttributeValue> element.");
+ PEPSUtil.createInstance(configs);
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given year against
+ * the testDate: 2011-10-10 15:20:00.0. Must return 10.
+ */
+ @Test
+ public void calculateAgeFromYear() {
+ Assert.assertTrue(TEN == DateUtil.calculateAge("2000", TESTDATE, FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given year and month
+ * against the testDate: 2011-10-10 15:20:00.0. Must return 11.
+ */
+ @Test
+ public void calculateAgeFromEarlyMonth() {
+ Assert.assertTrue(ELEVEN == DateUtil.calculateAge("200001", TESTDATE,
+ FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given year and month
+ * against the testDate: 2011-10-10 15:20:00.0. Must return 10.
+ */
+ @Test
+ public void calculateAgeFromSameMonth() {
+ Assert.assertTrue(TEN == DateUtil.calculateAge("200010", TESTDATE, FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given year and month
+ * against the testDate: 2011-10-10 15:20:00.0. Must return 10.
+ */
+ @Test
+ public void calculateAgeFromLaterMonth() {
+ Assert.assertTrue(TEN == DateUtil.calculateAge("200011", TESTDATE, FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return 11.
+ */
+ @Test
+ public void calculateAgeFromEarlyFullDate() {
+ Assert.assertTrue(ELEVEN == DateUtil.calculateAge("20000101", TESTDATE,
+ FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return 11.
+ */
+ @Test
+ public void calculateAgeFromSameDay() {
+ Assert.assertTrue(ELEVEN == DateUtil.calculateAge("20001010", TESTDATE,
+ FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return 10.
+ */
+ @Test
+ public void calculateAgeFromLaterFullDate() {
+ Assert.assertTrue(TEN == DateUtil
+ .calculateAge("20001011", TESTDATE, FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return a
+ * SecurityPEPSException exception.
+ */
+ @Test(expected = SecurityPEPSException.class)
+ public void calculateAgeFromInvalidDate() {
+ DateUtil.calculateAge("200", TESTDATE, FORMAT);
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return a
+ * SecurityPEPSException exception.
+ */
+ @Test(expected = SecurityPEPSException.class)
+ public void calculateAgeFromInvalidMonth() {
+ DateUtil.calculateAge("200013", TESTDATE, FORMAT);
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return a
+ * SecurityPEPSException exception.
+ */
+ @Test(expected = SecurityPEPSException.class)
+ public void calculateAgeFromInvalidDay() {
+ DateUtil.calculateAge("20000230", TESTDATE, FORMAT);
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return a
+ * SecurityPEPSException exception.
+ */
+ @Test(expected = SecurityPEPSException.class)
+ public void calculateAgeFromNullDate() {
+ DateUtil.calculateAge(null, TESTDATE, FORMAT);
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return a
+ * SecurityPEPSException exception.
+ */
+ @Test(expected = SecurityPEPSException.class)
+ public void calculateAgeFromNullCurDate() {
+ DateUtil.calculateAge("2000", null, FORMAT);
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return a
+ * SecurityPEPSException exception.
+ */
+ @Test(expected = SecurityPEPSException.class)
+ public void calculateAgeFromNullFormat() {
+ DateUtil.calculateAge("2000", TESTDATE, null);
+ }
+
+ /**
+ * Tests the {@link DateUtil#isValidFormatDate} method for the given year.
+ * Must return true
+ */
+ @Test
+ public void isValidFormatDateFromYear() {
+ Assert.assertTrue(DateUtil.isValidFormatDate("2000", FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#isValidFormatDate} method for the given year and
+ * month. Must return true.
+ */
+ @Test
+ public void isValidFormatDateFromMonth() {
+ Assert.assertTrue(DateUtil.isValidFormatDate("200001", FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#isValidFormatDate} method for the given year.
+ * Must return false.
+ */
+ @Test
+ public void isValidFormatDate() {
+ Assert.assertTrue(DateUtil.isValidFormatDate("20000101", FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#isValidFormatDate} method for the given year.
+ * Must return false.
+ */
+ @Test
+ public void isValidFormatDateInvalidYear() {
+ Assert.assertFalse(DateUtil.isValidFormatDate("200", FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#isValidFormatDate} method for the given year.
+ * Must return false.
+ */
+ @Test
+ public void isValidFormatDateInvalidMonth() {
+ Assert.assertFalse(DateUtil.isValidFormatDate("200013", FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#isValidFormatDate} method for the given year.
+ * Must return false.
+ */
+ @Test
+ public void isValidFormatDateInvalidDate() {
+ Assert.assertFalse(DateUtil.isValidFormatDate("20010229", FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#isValidFormatDate} method for the given year.
+ * Must return false.
+ */
+ @Test
+ public void isValidFormatDateNullDate() {
+ Assert.assertFalse(DateUtil.isValidFormatDate(null, FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#isValidFormatDate} method for the given year.
+ * Must return false.
+ */
+ @Test
+ public void isValidFormatDateNullFormat() {
+ Assert.assertFalse(DateUtil.isValidFormatDate("2000", null));
+ }
+
+ /**
+ * Tests the {@link DateUtil#currentTimeStamp()} method for the current
+ * TimeStamp (TS). Must return true.
+ */
+ @Test
+ public void testCurrentTimeStampBefore() {
+ Timestamp ts = DateUtil.currentTimeStamp();
+ Assert.assertNotSame(ts, DateUtil.currentTimeStamp());
+ }
+
+ /**
+ * Tests the {@link DateUtil#currentTimeStamp()} method for the current
+ * TimeStamp (TS). Must return true.
+ */
+ @Test
+ public void testCurrentTimeStampAfter() {
+ Timestamp ts = DateUtil.currentTimeStamp();
+ Assert.assertEquals(DateUtil.currentTimeStamp(), ts);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/PEPSUtilTestCase.java.svn-base b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/PEPSUtilTestCase.java.svn-base
new file mode 100644
index 000000000..d4841ed43
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/PEPSUtilTestCase.java.svn-base
@@ -0,0 +1,553 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.tests;
+
+import static org.junit.Assert.assertArrayEquals;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotSame;
+import static org.junit.Assert.assertNull;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.assertFalse;
+
+import java.util.Properties;
+
+import org.junit.Assert;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+import eu.stork.peps.auth.commons.IPersonalAttributeList;
+import eu.stork.peps.auth.commons.PEPSErrors;
+import eu.stork.peps.auth.commons.PEPSParameters;
+import eu.stork.peps.auth.commons.PEPSUtil;
+import eu.stork.peps.auth.commons.PersonalAttributeList;
+import eu.stork.peps.auth.commons.exceptions.InternalErrorPEPSException;
+import eu.stork.peps.auth.commons.exceptions.InvalidParameterPEPSException;
+
+/**
+ * The PEPSUtil's Test Case.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com
+ *
+ * @version $Revision: $, $Date: $
+ */
+public final class PEPSUtilTestCase {
+
+ /**
+ * Message example.
+ */
+ private static final String MESSAGE_SAMPLE = "003002 - Authentication Failed";
+
+ /**
+ * Error message example.
+ */
+ private static final String ERROR_MESSAGE_SAMPLE = "Authentication Failed";
+
+ /**
+ * Error code example.
+ */
+ private static final String ERROR_CODE_SAMPLE = "003002";
+
+ /**
+ * Properties values for testing proposes.
+ */
+ private static final Properties CONFIGS1 = new Properties();
+
+ /**
+ * Properties values for testing proposes.
+ */
+ private static final Properties CONFIGS2 = new Properties();
+
+ /**
+ * The empty string value: "".
+ */
+ private static final String EMPTY_STRING = "";
+
+ /**
+ * The empty byte value: [].
+ */
+ private static final byte[] EMPTY_BYTE = new byte[] {};
+
+ /**
+ * The empty byte hash value.
+ */
+ private static final byte[] EMPTY_HASH_BYTE = new byte[] { -49, -125, -31,
+ 53, 126, -17, -72, -67, -15, 84, 40, 80, -42, 109, -128, 7, -42, 32, -28,
+ 5, 11, 87, 21, -36, -125, -12, -87, 33, -45, 108, -23, -50, 71, -48, -47,
+ 60, 93, -123, -14, -80, -1, -125, 24, -46, -121, 126, -20, 47, 99, -71, 49,
+ -67, 71, 65, 122, -127, -91, 56, 50, 122, -7, 39, -38, 62 };
+
+ /**
+ * The SAML example byte[] value.
+ */
+ private static final byte[] SAML_BYTE_SAMPLE = new byte[] { 60, 115, 97, 109,
+ 108, 62, 46, 46, 46, 60, 47, 115, 97, 109, 108 };
+
+ /**
+ * The SAML's Base64 example value.
+ */
+ private static final String SAML_BASE64_SAMPLE = "PHNhbWw+Li4uPC9zYW1s";
+
+ /**
+ * The SAML's Base64 byte[] example value.
+ */
+ private static byte[] SAML_BASE64_BYTE_SAMPLE = new byte[] { 80, 72, 78, 104,
+ 98, 87, 119, 43, 76, 105, 52, 117, 80, 67, 57, 122, 89, 87, 49, 115 };
+
+ /**
+ * The SAML's Base64 Hash byte[] example value.
+ */
+ private static byte[] HASH_BYTE_SAMPLE = new byte[] { 67, 38, 11, 115, 49,
+ -5, 54, -85, 38, 43, -99, 96, 71, -41, 50, -96, 71, -86, 90, -97, 66, -67,
+ 90, 101, 30, 82, -13, 60, -106, -72, -103, -75, 19, 2, -107, 107, -6, -56,
+ 34, -111, -44, -57, -26, -5, 33, 78, -1, 30, 21, 74, -26, 118, -46, -12,
+ -102, 12, -56, 30, -59, -104, -21, -42, -103, 82 };
+
+ /**
+ * Init PEPSUtilTestCase class.
+ */
+ @BeforeClass
+ public static void runsBeforeTheTestSuite() {
+
+ CONFIGS1.setProperty("max.attrList.size", "20000");
+ CONFIGS1.setProperty("attrList.code", "202005");
+ CONFIGS1.setProperty("attrList.message", "invalid.attrList.parameter");
+
+ CONFIGS1.setProperty("max.qaaLevel.size", "1");
+ CONFIGS1.setProperty("max.spUrl.size", "inv");
+ CONFIGS1.setProperty("validation.active", "true");
+ CONFIGS1.setProperty("hashDigest.className",
+ "org.bouncycastle.crypto.digests.SHA512Digest");
+ CONFIGS1.setProperty("invalidAgeDateValue.code", "35");
+ CONFIGS1.setProperty("invalidAttributeValue.code", "34");
+ CONFIGS1.setProperty("invalidAttributeValue.message",
+ "Unexpected or invalid content was encountered within a "
+ + "<saml:Attribute> or <saml:AttributeValue> element.");
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#createInstance(Properties)} method for the given
+ * properties object.
+ */
+ @Test
+ public void testCreateInstance() {
+ Assert.assertNotNull(PEPSUtil.createInstance(CONFIGS2));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getConfigs()}.
+ */
+ @Test
+ public void testGetConfigs() {
+ final PEPSUtil pepsUtils = PEPSUtil.createInstance(CONFIGS1);
+ assertEquals(pepsUtils.getConfigs(), CONFIGS1);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getConfigs()}.
+ */
+ @Test
+ public void testGetConfigsDifferent() {
+ final PEPSUtil pepsUtils = PEPSUtil.createInstance(CONFIGS1);
+ assertNotSame(pepsUtils.getConfigs(), CONFIGS2);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getConfig(String)} method for the given existing
+ * config.
+ */
+ @Test
+ public void testGetConfigExists() {
+ assertEquals(PEPSUtil.getConfig("hashDigest.className"),
+ "org.bouncycastle.crypto.digests.SHA512Digest");
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getConfig(String)} method for the given not
+ * existing config.
+ */
+ @Test
+ public void testGetConfigNoExists() {
+ assertNull(PEPSUtil.getConfig("doesnt.exists"));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getConfig(String)} method for the given null
+ * value.
+ */
+ @Test(expected = NullPointerException.class)
+ public void testGetConfigNull() {
+ assertNull(PEPSUtil.getConfig(null));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#isValidParameter(String, String)} method for the
+ * given param values.
+ */
+ @Test
+ public void testIsValidParameterExists() {
+ assertTrue(PEPSUtil.isValidParameter("qaaLevel", "1"));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#isValidParameter(String, String)} method for the
+ * given param values.
+ */
+ @Test
+ public void testIsValidParameterExistsGreat() {
+ assertFalse(PEPSUtil.isValidParameter("qaaLevel", "12"));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#isValidParameter(String, String)} method for the
+ * given param values.
+ */
+ @Test
+ public void testIsValidParameterExistsIvalidConf() {
+ assertFalse(PEPSUtil
+ .isValidParameter("spUrl", "http://localhost:8080/SP/"));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#isValidParameter(String, String)} method for the
+ * given param values.
+ */
+ @Test
+ public void testIsValidParameterNotExists() {
+ assertFalse(PEPSUtil.isValidParameter("doesntexists",
+ "http://localhost:8080/SP/"));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#isValidParameter(String, String)} method for the
+ * given param values.
+ */
+ @Test
+ public void testIsValidParameterNullParamName() {
+ assertFalse(PEPSUtil.isValidParameter(null, "http://localhost:8080/SP/"));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#isValidParameter(String, String)} method for the
+ * given param values.
+ */
+ @Test
+ public void testIsValidParameterNullParamValue() {
+ assertFalse(PEPSUtil.isValidParameter("spUrl", null));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#validateParameter(String, String, Object)} method
+ * for the given object values.
+ */
+ @Test
+ public void testValidateParameterValid() {
+ final IPersonalAttributeList persAttrList = new PersonalAttributeList();
+ persAttrList.populate("isAgeOver:true:[15,]:Available;");
+ PEPSUtil.validateParameter("ServiceProviderAction",
+ PEPSParameters.ATTRIBUTE_LIST.toString(), persAttrList);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#validateParameter(String, String, Object)} method
+ * for the given string values.
+ */
+ @Test(expected = InvalidParameterPEPSException.class)
+ public void testValidateParameterNull() {
+ PEPSUtil.validateParameter("ServiceProviderAction",
+ PEPSParameters.ATTRIBUTE_LIST.toString(), null);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#validateParameter(String, String, String)} method
+ * for the given string values.
+ *
+ * The tested class just invokes
+ * {@link PEPSUtil#validateParameter(String, String, String, String, String)}
+ * so further tests will be later.
+ */
+ @Test
+ public void testValidateParameter() {
+ PEPSUtil.validateParameter("ServiceProviderAction",
+ PEPSParameters.ATTRIBUTE_LIST.toString(),
+ "isAgeOver:true:[15,]:Available;");
+ }
+
+ /**
+ * Tests the
+ * {@link PEPSUtil#validateParameter(String, String, String, PEPSErrors)}
+ * method for the given string value and {@link PEPSErrors} enum.
+ *
+ * The tested class just invokes
+ * {@link PEPSUtil#validateParameter(String, String, String, String, String)}
+ * so further tests will be later.
+ */
+ @Test
+ public void testValidateParameterPEPSErrors() {
+ PEPSUtil.validateParameter("CountrySelectorAction",
+ PEPSParameters.ATTRIBUTE_LIST.toString(),
+ "isAgeOver:true:[15,]:Available;",
+ PEPSErrors.SP_COUNTRY_SELECTOR_INVALID_ATTR);
+ }
+
+ /**
+ * Tests the
+ * {@link PEPSUtil#validateParameter(String, String, String, String, String)}
+ * method for the given string values.
+ */
+ @Test
+ public void testValidateParameterValidParams() {
+ PEPSUtil.validateParameter("ServiceProviderAction", "qaaLevel", "1",
+ "qaaLevel.code", "qaaLevel.message");
+ }
+
+ /**
+ * Tests the
+ * {@link PEPSUtil#validateParameter(String, String, String, String, String)}
+ * method for the given string values.
+ */
+ @Test(expected = InvalidParameterPEPSException.class)
+ public void testValidateParameterInvalidParamValue() {
+ PEPSUtil.validateParameter("ServiceProviderAction", "qaaLevel", "10",
+ "qaaLevel.code", "qaaLevel.message");
+ }
+
+ /**
+ * Tests the
+ * {@link PEPSUtil#validateParameter(String, String, String, String, String)}
+ * method for the given string values.
+ */
+ @Test(expected = InvalidParameterPEPSException.class)
+ public void testValidateParameterInvalidParamName() {
+ PEPSUtil.validateParameter("ServiceProviderAction", "doesnt.exists", "1",
+ "qaaLevel.code", "qaaLevel.message");
+ }
+
+ /**
+ * Tests the
+ * {@link PEPSUtil#validateParameter(String, String, String, String, String)}
+ * method for the given string values.
+ */
+ @Test(expected = InvalidParameterPEPSException.class)
+ public void testValidateParameterNullParamName() {
+ PEPSUtil.validateParameter("ServiceProviderAction", null, "1",
+ "qaaLevel.code", "qaaLevel.message");
+ }
+
+ /**
+ * Tests the
+ * {@link PEPSUtil#validateParameter(String, String, String, String, String)}
+ * method for the given string values.
+ */
+ @Test(expected = InvalidParameterPEPSException.class)
+ public void testValidateParameterNullParamValue() {
+ PEPSUtil.validateParameter("ServiceProviderAction", "qaaLevel", null,
+ "qaaLevel.code", "qaaLevel.message");
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#encodeSAMLToken(byte[])} method for the given
+ * string value.
+ */
+ @Test
+ public void testEncodeSAMLToken() {
+ assertEquals(PEPSUtil.encodeSAMLToken(SAML_BYTE_SAMPLE), SAML_BASE64_SAMPLE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#encodeSAMLToken(byte[])} method for the given
+ * null.
+ */
+ @Test(expected = NullPointerException.class)
+ public void testEncodeSAMLTokenNull() {
+ assertNotSame(PEPSUtil.encodeSAMLToken(null), SAML_BASE64_SAMPLE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#encodeSAMLToken(byte[])} method for the given
+ * empty byte[] value.
+ */
+ @Test
+ public void testEncodeSAMLTokenEmpty() {
+ assertEquals(PEPSUtil.encodeSAMLToken(EMPTY_BYTE), EMPTY_STRING);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#decodeSAMLToken(byte[])} method for the given
+ * byte[] value.
+ */
+ @Test
+ public void testDecodeSAMLToken() {
+ assertArrayEquals(PEPSUtil.decodeSAMLToken(SAML_BASE64_SAMPLE),
+ SAML_BYTE_SAMPLE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#decodeSAMLToken(byte[])} method for the given
+ * null value.
+ */
+ @Test(expected = NullPointerException.class)
+ public void testDecodeSAMLTokenNull() {
+ assertNotSame(PEPSUtil.decodeSAMLToken(null), SAML_BYTE_SAMPLE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#decodeSAMLToken(byte[])} method for the given
+ * empty string value.
+ */
+ @Test(expected = StringIndexOutOfBoundsException.class)
+ public void testDecodeSAMLTokenEmpty() {
+ assertTrue(PEPSUtil.decodeSAMLToken(EMPTY_STRING) == EMPTY_BYTE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#hashPersonalToken(byte[])} method for the given
+ * byte[] value.
+ */
+ @Test
+ public void testHashPersonalToken() {
+ assertArrayEquals(PEPSUtil.hashPersonalToken(SAML_BASE64_BYTE_SAMPLE),
+ HASH_BYTE_SAMPLE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#hashPersonalToken(byte[])} method for the given
+ * null value.
+ */
+ @Test(expected = InternalErrorPEPSException.class)
+ public void testHashPersonalTokenNull() {
+ assertNull(PEPSUtil.hashPersonalToken(null));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#hashPersonalToken(byte[])} method for the given
+ * empty value.
+ */
+ @Test
+ public void testHashPersonalTokenEmpty() {
+ assertArrayEquals(PEPSUtil.hashPersonalToken(EMPTY_BYTE), EMPTY_HASH_BYTE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorCode(String)} method for the given
+ * correct message.
+ */
+ @Test
+ public void testGetStorkErrorCodeExists() {
+ assertEquals(PEPSUtil.getStorkErrorCode(MESSAGE_SAMPLE), ERROR_CODE_SAMPLE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorCode(String)} method for the given
+ * invalid message.
+ */
+ @Test
+ public void testGetStorkErrorCodeNoExists() {
+ assertNull(PEPSUtil.getStorkErrorCode(ERROR_MESSAGE_SAMPLE));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorCode(String)} method for the given
+ * empty message.
+ */
+ @Test
+ public void testGetStorkErrorCodeEmpty() {
+ assertNull(PEPSUtil.getStorkErrorCode(EMPTY_STRING));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorCode(String)} method for the given
+ * null message.
+ */
+ @Test
+ public void testGetStorkErrorCodeNull() {
+ assertNull(PEPSUtil.getStorkErrorCode(null));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorCode(String)} method for the given
+ * invalid message.
+ */
+ @Test
+ public void testGetStorkErrorCodeWithSepFake() {
+ assertNull(PEPSUtil.getStorkErrorCode("-"));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorCode(String)} method for the given
+ * invalid message.
+ */
+ @Test
+ public void testGetStorkErrorCodeWithSepAndCodeFake() {
+ assertNull(PEPSUtil.getStorkErrorCode("000001 -"));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorMessage(String)} method for the
+ * given correct message.
+ */
+ @Test
+ public void testGetStorkErrorMessageExists() {
+ assertEquals(PEPSUtil.getStorkErrorMessage(MESSAGE_SAMPLE),
+ ERROR_MESSAGE_SAMPLE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorMessage(String)} method for the
+ * given invalid message.
+ */
+ @Test
+ public void testGetStorkErrorMessageNoExists() {
+ assertEquals(PEPSUtil.getStorkErrorMessage(ERROR_MESSAGE_SAMPLE),
+ ERROR_MESSAGE_SAMPLE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorMessage(String)} method for the
+ * given empty message.
+ */
+ @Test
+ public void testGetStorkErrorMessageEmpty() {
+ assertEquals(PEPSUtil.getStorkErrorMessage(EMPTY_STRING),
+ EMPTY_STRING);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorMessage(String)} method for the
+ * given null message.
+ */
+ @Test
+ public void testGetStorkErrorMessageNull() {
+ assertNull(PEPSUtil.getStorkErrorMessage(null));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorMessage(String)} method for the
+ * given invalid message.
+ */
+ @Test
+ public void testGetStorkErrorMessageWithSepFake() {
+ assertEquals(PEPSUtil.getStorkErrorMessage("-"),"-");
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorMessage(String)} method for the
+ * given invalid message.
+ */
+ @Test
+ public void testGetStorkErrorMessageWithSepAndCodeFake() {
+ assertEquals(PEPSUtil.getStorkErrorMessage("000001 -"),"000001 -");
+ }
+
+}
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/PersonalAttributeListTestCase.java.svn-base b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/PersonalAttributeListTestCase.java.svn-base
new file mode 100644
index 000000000..7052b320a
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/PersonalAttributeListTestCase.java.svn-base
@@ -0,0 +1,747 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.tests;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.Map;
+
+import org.junit.Assert;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+import eu.stork.peps.auth.commons.PersonalAttribute;
+import eu.stork.peps.auth.commons.PersonalAttributeList;
+import eu.stork.peps.auth.commons.STORKStatusCode;
+
+/**
+ * The PersonalAttributeList's Test Case.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.5 $, $Date: 2010-11-17 05:17:02 $
+ */
+public final class PersonalAttributeListTestCase {
+
+ /**
+ * isAgeOver constant value.
+ */
+ private static final String ISAGEOVER_CONS = "isAgeOver";
+
+ /**
+ * 1 constant value.
+ */
+ private static final int ONE_CONS = 1;
+
+ /**
+ * 2 constant value.
+ */
+ private static final int TWO_CONS = 2;
+
+ /**
+ * An empty attribute.
+ */
+ @SuppressWarnings("unused")
+ private static final PersonalAttributeList EMPTY_ATTR_LIST =
+ new PersonalAttributeList(0);
+
+ /**
+ * An attribute with a complex value (canonicalResidenceAddress).
+ */
+ private static PersonalAttribute complexAttrValue = null;
+
+ /**
+ * Simple attribute value list string.
+ */
+ private static final String SIMPLE_ATTRLIST =
+ "isAgeOver:true:[15,]:Available;";
+
+ /**
+ * Simple attribute value list string.
+ */
+ private static final String SIMPLE_ATTRLIST2 =
+ "isAgeOver:true:[18,]:Available;";
+
+ /**
+ * Simple attribute value list string.
+ */
+ private static final String SIMPLE_ATTRLIST3 =
+ "isAgeOver:true:[15,]:Available;isAgeOver:true:[18,]:Available;";
+
+ /**
+ * Simple attribute value list string.
+ */
+ private static final String SIMPLE_ATTRLIST3_REVERSE =
+ "isAgeOver:true:[18,]:Available;isAgeOver:true:[15,]:Available;";
+ /**
+ * Simple attribute value list string.
+ */
+ private static final String COMPLEX_ATTRLIST =
+ "canonicalResidenceAddress:true:[postalCode=4100,apartmentNumber=Ed. B,"
+ + "state=Porto,countryCodeAddress=PT,streetNumber=379,"
+ + "streetName=Avenida Sidonio Pais,town=Porto,]:Available;";
+ /**
+ * Mix attribute list string.
+ */
+ private static final String STR_MIX_ATTR_LIST =
+ "isAgeOver:true:[15,]:Available;canonicalResidenceAddress:true:["
+ + "postalCode=4100,apartmentNumber=Ed.B,state=Porto,countryCodeAddress=PT,"
+ + "streetNumber=379,streetName=Avenida Sidonio Pais,town=Porto,]:"
+ + "Available;";
+
+ /**
+ * Mix attribute list 2 string.
+ */
+ private static final String STR_MIX_ATTR_LIST2 =
+ "isAgeOver:true:[15,]:Available;canonicalResidenceAddress:true:["
+ + "postalCode=4100,apartmentNumber=Ed.B,state=Porto,countryCodeAddress=PT,"
+ + "streetNumber=379,streetName=Avenida Sidonio Pais,town=Porto,]:Available;"
+ + "mandateContent:true:["
+ + "isJoint=\"isjoint\",typeOfPower=\"power\",ValidTo=\"validto\",validfrom=\"validfrom\",AQAA=\"3\",isChained=\"ischained\",]:"
+ + "Available;";
+
+ /**
+ * Attribute List example.
+ */
+ @SuppressWarnings({ "serial" })
+ private static final PersonalAttribute ATTR_VALUE = new PersonalAttribute(
+ "age", true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ /**
+ * Init PersonalAttributeListTestCase class.
+ */
+ @SuppressWarnings("serial")
+ @BeforeClass
+ public static void runsBeforeTheTestSuite() {
+ final Map<String, String> values = new HashMap<String, String>() {
+ {
+ put("countryCodeAddress", "PT");
+ put("state", "Porto");
+ put("town", "Porto");
+ put("postalCode", "4100");
+ put("streetName", "Avenida Sidonio Pais");
+ put("streetNumber", "379");
+ put("apartmentNumber", "Ed. B");
+ }
+ };
+
+ complexAttrValue =
+ new PersonalAttribute("canonicalResidenceAddress", true, values,
+ STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ }
+
+ /**
+ * Testing Personal Attribute List add method. Personal Attribute list must be
+ * size 1 - Simple attribute.
+ */
+ @Test
+ public void testAddSimpleAttr() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(ATTR_VALUE);
+ Assert.assertTrue(attrList.size() == 1);
+ }
+
+ /**
+ * Testing Personal Attribute List add method. Personal Attribute list must be
+ * size 1 - Complex attribute.
+ */
+ @Test
+ public void testAddCompleAttr() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(complexAttrValue);
+ Assert.assertTrue(attrList.size() == 1);
+ }
+
+ /**
+ * Testing Personal Attribute List add method. Personal Attribute list must be
+ * size 0 - no attribute.
+ */
+ @Test
+ public void testAddNull() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(null);
+ Assert.assertTrue(attrList.size() == 0);
+ }
+
+ /**
+ * Testing Personal Attribute List add method. Same attribute name added
+ * twice. Personal Attribute list must be size 2 - IsAgeOver attribute added
+ * twice.
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testAddSameAttrName() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("18");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(attrValueUnder);
+ attrList.add(attrValueOver);
+ Assert.assertTrue(attrList.size() == 2);
+ }
+
+ /**
+ * Testing Personal Attribute List add method. Same attribute name added
+ * twice. Personal Attribute list must be size 2 - IsAgeOver attribute added
+ * twice.
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testAddSameAttrNameEmpty() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(attrValueUnder);
+ attrList.add(attrValueOver);
+ Assert.assertTrue(attrList.size() == 2);
+ }
+
+ /**
+ * Testing Personal Attribute List put method. Personal Attribute list must be
+ * size 1 - Simple Value.
+ */
+ @Test
+ public void testPutSimpleAttr() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.put(ATTR_VALUE.getName(), ATTR_VALUE);
+ Assert.assertTrue(attrList.size() == 1);
+ }
+
+ /**
+ * Testing Personal Attribute List put method. Personal Attribute list must be
+ * size 1 - Complex Value.
+ */
+ @Test
+ public void testPutComplexAttr() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.put(ATTR_VALUE.getName(), complexAttrValue);
+ Assert.assertTrue(attrList.size() == 1);
+ }
+
+ /**
+ * Testing Personal Attribute List put method. Personal Attribute list must be
+ * size 0 - no attribute.
+ */
+ @Test
+ public void testPutNull() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.put("", null);
+ Assert.assertTrue(attrList.size() == 0);
+ }
+
+ /**
+ * Testing Personal Attribute List put method. Personal Attribute list must be
+ * size 2 - IsAgeOver attribute added twice.
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testPutSameAttrName() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("18");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.put(attrValueUnder.getName(), attrValueUnder);
+ attrList.put(attrValueOver.getName(), attrValueOver);
+ Assert.assertTrue(attrList.size() == 2);
+ }
+
+ /**
+ * Testing Personal Attribute List put method. Personal Attribute list must be
+ * size 2 - IsAgeOver attribute added twice.
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testPutSameAttrNameEmpty() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.put(attrValueUnder.getName(), attrValueUnder);
+ attrList.put(attrValueOver.getName(), attrValueOver);
+ Assert.assertTrue(attrList.size() == 2);
+ }
+
+ /**
+ * Testing Personal Attribute List get method. Personal Attribute list must be
+ * size 1 - Simple attribute.
+ */
+ @Test
+ public void testGetSimpleAttr() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(ATTR_VALUE);
+ Assert.assertEquals(ATTR_VALUE, attrList.get(ATTR_VALUE.getName()));
+ }
+
+ /**
+ * Testing Personal Attribute List add method. Personal Attribute list must be
+ * size 1 - Complex attribute.
+ */
+ @Test
+ public void testGetCompleAttr() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(complexAttrValue);
+ Assert.assertEquals(complexAttrValue.toString(),
+ attrList.get(complexAttrValue.getName()).toString());
+ }
+
+ /**
+ * Testing Personal Attribute List get method. Personal Attribute list must be
+ * size 2 - IsAgeOver attribute.
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testGetIsAgeOverAttr() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("18");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(attrValueUnder);
+ attrList.add(attrValueOver);
+ Assert.assertEquals(SIMPLE_ATTRLIST,
+ attrList.get(attrValueUnder.getName()).toString());
+ Assert.assertEquals(SIMPLE_ATTRLIST2,
+ attrList.get(attrValueOver.getName()).toString());
+ }
+
+ /**
+ * Testing Personal Attribute List populate method. Personal Attribute list
+ * must be size 1 - Simple attribute.
+ */
+ @Test
+ public void testPopulateSimpleAttr() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.populate(SIMPLE_ATTRLIST);
+ Assert.assertTrue(attrList.size() == 1);
+ }
+
+ /**
+ * Testing Personal Attribute List populate method. Personal Attribute list
+ * must be size 1 - Complex attribute.
+ */
+ @Test
+ public void testPopulateComplexAttr() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.populate(COMPLEX_ATTRLIST);
+ Assert.assertTrue(attrList.size() == 1);
+ }
+
+ /**
+ * Testing Personal Attribute List populate method. Personal Attribute list
+ * must be size 1 - Simple and Complex attribute.
+ */
+ @Test
+ public void testPopulateMixAttrs() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.populate(STR_MIX_ATTR_LIST);
+ Assert.assertTrue(attrList.size() == 2);
+ }
+
+ /**
+ * Testing Personal Attribute List toString method using add.
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testToStringFromAdd() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("18");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(attrValueUnder);
+ attrList.add(attrValueOver);
+ Assert.assertEquals(SIMPLE_ATTRLIST3_REVERSE, attrList.toString());
+ }
+
+ /**
+ * Testing Personal Attribute List toString method using put.
+ *
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testToStringFromPut() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("18");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.put(attrValueUnder.getName(), attrValueUnder);
+ attrList.put(attrValueOver.getName(), attrValueOver);
+ Assert.assertEquals(SIMPLE_ATTRLIST3_REVERSE, attrList.toString());
+ }
+
+ /**
+ * Testing Personal Attribute List toString method using populate.
+ */
+ @Test
+ public void testToStringFromSimplePopulate() {
+ final String strAttrList = "isAgeOver:true";
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.populate(strAttrList);
+ Assert.assertEquals("isAgeOver:true:[]:;", attrList.toString());
+ }
+
+ /**
+ * Testing Personal Attribute List toString method using populate.
+ */
+ @Test
+ public void testToStringFromPopulate() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.populate(SIMPLE_ATTRLIST3);
+ Assert.assertEquals(SIMPLE_ATTRLIST3_REVERSE, attrList.toString());
+ }
+
+ /**
+ * Testing Personal Attribute List populate method, with invalid values.
+ */
+ @Test
+ public void testPopulateWithInvalidValuesFormat() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate("name:type:values:status;");
+ Assert.assertEquals(pal, new PersonalAttributeList());
+ }
+
+ /**
+ * Testing Personal Attribute List populate method, with invalid format.
+ */
+ @Test
+ public void testPopulateWithInvalidFormat() {
+
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate("name:type::status;");
+ Assert.assertEquals(pal, new PersonalAttributeList());
+ }
+
+ /**
+ * Testing Personal Attribute List clone method using add.
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testCloneFromAdd() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("18");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(attrValueUnder);
+ attrList.add(attrValueOver);
+ Assert.assertNotSame(attrList, attrList.clone());
+ }
+
+ /**
+ * Testing Personal Attribute List clone method using put.
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testCloneFromPut() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("18");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.put(attrValueUnder.getName(), attrValueUnder);
+ attrList.put(attrValueOver.getName(), attrValueOver);
+ Assert.assertNotSame(attrList, attrList.clone());
+ }
+
+ /**
+ * Testing Personal Attribute List clone method using populate.
+ */
+ @Test
+ public void testCloneFromPopulate() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(SIMPLE_ATTRLIST3);
+ Assert.assertNotSame(pal, pal.clone());
+ }
+
+ /**
+ * Testing Personal Attribute List iterator.
+ */
+ @Test
+ public void testIterator() {
+ final String strAttrList =
+ "isAgeOver:true:[15,]:Available;isAgeOver:true:[18,]:Available;";
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(strAttrList);
+ final Iterator<PersonalAttribute> itAttr = pal.iterator();
+ while (itAttr.hasNext()) {
+ final PersonalAttribute attr = itAttr.next();
+ Assert.assertEquals(ISAGEOVER_CONS, attr.getName());
+ }
+ }
+
+ /**
+ * Testing Personal Attribute List's GetOptionalAttributes method with empty attribute list.
+ */
+ @Test
+ public void testGetOptionalAttributesWithEmptyList() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ Assert.assertTrue(pal.getOptionalAttributes().isEmpty());
+ }
+
+ /**
+ * Testing Personal Attribute List's GetOptionalAttributes method without optional attributes.
+ */
+ @Test
+ public void testGetOptionalAttributesWithoutOptional() {
+ final String strAttrList =
+ "isAgeOver:true:[15,]:Available;isAgeOver:true:[18,]:Available;";
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(strAttrList);
+ Assert.assertTrue(pal.getOptionalAttributes().isEmpty());
+ }
+
+ /**
+ * Testing Personal Attribute List's GetOptionalAttributes method with one optional attribute.
+ */
+ @Test
+ public void testGetOptionalAttributesWithOneOptional() {
+ final String strAttrList =
+ "age:false:[]:;isAgeOver:true:[15,]:;isAgeOver:true:[18,]:;";
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(strAttrList);
+ Assert.assertTrue(pal.getOptionalAttributes().size() == ONE_CONS);
+ }
+
+ /**
+ * Testing Personal Attribute List's GetOptionalAttributes method with two optional attribute.
+ */
+ @Test
+ public void testGetOptionalAttributesWithOnlyOptional() {
+ final String strAttrList =
+ "age:false:[]:;isAgeOver:false:[18,]:;";
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(strAttrList);
+ Assert.assertTrue(pal.getOptionalAttributes().size() == TWO_CONS);
+ }
+
+ /**
+ * Testing Personal Attribute List's getMandatoryAttributes method with empty attribute list.
+ */
+ @Test
+ public void testGetMandatoryAttributesWithEmptyList() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ Assert.assertTrue(pal.getMandatoryAttributes().isEmpty());
+ }
+
+ /**
+ * Testing Personal Attribute List's getMandatoryAttributes method without mandatory attributes.
+ */
+ @Test
+ public void testGetMandatoryAttributesWithoutMandatory() {
+ final String strAttrList =
+ "isAgeOver:false:[15,]:Available;isAgeOver:false:[18,]:Available;";
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(strAttrList);
+ Assert.assertTrue(pal.getMandatoryAttributes().isEmpty());
+ }
+
+ /**
+ * Testing Personal Attribute List's GetMandatoryAttributes method with one mandatory attribute.
+ */
+ @Test
+ public void testGetMandatoryAttributesWithOneMandatory() {
+ final String strAttrList =
+ "age:true:[]:;isAgeOver:false:[15,]:;isAgeOver:false:[18,]:;";
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(strAttrList);
+ Assert.assertTrue(pal.getMandatoryAttributes().size() == ONE_CONS);
+ }
+
+ /**
+ * Testing Personal Attribute List's GetMandatoryAttributes method with two mandatory attribute.
+ */
+ @Test
+ public void testGetMandatoryAttributesWithOnlyMandatory() {
+ final String strAttrList =
+ "age:true:[]:;isAgeOver:true:[18,]:;";
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(strAttrList);
+ Assert.assertTrue(pal.getMandatoryAttributes().size() == TWO_CONS);
+ }
+
+ /**
+ * Testing Personal Attribute List's getSimpleValueAttributes method with empty attribute list.
+ */
+ @Test
+ public void testGetSimpleValueAttributesWithEmptyList() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ Assert.assertTrue(pal.getSimpleValueAttributes().isEmpty());
+ }
+
+ /**
+ * Testing Personal Attribute List's getSimpleValueAttributes() method without simple attributes.
+ */
+ @Test
+ public void testGetSimpleValueAttributesWithoutSimple() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(COMPLEX_ATTRLIST);
+ Assert.assertTrue(pal.getSimpleValueAttributes().isEmpty());
+ }
+
+ /**
+ * Testing Personal Attribute List's getSimpleValueAttributes() method with one simple attribute.
+ */
+ @Test
+ public void testGetSimpleValueAttributesWithOneSimple() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(STR_MIX_ATTR_LIST);
+ Assert.assertTrue(pal.getSimpleValueAttributes().size() == ONE_CONS);
+ }
+
+ /**
+ * Testing Personal Attribute List's GetMandatoryAttributes method with two simple attribute.
+ */
+ @Test
+ public void testGetSimpleValueAttributesWithOnlySimple() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(SIMPLE_ATTRLIST3);
+ Assert.assertTrue(pal.getSimpleValueAttributes().size() == TWO_CONS);
+ }
+
+ /**
+ * Testing Personal Attribute List's getComplexValueAttributes method with empty attribute list.
+ */
+ @Test
+ public void testGetComplexAttributesWithEmptyList() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ Assert.assertTrue(pal.getComplexAttributes().isEmpty());
+ }
+
+ /**
+ * Testing Personal Attribute List's getComplexAttributes() method without complex attributes.
+ */
+ @Test
+ public void testGetComplexAttributesWithoutSimple() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(SIMPLE_ATTRLIST2);
+ Assert.assertTrue(pal.getComplexAttributes().isEmpty());
+ }
+
+ /**
+ * Testing Personal Attribute List's getComplexAttributes() method with one complex attribute.
+ */
+ @Test
+ public void testGetComplexAttributesWithOneComplex() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(STR_MIX_ATTR_LIST);
+ Assert.assertTrue(pal.getComplexAttributes().size() == ONE_CONS);
+ }
+
+ /**
+ * Testing Personal Attribute List's GetMandatoryAttributes method with only two Complex attribute.
+ */
+ @Test
+ public void testGetComplexAttributesWithOnlyComplex() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(STR_MIX_ATTR_LIST2);
+ Assert.assertTrue(pal.getComplexAttributes().size() == TWO_CONS);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/PersonalAttributeTestCase.java.svn-base b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/PersonalAttributeTestCase.java.svn-base
new file mode 100644
index 000000000..458d510e0
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/PersonalAttributeTestCase.java.svn-base
@@ -0,0 +1,182 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.tests;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.Map;
+
+import junit.framework.Assert;
+
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+import eu.stork.peps.auth.commons.PersonalAttribute;
+import eu.stork.peps.auth.commons.STORKStatusCode;
+
+/**
+ * The PersonalAttribute's Test Case.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.4 $, $Date: 2010-11-17 05:17:03 $
+ */
+public final class PersonalAttributeTestCase {
+
+ /**
+ * An empty attribute.
+ */
+ private static final PersonalAttribute EMPTYATTR = new PersonalAttribute();
+
+ /**
+ * An attribute with a complex value (canonicalResidenceAddress).
+ */
+ private static PersonalAttribute complexAttrValue = null;
+
+ /**
+ * An attribute with a simple value (age).
+ */
+ @SuppressWarnings("serial")
+ private static final PersonalAttribute ATTR_VALUE = new PersonalAttribute(
+ "age", true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ /**
+ * Init PersonalAttributeTestCase class.
+ */
+ @SuppressWarnings("serial")
+ @BeforeClass
+ public static void runsBeforeTheTestSuite() {
+ final Map<String, String> values = new HashMap<String, String>() {
+ {
+ put("countryCodeAddress", "PT");
+ put("state", "Porto");
+ put("town", "Porto");
+ put("postalCode", "4100");
+ put("streetName", "Avenida Sidonio Pais");
+ put("streetNumber", "379");
+ put("apartmentNumber", "B");
+ }
+ };
+
+ complexAttrValue =
+ new PersonalAttribute("canonicalResidenceAddress", true, values,
+ STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#toString()} method for the given simple
+ * attribute value. Values must match.
+ */
+ @Test
+ public void testToStringValues() {
+ Assert.assertEquals("age:true:[15,]:Available;", ATTR_VALUE.toString());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#toString()} method for the given complex
+ * attribute value. Values must match.
+ */
+ @Test
+ public void testToStringComplexValues() {
+ Assert.assertEquals(
+ "canonicalResidenceAddress:true:[postalCode=4100,apartmentNumber=B,"
+ + "state=Porto,countryCodeAddress=PT,streetNumber=379,"
+ + "streetName=Avenida Sidonio Pais,town=Porto,]:Available;",
+ complexAttrValue.toString());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#isEmptyStatus()} method for the given
+ * empty attribute. Must return true.
+ */
+ @Test
+ public void testToIsEmptyStatusWithNull() {
+ Assert.assertTrue(EMPTYATTR.isEmptyStatus());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#isEmptyStatus()} method for the given
+ * new attribute. Must return true.
+ */
+ @Test
+ public void testToIsEmptyStatusWithEmptyString() {
+ final PersonalAttribute attr = (PersonalAttribute) EMPTYATTR.clone();
+ attr.setStatus("");
+ Assert.assertTrue(attr.isEmptyStatus());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#isEmptyValue()} method for the given
+ * empty attribute. Must return true.
+ */
+ @Test
+ public void testToIsEmptyValueWithNull() {
+ final PersonalAttribute attr = (PersonalAttribute) EMPTYATTR.clone();
+ attr.setValue(null);
+ Assert.assertTrue(attr.isEmptyValue());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#isEmptyValue()} method for the given
+ * empty attribute. Must return true.
+ */
+ @Test
+ public void testToIsEmptyValue() {
+ Assert.assertTrue(EMPTYATTR.isEmptyValue());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#isEmptyComplexValue()} method for the
+ * given empty attribute. Must return true.
+ */
+ @Test
+ public void testToIsEmptyComplexValueWithNull() {
+ final PersonalAttribute attr = (PersonalAttribute) EMPTYATTR.clone();
+ attr.setComplexValue(null);
+ Assert.assertTrue(attr.isEmptyComplexValue());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#isEmptyComplexValue()} method for the
+ * given empty attribute. Must return true.
+ */
+ @Test
+ public void testToIsEmptyComplexValueWithEmptyComplexValue() {
+ Assert.assertTrue(EMPTYATTR.isEmptyComplexValue());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#clone()} method for the given attribute.
+ * Must return true.
+ */
+ @Test
+ public void testCloneToComplexValue() {
+ Assert.assertNotSame(complexAttrValue, complexAttrValue.clone());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#clone()} method for the given attribute.
+ * Must return true.
+ */
+ @Test
+ public void testCloneToValue() {
+ Assert.assertNotSame(ATTR_VALUE, ATTR_VALUE.clone());
+ }
+}
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/package-info.java.svn-base b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/package-info.java.svn-base
new file mode 100644
index 000000000..452602210
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/.svn/text-base/package-info.java.svn-base
@@ -0,0 +1,5 @@
+/**
+ * This package provides all JUnit test classes.
+ */
+package eu.stork.peps.tests;
+
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/AttributeProvidersMapTestCase.java b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/AttributeProvidersMapTestCase.java
new file mode 100644
index 000000000..89f5adbed
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/AttributeProvidersMapTestCase.java
@@ -0,0 +1,134 @@
+package eu.stork.peps.tests;
+
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertTrue;
+
+import org.junit.Test;
+
+import eu.stork.peps.auth.commons.AttributeProvider;
+import eu.stork.peps.auth.commons.AttributeProvidersMap;
+import eu.stork.peps.auth.commons.AttributeSource;
+import eu.stork.peps.auth.commons.Country;
+import eu.stork.peps.auth.commons.IAttributeProvidersMap;
+import eu.stork.peps.auth.commons.IPersonalAttributeList;
+import eu.stork.peps.auth.commons.PersonalAttributeList;
+
+/**
+ * The AttributeSource's Test Case.
+ *
+ * @author Stelios Lelis (stelios.lelis@aegean.gr), Elias Pastos (ilias@aegean.gr)
+ *
+ * @version $Revision: $, $Date: $
+ */
+public class AttributeProvidersMapTestCase {
+
+ @Test
+ public void testObjectOK1() {
+ final IAttributeProvidersMap map = new AttributeProvidersMap();
+ final AttributeSource source = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL");
+ final IPersonalAttributeList pal = new PersonalAttributeList();
+ boolean outcome = false;
+
+ //Add a single item
+ map.put(source, pal);
+
+ if ( map.containsKey(source) ) {
+ outcome = true;
+ }
+
+ assertTrue(outcome);
+ }
+
+ @Test
+ public void testObjectOK2() {
+ final IAttributeProvidersMap map = new AttributeProvidersMap();
+ final AttributeSource source = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL");
+ final IPersonalAttributeList pal = new PersonalAttributeList();
+ boolean outcome = false;
+
+ //Add a single item
+ map.put(source, pal);
+
+ if ( map.containsKey(source) ) {
+ if ( map.get(source)!=null ) {
+ outcome = true;
+ }
+ }
+
+ assertTrue(outcome);
+ }
+
+ @Test
+ public void testObjectOK3() {
+ final IAttributeProvidersMap map = new AttributeProvidersMap();
+ final AttributeSource source = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL");
+ final AttributeSource target = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL");
+ final IPersonalAttributeList pal = new PersonalAttributeList();
+ boolean outcome = false;
+
+ //Add a single item
+ map.put(source, pal);
+
+ if ( map.containsKey(target) ) {
+ outcome = true;
+ }
+
+ assertTrue(outcome);
+ }
+
+ @Test
+ public void testObjectOK4() {
+ final IAttributeProvidersMap map = new AttributeProvidersMap();
+ final AttributeSource source = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL");
+ final AttributeSource target = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL");
+ final IPersonalAttributeList pal = new PersonalAttributeList();
+ boolean outcome = false;
+
+ //Add a single item
+ map.put(source, pal);
+
+ if ( map.containsKey(target) ) {
+ if ( map.get(target)!=null ) {
+ outcome = true;
+ }
+ }
+
+ assertTrue(outcome);
+ }
+
+ @Test
+ public void testObjectNOK1() {
+ final IAttributeProvidersMap map = new AttributeProvidersMap();
+ final AttributeSource source = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL");
+ final AttributeSource target = new AttributeSource(new Country("ID1", "Name 1"), "URL");
+ final IPersonalAttributeList pal = new PersonalAttributeList();
+ boolean outcome = false;
+
+ //Add a single item
+ map.put(source, pal);
+
+ if ( map.containsKey(target) ) {
+ outcome = true;
+ }
+
+ assertFalse(outcome);
+ }
+
+ @Test
+ public void testObjectNOK2() {
+ final IAttributeProvidersMap map = new AttributeProvidersMap();
+ final AttributeSource source = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL");
+ final AttributeSource target = new AttributeSource(new AttributeProvider("ID2", "Name 1", null), "URL");
+ final IPersonalAttributeList pal = new PersonalAttributeList();
+ boolean outcome = false;
+
+ //Add a single item
+ map.put(source, pal);
+
+ if ( map.containsKey(target) ) {
+ outcome = true;
+ }
+
+ assertFalse(outcome);
+ }
+}
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/AttributeSourceTestCase.java b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/AttributeSourceTestCase.java
new file mode 100644
index 000000000..e0f685ade
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/AttributeSourceTestCase.java
@@ -0,0 +1,88 @@
+package eu.stork.peps.tests;
+
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertTrue;
+
+import org.junit.Test;
+
+import eu.stork.peps.auth.commons.AttributeProvider;
+import eu.stork.peps.auth.commons.AttributeSource;
+import eu.stork.peps.auth.commons.Country;
+
+/**
+ * The AttributeSource's Test Case.
+ *
+ * @author Stelios Lelis (stelios.lelis@aegean.gr), Elias Pastos (ilias@aegean.gr)
+ *
+ * @version $Revision: $, $Date: $
+ */
+public final class AttributeSourceTestCase {
+ private final AttributeSource ap1 = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL1");
+ private final AttributeSource ap2 = new AttributeSource(new AttributeProvider("ID2", "Name 2", null), "URL2");
+ private final AttributeSource ap3 = new AttributeSource(new AttributeProvider("ID1", "Name 2", null), "URL2");
+ private final AttributeSource ap4 = new AttributeSource(new AttributeProvider("ID1", "Name 2", null), "URL1");
+ private final AttributeSource ap5 = new AttributeSource(new AttributeProvider("ID1", "Name 1", null), "URL1");
+
+ private final AttributeSource c1 = new AttributeSource(new Country("ID1", "Name 1"), "URL1");
+ private final AttributeSource c2 = new AttributeSource(new Country("ID2", "Name 2"), "URL2");
+ private final AttributeSource c3 = new AttributeSource(new Country("ID1", "Name 2"), "URL2");
+ private final AttributeSource c4 = new AttributeSource(new Country("ID1", "Name 2"), "URL1");
+ private final AttributeSource c5 = new AttributeSource(new Country("ID1", "Name 1"), "URL1");
+
+ @Test
+ public void testNotEquals1() {
+ assertFalse(ap1.equals(ap2));
+ }
+
+ @Test
+ public void testNotEquals2() {
+ assertFalse(ap1.equals(c1));
+ }
+
+ @Test
+ public void testNotEquals3() {
+ assertFalse(c1.equals(c2));
+ }
+
+ @Test
+ public void testEquals1() {
+ assertTrue(ap1.equals(ap3));
+ }
+
+ @Test
+ public void testEquals2() {
+ assertTrue(ap1.equals(ap4));
+ }
+
+ @Test
+ public void testEquals3() {
+ assertTrue(ap1.equals(ap5));
+ }
+
+ @Test
+ public void testEquals4() {
+ assertTrue(c1.equals(c3));
+ }
+
+ @Test
+ public void testEquals5() {
+ assertTrue(c1.equals(c4));
+ }
+
+ @Test
+ public void testEquals6() {
+ assertTrue(c1.equals(c5));
+ }
+
+ @Test
+ public void testEquals7() {
+ final Object obj = ap5;
+ assertTrue(ap1.equals(obj));
+ }
+
+ @Test
+ public void testEquals8() {
+ final Object obj = c5;
+ assertTrue(c1.equals(obj));
+ }
+}
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/AttributeUtilTestCase.java b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/AttributeUtilTestCase.java
new file mode 100644
index 000000000..77fc4b9c2
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/AttributeUtilTestCase.java
@@ -0,0 +1,537 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.tests;
+
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.assertEquals;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+import org.junit.Test;
+
+import eu.stork.peps.auth.commons.AttributeUtil;
+import eu.stork.peps.auth.commons.IPersonalAttributeList;
+import eu.stork.peps.auth.commons.PEPSValues;
+import eu.stork.peps.auth.commons.PersonalAttributeList;
+
+/**
+ * The AttributeUtil's Test Case.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com
+ *
+ * @version $Revision: $, $Date: $
+ */
+public final class AttributeUtilTestCase {
+
+ /**
+ * Empty String to be used on the tests.
+ */
+ private static final String EMPTY_STRING = "";
+
+ /**
+ * Tuple value sample to be used on the tests.
+ */
+ private static final String[] TUPLE_STRING = new String[] { "age", "true",
+ "[18]", "Available" };
+
+ /**
+ * Complex value to be used on escape/unescape tests.
+ */
+ private static final String COMPLEX_VAL = "postalCode=4100,"
+ + "apartmentNumber=A,state=Porto,countryCodeAddress=PT,streetNumber=379,"
+ + "streetName=Avenida Sidonio Pais,town=Porto,";
+
+ /**
+ * Escaped Complex value to be used on escape/unescape tests.
+ */
+ private static final String ESC_COMPLEX_VAL = "postalCode=4100%44"
+ + "apartmentNumber=A%44state=Porto%44countryCodeAddress=PT%44"
+ + "streetNumber=379%44streetName=Avenida Sidonio Pais%44town=Porto%44";
+
+ /**
+ * Simple value to be used on escape/unescape tests.
+ */
+ private static final String SIMPLE_VAL = "Avenida da Boavista, Porto";
+
+ /**
+ * Escaped simple value to be used on escape/unescape tests.
+ */
+ private static final String ESC_SIMPLE_VAL = "Avenida da Boavista%44 Porto";
+
+ /**
+ * Simple text to be used on escape/unescape tests. Must match the escaped
+ * text.
+ */
+ private static final String SIMPLE_TEXT = "John Doe";
+
+ /**
+ * Tests the {@link AttributeUtil#escape(String)} method for the given complex
+ * attribute value (canonical address' example attribute value).
+ */
+ @Test
+ public void testEscapeSpecialCharsComplexVal() {
+ assertEquals(AttributeUtil.escape(COMPLEX_VAL), ESC_COMPLEX_VAL);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#escape(String)} method for the given
+ * attribute value.
+ */
+ @Test
+ public void testEscapeSpecialCharsVal() {
+ assertEquals(AttributeUtil.escape(SIMPLE_VAL), ESC_SIMPLE_VAL);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#escape(String)} method for the given simple
+ * text: no special characters to escape.
+ */
+ @Test
+ public void testEscapeNormalChars() {
+ assertEquals(AttributeUtil.escape(SIMPLE_TEXT), SIMPLE_TEXT);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#unescape(String)} method for the given
+ * escape complex attribute value (canonical address' example attribute
+ * value).
+ */
+ @Test
+ public void testUnescapeSpecialCharsComplexVal() {
+ assertEquals(AttributeUtil.unescape(ESC_COMPLEX_VAL), COMPLEX_VAL);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#escape(String)} method for the given escape
+ * attribute value.
+ */
+ @Test
+ public void testUnescapeSpecialCharsVal() {
+ assertEquals(AttributeUtil.unescape(ESC_SIMPLE_VAL), SIMPLE_VAL);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#escape(String)} method for the given simple
+ * text: no special characters to unescape.
+ */
+ @Test
+ public void testUnescapeNormalChars() {
+ assertEquals(AttributeUtil.unescape(SIMPLE_TEXT), SIMPLE_TEXT);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#appendIfNotNull(StringBuilder, Object)}
+ * method for the given empty string.
+ */
+ @Test
+ public void testAppendIfNotNullEmptyStr() {
+ final StringBuilder strBuilder = new StringBuilder(SIMPLE_TEXT);
+ AttributeUtil.appendIfNotNull(strBuilder, EMPTY_STRING);
+ assertEquals(strBuilder.toString(), SIMPLE_TEXT);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#appendIfNotNull(StringBuilder, Object)}
+ * method for the given string.
+ */
+ @Test
+ public void testAppendIfNotNullStr() {
+ final StringBuilder strBuilder = new StringBuilder();
+ AttributeUtil.appendIfNotNull(strBuilder, SIMPLE_TEXT);
+ assertEquals(strBuilder.toString(), SIMPLE_TEXT);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#appendIfNotNull(StringBuilder, Object)}
+ * method for the given null value.
+ */
+ @Test
+ public void testAppendIfNotNull() {
+ final StringBuilder strBuilder = new StringBuilder();
+ AttributeUtil.appendIfNotNull(strBuilder, null);
+ assertEquals(strBuilder.toString(), EMPTY_STRING);
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#listToString(List, String)} method for the
+ * given List with two values.
+ */
+ @Test
+ public void testListToStringTwoVals() {
+ final List<String> vals = new ArrayList<String>();
+ vals.add(SIMPLE_VAL);
+ vals.add(SIMPLE_TEXT);
+
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append(ESC_SIMPLE_VAL);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+ strBuilder.append(SIMPLE_TEXT);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+
+ assertEquals(
+ AttributeUtil.listToString(vals,
+ PEPSValues.ATTRIBUTE_VALUE_SEP.toString()), strBuilder.toString());
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#listToString(List, String)} method for the
+ * given List with one values.
+ */
+ @Test
+ public void testListToStringOneVal() {
+ final List<String> vals = new ArrayList<String>();
+ vals.add(SIMPLE_VAL);
+
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append(ESC_SIMPLE_VAL);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+
+ assertEquals(
+ AttributeUtil.listToString(vals,
+ PEPSValues.ATTRIBUTE_VALUE_SEP.toString()), strBuilder.toString());
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#listToString(List, String)} method for the
+ * given List with one value.
+ */
+ @Test
+ public void testListToStringEmptyVal() {
+ final List<String> vals = new ArrayList<String>();
+
+ final StringBuilder strBuilder = new StringBuilder();
+
+ assertEquals(
+ AttributeUtil.listToString(vals,
+ PEPSValues.ATTRIBUTE_VALUE_SEP.toString()), strBuilder.toString());
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#mapToString(java.util.Map, String)} method
+ * for the given Map with one value.
+ */
+ @Test
+ public void testMapToStringOneVal() {
+ final Map<String, String> vals = new HashMap<String, String>();
+ vals.put("CanonicalAddress", COMPLEX_VAL);
+
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append("CanonicalAddress=");
+ strBuilder.append(ESC_COMPLEX_VAL);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+
+ assertEquals(AttributeUtil.mapToString(vals,
+ PEPSValues.ATTRIBUTE_VALUE_SEP.toString()), strBuilder.toString());
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#mapToString(java.util.Map, String)} method
+ * for the given empty Map.
+ */
+ @Test
+ public void testMapToStringEmptyVal() {
+ final Map<String, String> vals = new HashMap<String, String>();
+
+ final StringBuilder strBuilder = new StringBuilder();
+
+ assertEquals(AttributeUtil.mapToString(vals,
+ PEPSValues.ATTRIBUTE_VALUE_SEP.toString()), strBuilder.toString());
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * invalid List.
+ */
+ @Test
+ public void testIsValidValueInvalidList() {
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append(ESC_SIMPLE_VAL);
+ strBuilder.append("]");
+ assertFalse(AttributeUtil.isValidValue(strBuilder.toString()));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * null value.
+ */
+ @Test
+ public void testIsValidValueNullList() {
+ assertFalse(AttributeUtil.isValidValue(null));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * empty List.
+ */
+ @Test
+ public void testIsValidValueEmptyList() {
+ assertTrue(AttributeUtil.isValidValue("[]"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * empty List.
+ */
+ @Test
+ public void testIsValidValueEmptyCommaList() {
+ assertTrue(AttributeUtil.isValidValue("[,]"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * one simple value List.
+ */
+ @Test
+ public void testIsValidValueOneValueList() {
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append("[");
+ strBuilder.append(ESC_SIMPLE_VAL);
+ strBuilder.append("]");
+ assertTrue(AttributeUtil.isValidValue(strBuilder.toString()));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * one simple value List.
+ */
+ @Test
+ public void testIsValidValueOneValueCommaList() {
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append("[");
+ strBuilder.append(ESC_SIMPLE_VAL);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+ strBuilder.append("]");
+ assertTrue(AttributeUtil.isValidValue(strBuilder.toString()));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * one complex value List.
+ */
+ @Test
+ public void testIsValidValueOneComplexValueList() {
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append("[");
+ strBuilder.append(ESC_COMPLEX_VAL);
+ strBuilder.append("]");
+ assertTrue(AttributeUtil.isValidValue(strBuilder.toString()));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * one complex value List.
+ */
+ @Test
+ public void testIsValidValueOneComplexValueCommaList() {
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append("[");
+ strBuilder.append(ESC_COMPLEX_VAL);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+ strBuilder.append("]");
+ assertTrue(AttributeUtil.isValidValue(strBuilder.toString()));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * multi value List.
+ */
+ @Test
+ public void testIsValidValueMultiValueList() {
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append("[");
+ strBuilder.append(ESC_SIMPLE_VAL);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+ strBuilder.append(SIMPLE_TEXT);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+ strBuilder.append("]");
+ assertTrue(AttributeUtil.isValidValue(strBuilder.toString()));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidValue(String)} method for the given
+ * invalid multi value List.
+ */
+ @Test
+ public void testIsValidValueInvalidMultiValueList() {
+ final StringBuilder strBuilder = new StringBuilder();
+ strBuilder.append(ESC_SIMPLE_VAL);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+ strBuilder.append(SIMPLE_TEXT);
+ strBuilder.append(PEPSValues.ATTRIBUTE_VALUE_SEP.toString());
+ strBuilder.append("]");
+ assertFalse(AttributeUtil.isValidValue(strBuilder.toString()));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidType(String)} method for the given
+ * true type.
+ */
+ @Test
+ public void testIsValidTypetrue() {
+ assertTrue(AttributeUtil.isValidType("true"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidType(String)} method for the given
+ * True type.
+ */
+ @Test
+ public void testIsValidTypeTrue() {
+ assertTrue(AttributeUtil.isValidType("True"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidType(String)} method for the given
+ * TRUE type.
+ */
+ @Test
+ public void testIsValidTypeTRUE() {
+ assertTrue(AttributeUtil.isValidType("TRUE"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidType(String)} method for the given
+ * invalid type.
+ */
+ @Test
+ public void testIsValidTypeInvalidType() {
+ assertFalse(AttributeUtil.isValidType("str"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidType(String)} method for the given
+ * false type.
+ */
+ @Test
+ public void testIsValidTypefalse() {
+ assertTrue(AttributeUtil.isValidType("false"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidType(String)} method for the given
+ * False type.
+ */
+ @Test
+ public void testIsValidTypeFalse() {
+ assertTrue(AttributeUtil.isValidType("False"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidType(String)} method for the given
+ * FALSE type.
+ */
+ @Test
+ public void testIsValidTypeFALSEVal() {
+ assertTrue(AttributeUtil.isValidType("False"));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#isValidType(String)} method for the given
+ * null.
+ */
+ @Test
+ public void testIsValidTypeNullVal() {
+ assertFalse(AttributeUtil.isValidType(null));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#hasValidTuples(String[])} method for the
+ * given valid tuple.
+ */
+ @Test
+ public void testHasValidTuples() {
+ assertTrue(AttributeUtil.hasValidTuples(TUPLE_STRING));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#hasValidTuples(String[])} method for the
+ * given invalid tuple.
+ */
+ @Test
+ public void testHasValidTuplesInvalid() {
+ final String[] tuple = new String[]{"name", "type"};
+ assertFalse(AttributeUtil.hasValidTuples(tuple));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#hasValidTuples(String[])} method for the
+ * given invalid tuple with valid size.
+ */
+ @Test
+ public void testHasValidTuplesSameSizeInvalidValues() {
+ final String[] tuple = new String[] { "age", "type", "[18]", "Available"};
+ assertFalse(AttributeUtil.hasValidTuples(tuple));
+ }
+
+ /**
+ * Tests the {@link AttributeUtil#hasValidTuples(String[])} method for the
+ * given null value.
+ */
+ @Test
+ public void testHasValidTuplesNull() {
+ assertFalse(AttributeUtil.hasValidTuples(null));
+ }
+
+ /**
+ * Tests the
+ * {@link AttributeUtil#checkMandatoryAttributes(IPersonalAttributeList)}
+ * method for the given attribute list..
+ */
+ @Test
+ public void testCheckMandatoryAttributes() {
+ final IPersonalAttributeList attrList = new PersonalAttributeList();
+ attrList.populate("isAgeOver:true:[18,]:Available;");
+ assertTrue(AttributeUtil.checkMandatoryAttributes(attrList));
+
+ }
+
+ /**
+ * Tests the
+ * {@link AttributeUtil#checkMandatoryAttributes(IPersonalAttributeList)}
+ * method for the given null value.
+ */
+ @Test(expected = NullPointerException.class)
+ public void testCheckMandatoryAttributesNullAttrList() {
+ assertTrue(AttributeUtil.checkMandatoryAttributes(null));
+ }
+
+ /**
+ * Tests the
+ * {@link AttributeUtil#checkMandatoryAttributes(IPersonalAttributeList)}
+ * method for the given empty attribute list.
+ */
+ @Test
+ public void testCheckMandatoryAttributesEmptyAttrList() {
+ final IPersonalAttributeList attrList = new PersonalAttributeList();
+ assertTrue(AttributeUtil.checkMandatoryAttributes(attrList));
+ }
+
+ /**
+ * Tests the
+ * {@link AttributeUtil#checkMandatoryAttributes(IPersonalAttributeList)}
+ * method for the given attribute list (missing mandatory attribute).
+ */
+ @Test
+ public void testCheckMandatoryAttributesMissingAttr() {
+ final IPersonalAttributeList attrList = new PersonalAttributeList();
+ attrList.populate("isAgeOver:true:[]:NotAvailable;");
+ assertFalse(AttributeUtil.checkMandatoryAttributes(attrList));
+ }
+
+}
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/ComplexAttributesMarshalling.java b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/ComplexAttributesMarshalling.java
new file mode 100644
index 000000000..c7e195fa6
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/ComplexAttributesMarshalling.java
@@ -0,0 +1,187 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ *
+ * ---
+ *
+ * Test cases for marshalling complex attributes.
+ *
+ * Implemented are two testcases for marshalling and unmarshalling. These testcases are
+ * for canonical residenc address and has bank account.
+ */
+
+package eu.stork.peps.tests;
+
+import java.io.File;
+import java.io.FileNotFoundException;
+import java.io.FileOutputStream;
+
+import javax.xml.bind.JAXBContext;
+import javax.xml.bind.JAXBElement;
+import javax.xml.bind.JAXBException;
+import javax.xml.bind.Marshaller;
+import javax.xml.bind.Unmarshaller;
+import javax.xml.transform.stream.StreamSource;
+
+import org.junit.Test;
+
+import eu.stork.peps.complex.attributes.CanonicalAddressType;
+import eu.stork.peps.complex.attributes.HasAccountInBankType;
+import eu.stork.peps.complex.attributes.ObjectFactory;
+
+/**
+ * @author Advania
+ *
+ * Examples on how to use the jaxb marshaller.
+ *
+ * The classes are created from the StorkcomplexAttributes.xsd schema located in resources.
+ *
+ * @version $Revision: 1.00 $, $Date: 2014-17-02 11:15:00 $
+ *
+ */
+
+public class ComplexAttributesMarshalling {
+
+ /**
+ * Test marshalling canonical address
+ * <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+ * <canonicalResidenceAddress xmlns="urn:eu:stork:names:tc:STORK:1.0:assertion">
+ * <countryCodeAddress>IS</countryCodeAddress>
+ * <state>Reykjavik</state>
+ * <municipalityCode>RVK</municipalityCode>
+ * <town>Reykjavik</town>
+ * <postalCode>101</postalCode>
+ * <streetName>Laugavegur</streetName>
+ * <streetNumber>1</streetNumber>
+ * <apartmentNumber>10</apartmentNumber>
+ * </canonicalResidenceAddress>
+ */
+ @Test
+ public void testMarshallCanonicalResidencAddress()
+ {
+ try
+ {
+ final CanonicalAddressType object = new CanonicalAddressType();
+ object.setApartmentNumber("10");
+ object.setCountryCodeAddress("IS");
+ object.setMunicipalityCode("RVK");
+ object.setPostalCode("101");
+ object.setState("Reykjavik");
+ object.setStreetName("Laugavegur");
+ object.setStreetNumber("1");
+ object.setTown("Reykjavik");
+
+ final JAXBContext context = JAXBContext.newInstance(CanonicalAddressType.class);
+ final Marshaller m = context.createMarshaller();
+ m.setProperty(Marshaller.JAXB_FORMATTED_OUTPUT, true);
+ final ObjectFactory objf = new ObjectFactory();
+
+ m.marshal(objf.createCanonicalResidenceAddress(object), new FileOutputStream("CanonicalAddressType.xml"));
+ m.marshal(objf.createCanonicalResidenceAddress(object), System.out);
+ }
+ catch (JAXBException | FileNotFoundException e)
+ {
+ e.printStackTrace();
+ }
+ }
+
+ /**
+ * Test unmarshalling canonical address
+ * <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+ * <canonicalResidenceAddress xmlns="urn:eu:stork:names:tc:STORK:1.0:assertion">
+ * <countryCodeAddress>IS</countryCodeAddress>
+ * <state>Reykjavik</state>
+ * <municipalityCode>RVK</municipalityCode>
+ * <town>Reykjavik</town>
+ * <postalCode>101</postalCode>
+ * <streetName>Laugavegur</streetName>
+ * <streetNumber>1</streetNumber>
+ * <apartmentNumber>10</apartmentNumber>
+ * </canonicalResidenceAddress>
+ */
+ @Test
+ public void testUnmarshallCanonicalAddress()
+ {
+ JAXBContext uContext;
+ try
+ {
+ uContext = JAXBContext.newInstance(CanonicalAddressType.class);
+ final Unmarshaller u = uContext.createUnmarshaller();
+ final File file = new File("CanonicalAddressType.xml");
+
+ final JAXBElement<CanonicalAddressType> root = u.unmarshal(new StreamSource(file), CanonicalAddressType.class);
+ final CanonicalAddressType foo = root.getValue();
+
+ final String A = foo.getStreetName();
+ final String B = foo.getStreetNumber();
+
+ System.out.println("Streetname: " + A);
+ System.out.println("Streetnumber: " + B);
+
+ }
+ catch (final JAXBException e)
+ {
+ e.printStackTrace();
+ }
+ }
+
+ /**
+ * Test marshalling has bank account
+ * <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+ * <hasAccountInBank xmlns="urn:eu:stork:names:tc:STORK:1.0:assertion">
+ * <bankName>Arion</bankName>
+ * <AQAA>3</AQAA>
+ * </hasAccountInBank>
+ */
+ @Test
+ public void testMarshallHasBankAccount()
+ {
+ try
+ {
+ final HasAccountInBankType object = new HasAccountInBankType();
+ object.setAQAA(3);
+ object.setBankName("Arion Bank");
+ final JAXBContext context = JAXBContext.newInstance(HasAccountInBankType.class);
+ final Marshaller m = context.createMarshaller();
+ final ObjectFactory o = new ObjectFactory();
+ m.marshal(o.createHasAccountInBank(object), new FileOutputStream ("hasbankaccount.xml"));
+ m.marshal(o.createHasAccountInBank(object), System.out);
+
+ } catch (JAXBException | FileNotFoundException e) {
+ e.printStackTrace();
+ }
+ }
+ /**
+ * Test unmarshalling has bank account
+ * <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+ * <hasAccountInBank xmlns="urn:eu:stork:names:tc:STORK:1.0:assertion">
+ * <bankName>Arion</bankName>
+ * <AQAA>3</AQAA>
+ * </hasAccountInBank>
+ */
+ @Test
+ public void testUnmarshallHasBankAccount()
+ {
+ try
+ {
+ final JAXBContext context = JAXBContext.newInstance(HasAccountInBankType.class);
+ final Unmarshaller um = context.createUnmarshaller();
+ final File file = new File("hasbankaccount.xml");
+ final JAXBElement<HasAccountInBankType> root = um.unmarshal(new StreamSource(file), HasAccountInBankType.class);
+ final HasAccountInBankType foo = root.getValue();
+ System.out.println(foo.getBankName());
+ } catch (final JAXBException e) {
+ e.printStackTrace();
+ }
+ }
+
+}
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/DateUtilTestCase.java b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/DateUtilTestCase.java
new file mode 100644
index 000000000..5d2296997
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/DateUtilTestCase.java
@@ -0,0 +1,294 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.tests;
+
+import java.sql.Timestamp;
+import java.util.Properties;
+
+import org.joda.time.DateTime;
+import org.junit.Assert;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+import eu.stork.peps.auth.commons.DateUtil;
+import eu.stork.peps.auth.commons.PEPSUtil;
+import eu.stork.peps.auth.commons.exceptions.SecurityPEPSException;
+
+/**
+ * The PersonalAttribute's Test Case.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.2 $, $Date: 2010-11-17 05:17:03 $
+ */
+public final class DateUtilTestCase {
+
+ /**
+ * Stork Format date.
+ */
+ private static final String FORMAT = "yyyyMMdd";
+
+ /**
+ * Expected 10 value.
+ */
+ private static final int TEN = 10;
+
+ /**
+ * Expected 11 value.
+ */
+ private static final int ELEVEN = 11;
+
+ /**
+ * The testing Date ("current" date).
+ */
+ private static final DateTime TESTDATE = new DateTime(2011, 10, 10, 15, 20,
+ 0, 0);
+
+ /**
+ * Init DateUtilTestCase class.
+ */
+ @BeforeClass
+ public static void runsBeforeTheTestSuite() {
+ final Properties configs = new Properties();
+ configs.setProperty("invalidAgeDateValue.code", "35");
+ configs.setProperty("invalidAttributeValue.code", "34");
+ configs
+ .setProperty(
+ "invalidAttributeValue.message",
+ "Unexpected or invalid content was encountered within a "
+ + "<saml:Attribute> or <saml:AttributeValue> element.");
+ PEPSUtil.createInstance(configs);
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given year against
+ * the testDate: 2011-10-10 15:20:00.0. Must return 10.
+ */
+ @Test
+ public void calculateAgeFromYear() {
+ Assert.assertTrue(TEN == DateUtil.calculateAge("2000", TESTDATE, FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given year and month
+ * against the testDate: 2011-10-10 15:20:00.0. Must return 11.
+ */
+ @Test
+ public void calculateAgeFromEarlyMonth() {
+ Assert.assertTrue(ELEVEN == DateUtil.calculateAge("200001", TESTDATE,
+ FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given year and month
+ * against the testDate: 2011-10-10 15:20:00.0. Must return 10.
+ */
+ @Test
+ public void calculateAgeFromSameMonth() {
+ Assert.assertTrue(TEN == DateUtil.calculateAge("200010", TESTDATE, FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given year and month
+ * against the testDate: 2011-10-10 15:20:00.0. Must return 10.
+ */
+ @Test
+ public void calculateAgeFromLaterMonth() {
+ Assert.assertTrue(TEN == DateUtil.calculateAge("200011", TESTDATE, FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return 11.
+ */
+ @Test
+ public void calculateAgeFromEarlyFullDate() {
+ Assert.assertTrue(ELEVEN == DateUtil.calculateAge("20000101", TESTDATE,
+ FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return 11.
+ */
+ @Test
+ public void calculateAgeFromSameDay() {
+ Assert.assertTrue(ELEVEN == DateUtil.calculateAge("20001010", TESTDATE,
+ FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return 10.
+ */
+ @Test
+ public void calculateAgeFromLaterFullDate() {
+ Assert.assertTrue(TEN == DateUtil
+ .calculateAge("20001011", TESTDATE, FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return a
+ * SecurityPEPSException exception.
+ */
+ @Test(expected = SecurityPEPSException.class)
+ public void calculateAgeFromInvalidDate() {
+ DateUtil.calculateAge("200", TESTDATE, FORMAT);
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return a
+ * SecurityPEPSException exception.
+ */
+ @Test(expected = SecurityPEPSException.class)
+ public void calculateAgeFromInvalidMonth() {
+ DateUtil.calculateAge("200013", TESTDATE, FORMAT);
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return a
+ * SecurityPEPSException exception.
+ */
+ @Test(expected = SecurityPEPSException.class)
+ public void calculateAgeFromInvalidDay() {
+ DateUtil.calculateAge("20000230", TESTDATE, FORMAT);
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return a
+ * SecurityPEPSException exception.
+ */
+ @Test(expected = SecurityPEPSException.class)
+ public void calculateAgeFromNullDate() {
+ DateUtil.calculateAge(null, TESTDATE, FORMAT);
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return a
+ * SecurityPEPSException exception.
+ */
+ @Test(expected = SecurityPEPSException.class)
+ public void calculateAgeFromNullCurDate() {
+ DateUtil.calculateAge("2000", null, FORMAT);
+ }
+
+ /**
+ * Tests the {@link DateUtil#calculateAge} method for the given full date
+ * against the testDate: 2011-10-10 15:20:00.0. Must return a
+ * SecurityPEPSException exception.
+ */
+ @Test(expected = SecurityPEPSException.class)
+ public void calculateAgeFromNullFormat() {
+ DateUtil.calculateAge("2000", TESTDATE, null);
+ }
+
+ /**
+ * Tests the {@link DateUtil#isValidFormatDate} method for the given year.
+ * Must return true
+ */
+ @Test
+ public void isValidFormatDateFromYear() {
+ Assert.assertTrue(DateUtil.isValidFormatDate("2000", FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#isValidFormatDate} method for the given year and
+ * month. Must return true.
+ */
+ @Test
+ public void isValidFormatDateFromMonth() {
+ Assert.assertTrue(DateUtil.isValidFormatDate("200001", FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#isValidFormatDate} method for the given year.
+ * Must return false.
+ */
+ @Test
+ public void isValidFormatDate() {
+ Assert.assertTrue(DateUtil.isValidFormatDate("20000101", FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#isValidFormatDate} method for the given year.
+ * Must return false.
+ */
+ @Test
+ public void isValidFormatDateInvalidYear() {
+ Assert.assertFalse(DateUtil.isValidFormatDate("200", FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#isValidFormatDate} method for the given year.
+ * Must return false.
+ */
+ @Test
+ public void isValidFormatDateInvalidMonth() {
+ Assert.assertFalse(DateUtil.isValidFormatDate("200013", FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#isValidFormatDate} method for the given year.
+ * Must return false.
+ */
+ @Test
+ public void isValidFormatDateInvalidDate() {
+ Assert.assertFalse(DateUtil.isValidFormatDate("20010229", FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#isValidFormatDate} method for the given year.
+ * Must return false.
+ */
+ @Test
+ public void isValidFormatDateNullDate() {
+ Assert.assertFalse(DateUtil.isValidFormatDate(null, FORMAT));
+ }
+
+ /**
+ * Tests the {@link DateUtil#isValidFormatDate} method for the given year.
+ * Must return false.
+ */
+ @Test
+ public void isValidFormatDateNullFormat() {
+ Assert.assertFalse(DateUtil.isValidFormatDate("2000", null));
+ }
+
+ /**
+ * Tests the {@link DateUtil#currentTimeStamp()} method for the current
+ * TimeStamp (TS). Must return true.
+ */
+ @Test
+ public void testCurrentTimeStampBefore() {
+ Timestamp ts = DateUtil.currentTimeStamp();
+ Assert.assertNotSame(ts, DateUtil.currentTimeStamp());
+ }
+
+ /**
+ * Tests the {@link DateUtil#currentTimeStamp()} method for the current
+ * TimeStamp (TS). Must return true.
+ */
+ @Test
+ public void testCurrentTimeStampAfter() {
+ Timestamp ts = DateUtil.currentTimeStamp();
+ Assert.assertEquals(DateUtil.currentTimeStamp(), ts);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/PEPSUtilTestCase.java b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/PEPSUtilTestCase.java
new file mode 100644
index 000000000..d4841ed43
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/PEPSUtilTestCase.java
@@ -0,0 +1,553 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.tests;
+
+import static org.junit.Assert.assertArrayEquals;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotSame;
+import static org.junit.Assert.assertNull;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.assertFalse;
+
+import java.util.Properties;
+
+import org.junit.Assert;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+import eu.stork.peps.auth.commons.IPersonalAttributeList;
+import eu.stork.peps.auth.commons.PEPSErrors;
+import eu.stork.peps.auth.commons.PEPSParameters;
+import eu.stork.peps.auth.commons.PEPSUtil;
+import eu.stork.peps.auth.commons.PersonalAttributeList;
+import eu.stork.peps.auth.commons.exceptions.InternalErrorPEPSException;
+import eu.stork.peps.auth.commons.exceptions.InvalidParameterPEPSException;
+
+/**
+ * The PEPSUtil's Test Case.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com
+ *
+ * @version $Revision: $, $Date: $
+ */
+public final class PEPSUtilTestCase {
+
+ /**
+ * Message example.
+ */
+ private static final String MESSAGE_SAMPLE = "003002 - Authentication Failed";
+
+ /**
+ * Error message example.
+ */
+ private static final String ERROR_MESSAGE_SAMPLE = "Authentication Failed";
+
+ /**
+ * Error code example.
+ */
+ private static final String ERROR_CODE_SAMPLE = "003002";
+
+ /**
+ * Properties values for testing proposes.
+ */
+ private static final Properties CONFIGS1 = new Properties();
+
+ /**
+ * Properties values for testing proposes.
+ */
+ private static final Properties CONFIGS2 = new Properties();
+
+ /**
+ * The empty string value: "".
+ */
+ private static final String EMPTY_STRING = "";
+
+ /**
+ * The empty byte value: [].
+ */
+ private static final byte[] EMPTY_BYTE = new byte[] {};
+
+ /**
+ * The empty byte hash value.
+ */
+ private static final byte[] EMPTY_HASH_BYTE = new byte[] { -49, -125, -31,
+ 53, 126, -17, -72, -67, -15, 84, 40, 80, -42, 109, -128, 7, -42, 32, -28,
+ 5, 11, 87, 21, -36, -125, -12, -87, 33, -45, 108, -23, -50, 71, -48, -47,
+ 60, 93, -123, -14, -80, -1, -125, 24, -46, -121, 126, -20, 47, 99, -71, 49,
+ -67, 71, 65, 122, -127, -91, 56, 50, 122, -7, 39, -38, 62 };
+
+ /**
+ * The SAML example byte[] value.
+ */
+ private static final byte[] SAML_BYTE_SAMPLE = new byte[] { 60, 115, 97, 109,
+ 108, 62, 46, 46, 46, 60, 47, 115, 97, 109, 108 };
+
+ /**
+ * The SAML's Base64 example value.
+ */
+ private static final String SAML_BASE64_SAMPLE = "PHNhbWw+Li4uPC9zYW1s";
+
+ /**
+ * The SAML's Base64 byte[] example value.
+ */
+ private static byte[] SAML_BASE64_BYTE_SAMPLE = new byte[] { 80, 72, 78, 104,
+ 98, 87, 119, 43, 76, 105, 52, 117, 80, 67, 57, 122, 89, 87, 49, 115 };
+
+ /**
+ * The SAML's Base64 Hash byte[] example value.
+ */
+ private static byte[] HASH_BYTE_SAMPLE = new byte[] { 67, 38, 11, 115, 49,
+ -5, 54, -85, 38, 43, -99, 96, 71, -41, 50, -96, 71, -86, 90, -97, 66, -67,
+ 90, 101, 30, 82, -13, 60, -106, -72, -103, -75, 19, 2, -107, 107, -6, -56,
+ 34, -111, -44, -57, -26, -5, 33, 78, -1, 30, 21, 74, -26, 118, -46, -12,
+ -102, 12, -56, 30, -59, -104, -21, -42, -103, 82 };
+
+ /**
+ * Init PEPSUtilTestCase class.
+ */
+ @BeforeClass
+ public static void runsBeforeTheTestSuite() {
+
+ CONFIGS1.setProperty("max.attrList.size", "20000");
+ CONFIGS1.setProperty("attrList.code", "202005");
+ CONFIGS1.setProperty("attrList.message", "invalid.attrList.parameter");
+
+ CONFIGS1.setProperty("max.qaaLevel.size", "1");
+ CONFIGS1.setProperty("max.spUrl.size", "inv");
+ CONFIGS1.setProperty("validation.active", "true");
+ CONFIGS1.setProperty("hashDigest.className",
+ "org.bouncycastle.crypto.digests.SHA512Digest");
+ CONFIGS1.setProperty("invalidAgeDateValue.code", "35");
+ CONFIGS1.setProperty("invalidAttributeValue.code", "34");
+ CONFIGS1.setProperty("invalidAttributeValue.message",
+ "Unexpected or invalid content was encountered within a "
+ + "<saml:Attribute> or <saml:AttributeValue> element.");
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#createInstance(Properties)} method for the given
+ * properties object.
+ */
+ @Test
+ public void testCreateInstance() {
+ Assert.assertNotNull(PEPSUtil.createInstance(CONFIGS2));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getConfigs()}.
+ */
+ @Test
+ public void testGetConfigs() {
+ final PEPSUtil pepsUtils = PEPSUtil.createInstance(CONFIGS1);
+ assertEquals(pepsUtils.getConfigs(), CONFIGS1);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getConfigs()}.
+ */
+ @Test
+ public void testGetConfigsDifferent() {
+ final PEPSUtil pepsUtils = PEPSUtil.createInstance(CONFIGS1);
+ assertNotSame(pepsUtils.getConfigs(), CONFIGS2);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getConfig(String)} method for the given existing
+ * config.
+ */
+ @Test
+ public void testGetConfigExists() {
+ assertEquals(PEPSUtil.getConfig("hashDigest.className"),
+ "org.bouncycastle.crypto.digests.SHA512Digest");
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getConfig(String)} method for the given not
+ * existing config.
+ */
+ @Test
+ public void testGetConfigNoExists() {
+ assertNull(PEPSUtil.getConfig("doesnt.exists"));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getConfig(String)} method for the given null
+ * value.
+ */
+ @Test(expected = NullPointerException.class)
+ public void testGetConfigNull() {
+ assertNull(PEPSUtil.getConfig(null));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#isValidParameter(String, String)} method for the
+ * given param values.
+ */
+ @Test
+ public void testIsValidParameterExists() {
+ assertTrue(PEPSUtil.isValidParameter("qaaLevel", "1"));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#isValidParameter(String, String)} method for the
+ * given param values.
+ */
+ @Test
+ public void testIsValidParameterExistsGreat() {
+ assertFalse(PEPSUtil.isValidParameter("qaaLevel", "12"));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#isValidParameter(String, String)} method for the
+ * given param values.
+ */
+ @Test
+ public void testIsValidParameterExistsIvalidConf() {
+ assertFalse(PEPSUtil
+ .isValidParameter("spUrl", "http://localhost:8080/SP/"));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#isValidParameter(String, String)} method for the
+ * given param values.
+ */
+ @Test
+ public void testIsValidParameterNotExists() {
+ assertFalse(PEPSUtil.isValidParameter("doesntexists",
+ "http://localhost:8080/SP/"));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#isValidParameter(String, String)} method for the
+ * given param values.
+ */
+ @Test
+ public void testIsValidParameterNullParamName() {
+ assertFalse(PEPSUtil.isValidParameter(null, "http://localhost:8080/SP/"));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#isValidParameter(String, String)} method for the
+ * given param values.
+ */
+ @Test
+ public void testIsValidParameterNullParamValue() {
+ assertFalse(PEPSUtil.isValidParameter("spUrl", null));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#validateParameter(String, String, Object)} method
+ * for the given object values.
+ */
+ @Test
+ public void testValidateParameterValid() {
+ final IPersonalAttributeList persAttrList = new PersonalAttributeList();
+ persAttrList.populate("isAgeOver:true:[15,]:Available;");
+ PEPSUtil.validateParameter("ServiceProviderAction",
+ PEPSParameters.ATTRIBUTE_LIST.toString(), persAttrList);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#validateParameter(String, String, Object)} method
+ * for the given string values.
+ */
+ @Test(expected = InvalidParameterPEPSException.class)
+ public void testValidateParameterNull() {
+ PEPSUtil.validateParameter("ServiceProviderAction",
+ PEPSParameters.ATTRIBUTE_LIST.toString(), null);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#validateParameter(String, String, String)} method
+ * for the given string values.
+ *
+ * The tested class just invokes
+ * {@link PEPSUtil#validateParameter(String, String, String, String, String)}
+ * so further tests will be later.
+ */
+ @Test
+ public void testValidateParameter() {
+ PEPSUtil.validateParameter("ServiceProviderAction",
+ PEPSParameters.ATTRIBUTE_LIST.toString(),
+ "isAgeOver:true:[15,]:Available;");
+ }
+
+ /**
+ * Tests the
+ * {@link PEPSUtil#validateParameter(String, String, String, PEPSErrors)}
+ * method for the given string value and {@link PEPSErrors} enum.
+ *
+ * The tested class just invokes
+ * {@link PEPSUtil#validateParameter(String, String, String, String, String)}
+ * so further tests will be later.
+ */
+ @Test
+ public void testValidateParameterPEPSErrors() {
+ PEPSUtil.validateParameter("CountrySelectorAction",
+ PEPSParameters.ATTRIBUTE_LIST.toString(),
+ "isAgeOver:true:[15,]:Available;",
+ PEPSErrors.SP_COUNTRY_SELECTOR_INVALID_ATTR);
+ }
+
+ /**
+ * Tests the
+ * {@link PEPSUtil#validateParameter(String, String, String, String, String)}
+ * method for the given string values.
+ */
+ @Test
+ public void testValidateParameterValidParams() {
+ PEPSUtil.validateParameter("ServiceProviderAction", "qaaLevel", "1",
+ "qaaLevel.code", "qaaLevel.message");
+ }
+
+ /**
+ * Tests the
+ * {@link PEPSUtil#validateParameter(String, String, String, String, String)}
+ * method for the given string values.
+ */
+ @Test(expected = InvalidParameterPEPSException.class)
+ public void testValidateParameterInvalidParamValue() {
+ PEPSUtil.validateParameter("ServiceProviderAction", "qaaLevel", "10",
+ "qaaLevel.code", "qaaLevel.message");
+ }
+
+ /**
+ * Tests the
+ * {@link PEPSUtil#validateParameter(String, String, String, String, String)}
+ * method for the given string values.
+ */
+ @Test(expected = InvalidParameterPEPSException.class)
+ public void testValidateParameterInvalidParamName() {
+ PEPSUtil.validateParameter("ServiceProviderAction", "doesnt.exists", "1",
+ "qaaLevel.code", "qaaLevel.message");
+ }
+
+ /**
+ * Tests the
+ * {@link PEPSUtil#validateParameter(String, String, String, String, String)}
+ * method for the given string values.
+ */
+ @Test(expected = InvalidParameterPEPSException.class)
+ public void testValidateParameterNullParamName() {
+ PEPSUtil.validateParameter("ServiceProviderAction", null, "1",
+ "qaaLevel.code", "qaaLevel.message");
+ }
+
+ /**
+ * Tests the
+ * {@link PEPSUtil#validateParameter(String, String, String, String, String)}
+ * method for the given string values.
+ */
+ @Test(expected = InvalidParameterPEPSException.class)
+ public void testValidateParameterNullParamValue() {
+ PEPSUtil.validateParameter("ServiceProviderAction", "qaaLevel", null,
+ "qaaLevel.code", "qaaLevel.message");
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#encodeSAMLToken(byte[])} method for the given
+ * string value.
+ */
+ @Test
+ public void testEncodeSAMLToken() {
+ assertEquals(PEPSUtil.encodeSAMLToken(SAML_BYTE_SAMPLE), SAML_BASE64_SAMPLE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#encodeSAMLToken(byte[])} method for the given
+ * null.
+ */
+ @Test(expected = NullPointerException.class)
+ public void testEncodeSAMLTokenNull() {
+ assertNotSame(PEPSUtil.encodeSAMLToken(null), SAML_BASE64_SAMPLE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#encodeSAMLToken(byte[])} method for the given
+ * empty byte[] value.
+ */
+ @Test
+ public void testEncodeSAMLTokenEmpty() {
+ assertEquals(PEPSUtil.encodeSAMLToken(EMPTY_BYTE), EMPTY_STRING);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#decodeSAMLToken(byte[])} method for the given
+ * byte[] value.
+ */
+ @Test
+ public void testDecodeSAMLToken() {
+ assertArrayEquals(PEPSUtil.decodeSAMLToken(SAML_BASE64_SAMPLE),
+ SAML_BYTE_SAMPLE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#decodeSAMLToken(byte[])} method for the given
+ * null value.
+ */
+ @Test(expected = NullPointerException.class)
+ public void testDecodeSAMLTokenNull() {
+ assertNotSame(PEPSUtil.decodeSAMLToken(null), SAML_BYTE_SAMPLE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#decodeSAMLToken(byte[])} method for the given
+ * empty string value.
+ */
+ @Test(expected = StringIndexOutOfBoundsException.class)
+ public void testDecodeSAMLTokenEmpty() {
+ assertTrue(PEPSUtil.decodeSAMLToken(EMPTY_STRING) == EMPTY_BYTE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#hashPersonalToken(byte[])} method for the given
+ * byte[] value.
+ */
+ @Test
+ public void testHashPersonalToken() {
+ assertArrayEquals(PEPSUtil.hashPersonalToken(SAML_BASE64_BYTE_SAMPLE),
+ HASH_BYTE_SAMPLE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#hashPersonalToken(byte[])} method for the given
+ * null value.
+ */
+ @Test(expected = InternalErrorPEPSException.class)
+ public void testHashPersonalTokenNull() {
+ assertNull(PEPSUtil.hashPersonalToken(null));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#hashPersonalToken(byte[])} method for the given
+ * empty value.
+ */
+ @Test
+ public void testHashPersonalTokenEmpty() {
+ assertArrayEquals(PEPSUtil.hashPersonalToken(EMPTY_BYTE), EMPTY_HASH_BYTE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorCode(String)} method for the given
+ * correct message.
+ */
+ @Test
+ public void testGetStorkErrorCodeExists() {
+ assertEquals(PEPSUtil.getStorkErrorCode(MESSAGE_SAMPLE), ERROR_CODE_SAMPLE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorCode(String)} method for the given
+ * invalid message.
+ */
+ @Test
+ public void testGetStorkErrorCodeNoExists() {
+ assertNull(PEPSUtil.getStorkErrorCode(ERROR_MESSAGE_SAMPLE));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorCode(String)} method for the given
+ * empty message.
+ */
+ @Test
+ public void testGetStorkErrorCodeEmpty() {
+ assertNull(PEPSUtil.getStorkErrorCode(EMPTY_STRING));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorCode(String)} method for the given
+ * null message.
+ */
+ @Test
+ public void testGetStorkErrorCodeNull() {
+ assertNull(PEPSUtil.getStorkErrorCode(null));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorCode(String)} method for the given
+ * invalid message.
+ */
+ @Test
+ public void testGetStorkErrorCodeWithSepFake() {
+ assertNull(PEPSUtil.getStorkErrorCode("-"));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorCode(String)} method for the given
+ * invalid message.
+ */
+ @Test
+ public void testGetStorkErrorCodeWithSepAndCodeFake() {
+ assertNull(PEPSUtil.getStorkErrorCode("000001 -"));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorMessage(String)} method for the
+ * given correct message.
+ */
+ @Test
+ public void testGetStorkErrorMessageExists() {
+ assertEquals(PEPSUtil.getStorkErrorMessage(MESSAGE_SAMPLE),
+ ERROR_MESSAGE_SAMPLE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorMessage(String)} method for the
+ * given invalid message.
+ */
+ @Test
+ public void testGetStorkErrorMessageNoExists() {
+ assertEquals(PEPSUtil.getStorkErrorMessage(ERROR_MESSAGE_SAMPLE),
+ ERROR_MESSAGE_SAMPLE);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorMessage(String)} method for the
+ * given empty message.
+ */
+ @Test
+ public void testGetStorkErrorMessageEmpty() {
+ assertEquals(PEPSUtil.getStorkErrorMessage(EMPTY_STRING),
+ EMPTY_STRING);
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorMessage(String)} method for the
+ * given null message.
+ */
+ @Test
+ public void testGetStorkErrorMessageNull() {
+ assertNull(PEPSUtil.getStorkErrorMessage(null));
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorMessage(String)} method for the
+ * given invalid message.
+ */
+ @Test
+ public void testGetStorkErrorMessageWithSepFake() {
+ assertEquals(PEPSUtil.getStorkErrorMessage("-"),"-");
+ }
+
+ /**
+ * Tests the {@link PEPSUtil#getStorkErrorMessage(String)} method for the
+ * given invalid message.
+ */
+ @Test
+ public void testGetStorkErrorMessageWithSepAndCodeFake() {
+ assertEquals(PEPSUtil.getStorkErrorMessage("000001 -"),"000001 -");
+ }
+
+}
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/PersonalAttributeListTestCase.java b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/PersonalAttributeListTestCase.java
new file mode 100644
index 000000000..7052b320a
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/PersonalAttributeListTestCase.java
@@ -0,0 +1,747 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.tests;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.Map;
+
+import org.junit.Assert;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+import eu.stork.peps.auth.commons.PersonalAttribute;
+import eu.stork.peps.auth.commons.PersonalAttributeList;
+import eu.stork.peps.auth.commons.STORKStatusCode;
+
+/**
+ * The PersonalAttributeList's Test Case.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.5 $, $Date: 2010-11-17 05:17:02 $
+ */
+public final class PersonalAttributeListTestCase {
+
+ /**
+ * isAgeOver constant value.
+ */
+ private static final String ISAGEOVER_CONS = "isAgeOver";
+
+ /**
+ * 1 constant value.
+ */
+ private static final int ONE_CONS = 1;
+
+ /**
+ * 2 constant value.
+ */
+ private static final int TWO_CONS = 2;
+
+ /**
+ * An empty attribute.
+ */
+ @SuppressWarnings("unused")
+ private static final PersonalAttributeList EMPTY_ATTR_LIST =
+ new PersonalAttributeList(0);
+
+ /**
+ * An attribute with a complex value (canonicalResidenceAddress).
+ */
+ private static PersonalAttribute complexAttrValue = null;
+
+ /**
+ * Simple attribute value list string.
+ */
+ private static final String SIMPLE_ATTRLIST =
+ "isAgeOver:true:[15,]:Available;";
+
+ /**
+ * Simple attribute value list string.
+ */
+ private static final String SIMPLE_ATTRLIST2 =
+ "isAgeOver:true:[18,]:Available;";
+
+ /**
+ * Simple attribute value list string.
+ */
+ private static final String SIMPLE_ATTRLIST3 =
+ "isAgeOver:true:[15,]:Available;isAgeOver:true:[18,]:Available;";
+
+ /**
+ * Simple attribute value list string.
+ */
+ private static final String SIMPLE_ATTRLIST3_REVERSE =
+ "isAgeOver:true:[18,]:Available;isAgeOver:true:[15,]:Available;";
+ /**
+ * Simple attribute value list string.
+ */
+ private static final String COMPLEX_ATTRLIST =
+ "canonicalResidenceAddress:true:[postalCode=4100,apartmentNumber=Ed. B,"
+ + "state=Porto,countryCodeAddress=PT,streetNumber=379,"
+ + "streetName=Avenida Sidonio Pais,town=Porto,]:Available;";
+ /**
+ * Mix attribute list string.
+ */
+ private static final String STR_MIX_ATTR_LIST =
+ "isAgeOver:true:[15,]:Available;canonicalResidenceAddress:true:["
+ + "postalCode=4100,apartmentNumber=Ed.B,state=Porto,countryCodeAddress=PT,"
+ + "streetNumber=379,streetName=Avenida Sidonio Pais,town=Porto,]:"
+ + "Available;";
+
+ /**
+ * Mix attribute list 2 string.
+ */
+ private static final String STR_MIX_ATTR_LIST2 =
+ "isAgeOver:true:[15,]:Available;canonicalResidenceAddress:true:["
+ + "postalCode=4100,apartmentNumber=Ed.B,state=Porto,countryCodeAddress=PT,"
+ + "streetNumber=379,streetName=Avenida Sidonio Pais,town=Porto,]:Available;"
+ + "mandateContent:true:["
+ + "isJoint=\"isjoint\",typeOfPower=\"power\",ValidTo=\"validto\",validfrom=\"validfrom\",AQAA=\"3\",isChained=\"ischained\",]:"
+ + "Available;";
+
+ /**
+ * Attribute List example.
+ */
+ @SuppressWarnings({ "serial" })
+ private static final PersonalAttribute ATTR_VALUE = new PersonalAttribute(
+ "age", true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ /**
+ * Init PersonalAttributeListTestCase class.
+ */
+ @SuppressWarnings("serial")
+ @BeforeClass
+ public static void runsBeforeTheTestSuite() {
+ final Map<String, String> values = new HashMap<String, String>() {
+ {
+ put("countryCodeAddress", "PT");
+ put("state", "Porto");
+ put("town", "Porto");
+ put("postalCode", "4100");
+ put("streetName", "Avenida Sidonio Pais");
+ put("streetNumber", "379");
+ put("apartmentNumber", "Ed. B");
+ }
+ };
+
+ complexAttrValue =
+ new PersonalAttribute("canonicalResidenceAddress", true, values,
+ STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ }
+
+ /**
+ * Testing Personal Attribute List add method. Personal Attribute list must be
+ * size 1 - Simple attribute.
+ */
+ @Test
+ public void testAddSimpleAttr() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(ATTR_VALUE);
+ Assert.assertTrue(attrList.size() == 1);
+ }
+
+ /**
+ * Testing Personal Attribute List add method. Personal Attribute list must be
+ * size 1 - Complex attribute.
+ */
+ @Test
+ public void testAddCompleAttr() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(complexAttrValue);
+ Assert.assertTrue(attrList.size() == 1);
+ }
+
+ /**
+ * Testing Personal Attribute List add method. Personal Attribute list must be
+ * size 0 - no attribute.
+ */
+ @Test
+ public void testAddNull() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(null);
+ Assert.assertTrue(attrList.size() == 0);
+ }
+
+ /**
+ * Testing Personal Attribute List add method. Same attribute name added
+ * twice. Personal Attribute list must be size 2 - IsAgeOver attribute added
+ * twice.
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testAddSameAttrName() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("18");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(attrValueUnder);
+ attrList.add(attrValueOver);
+ Assert.assertTrue(attrList.size() == 2);
+ }
+
+ /**
+ * Testing Personal Attribute List add method. Same attribute name added
+ * twice. Personal Attribute list must be size 2 - IsAgeOver attribute added
+ * twice.
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testAddSameAttrNameEmpty() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(attrValueUnder);
+ attrList.add(attrValueOver);
+ Assert.assertTrue(attrList.size() == 2);
+ }
+
+ /**
+ * Testing Personal Attribute List put method. Personal Attribute list must be
+ * size 1 - Simple Value.
+ */
+ @Test
+ public void testPutSimpleAttr() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.put(ATTR_VALUE.getName(), ATTR_VALUE);
+ Assert.assertTrue(attrList.size() == 1);
+ }
+
+ /**
+ * Testing Personal Attribute List put method. Personal Attribute list must be
+ * size 1 - Complex Value.
+ */
+ @Test
+ public void testPutComplexAttr() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.put(ATTR_VALUE.getName(), complexAttrValue);
+ Assert.assertTrue(attrList.size() == 1);
+ }
+
+ /**
+ * Testing Personal Attribute List put method. Personal Attribute list must be
+ * size 0 - no attribute.
+ */
+ @Test
+ public void testPutNull() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.put("", null);
+ Assert.assertTrue(attrList.size() == 0);
+ }
+
+ /**
+ * Testing Personal Attribute List put method. Personal Attribute list must be
+ * size 2 - IsAgeOver attribute added twice.
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testPutSameAttrName() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("18");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.put(attrValueUnder.getName(), attrValueUnder);
+ attrList.put(attrValueOver.getName(), attrValueOver);
+ Assert.assertTrue(attrList.size() == 2);
+ }
+
+ /**
+ * Testing Personal Attribute List put method. Personal Attribute list must be
+ * size 2 - IsAgeOver attribute added twice.
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testPutSameAttrNameEmpty() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.put(attrValueUnder.getName(), attrValueUnder);
+ attrList.put(attrValueOver.getName(), attrValueOver);
+ Assert.assertTrue(attrList.size() == 2);
+ }
+
+ /**
+ * Testing Personal Attribute List get method. Personal Attribute list must be
+ * size 1 - Simple attribute.
+ */
+ @Test
+ public void testGetSimpleAttr() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(ATTR_VALUE);
+ Assert.assertEquals(ATTR_VALUE, attrList.get(ATTR_VALUE.getName()));
+ }
+
+ /**
+ * Testing Personal Attribute List add method. Personal Attribute list must be
+ * size 1 - Complex attribute.
+ */
+ @Test
+ public void testGetCompleAttr() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(complexAttrValue);
+ Assert.assertEquals(complexAttrValue.toString(),
+ attrList.get(complexAttrValue.getName()).toString());
+ }
+
+ /**
+ * Testing Personal Attribute List get method. Personal Attribute list must be
+ * size 2 - IsAgeOver attribute.
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testGetIsAgeOverAttr() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("18");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(attrValueUnder);
+ attrList.add(attrValueOver);
+ Assert.assertEquals(SIMPLE_ATTRLIST,
+ attrList.get(attrValueUnder.getName()).toString());
+ Assert.assertEquals(SIMPLE_ATTRLIST2,
+ attrList.get(attrValueOver.getName()).toString());
+ }
+
+ /**
+ * Testing Personal Attribute List populate method. Personal Attribute list
+ * must be size 1 - Simple attribute.
+ */
+ @Test
+ public void testPopulateSimpleAttr() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.populate(SIMPLE_ATTRLIST);
+ Assert.assertTrue(attrList.size() == 1);
+ }
+
+ /**
+ * Testing Personal Attribute List populate method. Personal Attribute list
+ * must be size 1 - Complex attribute.
+ */
+ @Test
+ public void testPopulateComplexAttr() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.populate(COMPLEX_ATTRLIST);
+ Assert.assertTrue(attrList.size() == 1);
+ }
+
+ /**
+ * Testing Personal Attribute List populate method. Personal Attribute list
+ * must be size 1 - Simple and Complex attribute.
+ */
+ @Test
+ public void testPopulateMixAttrs() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.populate(STR_MIX_ATTR_LIST);
+ Assert.assertTrue(attrList.size() == 2);
+ }
+
+ /**
+ * Testing Personal Attribute List toString method using add.
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testToStringFromAdd() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("18");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(attrValueUnder);
+ attrList.add(attrValueOver);
+ Assert.assertEquals(SIMPLE_ATTRLIST3_REVERSE, attrList.toString());
+ }
+
+ /**
+ * Testing Personal Attribute List toString method using put.
+ *
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testToStringFromPut() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("18");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.put(attrValueUnder.getName(), attrValueUnder);
+ attrList.put(attrValueOver.getName(), attrValueOver);
+ Assert.assertEquals(SIMPLE_ATTRLIST3_REVERSE, attrList.toString());
+ }
+
+ /**
+ * Testing Personal Attribute List toString method using populate.
+ */
+ @Test
+ public void testToStringFromSimplePopulate() {
+ final String strAttrList = "isAgeOver:true";
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.populate(strAttrList);
+ Assert.assertEquals("isAgeOver:true:[]:;", attrList.toString());
+ }
+
+ /**
+ * Testing Personal Attribute List toString method using populate.
+ */
+ @Test
+ public void testToStringFromPopulate() {
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.populate(SIMPLE_ATTRLIST3);
+ Assert.assertEquals(SIMPLE_ATTRLIST3_REVERSE, attrList.toString());
+ }
+
+ /**
+ * Testing Personal Attribute List populate method, with invalid values.
+ */
+ @Test
+ public void testPopulateWithInvalidValuesFormat() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate("name:type:values:status;");
+ Assert.assertEquals(pal, new PersonalAttributeList());
+ }
+
+ /**
+ * Testing Personal Attribute List populate method, with invalid format.
+ */
+ @Test
+ public void testPopulateWithInvalidFormat() {
+
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate("name:type::status;");
+ Assert.assertEquals(pal, new PersonalAttributeList());
+ }
+
+ /**
+ * Testing Personal Attribute List clone method using add.
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testCloneFromAdd() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("18");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.add(attrValueUnder);
+ attrList.add(attrValueOver);
+ Assert.assertNotSame(attrList, attrList.clone());
+ }
+
+ /**
+ * Testing Personal Attribute List clone method using put.
+ */
+ @SuppressWarnings("serial")
+ @Test
+ public void testCloneFromPut() {
+ final PersonalAttribute attrValueUnder =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ final PersonalAttribute attrValueOver =
+ new PersonalAttribute(ISAGEOVER_CONS, true, new ArrayList<String>() {
+ {
+ add("18");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+ final PersonalAttributeList attrList = new PersonalAttributeList(1);
+ attrList.put(attrValueUnder.getName(), attrValueUnder);
+ attrList.put(attrValueOver.getName(), attrValueOver);
+ Assert.assertNotSame(attrList, attrList.clone());
+ }
+
+ /**
+ * Testing Personal Attribute List clone method using populate.
+ */
+ @Test
+ public void testCloneFromPopulate() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(SIMPLE_ATTRLIST3);
+ Assert.assertNotSame(pal, pal.clone());
+ }
+
+ /**
+ * Testing Personal Attribute List iterator.
+ */
+ @Test
+ public void testIterator() {
+ final String strAttrList =
+ "isAgeOver:true:[15,]:Available;isAgeOver:true:[18,]:Available;";
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(strAttrList);
+ final Iterator<PersonalAttribute> itAttr = pal.iterator();
+ while (itAttr.hasNext()) {
+ final PersonalAttribute attr = itAttr.next();
+ Assert.assertEquals(ISAGEOVER_CONS, attr.getName());
+ }
+ }
+
+ /**
+ * Testing Personal Attribute List's GetOptionalAttributes method with empty attribute list.
+ */
+ @Test
+ public void testGetOptionalAttributesWithEmptyList() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ Assert.assertTrue(pal.getOptionalAttributes().isEmpty());
+ }
+
+ /**
+ * Testing Personal Attribute List's GetOptionalAttributes method without optional attributes.
+ */
+ @Test
+ public void testGetOptionalAttributesWithoutOptional() {
+ final String strAttrList =
+ "isAgeOver:true:[15,]:Available;isAgeOver:true:[18,]:Available;";
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(strAttrList);
+ Assert.assertTrue(pal.getOptionalAttributes().isEmpty());
+ }
+
+ /**
+ * Testing Personal Attribute List's GetOptionalAttributes method with one optional attribute.
+ */
+ @Test
+ public void testGetOptionalAttributesWithOneOptional() {
+ final String strAttrList =
+ "age:false:[]:;isAgeOver:true:[15,]:;isAgeOver:true:[18,]:;";
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(strAttrList);
+ Assert.assertTrue(pal.getOptionalAttributes().size() == ONE_CONS);
+ }
+
+ /**
+ * Testing Personal Attribute List's GetOptionalAttributes method with two optional attribute.
+ */
+ @Test
+ public void testGetOptionalAttributesWithOnlyOptional() {
+ final String strAttrList =
+ "age:false:[]:;isAgeOver:false:[18,]:;";
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(strAttrList);
+ Assert.assertTrue(pal.getOptionalAttributes().size() == TWO_CONS);
+ }
+
+ /**
+ * Testing Personal Attribute List's getMandatoryAttributes method with empty attribute list.
+ */
+ @Test
+ public void testGetMandatoryAttributesWithEmptyList() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ Assert.assertTrue(pal.getMandatoryAttributes().isEmpty());
+ }
+
+ /**
+ * Testing Personal Attribute List's getMandatoryAttributes method without mandatory attributes.
+ */
+ @Test
+ public void testGetMandatoryAttributesWithoutMandatory() {
+ final String strAttrList =
+ "isAgeOver:false:[15,]:Available;isAgeOver:false:[18,]:Available;";
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(strAttrList);
+ Assert.assertTrue(pal.getMandatoryAttributes().isEmpty());
+ }
+
+ /**
+ * Testing Personal Attribute List's GetMandatoryAttributes method with one mandatory attribute.
+ */
+ @Test
+ public void testGetMandatoryAttributesWithOneMandatory() {
+ final String strAttrList =
+ "age:true:[]:;isAgeOver:false:[15,]:;isAgeOver:false:[18,]:;";
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(strAttrList);
+ Assert.assertTrue(pal.getMandatoryAttributes().size() == ONE_CONS);
+ }
+
+ /**
+ * Testing Personal Attribute List's GetMandatoryAttributes method with two mandatory attribute.
+ */
+ @Test
+ public void testGetMandatoryAttributesWithOnlyMandatory() {
+ final String strAttrList =
+ "age:true:[]:;isAgeOver:true:[18,]:;";
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(strAttrList);
+ Assert.assertTrue(pal.getMandatoryAttributes().size() == TWO_CONS);
+ }
+
+ /**
+ * Testing Personal Attribute List's getSimpleValueAttributes method with empty attribute list.
+ */
+ @Test
+ public void testGetSimpleValueAttributesWithEmptyList() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ Assert.assertTrue(pal.getSimpleValueAttributes().isEmpty());
+ }
+
+ /**
+ * Testing Personal Attribute List's getSimpleValueAttributes() method without simple attributes.
+ */
+ @Test
+ public void testGetSimpleValueAttributesWithoutSimple() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(COMPLEX_ATTRLIST);
+ Assert.assertTrue(pal.getSimpleValueAttributes().isEmpty());
+ }
+
+ /**
+ * Testing Personal Attribute List's getSimpleValueAttributes() method with one simple attribute.
+ */
+ @Test
+ public void testGetSimpleValueAttributesWithOneSimple() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(STR_MIX_ATTR_LIST);
+ Assert.assertTrue(pal.getSimpleValueAttributes().size() == ONE_CONS);
+ }
+
+ /**
+ * Testing Personal Attribute List's GetMandatoryAttributes method with two simple attribute.
+ */
+ @Test
+ public void testGetSimpleValueAttributesWithOnlySimple() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(SIMPLE_ATTRLIST3);
+ Assert.assertTrue(pal.getSimpleValueAttributes().size() == TWO_CONS);
+ }
+
+ /**
+ * Testing Personal Attribute List's getComplexValueAttributes method with empty attribute list.
+ */
+ @Test
+ public void testGetComplexAttributesWithEmptyList() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ Assert.assertTrue(pal.getComplexAttributes().isEmpty());
+ }
+
+ /**
+ * Testing Personal Attribute List's getComplexAttributes() method without complex attributes.
+ */
+ @Test
+ public void testGetComplexAttributesWithoutSimple() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(SIMPLE_ATTRLIST2);
+ Assert.assertTrue(pal.getComplexAttributes().isEmpty());
+ }
+
+ /**
+ * Testing Personal Attribute List's getComplexAttributes() method with one complex attribute.
+ */
+ @Test
+ public void testGetComplexAttributesWithOneComplex() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(STR_MIX_ATTR_LIST);
+ Assert.assertTrue(pal.getComplexAttributes().size() == ONE_CONS);
+ }
+
+ /**
+ * Testing Personal Attribute List's GetMandatoryAttributes method with only two Complex attribute.
+ */
+ @Test
+ public void testGetComplexAttributesWithOnlyComplex() {
+ final PersonalAttributeList pal = new PersonalAttributeList();
+ pal.populate(STR_MIX_ATTR_LIST2);
+ Assert.assertTrue(pal.getComplexAttributes().size() == TWO_CONS);
+ }
+
+}
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/PersonalAttributeTestCase.java b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/PersonalAttributeTestCase.java
new file mode 100644
index 000000000..458d510e0
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/PersonalAttributeTestCase.java
@@ -0,0 +1,182 @@
+/*
+ * This work is Open Source and licensed by the European Commission under the
+ * conditions of the European Public License v1.1
+ *
+ * (http://www.osor.eu/eupl/european-union-public-licence-eupl-v.1.1);
+ *
+ * any use of this file implies acceptance of the conditions of this license.
+ * 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.
+ */
+package eu.stork.peps.tests;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.Map;
+
+import junit.framework.Assert;
+
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+import eu.stork.peps.auth.commons.PersonalAttribute;
+import eu.stork.peps.auth.commons.STORKStatusCode;
+
+/**
+ * The PersonalAttribute's Test Case.
+ *
+ * @author ricardo.ferreira@multicert.com, renato.portela@multicert.com,
+ * luis.felix@multicert.com, hugo.magalhaes@multicert.com,
+ * paulo.ribeiro@multicert.com
+ * @version $Revision: 1.4 $, $Date: 2010-11-17 05:17:03 $
+ */
+public final class PersonalAttributeTestCase {
+
+ /**
+ * An empty attribute.
+ */
+ private static final PersonalAttribute EMPTYATTR = new PersonalAttribute();
+
+ /**
+ * An attribute with a complex value (canonicalResidenceAddress).
+ */
+ private static PersonalAttribute complexAttrValue = null;
+
+ /**
+ * An attribute with a simple value (age).
+ */
+ @SuppressWarnings("serial")
+ private static final PersonalAttribute ATTR_VALUE = new PersonalAttribute(
+ "age", true, new ArrayList<String>() {
+ {
+ add("15");
+ }
+ }, STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ /**
+ * Init PersonalAttributeTestCase class.
+ */
+ @SuppressWarnings("serial")
+ @BeforeClass
+ public static void runsBeforeTheTestSuite() {
+ final Map<String, String> values = new HashMap<String, String>() {
+ {
+ put("countryCodeAddress", "PT");
+ put("state", "Porto");
+ put("town", "Porto");
+ put("postalCode", "4100");
+ put("streetName", "Avenida Sidonio Pais");
+ put("streetNumber", "379");
+ put("apartmentNumber", "B");
+ }
+ };
+
+ complexAttrValue =
+ new PersonalAttribute("canonicalResidenceAddress", true, values,
+ STORKStatusCode.STATUS_AVAILABLE.toString());
+
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#toString()} method for the given simple
+ * attribute value. Values must match.
+ */
+ @Test
+ public void testToStringValues() {
+ Assert.assertEquals("age:true:[15,]:Available;", ATTR_VALUE.toString());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#toString()} method for the given complex
+ * attribute value. Values must match.
+ */
+ @Test
+ public void testToStringComplexValues() {
+ Assert.assertEquals(
+ "canonicalResidenceAddress:true:[postalCode=4100,apartmentNumber=B,"
+ + "state=Porto,countryCodeAddress=PT,streetNumber=379,"
+ + "streetName=Avenida Sidonio Pais,town=Porto,]:Available;",
+ complexAttrValue.toString());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#isEmptyStatus()} method for the given
+ * empty attribute. Must return true.
+ */
+ @Test
+ public void testToIsEmptyStatusWithNull() {
+ Assert.assertTrue(EMPTYATTR.isEmptyStatus());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#isEmptyStatus()} method for the given
+ * new attribute. Must return true.
+ */
+ @Test
+ public void testToIsEmptyStatusWithEmptyString() {
+ final PersonalAttribute attr = (PersonalAttribute) EMPTYATTR.clone();
+ attr.setStatus("");
+ Assert.assertTrue(attr.isEmptyStatus());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#isEmptyValue()} method for the given
+ * empty attribute. Must return true.
+ */
+ @Test
+ public void testToIsEmptyValueWithNull() {
+ final PersonalAttribute attr = (PersonalAttribute) EMPTYATTR.clone();
+ attr.setValue(null);
+ Assert.assertTrue(attr.isEmptyValue());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#isEmptyValue()} method for the given
+ * empty attribute. Must return true.
+ */
+ @Test
+ public void testToIsEmptyValue() {
+ Assert.assertTrue(EMPTYATTR.isEmptyValue());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#isEmptyComplexValue()} method for the
+ * given empty attribute. Must return true.
+ */
+ @Test
+ public void testToIsEmptyComplexValueWithNull() {
+ final PersonalAttribute attr = (PersonalAttribute) EMPTYATTR.clone();
+ attr.setComplexValue(null);
+ Assert.assertTrue(attr.isEmptyComplexValue());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#isEmptyComplexValue()} method for the
+ * given empty attribute. Must return true.
+ */
+ @Test
+ public void testToIsEmptyComplexValueWithEmptyComplexValue() {
+ Assert.assertTrue(EMPTYATTR.isEmptyComplexValue());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#clone()} method for the given attribute.
+ * Must return true.
+ */
+ @Test
+ public void testCloneToComplexValue() {
+ Assert.assertNotSame(complexAttrValue, complexAttrValue.clone());
+ }
+
+ /**
+ * Tests the {@link PersonalAttribute#clone()} method for the given attribute.
+ * Must return true.
+ */
+ @Test
+ public void testCloneToValue() {
+ Assert.assertNotSame(ATTR_VALUE, ATTR_VALUE.clone());
+ }
+}
diff --git a/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/package-info.java b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/package-info.java
new file mode 100644
index 000000000..452602210
--- /dev/null
+++ b/id/server/stork2-commons/src/test/java/eu/stork/peps/tests/package-info.java
@@ -0,0 +1,5 @@
+/**
+ * This package provides all JUnit test classes.
+ */
+package eu.stork.peps.tests;
+
diff --git a/id/server/stork2-commons/src/test/resources/.svn/all-wcprops b/id/server/stork2-commons/src/test/resources/.svn/all-wcprops
new file mode 100644
index 000000000..a3a21b424
--- /dev/null
+++ b/id/server/stork2-commons/src/test/resources/.svn/all-wcprops
@@ -0,0 +1,11 @@
+K 25
+svn:wc:ra_dav:version-url
+V 63
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/test/resources
+END
+log4j.xml
+K 25
+svn:wc:ra_dav:version-url
+V 73
+/CITnet/svn/STORK2/!svn/ver/19/trunk/Commons/src/test/resources/log4j.xml
+END
diff --git a/id/server/stork2-commons/src/test/resources/.svn/entries b/id/server/stork2-commons/src/test/resources/.svn/entries
new file mode 100644
index 000000000..9274deb98
--- /dev/null
+++ b/id/server/stork2-commons/src/test/resources/.svn/entries
@@ -0,0 +1,62 @@
+10
+
+dir
+776
+https://webgate.ec.europa.eu/CITnet/svn/STORK2/trunk/Commons/src/test/resources
+https://webgate.ec.europa.eu/CITnet/svn/STORK2
+
+
+
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+aa842e49-f825-43fc-93ba-11ee9fd5a035
+
+log4j.xml
+file
+
+
+
+
+2013-12-20T12:27:56.542475Z
+4e990a84da0033594135b05cd01a9cdd
+2013-07-25T08:54:09.995385Z
+7
+emsomavmi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+645
+
diff --git a/id/server/stork2-commons/src/test/resources/.svn/text-base/log4j.xml.svn-base b/id/server/stork2-commons/src/test/resources/.svn/text-base/log4j.xml.svn-base
new file mode 100644
index 000000000..0ad2ea9a4
--- /dev/null
+++ b/id/server/stork2-commons/src/test/resources/.svn/text-base/log4j.xml.svn-base
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
+
+<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/">
+ <appender name="MainLogger" class="org.apache.log4j.DailyRollingFileAppender">
+ <param name="File" value="stork-commons.log" />
+ <param name="DatePattern" value="'.'yyyy-MM-dd" />
+ <param name="Append" value="true" />
+ <layout class="org.apache.log4j.PatternLayout">
+ <param name="ConversionPattern" value="%d{HH:mm:ss:SSS} - %p - %C{1} - %m%n" />
+ </layout>
+ </appender>
+
+ <root>
+ <priority value="info" />
+ <appender-ref ref="MainLogger" />
+ </root>
+
+</log4j:configuration>
diff --git a/id/server/stork2-commons/src/test/resources/log4j.xml b/id/server/stork2-commons/src/test/resources/log4j.xml
new file mode 100644
index 000000000..0ad2ea9a4
--- /dev/null
+++ b/id/server/stork2-commons/src/test/resources/log4j.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
+
+<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/">
+ <appender name="MainLogger" class="org.apache.log4j.DailyRollingFileAppender">
+ <param name="File" value="stork-commons.log" />
+ <param name="DatePattern" value="'.'yyyy-MM-dd" />
+ <param name="Append" value="true" />
+ <layout class="org.apache.log4j.PatternLayout">
+ <param name="ConversionPattern" value="%d{HH:mm:ss:SSS} - %p - %C{1} - %m%n" />
+ </layout>
+ </appender>
+
+ <root>
+ <priority value="info" />
+ <appender-ref ref="MainLogger" />
+ </root>
+
+</log4j:configuration>
diff --git a/id/server/SamlEngine-VIDP/pom.xml b/id/server/stork2-saml-engine/pom.xml
index cead61eb8..cead61eb8 100644
--- a/id/server/SamlEngine-VIDP/pom.xml
+++ b/id/server/stork2-saml-engine/pom.xml
diff --git a/id/server/SamlEngine-VIDP/src/main/java/META-INF/MANIFEST.MF b/id/server/stork2-saml-engine/src/main/java/META-INF/MANIFEST.MF
index 254272e1c..254272e1c 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/META-INF/MANIFEST.MF
+++ b/id/server/stork2-saml-engine/src/main/java/META-INF/MANIFEST.MF
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/SAMLEngine.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/SAMLEngine.java
index 26635e337..26635e337 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/SAMLEngine.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/SAMLEngine.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/SAMLEngineUtils.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/SAMLEngineUtils.java
index 1efbb8b32..1efbb8b32 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/SAMLEngineUtils.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/SAMLEngineUtils.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/STORKSAMLEngine.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/STORKSAMLEngine.java
index 6bdf7b320..6bdf7b320 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/STORKSAMLEngine.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/STORKSAMLEngine.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/X509PrincipalUtil.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/X509PrincipalUtil.java
index 724a522d1..724a522d1 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/X509PrincipalUtil.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/X509PrincipalUtil.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/AuthenticationAttributes.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/AuthenticationAttributes.java
index a9efe6362..a9efe6362 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/AuthenticationAttributes.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/AuthenticationAttributes.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/CitizenCountryCode.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/CitizenCountryCode.java
index 4af7524ea..4af7524ea 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/CitizenCountryCode.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/CitizenCountryCode.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/CustomAttributeQuery.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/CustomAttributeQuery.java
index b558fc19d..b558fc19d 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/CustomAttributeQuery.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/CustomAttributeQuery.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/CustomRequestAbstractType.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/CustomRequestAbstractType.java
index 77dd8c4a5..77dd8c4a5 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/CustomRequestAbstractType.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/CustomRequestAbstractType.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/EIDCrossBorderShare.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/EIDCrossBorderShare.java
index 03541ece1..03541ece1 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/EIDCrossBorderShare.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/EIDCrossBorderShare.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/EIDCrossSectorShare.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/EIDCrossSectorShare.java
index 14c504510..14c504510 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/EIDCrossSectorShare.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/EIDCrossSectorShare.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/EIDSectorShare.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/EIDSectorShare.java
index 0202f000c..0202f000c 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/EIDSectorShare.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/EIDSectorShare.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/QAAAttribute.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/QAAAttribute.java
index d99d23896..d99d23896 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/QAAAttribute.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/QAAAttribute.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/RequestedAttribute.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/RequestedAttribute.java
index ffd32b3cf..ffd32b3cf 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/RequestedAttribute.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/RequestedAttribute.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/RequestedAttributes.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/RequestedAttributes.java
index 6e3da28c3..6e3da28c3 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/RequestedAttributes.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/RequestedAttributes.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SAMLCore.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SAMLCore.java
index cbedcf7d9..cbedcf7d9 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SAMLCore.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SAMLCore.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SAMLEngineSignI.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SAMLEngineSignI.java
index e846983d8..e846983d8 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SAMLEngineSignI.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SAMLEngineSignI.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPApplication.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPApplication.java
index 9510bf790..9510bf790 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPApplication.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPApplication.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPCountry.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPCountry.java
index 829ace878..829ace878 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPCountry.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPCountry.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPID.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPID.java
index bd13f6dbf..bd13f6dbf 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPID.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPID.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPInformation.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPInformation.java
index bc870c2cc..bc870c2cc 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPInformation.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPInformation.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPInstitution.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPInstitution.java
index add45023c..add45023c 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPInstitution.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPInstitution.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPSector.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPSector.java
index 8322a0d47..8322a0d47 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/SPSector.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/SPSector.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/STORKSAMLCore.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/STORKSAMLCore.java
index 4c314ae68..4c314ae68 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/STORKSAMLCore.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/STORKSAMLCore.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/VIDPAuthenticationAttributes.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/VIDPAuthenticationAttributes.java
index 6ee9e0e1b..6ee9e0e1b 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/VIDPAuthenticationAttributes.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/VIDPAuthenticationAttributes.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesBuilder.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesBuilder.java
index 2d9039d4c..2d9039d4c 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesBuilder.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesBuilder.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesImpl.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesImpl.java
index e0de20f7d..e0de20f7d 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesImpl.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesImpl.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesMarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesMarshaller.java
index d31c052fe..d31c052fe 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesMarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesMarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesUnmarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesUnmarshaller.java
index 113214712..113214712 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesUnmarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/AuthenticationAttributesUnmarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeBuilder.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeBuilder.java
index 64651691f..64651691f 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeBuilder.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeBuilder.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeImpl.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeImpl.java
index 374398cf1..374398cf1 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeImpl.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeImpl.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeMarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeMarshaller.java
index decae04c5..decae04c5 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeMarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeMarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeUnmarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeUnmarshaller.java
index 93132b508..93132b508 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeUnmarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CitizenCountryCodeUnmarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryBuilder.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryBuilder.java
index 48da2a24b..48da2a24b 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryBuilder.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryBuilder.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryImpl.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryImpl.java
index cbf9221eb..cbf9221eb 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryImpl.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryImpl.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryMarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryMarshaller.java
index 7f2013ca8..7f2013ca8 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryMarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryMarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryUnmarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryUnmarshaller.java
index e351b65b0..e351b65b0 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryUnmarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/CustomAttributeQueryUnmarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareBuilder.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareBuilder.java
index 3f4fc633d..3f4fc633d 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareBuilder.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareBuilder.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareImpl.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareImpl.java
index 3827f5085..3827f5085 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareImpl.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareImpl.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareMarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareMarshaller.java
index c5e113013..c5e113013 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareMarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareMarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareUnmarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareUnmarshaller.java
index e74bee6ca..e74bee6ca 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareUnmarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossBorderShareUnmarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareBuilder.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareBuilder.java
index 5e91e18fd..5e91e18fd 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareBuilder.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareBuilder.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareImpl.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareImpl.java
index 7b2ad3dbd..7b2ad3dbd 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareImpl.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareImpl.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareMarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareMarshaller.java
index 3ee9df698..3ee9df698 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareMarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareMarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareUnmarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareUnmarshaller.java
index 94c7689be..94c7689be 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareUnmarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDCrossSectorShareUnmarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareBuilder.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareBuilder.java
index 230ff3ca4..230ff3ca4 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareBuilder.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareBuilder.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareImpl.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareImpl.java
index 9ed726a32..9ed726a32 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareImpl.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareImpl.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareMarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareMarshaller.java
index 0ce449cd1..0ce449cd1 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareMarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareMarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareUnmarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareUnmarshaller.java
index f7f00adb9..f7f00adb9 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareUnmarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/EIDSectorShareUnmarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeBuilder.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeBuilder.java
index 41676931b..41676931b 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeBuilder.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeBuilder.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeImpl.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeImpl.java
index 46f3bb402..46f3bb402 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeImpl.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeImpl.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeMarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeMarshaller.java
index 000879368..000879368 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeMarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeMarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeUnmarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeUnmarshaller.java
index 8445e4eeb..8445e4eeb 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeUnmarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/QAAAttributeUnmarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeBuilder.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeBuilder.java
index c9881c439..c9881c439 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeBuilder.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeBuilder.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeImpl.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeImpl.java
index ac2e8a3ee..ac2e8a3ee 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeImpl.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeImpl.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeMarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeMarshaller.java
index 1a14a118a..1a14a118a 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeMarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeMarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeUnmarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeUnmarshaller.java
index c07f852d9..c07f852d9 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeUnmarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributeUnmarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesBuilder.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesBuilder.java
index d421c53d2..d421c53d2 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesBuilder.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesBuilder.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesImpl.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesImpl.java
index 0a5b37add..0a5b37add 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesImpl.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesImpl.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesMarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesMarshaller.java
index dfc42adf3..dfc42adf3 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesMarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesMarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesUnmarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesUnmarshaller.java
index 41b3afa40..41b3afa40 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesUnmarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/RequestedAttributesUnmarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationBuilder.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationBuilder.java
index a35c77936..a35c77936 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationBuilder.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationBuilder.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationImpl.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationImpl.java
index 0a428a521..0a428a521 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationImpl.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationImpl.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationMarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationMarshaller.java
index 4866c3535..4866c3535 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationMarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationMarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationUnmarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationUnmarshaller.java
index a28432a13..a28432a13 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationUnmarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPApplicationUnmarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryBuilder.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryBuilder.java
index 48ec92f49..48ec92f49 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryBuilder.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryBuilder.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryImpl.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryImpl.java
index 40a1ac86a..40a1ac86a 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryImpl.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryImpl.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryMarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryMarshaller.java
index e82634749..e82634749 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryMarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryMarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryUnmarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryUnmarshaller.java
index deb695ac6..deb695ac6 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryUnmarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPCountryUnmarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDBuilder.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDBuilder.java
index b3640947b..b3640947b 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDBuilder.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDBuilder.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDImpl.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDImpl.java
index 68611997b..68611997b 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDImpl.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDImpl.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDMarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDMarshaller.java
index 24389522e..24389522e 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDMarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDMarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDUnmarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDUnmarshaller.java
index e4d230b94..e4d230b94 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDUnmarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPIDUnmarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationBuilder.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationBuilder.java
index a6e1fe686..a6e1fe686 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationBuilder.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationBuilder.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationImpl.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationImpl.java
index ff6e90999..ff6e90999 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationImpl.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationImpl.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationMarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationMarshaller.java
index 44845948c..44845948c 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationMarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationMarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationUnmarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationUnmarshaller.java
index 414b93386..414b93386 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationUnmarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInformationUnmarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionBuilder.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionBuilder.java
index fe47cf99c..fe47cf99c 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionBuilder.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionBuilder.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionImpl.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionImpl.java
index 38438613a..38438613a 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionImpl.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionImpl.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionMarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionMarshaller.java
index 504a1f035..504a1f035 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionMarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionMarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionUnmarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionUnmarshaller.java
index 103d5f2b2..103d5f2b2 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionUnmarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPInstitutionUnmarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorBuilder.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorBuilder.java
index a691b9008..a691b9008 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorBuilder.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorBuilder.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorImpl.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorImpl.java
index 4ac822876..4ac822876 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorImpl.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorImpl.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorMarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorMarshaller.java
index c5331e8f4..c5331e8f4 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorMarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorMarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorUnmarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorUnmarshaller.java
index cbb05c6e5..cbb05c6e5 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorUnmarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SPSectorUnmarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SignHW.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignHW.java
index 80796ea86..80796ea86 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SignHW.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignHW.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SignModuleFactory.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignModuleFactory.java
index c37074eab..c37074eab 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SignModuleFactory.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignModuleFactory.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SignP12.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignP12.java
index 6d9ac9ce3..6d9ac9ce3 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SignP12.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignP12.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SignSW.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignSW.java
index e31688069..e31688069 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/SignSW.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/SignSW.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesBuilder.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesBuilder.java
index a60515593..a60515593 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesBuilder.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesBuilder.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesImpl.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesImpl.java
index 25737e307..25737e307 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesImpl.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesImpl.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesMarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesMarshaller.java
index 5635ddd6b..5635ddd6b 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesMarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesMarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesUnmarshaller.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesUnmarshaller.java
index ba4a4fe3a..ba4a4fe3a 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesUnmarshaller.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/VIDPAuthenticationAttributesUnmarshaller.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/package-info.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/package-info.java
index 07db9c9db..07db9c9db 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/impl/package-info.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/impl/package-info.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/package-info.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/package-info.java
index 51745d796..51745d796 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/package-info.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/package-info.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/validator/CustomAttributeQueryValidator.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/validator/CustomAttributeQueryValidator.java
index c602ad38a..c602ad38a 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/validator/CustomAttributeQueryValidator.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/validator/CustomAttributeQueryValidator.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/validator/ExtensionsSchemaValidator.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/validator/ExtensionsSchemaValidator.java
index 491549aac..491549aac 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/validator/ExtensionsSchemaValidator.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/validator/ExtensionsSchemaValidator.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/validator/MultipleAssertionResponseValidator.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/validator/MultipleAssertionResponseValidator.java
index 72639c8ee..72639c8ee 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/validator/MultipleAssertionResponseValidator.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/validator/MultipleAssertionResponseValidator.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/validator/QAAAttributeSchemaValidator.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/validator/QAAAttributeSchemaValidator.java
index 44c9db380..44c9db380 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/validator/QAAAttributeSchemaValidator.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/validator/QAAAttributeSchemaValidator.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/validator/package-info.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/validator/package-info.java
index 07b632773..07b632773 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/core/validator/package-info.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/core/validator/package-info.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/package-info.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/package-info.java
index 30130b7f6..30130b7f6 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/auth/engine/package-info.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/auth/engine/package-info.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/ConfigurationCreator.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/ConfigurationCreator.java
index c53e18662..c53e18662 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/ConfigurationCreator.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/ConfigurationCreator.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/ConfigurationEngine.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/ConfigurationEngine.java
index d9e7e467a..d9e7e467a 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/ConfigurationEngine.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/ConfigurationEngine.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/ConfigurationReader.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/ConfigurationReader.java
index 7968c77ff..7968c77ff 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/ConfigurationReader.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/ConfigurationReader.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/ConfigurationSingleton.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/ConfigurationSingleton.java
index d00607853..d00607853 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/ConfigurationSingleton.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/ConfigurationSingleton.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/InstanceEngine.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/InstanceEngine.java
index 4d9bba8e7..4d9bba8e7 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/InstanceEngine.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/InstanceEngine.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/package-info.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/package-info.java
index 344368e03..344368e03 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/configuration/package-info.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/configuration/package-info.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/exceptions/SAMLEngineException.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/exceptions/SAMLEngineException.java
index ac46f73e4..ac46f73e4 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/exceptions/SAMLEngineException.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/exceptions/SAMLEngineException.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/exceptions/STORKSAMLEngineException.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/exceptions/STORKSAMLEngineException.java
index bddcbd1b3..bddcbd1b3 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/exceptions/STORKSAMLEngineException.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/exceptions/STORKSAMLEngineException.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/exceptions/STORKSAMLEngineRuntimeException.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/exceptions/STORKSAMLEngineRuntimeException.java
index fb01fd5aa..fb01fd5aa 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/exceptions/STORKSAMLEngineRuntimeException.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/exceptions/STORKSAMLEngineRuntimeException.java
diff --git a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/exceptions/package-info.java b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/exceptions/package-info.java
index 0c7341995..0c7341995 100644
--- a/id/server/SamlEngine-VIDP/src/main/java/eu/stork/peps/exceptions/package-info.java
+++ b/id/server/stork2-saml-engine/src/main/java/eu/stork/peps/exceptions/package-info.java
diff --git a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/SSETestUtils.java b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/SSETestUtils.java
index eb885eea9..eb885eea9 100644
--- a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/SSETestUtils.java
+++ b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/SSETestUtils.java
diff --git a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/SimpleBaseTest.java b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/SimpleBaseTest.java
index c52b8a779..c52b8a779 100644
--- a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/SimpleBaseTest.java
+++ b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/SimpleBaseTest.java
diff --git a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkAttrQueryRequestTest.java b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkAttrQueryRequestTest.java
index 0eda1bfbf..0eda1bfbf 100644
--- a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkAttrQueryRequestTest.java
+++ b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkAttrQueryRequestTest.java
diff --git a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkAttrQueryResponseTest.java b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkAttrQueryResponseTest.java
index a98d5b7c3..a98d5b7c3 100644
--- a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkAttrQueryResponseTest.java
+++ b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkAttrQueryResponseTest.java
diff --git a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkAuthRequestTest.java b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkAuthRequestTest.java
index 02a8a6fab..02a8a6fab 100644
--- a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkAuthRequestTest.java
+++ b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkAuthRequestTest.java
diff --git a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkLogoutRequestTest.java b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkLogoutRequestTest.java
index 46904788f..46904788f 100644
--- a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkLogoutRequestTest.java
+++ b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkLogoutRequestTest.java
diff --git a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkLogoutResponseTest.java b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkLogoutResponseTest.java
index 2d05e04aa..2d05e04aa 100644
--- a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkLogoutResponseTest.java
+++ b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkLogoutResponseTest.java
diff --git a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkNewResponseTest.java b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkNewResponseTest.java
index 62e9cfb18..62e9cfb18 100644
--- a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkNewResponseTest.java
+++ b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkNewResponseTest.java
diff --git a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkResponseTest.java b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkResponseTest.java
index fe6fcd4f6..fe6fcd4f6 100644
--- a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/StorkResponseTest.java
+++ b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/StorkResponseTest.java
diff --git a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/package-info.java b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/package-info.java
index 1c34e2ad5..1c34e2ad5 100644
--- a/id/server/SamlEngine-VIDP/src/test/java/eu/stork/peps/test/simple/package-info.java
+++ b/id/server/stork2-saml-engine/src/test/java/eu/stork/peps/test/simple/package-info.java
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/SamlEngine.xml b/id/server/stork2-saml-engine/src/test/resources/SamlEngine.xml
index 171e05f12..171e05f12 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/SamlEngine.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/SamlEngine.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/SignModule_Conf0.xml b/id/server/stork2-saml-engine/src/test/resources/SignModule_Conf0.xml
index a9f2038b8..a9f2038b8 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/SignModule_Conf0.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/SignModule_Conf0.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/SignModule_Conf1.xml b/id/server/stork2-saml-engine/src/test/resources/SignModule_Conf1.xml
index e556a7331..e556a7331 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/SignModule_Conf1.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/SignModule_Conf1.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/SignModule_Conf2.xml b/id/server/stork2-saml-engine/src/test/resources/SignModule_Conf2.xml
index 3da1e33df..3da1e33df 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/SignModule_Conf2.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/SignModule_Conf2.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/SignModule_Conf3.xml b/id/server/stork2-saml-engine/src/test/resources/SignModule_Conf3.xml
index 4c14a1711..4c14a1711 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/SignModule_Conf3.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/SignModule_Conf3.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/SignModule_P11.xml b/id/server/stork2-saml-engine/src/test/resources/SignModule_P11.xml
index c683d97c3..c683d97c3 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/SignModule_P11.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/SignModule_P11.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/StorkSamlEngine_Conf0.xml b/id/server/stork2-saml-engine/src/test/resources/StorkSamlEngine_Conf0.xml
index 8c3a94601..8c3a94601 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/StorkSamlEngine_Conf0.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/StorkSamlEngine_Conf0.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/StorkSamlEngine_Conf1.xml b/id/server/stork2-saml-engine/src/test/resources/StorkSamlEngine_Conf1.xml
index ad04cc3df..ad04cc3df 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/StorkSamlEngine_Conf1.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/StorkSamlEngine_Conf1.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/StorkSamlEngine_Conf2.xml b/id/server/stork2-saml-engine/src/test/resources/StorkSamlEngine_Conf2.xml
index fd1db92ac..fd1db92ac 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/StorkSamlEngine_Conf2.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/StorkSamlEngine_Conf2.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/StorkSamlEngine_Conf3.xml b/id/server/stork2-saml-engine/src/test/resources/StorkSamlEngine_Conf3.xml
index bea40d274..bea40d274 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/StorkSamlEngine_Conf3.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/StorkSamlEngine_Conf3.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequest.xml b/id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequest.xml
index 3764389e4..3764389e4 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequest.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequest.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequestSdoc.xml b/id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequestSdoc.xml
index d64572829..d64572829 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequestSdoc.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequestSdoc.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequestTagDelete.xml b/id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequestTagDelete.xml
index becc689fe..becc689fe 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequestTagDelete.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryRequestTagDelete.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryResponse.xml b/id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryResponse.xml
index 7ea486812..7ea486812 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryResponse.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AttrQueryResponse.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequest.xml b/id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequest.xml
index c48bfde95..c48bfde95 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequest.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequest.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDelete.xml b/id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDelete.xml
index 8766f9a8b..8766f9a8b 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDelete.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDelete.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDeleteEncoded.xml b/id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDeleteEncoded.xml
index 1b1e1646c..1b1e1646c 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDeleteEncoded.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/data/eu/stork/STORKSAMLEngine/AuthnRequestTagDeleteEncoded.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/logback-test.xml b/id/server/stork2-saml-engine/src/test/resources/logback-test.xml
index 99d7d353a..99d7d353a 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/logback-test.xml
+++ b/id/server/stork2-saml-engine/src/test/resources/logback-test.xml
diff --git a/id/server/SamlEngine-VIDP/src/test/resources/p11Conf.cfg b/id/server/stork2-saml-engine/src/test/resources/p11Conf.cfg
index bd9f357ce..bd9f357ce 100644
--- a/id/server/SamlEngine-VIDP/src/test/resources/p11Conf.cfg
+++ b/id/server/stork2-saml-engine/src/test/resources/p11Conf.cfg