diff options
author | Thomas Lenz <tlenz@iaik.tugraz.at> | 2015-01-16 11:15:38 +0100 |
---|---|---|
committer | Thomas Lenz <tlenz@iaik.tugraz.at> | 2015-01-16 11:15:38 +0100 |
commit | 3c795bdf9d27eadb48dc8d55573128f6b1edb030 (patch) | |
tree | 8f878048f69ccaca08dd7543c5b308d1c310f573 /id/server | |
parent | 098357d27cab4a43aa8bd911960e16a1cf69726a (diff) | |
download | moa-id-spss-3c795bdf9d27eadb48dc8d55573128f6b1edb030.tar.gz moa-id-spss-3c795bdf9d27eadb48dc8d55573128f6b1edb030.tar.bz2 moa-id-spss-3c795bdf9d27eadb48dc8d55573128f6b1edb030.zip |
add configuration parameter to deactivate PVP metadata schema validation
Diffstat (limited to 'id/server')
2 files changed, 13 insertions, 1 deletions
diff --git a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/config/auth/AuthConfigurationProvider.java b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/config/auth/AuthConfigurationProvider.java index a67badf49..43ec87b12 100644 --- a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/config/auth/AuthConfigurationProvider.java +++ b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/config/auth/AuthConfigurationProvider.java @@ -1047,6 +1047,11 @@ public class AuthConfigurationProvider extends ConfigurationProvider { return !Boolean.valueOf(prop); } + public boolean isPVPSchemaValidationActive() { + String prop = props.getProperty("protocols.pvp2.schemavalidation", "true"); + return !Boolean.valueOf(prop); + } + /** * Retruns the STORK Configuration * @return STORK Configuration diff --git a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/protocols/pvp2x/verification/metadata/SchemaValidationFilter.java b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/protocols/pvp2x/verification/metadata/SchemaValidationFilter.java index 403b68524..382adb108 100644 --- a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/protocols/pvp2x/verification/metadata/SchemaValidationFilter.java +++ b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/protocols/pvp2x/verification/metadata/SchemaValidationFilter.java @@ -36,6 +36,8 @@ import org.opensaml.common.xml.SAMLSchemaBuilder; import org.xml.sax.SAXException; +import at.gv.egovernment.moa.id.config.ConfigurationException; +import at.gv.egovernment.moa.id.config.auth.AuthConfigurationProvider; import at.gv.egovernment.moa.logging.Logger; /** @@ -47,7 +49,12 @@ public class SchemaValidationFilter implements MetadataFilter { private boolean isActive = true; public SchemaValidationFilter() { - + try { + isActive = AuthConfigurationProvider.getInstance().isPVPSchemaValidationActive(); + + } catch (ConfigurationException e) { + e.printStackTrace(); + } } /** |