aboutsummaryrefslogtreecommitdiff
path: root/id
diff options
context:
space:
mode:
authorThomas Lenz <tlenz@iaik.tugraz.at>2014-03-14 13:39:50 +0100
committerThomas Lenz <tlenz@iaik.tugraz.at>2014-03-14 13:39:50 +0100
commit76dd4489a0b0b93ff08c7c684ca229df6f29c0cb (patch)
tree385f728811fabae574d1c15f8764686f27dafdae /id
parent191bd90971b488bff16a5e08d0c1b2306da5876f (diff)
downloadmoa-id-spss-76dd4489a0b0b93ff08c7c684ca229df6f29c0cb.tar.gz
moa-id-spss-76dd4489a0b0b93ff08c7c684ca229df6f29c0cb.tar.bz2
moa-id-spss-76dd4489a0b0b93ff08c7c684ca229df6f29c0cb.zip
Revert "change PKIX chaining mode constant"
This reverts commit 6c9e452d5ab984c1ef221c4a2e746454aa41e014.
Diffstat (limited to 'id')
-rw-r--r--id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/data/GeneralMOAIDConfig.java6
-rw-r--r--id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/config/legacy/BuildFromLegacyConfig.java13
-rw-r--r--id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/config/legacy/ConfigurationBuilder.java5
-rw-r--r--id/server/moa-id-commons/src/main/resources/config/moaid_config_2.0.xsd2
4 files changed, 14 insertions, 12 deletions
diff --git a/id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/data/GeneralMOAIDConfig.java b/id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/data/GeneralMOAIDConfig.java
index a052f403b..773dd8e7c 100644
--- a/id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/data/GeneralMOAIDConfig.java
+++ b/id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/data/GeneralMOAIDConfig.java
@@ -307,11 +307,7 @@ public class GeneralMOAIDConfig {
ChainingModeType defaultmode = modes.getSystemDefaultMode();
if (defaultmode != null) {
- if (ConfigurationBuilder.CM_CHAINING.equals(defaultmode.value()))
- defaultchainigmode = ChainingModeType.CHAIN.value();
-
- else
- defaultchainigmode = defaultmode.value();
+ defaultchainigmode = defaultmode.value();
}
diff --git a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/config/legacy/BuildFromLegacyConfig.java b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/config/legacy/BuildFromLegacyConfig.java
index 9d105f151..7039bdb7f 100644
--- a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/config/legacy/BuildFromLegacyConfig.java
+++ b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/config/legacy/BuildFromLegacyConfig.java
@@ -446,8 +446,17 @@ public class BuildFromLegacyConfig {
//set chaining modes
ChainingModes moa_chainingModes = new ChainingModes();
moaIDConfig.setChainingModes(moa_chainingModes);
-
- ChainingModeType type = ChainingModeType.fromValue(builder.getDefaultChainingMode());
+
+
+
+ String defaultmode = builder.getDefaultChainingMode();
+ ChainingModeType type;
+ if (defaultmode.equals(iaik.pki.pathvalidation.ChainingModes.CHAIN_MODE))
+ type = ChainingModeType.CHAINING;
+ else
+ type = ChainingModeType.PKIX;
+
+
moa_chainingModes.setSystemDefaultMode(type);
Map<IssuerAndSerial, String> chainingModes = builder.buildChainingModes();
diff --git a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/config/legacy/ConfigurationBuilder.java b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/config/legacy/ConfigurationBuilder.java
index 682b00702..6ad45d8c9 100644
--- a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/config/legacy/ConfigurationBuilder.java
+++ b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/config/legacy/ConfigurationBuilder.java
@@ -113,7 +113,7 @@ public class ConfigurationBuilder {
// chaining mode constants appearing in the configuration file
//
/** an XPATH-Expression */
- public static final String CM_CHAINING = "chaining";
+ protected static final String CM_CHAINING = "chaining";
/** an XPATH-Expression */
protected static final String CM_PKIX = "pkix";
/** an XPATH-Expression */
@@ -939,13 +939,10 @@ public List getTrustedTemplateURLs() {
protected String translateChainingMode(String chainingMode) {
if (chainingMode.equals(CM_CHAINING)) {
return ChainingModes.CHAIN_MODE;
-
} else if (chainingMode.equals(CM_PKIX)) {
return ChainingModes.PKIX_MODE;
-
} else {
return ChainingModes.CHAIN_MODE;
-
}
}
diff --git a/id/server/moa-id-commons/src/main/resources/config/moaid_config_2.0.xsd b/id/server/moa-id-commons/src/main/resources/config/moaid_config_2.0.xsd
index 269da4cd6..e6705dbb8 100644
--- a/id/server/moa-id-commons/src/main/resources/config/moaid_config_2.0.xsd
+++ b/id/server/moa-id-commons/src/main/resources/config/moaid_config_2.0.xsd
@@ -569,7 +569,7 @@
<xsd:element name="TrustProfileID" type="xsd:string"/>
<xsd:simpleType name="ChainingModeType">
<xsd:restriction base="xsd:string">
- <xsd:enumeration value="chain"/>
+ <xsd:enumeration value="chaining"/>
<xsd:enumeration value="pkix"/>
</xsd:restriction>
</xsd:simpleType>